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

Provide feedback on Decoding v4 third party block with a biscuit-auth v5 backend #39

Open
CleverAkanoa opened this issue Aug 7, 2024 · 2 comments

Comments

@CleverAkanoa
Copy link

I don't know if its the right repository.

Description

The biscuitsec.org provides a web-component to decode existing Biscuit, unfortunately a breaking changes in biscuit-auth/biscuit@c87cbb5 forbids to decode v4 Biscuit.

On the website side, a "Please enter a base64-encoded token" is thrown but in the console the real error is displayed.

called `Result::unwrap()` on an `Err` value: Format(DeserializationError("deserialization error: third-party blocks must be v5"))

This error should be shown to users.

@divarvel
Copy link
Collaborator

divarvel commented Aug 7, 2024

Token parsing happens here https://github.com/biscuit-auth/biscuit-component-wasm/blob/main/src/parse_token.rs#L29 the parsing error is returned as is.

So the issue is probably in https://github.com/biscuit-auth/biscuit-web-components/blob/main/src/bc-token-printer.ts
this is good news because this only requires changing the TS side of things.

To start a dev server, you can run npm run serve, this should get you started.

@CleverAkanoa
Copy link
Author

Great, I'll try to fix it, thanks for pointers

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

No branches or pull requests

2 participants