Announcement Announcement Module
No announcement yet.
Not getting 404 errors Page Title Module
Move Remove Collapse
Conversation Detail Module
  • Filter
  • Time
  • Show
Clear All
new posts

  • Not getting 404 errors

    I'm noticing that I don't get 404 errors when "nonsense" URLs are requested (ie URLs with no @RequestMapping), regardless of whether or not the user has valid credentials. I'm using the embedded Tomcat configuration with Basic HTTP authentication. I've noticed this in the logs:

    2013-11-09 09:29:51.976 INFO 931 --- [ost-startStop-1] o.s.w.s.handler.SimpleUrlHandlerMapping : Mapped URL path [/**] onto handler of type [class org.springframework.web.servlet.resource.ResourceH ttpRequestHandler]

    Which appears to be related to the WebMvcAutoConfiguration class (but Im not sure):

    I'd expect the user to get 404 errors when requesting resources that I have no request-handlers for (like "/'), regardless of login. Instead I get 401 errors (when not authenticated) and 405 errors (when authenticated). Is there a way to turn off this behavior?

  • #2
    We are currently in the process of moving to for our forums. If you're still having this issue please consider asking it again at using the #spring-boot tag. If you do post it there, please reply here with the link. Thanks!