mirror of
https://github.com/vacp2p/linea-monorepo.git
synced 2026-01-09 20:27:58 -05:00
* did poc for autogenerated *.mdx into docs.linea.build * changed sparseMerkleProof * first draft of contracts-docgen * fix typos * try different github token * cleanup * created create-docs-website-pr-branch * cleanup for doc website repo scripts * created first docs-repo pr using create-docs-website-pr-branch.sh * improve comments * added bash script segment to change filename to lowercase * fix *.mdx headers to make more docusarus friendly * update scripts for updated docs pr * added comments to updateSidebar.js * fix scripts after local test * added installation checks * Update contracts/docs/scripts/create-docs-website-pr-branch.sh Co-authored-by: The Dark Jester <thedarkjester@users.noreply.github.com> Signed-off-by: kyzooghost <73516204+kyzooghost@users.noreply.github.com> --------- Signed-off-by: kyzooghost <73516204+kyzooghost@users.noreply.github.com> Co-authored-by: The Dark Jester <thedarkjester@users.noreply.github.com>
25 lines
869 B
Plaintext
25 lines
869 B
Plaintext
# `MessageHashing`
|
|
|
|
### _hashMessage
|
|
|
|
```solidity
|
|
function _hashMessage(address _from, address _to, uint256 _fee, uint256 _valueSent, uint256 _messageNumber, bytes _calldata) internal pure returns (bytes32 messageHash)
|
|
```
|
|
|
|
Hashes messages using assembly for efficiency.
|
|
|
|
_Adding 0xc0 is to indicate the calldata offset relative to the memory being added to.
|
|
If the calldata is not modulus 32, the extra bit needs to be added on at the end else the hash is wrong._
|
|
|
|
#### Parameters
|
|
|
|
| Name | Type | Description |
|
|
| ---- | ---- | ----------- |
|
|
| _from | address | The from address. |
|
|
| _to | address | The to address. |
|
|
| _fee | uint256 | The fee paid for delivery. |
|
|
| _valueSent | uint256 | The value to be sent when delivering. |
|
|
| _messageNumber | uint256 | The unique message number. |
|
|
| _calldata | bytes | The calldata to be passed to the destination address. |
|
|
|