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

Password hash should use Argon and be usable without Nuxt context #200

Open
tobiasdiez opened this issue Oct 3, 2024 · 1 comment
Open

Comments

@tobiasdiez
Copy link

The password hashing currently uses scrpyt, with no way to change this. But Argon2 is recommended nowadays for hashing of passwords, so I think this should be the default.

Moreover, it would be nice if the password methods could be exposed, say via nuxt-auth-utils/password so that one can use them eg in tests or other contexts where nuxt is not available (eg seeding in a db). For this, maybe extract the useRuntimeConfig call and pass the config as a parameter. Alternatively, use tryUseNuxtApp to check if a nuxt app is available and only then query the runtime config.

@atinux
Copy link
Owner

atinux commented Oct 4, 2024

I decided to go with scrypt for a reason, it works on all JS runtime nowaday, once Argon2 will be supported, I will switch to it.

In the meantime, you can always use argon2 yourself.

For exporting the utils, I think if can be a good idea yes.

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