Skip to content

Conjugation Key-Based Conjugation

Engine.conjugate(ciphertext, conjugation_key)
Returns the conjugate of the input ciphertext. In general, does not consume any level. A level is consumed only if the operation is not a multiparty computation and the ciphertext is at the maximum allowable level for a given parameter.
  • Input:
    • Ciphertext
    • ConjugationKey
  • Output:
    • Ciphertext
from desilofhe import Engine

engine = Engine()
secret_key = engine.create_secret_key()
public_key = engine.create_public_key(secret_key)
conjugation_key = engine.create_conjugation_key(secret_key)

message = [1, 2, 3]
ciphertext = engine.encrypt(message, public_key)
conjugated_ciphertext = engine.conjugate(ciphertext, conjugation_key)

Plaintext Conjugation

Engine.conjugate(plaintext)
Returns the conjugate of the input plaintext.
  • Input:
    • Plaintext
  • Output:
    • Plaintext
from desilofhe import Engine

engine = Engine()

message = [1, 2, 3]
plaintext = engine.encode(message)
conjugated_plaintext = engine.conjugate(plaintext)