I can't find much documentation on this, is it possible to encrypt/decrypt data within a tezos smart contract? So how would I do something like AES crypto (although does not matter much) in a smart contract?
2 Answers
There are currently no encrypt/decrypt instructions for Michelson. You can view the full list of instructions here: http://tezos.gitlab.io/mainnet/whitedoc/michelson.html
It's not clear what decrypting data from within a smart contract would achieve since all operations are public.
-
obviously all transactions and data is public, encryption in a smart contract could be used to implement something like a vickery auction (en.wikipedia.org/wiki/Vickrey_auction) - all bidders send in their bid during bid period, bids only get known to public after bid period is over. btw this is not an answer this should have been a comment. Feb 3, 2019 at 17:41
-