decentralized-identity / decentralized-identity/web5-rs

(Feature): Add command and functionality to parse/decode signed JWT in Web5 CLI

Open
#327 13 comments 0 reactions 1 assignee Claimed by @0x-aut View on GitHub
hacktoberfest medium
Dominant language
Kotlin
Stars
19
Forks
15
PR merge metrics
No merged PRs in 30d

Description

## 🚀 Goal
Add a new feature to the Web5 Rust CLI that allows users to parse or decode JSON Web Tokens (JWTs).

## 🔑 Tasks
- [ ] Create a new command for parsing/decoding JWTs (e.g., `web5 jwt decode`)
- [ ] Implement the logic to decode and display the header, payload, and signature of a JWT
- [ ] Add options to format the output (e.g., pretty-print JSON)
- [ ] Implement error handling for invalid JWTs
- [ ] Add appropriate documentation to [README](https://github.com/TBD54566975/web5-rs/blob/main/crates/web5_cli/README.md) for the new command
- [ ] Write tests to ensure the feature works correctly
- [ ] Update the CLI's help information to include the new command

## 🌟 Resources
- [Current Web5 Rust CLI README](https://github.com/TBD54566975/web5-rs/blob/main/crates/web5_cli/README.md)
- [Web5 Rust CLI Source Code](https://github.com/TBD54566975/web5-rs/tree/main/crates/web5_cli/src)
- [Web5 Documentation on parsing signed JWT](https://developer.tbd.website/docs/web5/verifiable-credentials/jwt-to-vc)
- [Web5 CLI built in Go for reference](https://github.com/TBD54566975/web5-go/tree/main/cmd/web5)
- [JWT.io](https://jwt.io/)
- [RFC 7519: JSON Web Token (JWT)](https://tools.ietf.org/html/rfc7519)

## ⚡ Getting Started
1. Comment ".take" on this issue to get assigned
2. Fork the repository and create a new branch for this task
3. Update the documentation as described in the tasks
4. Submit a pull request with your changes
5. Respond to any feedback during the review process

## 💭 Questions?
If you have any questions or need clarification, please comment on this issue or join our [Discord](https://discord.gg/tbd) community.
Happy coding! 🎉

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.