php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #59374 Crashes on certain input
Submitted: 2010-08-18 23:13 UTC Modified: 2010-11-14 10:02 UTC
From: michal dot takacs at gmail dot com Assigned:
Status: Closed Package: bbcode (PECL)
PHP Version: 5.3.2 OS: Linux CentOS 5 x64
Private report: No CVE-ID: None
 [2010-08-18 23:13 UTC] michal dot takacs at gmail dot com
Description:
------------
When a [url] has another malformed nested [url] in it, it 
crashes the PHP process upon parsing.

Reproduce code:
---------------
I already fixed the input in the database.

Sorry I cannot really reproduce easily, I'd have to restore a massive several - GB database. If you guys really need this, I'll do it.

Basically the input was something like:

[url="here was the URL"][b]Text]url=".."here it was kind of repeated]

Expected result:
----------------
Parsed BB code.

Actual result:
--------------
Crash

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2010-09-27 05:19 UTC] clyde dot semeleer at valtaf dot nl
Hi, we also have a related bug. We use the tag [url] in 2 
different ways. For example links for specific url's we use: 
[url="http://google.com"]google.com[/url]

On our website we also have some blogs, we customized the 
url tag to also accept id's for example [url=1234]some 
text[/url]. All the above works fine. 

The problem is when a user uses [url="1234]some text[/url] 
(which is wrong), we would expect the parser to ignore the 
text as this is not valid bbcode. Instead we get a 
segmentation fault error!
 [2010-09-27 06:29 UTC] xdecock at gmail dot com
Can you try the svn version?

I'll need to add some test case and probably rebuild a new release as a set of patches are waiting in svn for now.

Xavier.
 [2010-11-13 06:02 UTC] felixjet at gmail dot com
just asking, are you void (or any other) going to repackage 
this to compile against PHP 5.3 ? anytime soon? this bbcode 
parser is 10x faster than any other, keep up the good work
 [2010-11-14 10:02 UTC] xdecock at gmail dot com
Thank you for your bug report. This issue has been fixed
in the latest released version of the package, which you can download at
http://pecl.php.net/get/bbcode

Fixes Released in new beta
 
PHP Copyright © 2001-2021 The PHP Group
All rights reserved.
Last updated: Thu Dec 02 10:03:34 2021 UTC