Metadata-Version: 2.1
Name: py-bsdauth
Version: 1.1.2
Summary: Python interface to OpenBSD's BSD Auth.
Home-page: https://github.com/rbaylon/py-bsdauth
Author: Ricardo Baylon
Author-email: rbaylon@outlook.com
License: ISC
Platform: OpenBSD
Classifier: License :: OSI Approved :: ISC License (ISCL)
Classifier: Programming Language :: Python :: 3
Description-Content-Type: text/markdown
License-File: LICENSE

# py-bsdauth

- Python interface to OpenBSD's BSD Auth
- Currently only implements auth_userokay(3) passwd authentication style.

### Note
- Your application must be in the 'auth' group to call auth_userokay(3):

```sh
usermod -G auth <yourdaemonuser>
```
 
Usage:
```sh
>>> from bsdauth.bsdauth import UserOkay
>>> u='user1'
>>> pw='goodpassword'
>>> uo=UserOkay(u,pw)
>>> uo.login()
True
>>> pw='badpassword'
>>> uo = UserOkay(u,pw)
>>> uo.login()
False
>>> ur='baduser'
>>> pw='goodpassword'
>>> uo = UserOkay(ur,pw)
>>> uo.login()
False
>>> exit()
```
