{"id":19621300,"url":"https://github.com/commenthol/bcrypt-password-hash","last_synced_at":"2026-06-10T18:31:45.841Z","repository":{"id":66111659,"uuid":"139355974","full_name":"commenthol/bcrypt-password-hash","owner":"commenthol","description":"hash password with bcrypt","archived":false,"fork":false,"pushed_at":"2018-07-01T19:35:22.000Z","size":20,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-09-06T14:45:51.417Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"unlicense","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/commenthol.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2018-07-01T19:26:51.000Z","updated_at":"2018-07-01T19:38:07.000Z","dependencies_parsed_at":"2023-03-05T15:30:42.210Z","dependency_job_id":null,"html_url":"https://github.com/commenthol/bcrypt-password-hash","commit_stats":{"total_commits":2,"total_committers":1,"mean_commits":2.0,"dds":0.0,"last_synced_commit":"ee2b5ccca04d20ad1c2b3ccad811f71f04028f16"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/commenthol/bcrypt-password-hash","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/commenthol%2Fbcrypt-password-hash","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/commenthol%2Fbcrypt-password-hash/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/commenthol%2Fbcrypt-password-hash/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/commenthol%2Fbcrypt-password-hash/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/commenthol","download_url":"https://codeload.github.com/commenthol/bcrypt-password-hash/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/commenthol%2Fbcrypt-password-hash/sbom","scorecard":{"id":300796,"data":{"date":"2025-08-11","repo":{"name":"github.com/commenthol/bcrypt-password-hash","commit":"ee2b5ccca04d20ad1c2b3ccad811f71f04028f16"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":1.7,"checks":[{"name":"Token-Permissions","score":-1,"reason":"No tokens found","details":null,"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Code-Review","score":0,"reason":"Found 0/2 approved changesets -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Dangerous-Workflow","score":-1,"reason":"no workflows found","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"SAST","score":0,"reason":"no SAST tool detected","details":["Warn: no pull requests merged into dev branch"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"Pinned-Dependencies","score":-1,"reason":"no dependencies found","details":null,"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: The Unlicense: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"Vulnerabilities","score":0,"reason":"31 existing vulnerabilities detected","details":["Warn: Project is vulnerable to: GHSA-6chw-6frg-f759","Warn: Project is vulnerable to: GHSA-v88g-cgmw-v5xw","Warn: Project is vulnerable to: GHSA-93q8-gq69-wqmw","Warn: Project is vulnerable to: GHSA-5wg4-74h6-q47v","Warn: Project is vulnerable to: GHSA-v6h2-p8h4-qcjw","Warn: Project is vulnerable to: GHSA-c6rq-rjc2-86v2","Warn: Project is vulnerable to: GHSA-3xgq-45jj-v275","Warn: Project is vulnerable to: GHSA-hr2v-3952-633q","Warn: Project is vulnerable to: GHSA-43f8-2h32-f4cj","Warn: Project is vulnerable to: GHSA-qqgx-2p2h-9c37","Warn: Project is vulnerable to: GHSA-2pr6-76vf-7546","Warn: Project is vulnerable to: GHSA-8j8c-7jfh-h6hx","Warn: Project is vulnerable to: GHSA-4xc9-xhrj-v574","Warn: Project is vulnerable to: GHSA-x5rq-j2xg-h7qm","Warn: Project is vulnerable to: GHSA-jf85-cpcp-j695","Warn: Project is vulnerable to: GHSA-p6mc-m468-83gw","Warn: Project is vulnerable to: GHSA-29mw-wpgm-hmr9","Warn: Project is vulnerable to: GHSA-35jh-r3h4-6jhm","Warn: Project is vulnerable to: GHSA-f8q6-p94x-37v3","Warn: Project is vulnerable to: GHSA-vh95-rmgr-6w4m","Warn: Project is vulnerable to: GHSA-xvch-5gv4-984h","Warn: Project is vulnerable to: GHSA-hj48-42vr-x3v9","Warn: Project is vulnerable to: GHSA-c2qf-rxjj-qqgw","Warn: Project is vulnerable to: GHSA-j44m-qm6p-hp7m","Warn: Project is vulnerable to: GHSA-3jfq-g458-7qm9","Warn: Project is vulnerable to: GHSA-r628-mhmh-qjhw","Warn: Project is vulnerable to: GHSA-9r2w-394v-53qc","Warn: Project is vulnerable to: GHSA-5955-9wpr-37jh","Warn: Project is vulnerable to: GHSA-qq89-hq3f-393p","Warn: Project is vulnerable to: GHSA-f5x3-32g6-xq36","Warn: Project is vulnerable to: GHSA-52f5-9888-hmc6"],"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}}]},"last_synced_at":"2025-08-17T20:34:48.215Z","repository_id":66111659,"created_at":"2025-08-17T20:34:48.215Z","updated_at":"2025-08-17T20:34:48.215Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":34165482,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-06-10T02:00:07.152Z","response_time":89,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-11T11:22:18.180Z","updated_at":"2026-06-10T18:31:45.824Z","avatar_url":"https://github.com/commenthol.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# bcrypt-password-hash\n\n\u003e hash password with bcrypt\n\n[![NPM version](https://badge.fury.io/js/bcrypt-password-hash.svg)](https://www.npmjs.com/package/bcrypt-password-hash/)\n\nGeneration and validation of passwords using bcrypt hashes.\nUses same api as [pbkdf2-password-hash](https://www.npmjs.com/package/pbkdf2-password-hash).\n\nRequires node \u003e= v8.0.0\n\n## TOC\n\n\u003c!-- !toc (minlevel=2 omit=\"TOC\") --\u003e\n\n* [Example](#example)\n* [API](#api)\n  * [`hash(password, [salt], [opts])`](#hashpassword-salt-opts)\n  * [`compare(password, passwordHash)`](#comparepassword-passwordhash)\n* [Installation](#installation)\n* [Tests](#tests)\n* [LICENSE](#license)\n\n\u003c!-- toc! --\u003e\n\n## Example\n\nGenerate new password hash\n\n```js\nconst passwordHash = require('bcrypt-password-hash')\n\n// generates random salt\npasswordHash.hash('password')\n  .then((hash) =\u003e {\n    //\u003e hash === 'bcrypt$2b$10$Y6MKD5ZI5gtkvBdYyqwr1.CrHA66ppM/9YNDvacUuqWZSVduKQcIq'\n  })\n```\n\nGenerate password hash with different options\n\n```js\npasswordHash.hash('password', {saltRounds: 14})\n.then((hash) =\u003e {\n  //\u003e hash === 'bcrypt$2b$14$9zjobUQJ9LVswQrQJ7leKe6NnJKMc3ZouykkhZZ6uFa9ARMZVSUgy'\n})\n```\n\nValidate password hash\n\n```js\nconst hash = 'bcrypt$2b$14$9zjobUQJ9LVswQrQJ7leKe6NnJKMc3ZouykkhZZ6uFa9ARMZVSUgy'\npasswordHash.compare('password', hash)\n.then((isValid) =\u003e {\n  //\u003e isValid === true\n})\n```\n\n## API\n\n\u003ca name=\"hashpassword-salt-opts\"\u003e\u003c/a\u003e\n### `hash(password, [salt], [opts])`\n\nGenerate a new password hash for password using [bcrypt][].\n\n**Parameters**\n\n| parameter              | type   | description                      |\n| ---------------------- | ------ | -------------------------------- |\n| `password`             | String |                                  |\n| `[salt]`               | String | _optional:_ salt                 |\n| `[opts.saltRound=10]`  | Number | _optional:_ number of iterations |\n\n**Returns** `Promise`, hashed password in `bcrypt$\u003cversion\u003e$\u003csaltRound\u003e$\u003csalt\u003e\u003chash\u003e` notation.\n\n\u003ca name=\"comparepassword-passwordhash\"\u003e\u003c/a\u003e\n### `compare(password, passwordHash)`\n\nvalidate password against passwordHash\n\n**Parameters**\n\n| parameter      | type   | description         |\n| -------------- | ------ | ------------------- |\n| `password`     | String | plain-text password |\n| `passwordHash` | String | hashed password     |\n\n**Returns** `Promise`, true if hash matches password\n\n## Installation\n\nRequires [nodejs](http://nodejs.org/) \u003e= v8.0.0\n\n```sh\n$ npm install --save bcrypt-password-hash\n```\n\n## Tests\n\n```sh\n$ npm test\n```\n\n## LICENSE\n\nUNLICENSE \u003chttps://unlicense.org\u003e\n\n[bcrypt]: https://www.npmjs.com/package/bcrypt\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcommenthol%2Fbcrypt-password-hash","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcommenthol%2Fbcrypt-password-hash","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcommenthol%2Fbcrypt-password-hash/lists"}