{"exploit":{"id":"EDB-37521","name":"CodeIgniter 2.1 - 'xss_clean()' Filter Security Bypass","description":"CodeIgniter 2.1 - 'xss_clean()' Filter Security Bypass","cves":["CVE-2012-1915"],"author":"Krzysztof Kotowicz","published":"2012-07-19","platform":"php","type":"webapps","language":"Text","source":"exploit-db","sourceUrl":"https://www.exploit-db.com/exploits/37521","path":"exploits/php/webapps/37521.txt","revision":"8a926a9b85beb3bccd6e8016211fdb73e904b52b","filename":"EDB-37521.txt","vulnerabilities":[{"id":"CVE-2012-1915","state":"PUBLISHED","title":null,"titleSource":null,"description":"EllisLab CodeIgniter 2.1.2 allows remote attackers to bypass the xss_clean() Filter and perform XSS attacks.","descriptionSource":"CVE Program","descriptionUrl":"https://www.cve.org/CVERecord?id=CVE-2012-1915","cvss":{"version":"3.1","baseScore":6.1,"severity":"medium","vectorString":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N","source":"NVD","sourceUrl":"https://nvd.nist.gov/vuln/detail/CVE-2012-1915"},"updatedAt":"2024-08-06T19:17:27.287Z","retrievedAt":"2026-11-27T08:09:16.690Z","stale":false,"error":null}],"imageUrl":"https://exploitbin.com/social/exploits/EDB-37521.png?v=2","url":"https://exploitbin.com/exploits/EDB-37521","downloadUrl":"https://exploitbin.com/api/v1/exploits/EDB-37521/download","codeUrl":"https://exploitbin.com/api/v1/exploits/EDB-37521/code","licenseUrl":"https://exploitbin.com/sources#exploit-db"},"code":"source: https://web.archive.org/web/2012/https://www.securityfocus.com/bid/54620/info\n\nCodeIgniter is prone to a security-bypass vulnerability.\n\nAn attacker can exploit this issue to bypass XSS filter protections and perform cross-site scripting attacks.\n\nCodeIgniter versions prior to 2.1.2 are vulnerable.\n\n----------------------------------------\n\nBuild an application on CodeIgniter 2.1.0:\n\n// application/controllers/xssdemo.php\n<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');\n\nclass Xssdemo extends CI_Controller {\n\n        public function index() {\n            $data['xss'] =\n$this->security->xss_clean($this->input->post('xss'));\n            $this->load->view('xssdemo', $data);\n        }\n}\n\n// application/views/xssdemo.php\n<form method=post>\n                <textarea name=xss><?php echo htmlspecialchars($xss);\n?>&lt;/textarea&gt;\n                <input type=submit />\n                </form>\n        <p>XSS:\n        <hr />\n    <?php echo $xss ?>\n\nLaunch http://app-uri/index.php/xssdemo and try above vectors.","sha256":"2f547daf4256b4438511c208e9b27c4a232d8bc86b56282f7e05b0be17bf0548","bytes":1048,"fetchedAt":"2026-11-27T08:09:15.044Z","encoding":"utf-8 (display only; download retains original bytes)"}