
Standalone
Stealth Addresses

Part III
Unlocking Stealth Addresses
CursedGrimoires now supports stealth transfers. But the receiver will still have to compute their own private keys.
This can be done like so:
The recipient scans through the history of emitted
StealthTransferevents.For each
publishedDataX/publishedDataYpair, the user generates a corresponding address (with their private key).If the address matches the emitted
stealthRecipientaddress, the user can conclude that they are the designated recipient of the stealth transfer.The recipient can then compute and store the private key to the stealth address, effectively gaining ownership of the transferred token.
Let us see how we can implement step 4.
Your Task
input/stealthTransfer.json contains a StealthTransfer event designated to a recipient with private key:
Private key: 0xdeadbeefdeadbeefdeadbeefdead...Compute the private key of stealthRecipient and log your answer in output/stealthRecipient.json.
// In output/stealthRecipient.json
{
"privateKey": "{YOUR_ANSWER}"
}Run tests in Questplay
Submit work in Questplay

You have a rough idea on how to implement such a secret system. Can you figure out the rest of the pieces?