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

Security fix for 31 rounds salts #24

Closed
wants to merge 1 commit into from

Conversation

tanertopal
Copy link

In case 31 rounds are used

rounds = 1 << rounds;

rounds = 1 << rounds;

will result in -2147483648 rounds which produces a useless hash.

@dcodeIO dcodeIO closed this in dd6eaf7 Aug 2, 2015
tanertopal added a commit to tanertopal/bcrypt.js that referenced this pull request Aug 3, 2015
* commit 'dd6eaf724afc72618126782de8dfb061c1a5ae90':
  Prevent integer wrap-around with 31 rounds, fixes dcodeIO#24, fixes dcodeIO#25

Conflicts:
	dist/bcrypt.js
	dist/bcrypt.min.js
	dist/bcrypt.min.map
	src/bcrypt/impl.js
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.

1 participant