29 Commits

Author SHA1 Message Date
104a6c6bf5 Inject every models variations and DB model in DB adapters (#84)
* Inject every model variations in router and DB model in DB adapters

* Update documentation and import Tortoise in db module

* Use path operation decorator dependencies for superuser routes
2020-01-04 15:36:34 +01:00
49deb437a6 Fix #42: multiple authentication backends (#47)
* Revamp authentication to allow multiple backends

* Make router generate a login route for each backend

* Apply black

* Remove unused imports

* Complete docstrings

* Update documentation

* WIP add cookie auth

* Complete cookie auth unit tests

* Add documentation for cookie auth

* Fix cookie backend default name

* Don't make cookie return a Response
2019-12-04 13:32:49 +01:00
59b8f144d7 Bump fastapi from 0.43.0 to 0.44.0 (#63)
* Bump fastapi from 0.43.0 to 0.44.0

Bumps [fastapi](https://github.com/tiangolo/fastapi) from 0.43.0 to 0.44.0.
- [Release notes](https://github.com/tiangolo/fastapi/releases)
- [Changelog](https://github.com/tiangolo/fastapi/blob/master/docs/history-design-future.md)
- [Commits](https://github.com/tiangolo/fastapi/compare/0.43.0...0.44.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

* Fix breaking changes and depreciation following fastapi 0.44.0

* Bump fastapi==0.44.0 in pyproject.toml
2019-11-28 07:33:38 +01:00
658161518a Add error codes on routes (#34)
Fix #33
2019-10-31 10:10:53 +01:00
b512197094 Use singular Event enum name 2019-10-31 09:59:41 +01:00
f6ab644691 Apply Black formatting 2019-10-29 13:35:38 +01:00
9b7ec58800 #21: Add superuser routes (#30)
* Add CRU superuser routes

* Add delete method on DB adapters

* Add superuser delete route

* Add superuser routes documentation

* Pass black formatter
2019-10-29 13:32:44 +01:00
3506df31e7 Add ON_AFTER_REGISTER event handler 2019-10-25 08:28:29 +02:00
008a8296f2 Define on_after_forgot_password with a decorator 2019-10-24 09:18:07 +02:00
e146e4bca4 Fix #13: add /me update route 2019-10-20 10:11:48 +02:00
1996ed69ea Fix #14: add /me route 2019-10-20 09:30:26 +02:00
8d65a11a4f Fix #17: prevent to set is_active/is_superuser on register route 2019-10-19 18:56:54 +02:00
5d4979f9a9 Fix #19: 201 status code on successful registration 2019-10-19 18:36:57 +02:00
a4171f8bea Fix #18: check for existing user on registration 2019-10-19 18:31:08 +02:00
f2892aa378 #5 Improve test coverage (#6)
* Improve test coverage of BaseUserDatabase

* Improve unit test isolation

* Improve coverage of router and authentication
2019-10-15 07:54:53 +02:00
49daeff869 Close #3: forgot/reset password routes 2019-10-13 12:05:10 +02:00
9e1fd76f30 Add more docstrings 2019-10-10 19:03:52 +02:00
0112e700ac Improve typing and make User pydantic models dynamic 2019-10-10 13:37:52 +02:00
af63280cf7 Use snake case for user_db variable 😱 2019-10-10 07:27:53 +02:00
d781a41872 Install Black formatter 2019-10-09 16:52:06 +02:00
9f04b7cc89 Ensure hashed_password is not output on register success 2019-10-08 17:23:14 +02:00
06dd8ad22e Implement JWT authentication 2019-10-08 17:18:38 +02:00
20aa806375 Rename DB classes 2019-10-07 17:34:12 +02:00
20bb285f03 Use built-in OAuth2PasswordRequestForm for login 2019-10-06 14:02:42 +02:00
4ff6e2ad2b Add inactive user handling 2019-10-06 13:23:08 +02:00
a81b438ec9 Implement authentication mechanism 2019-10-06 11:53:42 +02:00
bcc88a8b14 Implement working SQLAlchemy DB adapter 2019-10-06 11:00:24 +02:00
552f313d76 Add database abstraction 2019-10-06 08:53:13 +02:00
4e0b0f6f7d Start foundations 2019-10-05 17:39:37 +02:00