Size: a a a

Spring Framework and more

2020 May 31

z

zis in Spring Framework and more
сработало
источник

z

zis in Spring Framework and more
0_о
источник

ЧЧ

Чел Челу Чел Челыч... in Spring Framework and more
)
источник

z

zis in Spring Framework and more
спасибо)
источник

z

zis in Spring Framework and more
не работает
источник
2020 June 01

AE

Alexandr Emelyanov in Spring Framework and more
фигасе выше вселенские проблемы
источник

AE

Alexandr Emelyanov in Spring Framework and more
поиск пользователя по единице или нулю
источник

АО

Александр Остапенко... in Spring Framework and more
Здравствуйте, подскажите пожалуйста. Если делаю обработку части бинов через postProcessBeanFactory, они исчезают из обработки postProcessAfterInitialization. Это взаимоисключающие вещи ? Или что то неправильно делаю ?
источник

IV

Ilja V in Spring Framework and more
Подскажите в чем проблема..пытаюсь залогиниться через Spring Security - ввожу имя пороль а он редиректит назад на логин ...
источник

IV

Ilja V in Spring Framework and more
@Configuration
@EnableWebSecurity
public class WebSecurityConfig extends WebSecurityConfigurerAdapter {

   @Override
   public void configure(WebSecurity web) throws Exception {
       web
               .ignoring()
               .antMatchers("/resources/**","/static/**");
   }

   protected void configure (AuthenticationManagerBuilder builder) throws Exception {
       builder.inMemoryAuthentication().withUser("user").password("12345").roles("user");
   }

   protected void configure (HttpSecurity http) throws Exception {

       http.authorizeRequests().
               anyRequest().authenticated().
               and().formLogin().loginPage("/login")
               .loginProcessingUrl("authenticateMe").permitAll();
источник

IV

Ilja V in Spring Framework and more
<body>

 <form method="post" th:action="@{/authenticateMe}"  class="login">
   <p>
       <label th:for="Username">Username: </label>
       <input type="text" th:name="username" id="username"/>
   </p>

   <p>
       <label th:for="Password">Password: </label>
       <input type="password" th:name="password" id="password"/>
   </p>

   <p class="login-submit">
     <button type="submit" class="login-button">Login</button>
   </p>

 </form>
источник

IV

Ilja V in Spring Framework and more
@org.springframework.stereotype.Controller
public class Controller {

   @GetMapping("/login")
   public String showLogin () {
       return "index";
   }
источник

S

Stanislav in Spring Framework and more
Ilja V
@Configuration
@EnableWebSecurity
public class WebSecurityConfig extends WebSecurityConfigurerAdapter {

   @Override
   public void configure(WebSecurity web) throws Exception {
       web
               .ignoring()
               .antMatchers("/resources/**","/static/**");
   }

   protected void configure (AuthenticationManagerBuilder builder) throws Exception {
       builder.inMemoryAuthentication().withUser("user").password("12345").roles("user");
   }

   protected void configure (HttpSecurity http) throws Exception {

       http.authorizeRequests().
               anyRequest().authenticated().
               and().formLogin().loginPage("/login")
               .loginProcessingUrl("authenticateMe").permitAll();
.defaultSuccessUrl("/index.html", true)
источник

IV

Ilja V in Spring Framework and more
к сожалению не сработало
источник

IV

Ilja V in Spring Framework and more
protected void configure (HttpSecurity http) throws Exception {

       http.authorizeRequests().
               anyRequest().authenticated().
               and().formLogin().loginPage("/login")
               .loginProcessingUrl("authenticateMe").permitAll().defaultSuccessUrl("/start", true);
источник

IV

Ilja V in Spring Framework and more
@GetMapping("/start")
   public String login () {
       return "login-page";
   }
источник

IV

Ilja V in Spring Framework and more
что это за скрипт появляется на html? у меня его нет в коде
источник

IV

Ilja V in Spring Framework and more
источник

VS

Vitaly Sirotkin in Spring Framework and more
Ilja V
что это за скрипт появляется на html? у меня его нет в коде
Плагин по-любому какой то чето наинжектил
источник

РН

Роман Нагаев... in Spring Framework and more
Ilja V
такую штуку бывает провайдеры подсовывают если скрипты с cdn запрашиваются через http
источник