0

The data which we send via Ethereum blockchain , is it ecrypted and sent to sender only & never stored on blockchain OR is it hashed ?

Hashing is a one way process . It means that the data once hashed can't be reverted back to its original form. So if it is hashed then how sender gets the original message ?

1
  • What data are you referring to? There's transaction data sent to node, input data sent to contracts, value data transferred between accounts, etc.
    – Kof
    Commented May 4, 2022 at 12:26

2 Answers 2

0

The data which we send via Ethereum blockchain , is it ecrypted and sent to sender only & never stored on blockchain OR is it hashed ?

It is not encrypted, but signed with ECDSA which includes a hashing operation using keccak256 in the case of Ethereum. This means that you are sending both the clear data (e.g., Transaction) and your signature (e.g., r, s, v).

That way, the recipent(s) can check the validity of your tx data AND ensure through signature verification that the sender has the required keys to send a transaction from the account defined in the from field of the transaction.

0

Let’s have a closer look at the input parameter 0x6898f82b0000000000000000000000000000000000000000000000000000000000000066 (transaction data) in below screenshot of a sample Transaction done in Remix.

Transaction

This hex value consists of two parts. The first four bytes (6898f82b) specify which function to call. It’s generated using the Keccak-256 hash of the function’s name and arguments otherwise known as function signature.

Starting from the fifth byte in the hex value, the encoded arguments follow. i.e. whatever the user passed as arguments to the function. Each argument is represented by the hex value of the input padded to 32 bytes. Hex of 102 is 66.

For more detailed explanation on the same click here.

Your Answer

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

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