0

Let's say I bought a millions worth of USDC and sent it to a multi-sig wallet.

I'm trying to reward users in my site with USDC right away whenever they accomplished some tasks.

Is it possible to automate this process from the backend using web3.js?

I just want to know if it's a safe thing to do and possible to avoid sending tokens to each user manually whenever they completed tasks.

3
  • 1
    If it's possible for anyone to determine that the tasks have been accomplished by user x, then you can put a different private key on each server. Those servers will poll the contract to check if the tasks have been accomplished by user x, and then each one of them will sign the transaction. In order to hack your system, one would need to hack each one of your servers. Commented Sep 7, 2020 at 21:31
  • Thanks, this sounds alright too. What do you think about HSM?
    – bbusdriver
    Commented Sep 7, 2020 at 21:53
  • That's an additional layer of security. What I've mentioned is just the basic requirement - a logical condition which all servers can verify before signing. Any other protection on top of it (HSM, HTTPS, etc) is unrelated of Ethereum. Commented Sep 8, 2020 at 6:29

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.