Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/infinum/android-complexify
An Android library which makes checking the quality of user's password a breeze.
https://github.com/infinum/android-complexify
android android-development android-library complexify edittext open-source password password-strength
Last synced: about 1 month ago
JSON representation
An Android library which makes checking the quality of user's password a breeze.
- Host: GitHub
- URL: https://github.com/infinum/android-complexify
- Owner: infinum
- Archived: true
- Created: 2016-08-03T08:41:53.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2023-12-18T09:29:06.000Z (11 months ago)
- Last Synced: 2024-09-26T01:38:41.415Z (about 1 month ago)
- Topics: android, android-development, android-library, complexify, edittext, open-source, password, password-strength
- Language: Java
- Homepage:
- Size: 184 KB
- Stars: 113
- Watchers: 25
- Forks: 10
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
- awesome-list - infinum/android-complexify - An Android library which makes checking the quality of user's password a breeze. (Java)
README
# Deprecated
This library is no longer supported and will not receive any more updates.# android-complexify
Android port of Dan Palmers's [jquery.complexify.js](https://github.com/danpalmer/jquery.complexify.js/).
## Download
Use Gradle:
```gradle
repositories {
jcenter()
}dependencies {
compile 'co.infinum:complexify-android:2.0.1'
}
```## Usage
``` java
EditText editText = (EditText) findViewById(R.id.editText); // your editText where you want to check password complexity as user writes
Complexify complexify = new Complexify(editText, new ComplexifyListener() {
@Override
public void onSuccess(boolean isValid, double complexity) {
// isValid is true if password is valid, false otherwise
// complexity is number form range [0.0, 100.0] where greater number represents greater complexity
}
});```
## Configuration
You can override the default configuration by using setters:
``` java
setBanMode(ComplexifyBanMode banMode) // use strict (don't allow substrings of banned passwords) or loose (only ban exact matches) comparisons for banned passwords. (default: ComplexifyBanMode.STRICT)
setExecuteMode(ComplexifyExecuteMode executeMode) // defines whether execution is synchronous or asynchronous. (default: ComplexifyExecuteMode.SYNC)
setStrengthScaleFactor(int strengthScaleFactor) // scale the required password strength (higher numbers require a more complex password) (default: 1)
setMinimumChars(int minimumChars) // the minimum acceptable password length (default: 8)
setBanList(String[] banList) // array of banned passwords (default: Generated from 500 worst passwords and 370 Banned Twitter lists found here)
```
## License
This code is distributed under the WTFPL v2 licence.