Question: I have strange question to you, when I built a simple spring boot application I created for testing that everything working as it should a simple Controller called HomeController.java, but when I go to address in my case 'localhost:5000/app' I thought that there should appear Hello World! but it redirect me to address 'localhost:5000/login' and a login form box appear. Can someone explain me what happend?

```
@Controller
public class HomeController {

   @RequestMapping(value = "/app")
    public String index() {
        return "Hello World!";
    }
}

```

Answer: 
Just create a class for security configuration like this

```
    @Configuration
    @EnableWebSecurity
    public class SecurityConfiguration extends WebSecurityConfigurerAdapter {

        @Override
        protected void configure(HttpSecurity http) throws Exception {

            http
                    .authorizeRequests()
                    .antMatchers("/app/**",).permitAll();      

    }

```
That's because you are not allowing anonymous access to your `/app` url, which in return redirects you to the login form as to authenticate the user. You would need to add the following configuration to your spring security.

```
.authorizeRequests()
        .antMatchers("/app/**")
        .permitAll()

```

The `**` will allow any matches with the entire directory tree, including subdirectories.