39 Commits

Author SHA1 Message Date
Josh Cummings
531c5cafdc
Standardize Mocked Request Paths
Historically, Spring Security tests have set the servlet path
to indicate the path of a MockHttpServletRequest. This was needed
for AntPath and MvcRequestMatcher to correctly match the
specified request path.

This can leave MockHttpServletRequest in an inconsistent state
since requestURI is null while servletPath has a value.

For example, PathPatternRequestMatcher does not use the servlet path.
For tests to continue working both before and after the migration
from AntPath/MvcRequestMatcher to PathPatternRequestMatcher, the
mock requests should have a consistent representation of path
in getRequestURI and getServletPath.

This commit updates classes to use TestMockHttpServletRequests,
which ensures that the given path is applied to the servletPath and
requestURI, while also overriding with contextPath, servletPath,
and pathInfo when necessary.
2025-07-02 13:18:09 -06:00
chao.wang
16fd24c002 Add JdbcAssertingPartyMetadataRepository
Closes gh-16012

Signed-off-by: chao.wang <chao.wang@zatech.com>
2025-06-11 18:08:31 -06:00
Rob Winch
04f530bc1b
opensamlFiveTest.extendsFrom testRuntimeOnly
Issue gh-16756
2025-03-17 15:41:07 -05:00
Rob Winch
05116eabbd
Merge branch '6.3.x' into 6.4.x
- adb303e Add testRuntimeOnly junit-platform-launcher

Closes gh-16756
2025-03-17 14:18:49 -05:00
Rob Winch
adb303e152
Add testRuntimeOnly junit-platform-launcher
Closes gh-16755
2025-03-17 14:16:44 -05:00
Josh Cummings
08d1be5774
Fix Build to Add Missing Tests
Issue gh-11658
2024-08-06 18:14:12 -06:00
Josh Cummings
1da383b360
Add OpenSAML 5 Support
Issue gh-11658
2024-08-06 18:14:11 -06:00
Josh Cummings
c6d6bfd74f
Move OpenSAML 4 Support to Separate Source Directory
Issue gh-11658
2024-08-06 18:14:11 -06:00
Josh Cummings
1be596bb2f
Use OpenSAML API for registration
Issue gh-11658
2024-08-06 18:14:11 -06:00
Josh Cummings
78a0173cc1
Use OpenSAML API for web
Issue gh-11658
2024-08-06 18:14:11 -06:00
Josh Cummings
bf5b334531
Use OpenSAML API for web.authentication
Issue gh-11658
2024-08-06 18:14:10 -06:00
Josh Cummings
51fc05630d
Use OpenSAML API for web.authentication.logout
Issue gh-11658
2024-08-06 18:14:10 -06:00
Josh Cummings
ff9a925e88
Use OpenSAML API for metadata
Issue gh-11658
2024-08-06 18:14:10 -06:00
Josh Cummings
80b31820cd
Use OpenSAML API in authentication
Issue gh-11658
2024-08-06 18:14:10 -06:00
Josh Cummings
416859e70e
Use OpenSAML API in authentication.logout
Issue gh-11658
2024-08-06 18:14:10 -06:00
Steve Riesenberg
d6ff58bb7f
Update Mockito to 5.5.0
Closes gh-13810
2023-09-19 10:39:03 -05:00
Rob Winch
48e31f87e4 Remove Deprecated OpenSAML 3 Support
Closes gh-10556
2022-09-20 16:57:38 -06:00
Ulrich Grave
2334610fa9 Add Jackson Support for Saml2 Module
Closes gh-10905
2022-03-01 14:17:17 -07:00
Josh Cummings
cbf0e1da68 Remove commons-logging from saml2
Issue gh-10499
2021-12-16 10:15:58 -07:00
Marcus Da Coregio
db60df2f9c Update to Spring Framework 6.0
Issue gh-10360
2021-11-01 09:02:42 -03:00
Marcus Da Coregio
010f719344 Upgrade to JDK 17
Closes gh-10343
2021-11-01 09:02:42 -03:00
Marcus Da Coregio
02b2fcc6f0 Restore ManagementConfigurationPlugin
Issue gh-9615
2021-10-05 11:23:29 -03:00
Marcus Da Coregio
d2e5f2ae0d Update Gradle to 7.2
Closes gh-9615
2021-10-04 15:19:40 -03:00
Josh Cummings
822e59af45 useJUnitPlatform for SAML 2.0 Tests
Issue gh-9467
2021-09-13 16:39:48 -06:00
Marcus Da Coregio
16e17d242e Add Saml2AuthenticationRequestRepository
Closes gh-9185
2021-07-27 14:55:53 -06:00
Rob Winch
f73f213f50 Remove DependencySetPlugin
Closes gh-10070
2021-07-12 15:31:38 -05:00
Rob Winch
1491f2e0b6 Fix saml javadoc 2021-05-17 22:39:34 -05:00
Rob Winch
eda38b8f88 opensaml fixes 2021-05-17 15:51:55 -05:00
Josh Cummings
a8a7ab4ffa
Restore spring-security-web Dependency
Issue gh-9095
2021-04-09 12:42:04 -06:00
Josh Cummings
6f79921750
Default to OpenSAML 3
- To make upgrade passive

Issue gh-9095
2021-04-06 17:11:33 -06:00
Josh Cummings
951202e797
Polish SAML 2.0 Artifacts
- Produce sources jar
- Produce Javadoc jar

Issue gh-9095
2021-04-06 17:10:53 -06:00
Rob Winch
60d3db5798 add management platform(project(":spring-security-dependencies"))
Closes gh-9540
2021-04-05 10:36:36 -05:00
Josh Cummings
d0d0a8d958 Add OpenSAML 4 Support
Closes gh-9095
2021-03-23 19:07:23 -06:00
Josh Cummings
f82190b414
Add RelyingPartyRegistrations
Closes gh-8484
2020-08-05 10:08:47 -06:00
Josh Cummings
506786f46e
Replaced Spaces with Tabs
Updated the .gradle file for SAML 2.0 Service Provider to use tabs
2020-08-05 10:08:47 -06:00
Filip Hanik
adde18b873 Revert "Merge pull request #7432 from fhanik/feature/propagate_saml_authentication_exception"
This reverts commit e9619fb0e7459528f7861faab3b06c7bb6b21bd0, reversing
changes made to 45a1490d5d713d39cad11ac2cdfddf7820e09f4b.
2019-09-24 16:05:09 -07:00
Filip Hanik
d472e99528 SAML Assertion validation should propagate errors: #7375 and #7375
Fixes gh-7377
Fixes gh-7375

https://github.com/spring-projects/spring-security/issues/7377
https://github.com/spring-projects/spring-security/issues/7375
2019-09-24 14:40:39 -07:00
Josh Cummings
c716b400a1
Update to OpenSaml 3.3.1
Fixes gh-7388
2019-09-06 07:20:13 -06:00
Filip Hanik
e9a44bc0ce HttpSecurity.saml2login() - MVP Core Code
Implements minimal SAML 2.0 login/authentication functionality with the
following feature set:

  - Supports IDP initiated login at the default url of /login/saml2/sso/{registrationId}
  - Supports SP initiated login at the default url of /saml2/authenticate/{registrationId}
  - Supports basic java-configuration via DSL
  - Provides an integration sample using Spring Boot

Not implemented with this MVP

  - Single Logout
  - Dynamic Service Provider Metadata

Fixes gh-6019
2019-09-05 14:40:08 -07:00