You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
The full krakend is working fine, great job.
Except when the auth/validator returns a 403 forbidden because the Keycloak JWT hasn't the good role.
In this case, the validator jose aborts directly without adding the cors headers.
So the browser refuses to render the response to the JS.
The preflight request is OK before that request
Your configuration file:
{
"$schema": "https://www.krakend.io/schema/v2.6/krakend.json",
"version": 3,
"output_encoding": "no-op",
"extra_config": {
{{ template "cors.tmpl" . }},
"router": {
"@comment": "The health endpoint checks do not show in the logs",
"auto_options": true,
"logger_skip_paths": [
"/__health"
]
},
"telemetry/logging": {
"level": "{{ .env.logLevel }}",
"prefix": "[KRAKEND]",
"syslog": false,
"stdout": true
}
},
"endpoints": {{ template "endpoints.tmpl" . }}
}
Environment info:
docker
Describe the bug
The full krakend is working fine, great job.
Except when the auth/validator returns a 403 forbidden because the Keycloak JWT hasn't the good role.
In this case, the validator jose aborts directly without adding the cors headers.
So the browser refuses to render the response to the JS.
The preflight request is OK before that request
Your configuration file:
Commands used
How did you start the software?
Kubernetes deployment with the krakend config file as a configmap
Expected behavior
the response has the cors headers for the react application
Logs
Additional context
Add any other context about the problem here.
The text was updated successfully, but these errors were encountered: