def create_symmetric_decryption_ctx(self, cipher, mode):
     if isinstance(mode, GCM):
         return _GCMCipherContext(
             self, cipher, mode, self._lib.kCCDecrypt
         )
     else:
         return _CipherContext(self, cipher, mode, self._lib.kCCDecrypt)
Esempio n. 2
0
 def create_symmetric_decryption_ctx(self, cipher, mode):
     if isinstance(mode, GCM):
         return _GCMCipherContext(
             self, cipher, mode, self._lib.kCCDecrypt
         )
     else:
         return _CipherContext(self, cipher, mode, self._lib.kCCDecrypt)