Skip to content
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

Vähennetään apigw:stä tulevia turhia virhehälyjä #6382

Merged
merged 3 commits into from
Feb 14, 2025

Conversation

Gekkio
Copy link
Contributor

@Gekkio Gekkio commented Feb 13, 2025

  • virheelliset auth-kutsut kiinni heti apigw:ssä -> ei enää Spring-virheitä no GET endpoint /citizen/auth/...
  • anti-CSRF-virheet pois lokeilta kokonaan
  • korjataan bugi SAML logout-käsittelyssä jossa ei huomioitu try/catch -blokkia ennen mahdollisesti tulevia virheitä, jotka lensi ylätasolle yleiseen virhelokitukseen

For some reason we sometimes receive GET requests to SAML login endpoints,
but there's no handler for the request ends up getting proxied to
evaka-service, which logs noisy errors.

It's better to just redirect to the corresponding app root in apigw,
because all valid auth routes are there so we know any other routes
don't exist and will just lead to an error later.
These errors are noisy, and seem to nowadays happen only when some bots
hammer our APIs with random requests.
- move to a separate function
- call the function inside try/catch -> errors are handled instead of
  thrown to generic error middleware
@Gekkio Gekkio added the tech Tekninen muutos, esim. refaktorointi label Feb 13, 2025
@Gekkio Gekkio merged commit 012c67b into master Feb 14, 2025
30 checks passed
@Gekkio Gekkio deleted the reduce-apigw-noise branch February 14, 2025 11:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
tech Tekninen muutos, esim. refaktorointi
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants