Questions tagged [bcrypt]

bcrypt is an implementation of the Blowfish cipher and a computationally-expensive hash function mostly used for password hashing.

bcrypt is an implementation of the Blowfish cipher and a computationally-expensive hash function mostly used for password hashing.

Resources

2290 questions
0
votes
0 answers

HEROKU 20 - RUBY 2.7.2 / 401 Unauthorized Error

I have a problem with ruby. In my current project the version of ruby is 2.5.7. As Heroku 16 is deprecated soon, i update the version to 2.7.2. ~ $ ruby -v ruby 2.7.2p137 (2020-10-01 revision 5445e04352) [x86_64-linux] ~ $ rails -v Rails 5.2.4 ~ $…
Lola_Padilya
  • 107
  • 1
  • 7
0
votes
1 answer

Password authentication method is giving success, on failure

I'm trying to authenticate my user given password with the one that is hashed in the DB, but I think I'm comparing the both given? Is there a better (or proper) way to do this? I'm also not sure what exception I should use for the password not…
user15424420
0
votes
1 answer

BCrypt rawPassword cannot be null Spring

I have following problem : There was an unexpected error (type=Internal Server Error, status=500). rawPassword cannot be null java.lang.IllegalArgumentException: rawPassword cannot be null This is my SecurityConfig class package…
Spectra
  • 61
  • 3
  • 8
0
votes
1 answer

Mongoose bcrypt set password and saving asynchronously

I have a mongoose schema: UserSchema.methods.setPassword = function (password) { bcrypt.hash(password, saltRounds).then(function (hash) { this.hash = hash; }); }; and here is how I create the user object: router.post('/signup',…
hedgehog
  • 3
  • 2
0
votes
1 answer

Unable to build TypeScript application in Docker due to bcrypt / Make issue

I have a GraphqQL backend application which I've forked from https://github.com/w3tecch/express-typescript-boilerplate I've been building my fork of the app in Docker successfully for a long time, however it suddenly started failing out of the blue…
Oliver Caine
  • 648
  • 7
  • 9
0
votes
2 answers

i can't run this command with my project npm run sample

this is my package.json I have downloaded the project and I am trying to run this in my pc Heading and I can't run this because I face an error i wanna know what I should do to resolve it { "name": "ng-contact-manager", "version": "0.0.0", …
0
votes
2 answers

How use bcrypt on 2 properties

I use bcrypt on mongo project, i need to use this one on properties Password and email, but I don't know how to use it on 2 properties exports.signup = (req, res, next) => { bcrypt.hash(req.body.password, 10) .then(hash => { const user =…
user15121115
0
votes
1 answer

why bcryptjs compare gives null value even though hash used is generated one?

FOr authentication purpose, I'm storing the hashed password in MongoDB when I try to compare this password for the same string bcryptjs throws a null value. where it stores hashed password in Binary form for string '123'. here is my generating…
Nikhil R
  • 95
  • 4
  • 13
0
votes
0 answers

why am I getting password mismatch by bcrypt compare even though both password and hashed password from database matches?

For user authentication, I'm storing passwords by hashing using bcrypt which is stored in MongoDB cluster but when I try to authenticate the user using the same string I get the wrong comparison with bcrypt.compare says mismatch. Here is the code…
Nikhil R
  • 95
  • 4
  • 13
0
votes
0 answers

bcrypt is causing POST request 500?

I have no idea why but I’ve started getting these errors on Vercel, but no issues on LocalHost, even doing yarn build && yarn start I have made sure that I'm using CORS in Next.js And my api code import bcrypt from 'bcrypt' import {…
Marius
  • 1,664
  • 2
  • 16
  • 28
0
votes
2 answers

Why am I getting isMatch null from bcrypt compare even though two password string matches perfectly?

I'm trying to authenticate the user based on a password. I'm using bcrypt compare to compare user requested password and one in mongodb but even though two password matches perfectly I get null value, here is the code which I"m…
Nikhil R
  • 95
  • 4
  • 13
0
votes
2 answers

Nodejs Mongoose Bcrypt when i change hash password i cant login back

When i renew password I cant login back. giving response password is not match error but if I dont renew my password I can login. Step 1 (Register) Customer.findOne({$or:[{email:user.email},{username:user.username}]},function(err,data){ …
Enes
  • 55
  • 1
  • 5
0
votes
1 answer

Can we generate BCrypt / SCrypt / Argon2 hash password using CNG (Windows Cryptography API)?

Is it possible with the CNG (Windows Cryptography API: Next Generation) to generate BCrypt / SCrypt / Argon2 hash password ? BCrypt is a computationally difficult algorithm designed to store passwords by way of a one-way hashing function. You input…
zeus
  • 12,173
  • 9
  • 63
  • 184
0
votes
1 answer

Issue while calling hash method

Im trying to create simple login app with MERN stack and i have an issue while using bcrypt to hash my password. server.js const mongoose = require("mongoose"); const express = require("express"); const cors = require("cors"); const passport =…
IgorYzk
  • 31
  • 3
0
votes
0 answers

I have a problem with BCRYPT Compare with NodeJs Comparing password from Mysql Database

I used Bcryptjs to encrypt a password stored in mysql database. The Problem I have is the login porcess trying to compare the password in the Mysql Database to the login password.The Error message is what I get below. (node:3616)…
user3239115