Firstly thank you for all your efforts. I checked out your project from your blog "Securing Spring Boot application with Keycloak"
My Keycloak setup is a little different in that it is on another server. However I have configured everything exactly as you have explained. BTW I am also using Java 14, Spring Boot 2.5.0 and Keycloak 13.0.0
When I run the project unchanged and click on the Customer List link on the index page I get the following error:
javax.servlet.ServletException: Circular view path [customers]: would dispatch back to the current handler URL [/customers] again. Check your ViewResolver setup! (Hint: This may be the result of an unspecified view, due to default view name generation.)
So I change the following in the controller:
@GetMapping(path = "/listCustomers")
public String getCustomers(Model model){
model.addAttribute("customers", Arrays.asList("John Smith","Uncle Tom","Fred Flinstone"));
return "customers";
}
I also change the index.html:
<a href="/listCustomers">Customer List</a>
and the application.properties:
keycloak.security-constraints[0].securityCollections[0].patterns[0]=/listCustomers/*
However now I after I successfully login I get a Whitelabel Error Page when I actually expect to see the list of clustomers. There are no errors or logs that I can see.
What have I missed?
Firstly thank you for all your efforts. I checked out your project from your blog "Securing Spring Boot application with Keycloak"
My Keycloak setup is a little different in that it is on another server. However I have configured everything exactly as you have explained. BTW I am also using Java 14, Spring Boot 2.5.0 and Keycloak 13.0.0
When I run the project unchanged and click on the Customer List link on the index page I get the following error:
javax.servlet.ServletException: Circular view path [customers]: would dispatch back to the current handler URL [/customers] again. Check your ViewResolver setup! (Hint: This may be the result of an unspecified view, due to default view name generation.)
So I change the following in the controller:
I also change the index.html:
and the application.properties:
However now I after I successfully login I get a Whitelabel Error Page when I actually expect to see the list of clustomers. There are no errors or logs that I can see.
What have I missed?