php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #62314 strip_tags - Only one iteration
Submitted: 2012-06-13 15:31 UTC Modified: 2012-06-14 12:09 UTC
From: FireFart at gmail dot com Assigned:
Status: Not a bug Package: *General Issues
PHP Version: Irrelevant OS:
Private report: No CVE-ID: None
 [2012-06-13 15:31 UTC] FireFart at gmail dot com
Description:
------------
The "strip_tags" function strips tags only in one iteration.
So the following string can be used to bypass the strip_tags functionality.
I'm not sure if it's a bug or a documentation issue, because a warning on the docs would also do the job.

Test script:
---------------
<scr<script></script>ipt>alert(document.cookie);</scri<script></script>pt>


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2012-06-13 15:35 UTC] FireFart at gmail dot com
-Status: Open +Status: Closed
 [2012-06-13 15:35 UTC] FireFart at gmail dot com
wrong
 [2012-06-14 12:09 UTC] rasmus@php.net
-Status: Closed +Status: Not a bug
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Feb 22 12:01:29 2024 UTC