SUSE / telemetry-server

Proof of Concept Telemetry Server scaffolding
Apache License 2.0
2 stars 0 forks source link

Use JWT based auth tokens. #36

Closed rtamalin closed 1 month ago

rtamalin commented 1 month ago

Add support for auth management settings to the server config.

Add an AuthManager to the App which provides methods for creating and validating auth tokens.

Update /register handler to generate the auth token using the new AuthManager.

Update /report handler to check for the Authorization header and fail if the provided auth token is not valid.

Updated app tests to support authentication, and verify that requests without authentication fail.

Add tests to validate the parsing of the duration specified in the server config file.

Relates: #35