Agent SDK
Public Member Functions | List of all members
ionicsdk.cryptocipher.CryptoCipherBase Class Reference

Root Cipher class that defines the interface and includes a number of utility functions shared by all Cipher classes. More...

Inheritance diagram for ionicsdk.cryptocipher.CryptoCipherBase:
ionicsdk.cryptocipher.AesCtrCipher ionicsdk.cryptocipher.AesGcmCipher

Public Member Functions

def encryptstr (self, plaintext)
 Encrypts a Unicode or UTF-8 encoded string in memory. More...
 
def encryptbytes (self, plaintextbytes)
 Encrypts a byte array in memory. More...
 
def decryptstr (self, ciphertext)
 Decrypts ciphertext in memory to a unicode string. More...
 
def decryptbytes (self, ciphertext)
 Decrypts ciphertext in memory to a byte array. More...
 

Detailed Description

Root Cipher class that defines the interface and includes a number of utility functions shared by all Cipher classes.

Member Function Documentation

§ decryptbytes()

def ionicsdk.cryptocipher.CryptoCipherBase.decryptbytes (   self,
  ciphertext 
)

Decrypts ciphertext in memory to a byte array.

Throws an exception on any error.

Parameters
ciphertext(bytes): The bytes to decrypt
Returns
(bytes) The decrypted bytes

§ decryptstr()

def ionicsdk.cryptocipher.CryptoCipherBase.decryptstr (   self,
  ciphertext 
)

Decrypts ciphertext in memory to a unicode string.

Throws an exception on any error.

Parameters
ciphertext(bytes): The bytes to decrypt
Returns
(unicode) The decrypted string

§ encryptbytes()

def ionicsdk.cryptocipher.CryptoCipherBase.encryptbytes (   self,
  plaintextbytes 
)

Encrypts a byte array in memory.

Throws an exception on any error.

Parameters
plaintextbytes(bytes): The bytes to encrypt
Returns
(bytes) The encrypted bytes

§ encryptstr()

def ionicsdk.cryptocipher.CryptoCipherBase.encryptstr (   self,
  plaintext 
)

Encrypts a Unicode or UTF-8 encoded string in memory.

Throws an exception on any error.

Parameters
plaintext(unicode or UTF-8 string): The text to encrypt
Returns
(bytes) The encrypted bytes

The documentation for this class was generated from the following file: