From d3fbe07c907c56ac417df7cb2bf90ffcfd73c8c0 Mon Sep 17 00:00:00 2001 From: nejdet Date: Wed, 3 Aug 2016 17:23:59 -0400 Subject: [PATCH] Padding for `base64.b64decodestring` changed into `b'==='`. Fixes #6 --- stegano/tools.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/stegano/tools.py b/stegano/tools.py index 16490e0..eba4be7 100755 --- a/stegano/tools.py +++ b/stegano/tools.py @@ -107,9 +107,7 @@ def base642binary(b64_fname): #b64_str = fin.read() #fin.close() # Decode base64 string to original binary sound object - missing_padding = 4 - len(b64_fname) % 4 - if missing_padding: - b64_fname += b'='* missing_padding + b64_fname += b'===' return base64.decodestring(b64_fname) #return base64.b64decode(b64_fname)