stacks-network / sbtc-bridge-web

Web tool to facilitage peg operations for sBTC
https://sbtc.world
GNU Affero General Public License v3.0
14 stars 5 forks source link

[...] or you can specify a different address if preferred. #284

Open U00A3 opened 9 months ago

U00A3 commented 9 months ago

It seems that depositing or withdrawing to a different account is impossible or I'm doing something wrong :)

2023-10-27 13_27_18-Leather 2023-10-27 13_32_40-sBTC Bridge - Dashboard

friedger commented 9 months ago

You can specify a different stx address, not a different bitcoin address.

When signing, you account in Leather wallets must be the same account as the one you used to log in to the sbtc bridge. Otherwise, you get this nice little message from Leather wallet:

image

radicleart commented 9 months ago

@U00A3 - thanks for posting..

The quick answer is that the error Unable to sign PSBT at index... usually means the wallet is connected to a different account to the app.

Try changing the the wallet account and retrying the UI.

radicleart commented 9 months ago

The longer answer is that it depends what you mean by account.

For deposits you can

a) change the stacks address and have your sBTC minted to any stacks principal - including contract principals

b) change the bitcoin address - say you wish to deposit from an Electrum wallet. You can change the btc address to your electrum wallet and click continue. The next screen will have a button to show the PSBT allowing you to copy paste it into Electrum. From there you can sign and broadcast.

For Withdrawals you can;

a) change the btc address to withdraw the funds to - it defaults to you current Leather/Xverse payment address but its up to you.

you can't change the stacks address for withdrawals as you need to validate that you control the stacks address by signing a message.

Macxim commented 9 months ago

We could still probably improve the UX here anyway.

radicleart commented 9 months ago

keeping this open for now as the functionality to test depositing form the bridge into a contract is yet to be tested.

U00A3 commented 9 months ago

When I try to withdraw BTC to another account, the app ignores the address I entered. The sign Message contains the address connected to the sBTC bridge. When I confirm the transaction, nothing happens.

I'll do more tests tomorrow :)

2023-10-27 20_09_58-sBTC Bridge - Dashboard