vendor:
phpWebNews
by:
sToRm
7.5
CVSS
HIGH
SQL Injection
89
CWE
Product Name: phpWebNews
Affected Version From: 0.2
Affected Version To: 0.2
Patch Exists: N/A
Related CWE: N/A
CPE: a:phpwebnews:phpwebnews:0.2
Metasploit:
N/A
Other Scripts:
N/A
Tags: N/A
CVSS Metrics: N/A
Nuclei References:
N/A
Nuclei Metadata: N/A
Platforms Tested: N/A
2008
phpWebNews v0.2 MySQL Edition (Surat kabar/News Management Online) SQL Injection
Here, we have a classic SQL MySQL injection. The GET variable 'id_kat' isn't sanitized before being passed to the query. By injecting our string, the query becomes: select * from berita where status='tampil' and kode_kategori=null UNION ALL SELECT 1,2,3,4,concat(user,0x3a,passwd),6,7,8,9,10,11,12,13 FROM user-- and isi_berita like %'$m_txt'% order by tgl desc. The comment renders the rest of the query to be useless. We are effectively grabbing the first user from the table 'user', which is the admin. You can inject the other strings with server variables and attempt to fetch mysql.user hashes, if the conditions apply.
Mitigation:
Sanitize user input before passing it to the query.