cloudoperators / heureka

Security and compliance management
Apache License 2.0
3 stars 1 forks source link

feat(authN): Implement Token Based Authentication (#83) #191

Closed michalkrzyz closed 1 month ago

michalkrzyz commented 2 months ago

Add middleware layer for API access. Token auth can be set by AUTH_TYPE=token, when token base authentication is used then AUTH_TOKEN_MAP has to be provided with scaner names and their secrets.

dorneanu commented 2 months ago

Please also add the passing of the Authentication information as context to the Application.

So on the Application Layer we are later on able to access e.g. the "username"

Here is some example how to do it: https://blog.meain.io/2024/golang-context/#context.withvalue

dorneanu commented 1 month ago

Please also make sure you merge the commits from main into this branch as well (before squash&merge into main).