Spring MVC Security Thymeleaf | Login and Register Form

Поділитися
Вставка
  • Опубліковано 18 гру 2024

КОМЕНТАРІ • 10

  • @creumakuzola4227
    @creumakuzola4227 Місяць тому +1

    Excellent and very clear tutorial. It was very easy for me to understand. Thank you sir

  • @kutman.eshenkulov
    @kutman.eshenkulov 8 місяців тому +1

    Thank you for your insightful and up-to-date video, it cleared up the confusion caused by outdated tutorials and deprecated methods.

  • @gianbox12
    @gianbox12 7 місяців тому

    Hey, thanks you for the up to date info, i have some problems with login and database authentication, can u make a video expaining it?

  • @robottalks7312
    @robottalks7312 4 місяці тому

    Thank you

  • @joseluizdurigon8893
    @joseluizdurigon8893 7 місяців тому

    What if i want to persist the password and username (basically all the User data) in the database and retrieve from it?

  • @thangbui-hd5le
    @thangbui-hd5le 7 місяців тому

    There seems to be a problem with authentication when an account exists but the wrong password is entered. Does anyone have a solution?

    • @thangbui-hd5le
      @thangbui-hd5le 7 місяців тому

      I fixed by add one line of code "authenticationManagerBuilder.parentAuthenticationManager(null);" to authenticationManager method in SecurityConfig class. This is modified code: @Bean
      public AuthenticationManager authenticationManager(HttpSecurity http) throws Exception {
      AuthenticationManagerBuilder authenticationManagerBuilder = http.getSharedObject(AuthenticationManagerBuilder.class);
      authenticationManagerBuilder.parentAuthenticationManager(null);
      authenticationManagerBuilder.userDetailsService(userDetailsService()).passwordEncoder(passwordEncoder());
      return authenticationManagerBuilder.build();
      }

  • @joaogabriel443
    @joaogabriel443 7 місяців тому

    When you have a username but the password is incorrect it goes into an infinite loop of database queries, does anyone know how to fix it?

    • @thangbui-hd5le
      @thangbui-hd5le 6 місяців тому

      I fixed it by add this one line of code "authenticationManagerBuilder.parentAuthenticationManager(null);" to authenticationManager method in SecurityConfig class.

    • @banananana8944
      @banananana8944 21 день тому

      I got a same problem, and looking for solution too