protocol

In tf-encrypted, a protocol represents a certain type of cryptographic protocol to achieve security.

The goal is that you can easily play with or use different cryptographic methods by simply changing the protocol.

import tf_encrypted as tfe

tfe.set_protocol(tfe.protocol.SecureNN())
tf_encrypted.protocol.protocol.set_protocol(prot: Optional[tf_encrypted.protocol.protocol.Protocol]) → None[source]

Sets the global protocol. E.g. SecureNN or Pond.

Parameters:prot (Protocol) – An instance of a tfe protocol.
tf_encrypted.protocol.protocol.get_protocol() → Optional[tf_encrypted.protocol.protocol.Protocol][source]
Return type:Protocol
Returns:The global protocol.