Skip to content

feat: jwt authentication setup#253

Merged
derianrddev merged 1 commit intoKaizenode:mainfrom
Guzbyte-tech:jwt-auth-setup
Apr 26, 2025
Merged

feat: jwt authentication setup#253
derianrddev merged 1 commit intoKaizenode:mainfrom
Guzbyte-tech:jwt-auth-setup

Conversation

@Guzbyte-tech
Copy link
Contributor

📝 JWT Authentication

🛠️ Issue

📖 Description

Implements JWT-based authentication flow using Passport strategy in NestJS. This is a benchmark for future authentication implementation.

✅ Changes made

  • Installed @nestjs/jwt @nestjs/passport passport passport-jwt
  • Installed @types/passport-jwt
  • Integrated JwtModule.registerAsync with ConfigService
  • Implemented JwtStrategy for validating bearer tokens
  • Created JwtAuthGuard to protect authenticated routes
  • Create authcontroller to test implementation
  • Added test /auth/token route to issue JWTs
  • Added test /auth/profile route as a protected endpoint to test guard functionality
  • All changes are inside the apps/backend/src/auth

🖼️ Media (screenshots/videos)

Generate Token

image

Testing Protected Routes

image

📜 Additional Notes

@derianrddev derianrddev added backend ODHack13 This issue will be available ONLY during the ODHack13 labels Apr 25, 2025
Copy link
Contributor

@derianrddev derianrddev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great job! Thank you very much!

@derianrddev derianrddev merged commit 8a3aff7 into Kaizenode:main Apr 26, 2025
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backend ODHack13 This issue will be available ONLY during the ODHack13

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[FEAT]: Set Up JWT Authentication

2 participants