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

Verify chain / network on RGB invoice #362

Open
cryptoquick opened this issue Aug 29, 2023 · 6 comments
Open

Verify chain / network on RGB invoice #362

cryptoquick opened this issue Aug 29, 2023 · 6 comments
Assignees
Milestone

Comments

@cryptoquick
Copy link
Member

Different from #360; We need to verify if an invoice for the wrong network has been provided, and return an error if that is the case. We'll also need tests, and the necessary upstream functionality.

@crisdut
Copy link
Member

crisdut commented Nov 2, 2023

Hi @cryptoquick and @josediegorobles , we can make solve it, if add optional parameter in invoice called network. This maintain compatibility with other wallets and prevents the problem use invoices in wrong network. Does make sense?

@cryptoquick cryptoquick modified the milestones: 0.7.0, 0.7.1 Nov 2, 2023
@cryptoquick
Copy link
Member Author

cryptoquick commented Nov 2, 2023

This should already be on the RGB invoice struct

@crisdut
Copy link
Member

crisdut commented Nov 2, 2023

This should already be on the RGB invoice struct

Yes, but it is only used in case you know the beneficiary (see here).

@cryptoquick
Copy link
Member Author

So, that would be an invoice that includes a blinded UTXO? That's fine I think.

@crisdut
Copy link
Member

crisdut commented Nov 2, 2023

So, that would be an invoice that includes a blinded UTXO? That's fine I think.

No, RgbInvoice parse the chain only when beneficiary is a bitcoin address, not when a blind UTXO

@cryptoquick
Copy link
Member Author

cryptoquick commented Nov 2, 2023

I see. You're right, we may need to add an optional parameter to the invoice then. I'll also tag @dr-orlovsky and @fedsten on this issue so they're aware of the issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants