Name | ez_credentials JSON |
Version |
1.2.3
JSON |
| download |
home_page | None |
Summary | Easy credentials management using keyring |
upload_time | 2024-12-07 06:53:41 |
maintainer | Christophe Druet |
docs_url | None |
author | Christophe Druet |
requires_python | <3.13,>=3.10 |
license | MIT |
keywords |
credentials
keyring
|
VCS |
|
bugtrack_url |
|
requirements |
No requirements were recorded.
|
Travis-CI |
No Travis.
|
coveralls test coverage |
No coveralls.
|
# Easy credentials
Simple set of classes to manage credentials (user/pwd, token...)
## Installation
Classic through pip or your favourite package manager:
```shell
pip install ez-credentials
```
## Usage
Instantiate a credential manager. The instance is callable and returns the credentials. You can also get the credentials as a dictionnary or as a tuple.
```python
from ez_credentials import CredentialManager
cred = CredentialManager('test')
cred()
```
You'll be prompted for your credentials. They will be stored in your keyring.
'test' is the name of the service. You can define several credential managers with different service names.
Optionally, you cat set how long the credentials should be stored, i.e. how frequently the password is asked for.
This is defined in seconds, and default to 30 days.
```python
from time import sleep
from ez_credentials import CredentialManager
cred = CredentialManager('test', expires_in=1)
cred()
sleep(1)
cred()
```
There are other classes (TokenManager, TokenCredentialManager, WebServiceTokenManager and WebServiceTorkenManager; and some aliases).
Raw data
{
"_id": null,
"home_page": null,
"name": "ez_credentials",
"maintainer": "Christophe Druet",
"docs_url": null,
"requires_python": "<3.13,>=3.10",
"maintainer_email": "christophe@stoachup.com",
"keywords": "credentials, keyring",
"author": "Christophe Druet",
"author_email": "christophe@stoachup.com",
"download_url": "https://files.pythonhosted.org/packages/d5/d7/ad9cf4ed81410109cf248e28bc7a2742e5f57f79c32b800c689003a0fae1/ez_credentials-1.2.3.tar.gz",
"platform": null,
"description": "# Easy credentials\n\nSimple set of classes to manage credentials (user/pwd, token...)\n\n## Installation\n\nClassic through pip or your favourite package manager:\n\n```shell\npip install ez-credentials\n```\n\n## Usage\n\nInstantiate a credential manager. The instance is callable and returns the credentials. You can also get the credentials as a dictionnary or as a tuple.\n\n```python\nfrom ez_credentials import CredentialManager\n\ncred = CredentialManager('test')\n\ncred()\n```\n\nYou'll be prompted for your credentials. They will be stored in your keyring. \n\n'test' is the name of the service. You can define several credential managers with different service names.\n\nOptionally, you cat set how long the credentials should be stored, i.e. how frequently the password is asked for.\nThis is defined in seconds, and default to 30 days.\n\n```python\nfrom time import sleep\nfrom ez_credentials import CredentialManager\n\ncred = CredentialManager('test', expires_in=1)\n\ncred()\nsleep(1)\ncred()\n```\n\nThere are other classes (TokenManager, TokenCredentialManager, WebServiceTokenManager and WebServiceTorkenManager; and some aliases).\n",
"bugtrack_url": null,
"license": "MIT",
"summary": "Easy credentials management using keyring",
"version": "1.2.3",
"project_urls": null,
"split_keywords": [
"credentials",
" keyring"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "aa32b569f68fa509f63ee7fef7f7904a02e1ac508be044b45532dd37650d72bc",
"md5": "dddb0e5cba6e233ca7ebbd5a2cadf656",
"sha256": "90d48995ba57c253433e17dc163687986fc21224f5b07104d2b92e2d9de401f2"
},
"downloads": -1,
"filename": "ez_credentials-1.2.3-py3-none-any.whl",
"has_sig": false,
"md5_digest": "dddb0e5cba6e233ca7ebbd5a2cadf656",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": "<3.13,>=3.10",
"size": 10495,
"upload_time": "2024-12-07T06:53:39",
"upload_time_iso_8601": "2024-12-07T06:53:39.789599Z",
"url": "https://files.pythonhosted.org/packages/aa/32/b569f68fa509f63ee7fef7f7904a02e1ac508be044b45532dd37650d72bc/ez_credentials-1.2.3-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "d5d7ad9cf4ed81410109cf248e28bc7a2742e5f57f79c32b800c689003a0fae1",
"md5": "40dab937fbedf2b16e3a52b0abc30bea",
"sha256": "02d7ed8bf67701503e8691a8db5372f3ee9727e78c2b65469a5a85f44ebd29b2"
},
"downloads": -1,
"filename": "ez_credentials-1.2.3.tar.gz",
"has_sig": false,
"md5_digest": "40dab937fbedf2b16e3a52b0abc30bea",
"packagetype": "sdist",
"python_version": "source",
"requires_python": "<3.13,>=3.10",
"size": 10085,
"upload_time": "2024-12-07T06:53:41",
"upload_time_iso_8601": "2024-12-07T06:53:41.372766Z",
"url": "https://files.pythonhosted.org/packages/d5/d7/ad9cf4ed81410109cf248e28bc7a2742e5f57f79c32b800c689003a0fae1/ez_credentials-1.2.3.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-12-07 06:53:41",
"github": false,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"lcname": "ez_credentials"
}