1
0
mirror of https://github.com/PurpleI2P/i2pd.git synced 2025-01-08 18:47:52 +00:00

Merge pull request #1946 from chadf/fuzzing-3

Fixed crash when Base64ToByteStream() is only given '=' characters.
This commit is contained in:
orignal 2023-07-10 08:00:30 -04:00 committed by GitHub
commit 8590dbd3d3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -187,6 +187,9 @@ namespace data
else else
return 0; return 0;
if(*InBuffer == P64)
return 0;
ps = (unsigned char *)(InBuffer + InCount - 1); ps = (unsigned char *)(InBuffer + InCount - 1);
while ( *ps-- == P64 ) while ( *ps-- == P64 )
outCount--; outCount--;