{"id":18784897,"url":"https://github.com/ghostbar/angular-zxcvbn","last_synced_at":"2026-03-11T04:04:02.932Z","repository":{"id":17845009,"uuid":"20760408","full_name":"ghostbar/angular-zxcvbn","owner":"ghostbar","description":"Simple zxcvbn directive for Angular.js","archived":false,"fork":false,"pushed_at":"2017-12-05T20:03:36.000Z","size":67,"stargazers_count":60,"open_issues_count":7,"forks_count":11,"subscribers_count":2,"default_branch":"master","last_synced_at":"2026-01-26T17:42:19.604Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ghostbar.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2014-06-12T08:38:02.000Z","updated_at":"2025-07-18T22:08:33.000Z","dependencies_parsed_at":"2022-09-11T18:32:02.961Z","dependency_job_id":null,"html_url":"https://github.com/ghostbar/angular-zxcvbn","commit_stats":null,"previous_names":["ghostbar/angular-zxcbn"],"tags_count":15,"template":false,"template_full_name":null,"purl":"pkg:github/ghostbar/angular-zxcvbn","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ghostbar%2Fangular-zxcvbn","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ghostbar%2Fangular-zxcvbn/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ghostbar%2Fangular-zxcvbn/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ghostbar%2Fangular-zxcvbn/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ghostbar","download_url":"https://codeload.github.com/ghostbar/angular-zxcvbn/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ghostbar%2Fangular-zxcvbn/sbom","scorecard":{"id":425843,"data":{"date":"2025-08-11","repo":{"name":"github.com/ghostbar/angular-zxcvbn","commit":"2bacf206895a3de5173f72bc3b24910515b3d30b"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":3.2,"checks":[{"name":"Code-Review","score":1,"reason":"Found 4/26 approved changesets -- score normalized to 1","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":"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":"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":"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":"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":"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":"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":"Vulnerabilities","score":10,"reason":"0 existing vulnerabilities detected","details":null,"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}},{"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: MIT License: 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":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 9 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}}]},"last_synced_at":"2025-08-19T02:13:25.827Z","repository_id":17845009,"created_at":"2025-08-19T02:13:25.827Z","updated_at":"2025-08-19T02:13:25.827Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30370297,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-10T21:41:54.280Z","status":"online","status_checked_at":"2026-03-11T02:00:07.027Z","response_time":84,"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-07T20:44:23.906Z","updated_at":"2026-03-11T04:04:02.909Z","avatar_url":"https://github.com/ghostbar.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# angular-zxcvbn [![Build Status](https://travis-ci.org/ghostbar/angular-zxcvbn.svg)](https://travis-ci.org/ghostbar/angular-zxcvbn) [![Code Climate](https://codeclimate.com/github/ghostbar/angular-zxcvbn/badges/gpa.svg)](https://codeclimate.com/github/ghostbar/angular-zxcvbn) [![Test Coverage](https://codeclimate.com/github/ghostbar/angular-zxcvbn/badges/coverage.svg)](https://codeclimate.com/github/ghostbar/angular-zxcvbn/coverage)\n\n[![Saucelabs Test Status](https://saucelabs.com/browser-matrix/angular-zxcvbn.svg)](https://saucelabs.com/u/angular-zxcvbn)\n\nThis is a simple directive for the [zxcvbn](https://github.com/dropbox/zxcvbn) library.\n\n## Table of Contents\n* [Installation](#installation)\n* [Usage](#usage)\n * [Attribute](#attribute) \n * [Element](#element)\n* [History](#history)\n* [Author](#author)\n* [Contributors](#contributors)\n* [License](#license)\n\n## Installation\n\nInstall with bower:\n```bash\nbower install zxcvbn angular-zxcvbn\n```\n\nInclude the following javascript source files:\n```html\n\u003cscript src='/bower_components/zxcvbn/dist/zxcvbn.js'\u003e\u003c/script\u003e\n\u003cscript src='/bower_components/angular-zxcvbn/dist/angular-zxcvbn.js'\u003e\u003c/script\u003e\n```\n\nAdd `zxcvbn` as an angular dependency. E.G. If your module is called `myApp` then you would do:\n```javascript\nangular.module('myApp', ['zxcvbn']);\n  ```\n\n## Usage\n\n##### Attribute\n\nLive plunker: \u003chttp://plnkr.co/edit/COTgky?p=preview\u003e\n\nThe main way to use the directive is as an attribute alongside the `ng-model` attribute:\n```html\n\u003cinput type='password' ng-model='userPassword' zxcvbn=\"passwordStrength\"\u003e\n```\nThis will set `$scope.passwordStrength` to the [result](https://github.com/dropbox/zxcvbn#usage) of calling the zxcvbn function on \n`$scope.userPassword`.\n\n---\n##### Extras\n\nThe directive has an optional attribute of `zx-extras`. This takes either an `array` or an [angular form object](https://docs.angularjs\n.org/api/ng/type/form.FormController), which will be passed as the optional argument to the `zxcvbn` call. \n\n\u003e The optional argument is an array of strings that zxcvbn will treat as an extra dictionary. This can be whatever list of strings you like, but is meant for user inputs from other fields of the form, like name and email. That way a password that includes a user's personal information can be heavily penalized. This list is also good for site-specific vocabulary — Acme Brick Co. might want to include ['acme', 'brick', 'acmebrick', etc]. \n**-- \u003ccite\u003ezxcvbn readme.md\u003c/cite\u003e**\n\nExample:\n```html\n\u003cform name=\"myForm\"\u003e\n  \u003cinput type=\"email\" ng-model=\"email\" name=\"emailAddress\"\u003e\n  \u003cinput type=\"text\" ng-model=\"username\" name=\"username\"\u003e\n  \u003cinput type=\"password\" ng-model=\"password\" name=\"password\" zxcvbn=\"passwordStrength\" zx-extras=\"myForm\"\u003e\n  \u003cinput type=\"password\" ng-model=\"confirmPassword\" name=\"confirmPassword\"\u003e\n\u003c/form\u003e\n```\nWe pass `zx-extras` the value `myForm`, which is the value of the `name` attribute of the parent `\u003cform\u003e` element.\n\n`angular-zxcvbn` will look at all `\u003cinput\u003e` elements with `name` and `ng-model` attributes inside the `\u003cform\u003e` element -  *ignoring \nfields with 'password' in their name*. Found fields are then used as the extras parameter in the zxcvbn call.\n\n**Note:** if you do not wish to pass in a form object, you can also pass a scope variable that is an *array of strings*.\n\n---\n##### Form Validation\n\nIf you are using the [AngularJS form directive](https://docs.angularjs.org/api/ng/directive/form) you may also want to have the password field marked as \ninvalid when below a certain score. \n\nThis can be done by passing a `zx-min-score` attribute, which takes an integer between 0 and 4 inclusive. For example: `zx-min-score=\"2\"` \nwould invalidate passwords with scores 0 or 1. \n\n```html\n\u003cinput type=\"password\" ng-model=\"password\" name=\"password\" zxcvbn=\"passwordStrength\" zx-min-score=\"2\"\u003e\n```\n\nYou can also pass an interpolated scope value: `zx-min-score=\"{{ minScore }}\"`\n\n---\n### Element\n\nYou can use the directive as an element. The element takes 3 attributes:\n* `password`\u003csub\u003e**required**\u003c/sub\u003e - the password that you want to be tested (scope variable).\n* `extras`\u003csub\u003e*optional*\u003c/sub\u003e - an array of strings that zxcvbn will use to get a better \"crack time\" estimate. *Here you would normally have other form fields such as name, email address, username...*\n* `data`\u003csub\u003e*optional*\u003c/sub\u003e - a scope object that will contain the [returned data](https://github.com/dropbox/zxcvbn#usage) from the zxcvbn call.\n\n```html\n\u003czxcvbn password='passwordVar' extras='extrasArray' data='zxcvbnData'\u003e\u003c/zxcvbn\u003e\n```\n\nLive plunker: \u003chttp://plnkr.co/edit/CYtyRA?p=preview\u003e\n\n## Changelog ##\n\nRefer to the [CHANGELOG](CHANGELOG) file.\n\n## Author ##\n\n© 2014, Jose Luis Rivas, \u003cme@ghostbar.co\u003e.\n\n## Contributors ##\n\n2015, James Clark, \u003cjames.clark92@hotmail.co.uk\u003e\n\n2016, Giovanni Pellerano, \u003cgiovanni.pellerano@evilaliv3.org\u003e\n\n## License ##\n\nThe files are licensed under the MIT terms.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fghostbar%2Fangular-zxcvbn","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fghostbar%2Fangular-zxcvbn","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fghostbar%2Fangular-zxcvbn/lists"}