Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update RSKIP176 #362

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
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
4 changes: 2 additions & 2 deletions IPs/RSKIP176.md
Original file line number Diff line number Diff line change
Expand Up @@ -61,9 +61,9 @@ A new method called **registerFastBridgeBtcTransaction**() is added to the Bridg
- *bytes* **liquidityProviderBtcAddress**: Binary encoding representing the Liquidity Provider BTC refund address.
- *bool* **shouldTransferToContract**: Status provided by the caller contract to know if should transfer value to the contract or not.

To compute the UPI, the IDAs are serialized as a concatenation of derivationArgumentsHash (32 bytes), userRefundBtcAddress (21 bytes), liquidityProviderBtcAddress (21 bytes), liquidityBridgeContractAddress (20 bytes). Each argument occupies a fixed number of bytes shown in brackets. Formally, this is:
To compute the UPI, the IDAs are serialized as a concatenation of derivationArgumentsHash (32 bytes), userRefundBtcAddress (21 bytes), liquidityBridgeContractAddress (20 bytes), liquidityProviderBtcAddress (21 bytes). Each argument occupies a fixed number of bytes shown in brackets. Formally, this is:

`UPI = Keccak256(derivationArgumentsHash, userRefundBtcAddress, liquidityProviderBtcAddress , liquidityBridgeContractAddress)`
`UPI = Keccak256(derivationArgumentsHash, userRefundBtcAddress, liquidityBridgeContractAddress , liquidityProviderBtcAddress)`

The total number of bytes hashed is 94. Note that the concatenation order is different from the argument passing order.

Expand Down