php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #29605 segfault if end tag missing
Submitted: 2004-08-10 20:14 UTC Modified: 2004-08-11 08:25 UTC
From: x-penguin at tut dot by Assigned:
Status: Closed Package: XSLT related
PHP Version: 5CVS-2004-08-10 (dev) OS: Linux
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: x-penguin at tut dot by
New email:
PHP Version: OS:

 

 [2004-08-10 20:14 UTC] x-penguin at tut dot by
Description:
------------
PHP Version 5.1.0-dev, configure with:
'./configure' '--prefix=/usr/' '--with-apxs2' '--with-gettext'
'--with-iconv' '--with-mysql' '--enable-mbstring=ru' '--enable-mbregex'
'--enable-mbstr-enc-trans' '--disable-short-tags' '--with-xsl'
'--with-libxml' '--without-sqlite' '--enable-soap'

libxslt Version     1.1.8
libxml Version      2.6.11
libexslt Version    1.1.8

apache 2.0.48

Reproduce code:
---------------
<?php
$xsl = new DomDocument();
$xsl->loadXML(
'<?xml version="1.0" encoding="iso-8859-1" ?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:php="http://php.net/xsl">
<xsl:template match="/">
    <xsl:value-of select=".">
</xsl:template>
</xsl:stylesheet>'
);

$xml = new DomDocument;
$xml->loadXML('<?xml version="1.0" encoding="iso-8859-1" ?><null>ss</null>');

$proc = new XSLTProcessor();
$proc->importStylesheet($xsl);

$dom = $proc->transformToDoc($xml);
echo $dom->saveXML();
?>

Expected result:
----------------
Error message from XSLTProcessor: "Missing end tag for <xsl:value-of select=".">..."

Actual result:
--------------
from apache error log: 
[Tue Aug 10 21:12:07 2004] [notice] child pid 2353 exit signal Segmentation fault (11)

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2004-08-11 08:25 UTC] chregu@php.net
Please try using this CVS snapshot:

  http://snaps.php.net/php5-latest.tar.gz
 
For Windows:
 
  http://snaps.php.net/win32/php5-win32-latest.zip


 [2004-08-11 08:25 UTC] derick@php.net
This bug has been fixed in CVS.

Snapshots of the sources are packaged every three hours; this change
will be in the next snapshot. You can grab the snapshot at
http://snaps.php.net/.
 
Thank you for the report, and for helping us make PHP better.
 
PHP Copyright © 2001-2025 The PHP Group
All rights reserved.
Last updated: Sat Aug 16 23:00:02 2025 UTC