Introduce client API tokens.

Review Request #13032 — Created May 19, 2023 and submitted — Latest diff uploaded

Information

Review Board
release-5.0.x

Reviewers

This change introduces client API tokens which are API tokens that belong
specifically to a given client. Clients (e.g. RBTools) will use these tokens
to authenticate to Review Board. These tokens are important for an upcoming
change that allows users to authenticate clients to Review Board via a
web-based login flow.

During the web-based login flow, client API tokens are automatically created
if they do not exist or if previous client tokens are expired. Each client
will have their own client tokens, and the tokens will be marked with a note
that says the token was automatically created for the given client.

  • Ran unit tests.
  • Tested creating a normal token and saw the right email being sent.
  • Tested creating a client token and saw the right email being sent.
  • Manually tested with the upcoming client web-based login flow change.

Changes between revision 1 and 2

orig
1
2

Commits

Summary ID Author
Add support for client API tokens.
3964adb643332b05aee8ff74d4df3722e8326b6e Michelle Aubin
Add support for client API tokens.
98e1dc56139935bbc7bb26c58727b00680da7888 Michelle Aubin
reviewboard/notifications/tests/test_email_sending.py
reviewboard/templates/notifications/api_token_created.html
reviewboard/templates/notifications/api_token_created.txt
reviewboard/webapi/managers.py
reviewboard/webapi/models.py
reviewboard/webapi/tests/test_managers.py
Loading...