A
A
Anton Ivanov2020-01-28 16:09:34
Java
Anton Ivanov, 2020-01-28 16:09:34

Is it possible to programmatically find out the value of the loginPage that was set when configuring Spring Security?

Hello.

I'm studying Java, I made a project in which I configure HttpSecurity and, in particular, set my loginPage.

@Configuration
public class BasicConfiguration extends WebSecurityConfigurerAdapter {
    @Override
    protected void configure(HttpSecurity http) throws Exception {
        http
...
                .and()
                .formLogin().loginPage("/sign_in").permitAll()
                .and()
                .logout().permitAll();
    }
}


Is it possible to get this value (/sign_in) programmatically to use in the view?

Thanks

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question