-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Protect eoAPI's STAC API Transaction Extension endpoints #101
Comments
Decision from meeting today: We will start by trying to solve this simple case using the API Gateway (APISIX + KeyCloak or OPA) and configure two routes on the same application to behave differently:
There are indications that HTTP method-based auth should be possible with APISIX https://apisix.apache.org/docs/ingress-controller/concepts/apisix_route/#advanced-routing This will follow the example of the Workspace API, which is currently under development. |
Linking related issues about authentication and API gateway:
For reference, these are the endpoints and their http methods we want to protect:
|
from @achtsnits
|
Plan from here:
|
Related to issues #90 and #12
The STAC API, part of EOEPCA's eoAPI, requires protection for its CRUD operation endpoints as defined by the STAC API Transaction Extension. Authentication for these endpoints will be managed through the project's Keycloak instance.
We are currently evaluating several approaches for securing these endpoints:
Application runtime integration: One approach is to integrate endpoint protection directly within the application runtime by leveraging stac-fastapi-pgstac alongside eoapi-auth-utils. This solution offers a straightforward way to implement authentication within the STAC API component itself.
Dedicated auth proxy: Another option is to deploy the lightweight proxy stac-auth-proxy between the internal STAC API endpoints and the ingress. This proxy would handle authentication for the designated endpoints, providing a clean separation between the API logic and the authentication layer. Additionally, it offers flexibility, as it integrates seamlessly within the same ecosystem as the application.
Kubernetes ingress proxy: Leveraging Kubernetes Ingress for authentication is another potential solution. While this can offer a centralized mechanism for securing the API, it has limitations that make it more complicated compared to the other options. Kubernetes Ingress is not primarily designed for handling authentication, and its configuration can become complex when enforcing fine-grained access control for specific endpoints.
API Gateway: Finally, we are considering managing authentication and protection for all STAC API endpoints through the project’s apisix API Gateway. This approach would centralize access control, but it may introduce additional limitations in terms of functionality and customization.
I currently favor the second approach using a proxy. This would allow us to continue running eoAPI without modifying the packaged runtime, while also providing greater flexibility.
Acceptance criteria
The text was updated successfully, but these errors were encountered: