Careful Decrypting
The creator of a contract must understand the implications of decryption in various scenarios. For instance, decryption should never occur within a view function without considering alternative security measures, as relying solely on msg.sender
can be unreliable due to the potential for forging.
As a general precaution, handling a call to decrypt should be approached with caution, considering the various options for invoking such a function. For example, a secret intended for a specific user should not be decrypted in a manner that exposes it to everyone.
Don't: Do not reveal data intended for a specific user to everybody
Do : Offboard
to a specific user.
Last updated