-
Notifications
You must be signed in to change notification settings - Fork 0
Home
- PasswordDB
-
Contains multiple site object and utility functions
- Site
-
Contains username, email and passwords of a user
Contains multiple site object and utility functions
Kind: global class
-
PasswordDB
- new PasswordDB(encrypted, password, options)
-
.getSite(name) ⇒
Site
- .addSite(name, site)
-
.listSites() ⇒
Array.<string>
-
.encrypt(password, options) ⇒
object
Create a new password database when no arguments given, otherwise decrypt one
Param | Type | Description |
---|---|---|
encrypted | object |
The encrypted object |
password | string |
The encryption algorithm |
options | object |
Custom crypto-json options |
passwordDB.getSite(name) ⇒ Site
Get a site object in the database
Kind: instance method of PasswordDB
Returns: Site
- The site object
Param | Type | Description |
---|---|---|
name | string |
The name of the site |
Add a new site
Kind: instance method of PasswordDB
Param | Type | Description |
---|---|---|
name | string |
The name of the site |
site | Site |
The site to add to the database |
Get a list of sites in the database
Kind: instance method of PasswordDB
Returns: Array.<string>
- Array of site names
Encrypt the database for saving
Kind: instance method of PasswordDB
Returns: object
- Encrypted database object
Param | Type | Description |
---|---|---|
password | string |
The encryption password |
options | object |
Custom crypto-json options |
Contains username, email and passwords of a user
Kind: global class
-
Site
- new Site(username, email, password)
-
.getUsername() ⇒
string
-
.getEmail() ⇒
string
-
.getPassword() ⇒
string
Create a new site object
Param | Type | Description |
---|---|---|
username | string |
The username, empty string if not specified |
string |
The E-Mail address, empty string if not specified | |
password | string |
The password, empty string if not specified |
Get the username
Kind: instance method of Site
Returns: string
- username
Get the E-Mail
Kind: instance method of Site
Returns: string
- E-Mail
Get the password
Kind: instance method of Site
Returns: string
- password