I am searching for the specification or an exact description about how the PHP serialize() function exactly works. All I could find for that topic is that comment in the manual.
Is there anywhere out there a more detailed description about how php implements this?
To truly know how PHP handles serialized strings, one would need to dig in the sourcecode as suggested by Pekka 웃 in the comments.
Try starting at: http://lxr.php.net/search?q=PHP_FUNCTION+serialize&project=PHP_5_4 which gives a convenient way to search the sources.
This link comes from http://nikic.github.io/2012/03/16/Understanding-PHPs-internal-function-definitions.html which explains how to find specific function definitions in the php source.
Goodluck!
I wanted to dig into this years ago. Warning: this blogpost is way old. I think the spec is still accurate, but ignore the content around it ;)
http://evertpot.com/133/ Jump to the section titled: The serialized data format.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With