Bug #75910 [Opn->Ver]: convert.base64-encode omits padding bytes
| From: | cmb@php.net | Date: | Sun, 08 Jul 2018 18:01:13 +0000 |
| Subject: | Bug #75910 [Opn->Ver]: convert.base64-encode omits padding bytes | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-216228@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=75910&edit=1
ID: 75910
Updated by: cmb@php.net
Reported by: me at levisflorian dot name
Summary: convert.base64-encode omits padding bytes
-Status: Open
+Status: Verified
Type: Bug
Package: Streams related
Operating System: macOS 10.13.3 (via brew)
PHP Version: 7.2.2
-Assigned To:
+Assigned To: pollita
Block user comment: N
Private report: N
New Comment:
Confirmed: <https://3v4l.org/HFW1e>.
Apparently, this regression has been introduced by commit
0a45e8f[1]. Sara, could you please have a look at this?
[1] <https://github.com/php/php-src/commit/0a45e8f096a04464bda6277c6f3d0b5461737a27>
Previous Comments:
------------------------------------------------------------------------
[2018-02-02 22:19:46] me at levisflorian dot name
Change "package" from "Filter related" to "Streams related"
------------------------------------------------------------------------
[2018-02-02 22:09:24] me at levisflorian dot name
Description:
------------
When using temp stream, filter convert.base64-encode omits padding bytes.
Actually on php 7.2.1 (instead of 7.2.2 selected above) - multiple php versions installed with
brew.sh
Found a similar bug on old php version #68532 (https://bugs.php.net/bug.php?id=68532)
Test script:
---------------
Please find test script (based on #68532) here: https://gist.github.com/Gounlaf/c54dce4f843e89d4f5814eb7790cdcd3
Expected result:
----------------
encode - low-level - memory = dGVzdA==
decode - low-level - memory = test
encode - low-level - temp = dGVzdA==
decode - low-level - temp = test
Actual result:
--------------
encode - low-level - memory = dGVzdA==
decode - low-level - memory = test
encode - low-level - temp = dGVz
decode - low-level - temp = test
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=75910&edit=1