Spring MVC Security Thymeleaf | Login and Register Form

Поделиться
HTML-код
  • Опубликовано: 27 ноя 2024

Комментарии • 10

  • @creumakuzola4227
    @creumakuzola4227 23 дня назад +1

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

  • @kutman.eshenkulov
    @kutman.eshenkulov 7 месяцев назад +1

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

  • @robottalks7312
    @robottalks7312 4 месяца назад

    Thank you

  • @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?

  • @joseluizdurigon8893
    @joseluizdurigon8893 6 месяцев назад

    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 6 месяцев назад

      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 6 месяцев назад

    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 18 часов назад

      I got a same problem, and looking for solution too