Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -772,6 +772,9 @@ Please note that when you configure a permissioned deploy protection, you **must

Furthermore, you can configure _only_ cross-chain redeploy protection by setting the first 20 bytes equal to the zero address `0x0000000000000000000000000000000000000000`. The rationale behind this logic is to prevent a pseudo-randomly generated 32 byte salt from inadvertently activating cross-chain redeploy protection. Also in this case, if you don't specify a cross-chain redeploy protection, i.e. the 21st byte is greater than `0x01`, the function reverts. The underlying reason for this logic is as well to enforce developer explicitness.

> [!IMPORTANT]
> When using the read-only functions [`computeCreate2Address(bytes32,bytes32)`](https://github.com/pcaversaccio/createx/blob/main/src/CreateX.sol#L600-L610) or [`computeCreate3Address(bytes32)`](https://github.com/pcaversaccio/createx/blob/main/src/CreateX.sol#L857-L867), it is essential to provide the _guarded_ `salt` value, meaning the value after being processed by the `_guard` function, as the input parameter. This ensures the correct computation of the deployment address. For more details, refer to [this issue](https://github.com/pcaversaccio/createx/issues/140).

### Pseudo-Random Salt Value

For developer convenience, the [`CreateX`](./src/CreateX.sol) contract offers several overloaded functions that generate the salt value pseudo-randomly using a diverse selection of block and transaction properties. Please note that this approach does not guarantee true randomness!
Expand Down
Loading