Function get_shared_secret
pub unconstrained fn get_shared_secret(
address: AztecAddress,
ephPk: EmbeddedCurvePoint,
) -> EmbeddedCurvePoint
pub unconstrained fn get_shared_secret(
address: AztecAddress,
ephPk: EmbeddedCurvePoint,
) -> EmbeddedCurvePoint
Returns an app-siloed shared secret between
addressand someone who knows the secret key behind an ephemeral public keyephPk. The app-siloing means that contracts cannot retrieve secrets that belong to other contracts, and therefore cannot e.g. decrypt their messages. This is an important security consideration given that both theaddressandephPkare public information.The shared secret
Sis computed as:let S = (ivsk + h) * ephPkwhereivsk + his the 'preaddress' i.e. the preimage of the address, also called the address secret. TODO(#12656): app-silo this secret