Authorization: Pre-shared bearer tokens #2

Closed
opened 2024-02-11 03:53:58 +00:00 by solao · 0 comments
Owner

Database

  • Finished

The database needs to be able to hold the token.

+--------+-------------------------------------------------+
| Column | Definition                                      |
+--------+-------------------------------------------------+
| id     | BIGINTEGER AUTO_INCREMENT PRIMARY KEY           |
| name   | VARCHAR(255) NOT NULL                           |
| token  | VARCHAR(255) NOT NULL UNIQUE KEY                |
+--------+-------------------------------------------------+

Artisan Command

  • List Command
  • Grant Command
  • Revoke Command

Base command: php artisan chaosbot:tokens
This will open a select menu for list, create, revoke.

Middleware

  • Finished

Checks the Authorization header. If the header is not present, return a 401 Unauthorized. If the header is present but there is no match in the database, return a 403 Forbidden. Otherwise proceed as planned.

### Database - [x] Finished The database needs to be able to hold the token. ``` +--------+-------------------------------------------------+ | Column | Definition | +--------+-------------------------------------------------+ | id | BIGINTEGER AUTO_INCREMENT PRIMARY KEY | | name | VARCHAR(255) NOT NULL | | token | VARCHAR(255) NOT NULL UNIQUE KEY | +--------+-------------------------------------------------+ ``` ### Artisan Command - [x] List Command - [x] Grant Command - [x] Revoke Command Base command: `php artisan chaosbot:tokens` This will open a select menu for `list`, `create`, `revoke`. ### Middleware - [x] Finished Checks the `Authorization` header. If the header is not present, return a 401 Unauthorized. If the header is present but there is no match in the database, return a 403 Forbidden. Otherwise proceed as planned.
daniel was assigned by solao 2024-02-11 03:53:58 +00:00
solao closed this issue 2024-02-11 03:53:59 +00:00
Sign in to join this conversation.
No Label
Doing
To Do
No Milestone
No project
No Assignees
1 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: FFXIV/FFXIV_Lodestone_Handler#2
No description provided.