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

Signup gautam #6

Closed
wants to merge 2 commits into from
Closed

Conversation

gautamb02
Copy link

Hey,

The issue #3

The endpoint for signup is completed!!
It consists Email Validation : where it doesn't allow the user to use invalid mail
It also has unique email feature i.e : one email can be used for only one email
Password Encryption : The password are stored in encrypted manner
JWT : JSON web token is also implemented for API calls

Regards,
Gautam B.

@Sayed-Afnan-Khazi Sayed-Afnan-Khazi linked an issue Oct 17, 2023 that may be closed by this pull request
@sikehish
Copy link
Collaborator

Good work @gautam-bhagat! Your work is under review. We will get back shortly.

@sikehish
Copy link
Collaborator

@gautam-bhagat We generate JWT token on user login, which you havent incorporated. Please include it, and also, there's no need to generate JWT on signup

@gautamb02
Copy link
Author

gautamb02 commented Oct 21, 2023

@sikehish The JWT token is generated on signup and stored!
Only while doing the login the user is provided with JWT Token! The token is never passed as response on signup!!

Copy link
Collaborator

@Sayed-Afnan-Khazi Sayed-Afnan-Khazi left a comment

Choose a reason for hiding this comment

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

Hey @gautam-bhagat,

Generating and storing JWT tokens during the signup process and saving them for future use in a database is not a common or recommended approach, as it can introduce security risks if not handled correctly. JWT tokens are usually generated each time a user logs into an app and are used to authenticate and authorize the user for subsequent requests.

TLDR; JWT tokens are not generated during the signup process but are generated and tied to the user's session after a successful login.

So,

  • Could you please move the generation of the JWT token to the login endpoint?
    This would involve moving the code that generates the JWT token to the login endpoint and changing the table's structure to remove the token attribute.
  • Also, you are not using the environment variable you've defined in the .env file

Once you do that, we can merge your PR since the remaining code is well-written.

@gautamb02 gautamb02 closed this by deleting the head repository Dec 26, 2024
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

Successfully merging this pull request may close these issues.

Create a signup endpoint
3 participants