Ejemplo n.º 1
0
 def decryption_engine(self, ReceivedCiphertext):
     print(
         "======================PLS Client Decrypting Data from Server===================="
     )
     MakePlaintext = CipherUtil.CIPHER_AES128_CBC(self.EKS, self.IVS)
     Plaintext = MakePlaintext.decrypt(ReceivedCiphertext)
     return Plaintext
Ejemplo n.º 2
0
 def encryption_engine(self, plaintext):
     print(
         "======================PLS Client Encrypting Data from Upper Layer===================="
     )
     MakeCipher = CipherUtil.CIPHER_AES128_CBC(self.EKC, self.IVC)
     Ciphertext = MakeCipher.encrypt(plaintext)
     print(
         "===============Encrypted that Data. Calling MAC Engine========================"
     )
     self.mac_engine(Ciphertext)