Fix win auth example

- Relates #165
This commit is contained in:
Janne Valkealahti
2023-04-06 07:30:54 +01:00
parent 13691aabbd
commit 1bb263182e
3 changed files with 6 additions and 7 deletions

View File

@@ -97,7 +97,7 @@ public class WebSecurityConfig {
return new SpnegoEntryPoint("/login");
}
@Bean
// @Bean
public SpnegoAuthenticationProcessingFilter spnegoAuthenticationProcessingFilter(
AuthenticationManager authenticationManager) {
SpnegoAuthenticationProcessingFilter filter = new SpnegoAuthenticationProcessingFilter();

View File

@@ -1,9 +1,9 @@
server:
port: 8080
app:
ad-domain: EXAMPLE.ORG
ad-server: ldap://WIN-EKBO0EQ7TS7.example.org/
service-principal: HTTP/neo.example.org@EXAMPLE.ORG
ad-domain: example.org
ad-server: ldap://vagrantvm.example.org
service-principal: HTTP/cypher.example.org@EXAMPLE.ORG
keytab-location: /tmp/tomcat.keytab
ldap-search-base: dc=example,dc=org
ldap-search-filter: "(| (userPrincipalName={0}) (sAMAccountName={0}))"

View File

@@ -1,11 +1,10 @@
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:th="http://www.thymeleaf.org"
xmlns:sec="http://www.thymeleaf.org/thymeleaf-extras-springsecurity3">
xmlns:sec="http://www.thymeleaf.org/extras/spring-security">
<head>
<title>Spring Security Kerberos Example</title>
</head>
<body>
<h1 th:inline="text">Hello [[${#httpServletRequest.remoteUser}]]!</h1>
<h1 th:inline="text">User principal is [[${#httpServletRequest.userPrincipal}]]!</h1>
<div th:text="${#authentication}"></div>
</body>
</html>