Changeset 35 for trunk/lib


Ignore:
Timestamp:
02/12/13 13:12:08 (12 years ago)
Author:
tmorgan
Message:

now encoding '/' in percent encoding

fixed bug in POA's stripping of pkcs5 pads

debugging statement changes

Location:
trunk/lib/bletchley
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/lib/bletchley/CBC/__init__.py

    r21 r35  
    231231        while(len(last_bytes)!=self.block_size):
    232232            last_bytes = self.decrypt_next_byte(prior, block, last_bytes)
     233
     234        self.log_message("Decrypted block: %s" % repr(last_bytes))
    233235        return last_bytes
    234236
     
    282284            decrypted = self.decrypt_block(self._iv, blocks[0]) + decrypted
    283285           
    284         return buffertools.stripPKCS7Pad(decrypted)
     286        return buffertools.stripPKCS7Pad(decrypted, self.block_size)
    285287
    286288
  • trunk/lib/bletchley/blobtools.py

    r34 r35  
    287287    def encode(self, blob):
    288288        if 'plus' in self.dialect:
    289             return urllib.quote(blob)
     289            return urllib.quote(blob, '')
    290290        else:
    291             return urllib.quote_plus(blob)
     291            return urllib.quote_plus(blob, '')
    292292
    293293
Note: See TracChangeset for help on using the changeset viewer.