content: package com.alphnology.security;
  
  import com.alphnology.views.login.LoginView;
  import com.vaadin.flow.spring.security.VaadinWebSecurity;
  import org.springframework.context.annotation.Bean;
  import org.springframework.context.annotation.Configuration;
  import org.springframework.security.config.annotation.web.builders.HttpSecurity;
  import org.springframework.security.config.annotation.web.configuration.EnableWebSecurity;
  import org.springframework.security.crypto.bcrypt.BCryptPasswordEncoder;
  import org.springframework.security.crypto.password.PasswordEncoder;
  
  @EnableWebSecurity
  @Configuration
  public class SecurityConfiguration extends VaadinWebSecurity {
  
      @Bean
      public PasswordEncoder passwordEncoder() {
          return new BCryptPasswordEncoder();
      }
  
      @Override
      protected void configure(HttpSecurity http) throws Exception {
  
          http.authorizeHttpRequests(authorize -> authorize
                  .requestMatchers("/images/*.png", "/icons/**", "/line-awesome/**")
                  .permitAll()
                  .requestMatchers("/share/**")
                  .anonymous());
  
  
          super.configure(http);
          setLoginView(http, LoginView.class);
      }
  
  }
  