spring-projects / spring-projects/spring-security

Saml response verfication inside Controller

Open
#16,160 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

status: waiting-for-triage type: bug
Dominant language
Java
Stars
9.6k
Forks
6.3k
Avg merge
2d 11h
Merged PRs (30d)
52

Description

I am integrating our exsisting application with spring security. Our exsisting application triggers saml request and validates the saml response inside a controller using openam. I am able to trigger the saml request inside the servlet by redirecting to "/saml2/authenticate/" + registrationID.
But when it comes to validating the response received inside the controller I am not sure how to. I tried creating a controller mapping to "login/saml2/sso" but the spring security filters will be called first before hitting this servlet so not sure how I can validate the saml response inside the servlet and redirect to the login page or error page.

@jzheaux can you point me to the right direction how I can implement or any examples to know how to implement.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reading the issue's controller mapping for login/saml2/sso and the existing Spring Security SAML request flow around /saml2/authenticate/{registrationID}. Compare that flow with the framework's filter handling, then determine what an implementation would need to do for successful response validation and login or error redirection.

Written by the indexing model from the issue text.

Assessment

Tech stack
java, spring
Domain
authentication, backend, security
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
20/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.