mirror of
https://github.com/php/php-src.git
synced 2025-08-15 21:48:51 +02:00
base64_decode: Handle all invalid padding equally
This commit is contained in:
parent
5c62f3f68e
commit
316d5a19a6
1 changed files with 0 additions and 5 deletions
|
@ -149,11 +149,6 @@ PHPAPI zend_string *php_base64_decode_ex(const unsigned char *str, size_t length
|
|||
break;
|
||||
}
|
||||
if (ch == base64_pad) {
|
||||
/* fail if the padding character is second in a group (like V===) */
|
||||
/* FIXME: why do we still allow invalid padding in other places in the middle of the string? */
|
||||
if (i % 4 == 1) {
|
||||
goto fail;
|
||||
}
|
||||
padding++;
|
||||
continue;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue