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

Adding TOTP / 2FA to lemmy #2741

Merged
merged 9 commits into from
Mar 2, 2023
Merged

Adding TOTP / 2FA to lemmy #2741

merged 9 commits into from
Mar 2, 2023

Conversation

dessalines
Copy link
Member

The front end for this is almost done.

@dessalines dessalines requested a review from Nutomic as a code owner February 17, 2023 18:17
@Nutomic
Copy link
Member

Nutomic commented Feb 18, 2023

I think this feature will require some specific documentation so client devs know how to implement it.

@dessalines
Copy link
Member Author

I can do that, just let me know where.

@Nutomic
Copy link
Member

Nutomic commented Feb 20, 2023

Best write it in the joinlemmy docs.

@dessalines
Copy link
Member Author

I'll do that In the lemmy js client API docs.

@dessalines
Copy link
Member Author

I had to use totp_2fa, since rust doesn't allow variable names to start with numbers.

Some(site_name.to_string()),
username.to_string(),
)
.map_err(|_| LemmyError::from_message("Couldnt generate TOTP"))
Copy link
Member

Choose a reason for hiding this comment

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

Never drop errors like this.

crates/utils/src/utils/validation.rs Outdated Show resolved Hide resolved
@Nutomic
Copy link
Member

Nutomic commented Feb 25, 2023

Can you also link the docs you are writing for this so I can have a look?

@dessalines
Copy link
Member Author

These get bundled into the client docs: https://github.com/LemmyNet/lemmy-js-client/pull/106/files

@dessalines
Copy link
Member Author

This should be ready to go now.

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.

3 participants