1

Is it possible for a smart contract to access swarm-content to perform an operation? For example, lets say a user uploads a document to swarm. I would then like to take access the contents of the document from a smart contract to perform some computation on the contents of the document.

1

It is not possible. Smart contracts can only interact with data that is in EVM state.

  • Technically you can maintain a datastore on just the EVM since the contracts are in some sense forever living. When would you choose to use swarm over the EVM? Are there privacy and security benefits to using swarm? – AndroidDev93 Jan 21 '18 at 0:19
0

You could store the hash of a related content with your data in the smart contract though, allowing for application logic which can access swarm to process this association.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.