- Xiaomi 15T Pro - a téma nincs lezárva
- Poco X8 Pro Max - nem kell ide sem bank, sem akkubank
- iGO Primo
- iPhone topik
- One mobilszolgáltatások
- Így lehet kiszúrni, ha kamu AirPods fülest akarnak eladni neked
- Itt a Galaxy S26 széria: az Ultra fejlődött, a másik kettő alig
- Google Pixel topik
- Amazfit Active 2 NFC - jó kör
- Android alkalmazások - szoftver kibeszélő topik
Új hozzászólás Aktív témák
-
Csaby25
őstag
Sziasztok!
package com.sec.config;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Configuration;
import org.springframework.security.config.annotation.authentication.builders.AuthenticationManagerBuilder;
import org.springframework.security.config.annotation.method.configuration.EnableGlobalMethodSecurity;
import org.springframework.security.config.annotation.web.builders.HttpSecurity;
import org.springframework.security.config.annotation.web.configuration.WebSecurityConfigurerAdapter;
@EnableGlobalMethodSecurity(securedEnabled = true)
@Configuration
public class SecurityConf extends WebSecurityConfigurerAdapter{
@Autowired
public void configureAuth(AuthenticationManagerBuilder auth) throws Exception {
auth
.inMemoryAuthentication()
.withUser("sfjuser")
.password("{noop}pass")
.roles("USER")
.and()
.withUser("sfjadmin")
.password("{noop}pass")
.roles("ADMIN");
}
@Override
protected void configure(HttpSecurity http) throws Exception {
http
.authorizeRequests()
.antMatchers("admin/**").hasRole("ADMIN")
.anyRequest().authenticated()
.and()
.formLogin()
.loginPage("/login.html")
.permitAll()
.and()
.logout()
.logoutSuccessUrl("/login?logout")
.permitAll();
}
}Nem találja a login.html-t, pedig a templates mappában van. Van ötletetek miért?
Új hozzászólás Aktív témák
A topicot kiemeltem. Valaki nem akar egy nyitó hsz-t írni?:))
- BESZÁMÍTÁS! GIGABYTE B650E R9 7900X 64GB DDR5 1TB SSD RTX 5080 16GB NZXT H9 Flow White Corsair 850W
- BESZÁMÍTÁS! MSI X570 R5 5600X 32GB DDR4 512GB SSD RX 6800 16GB Kolink Unity Lateral ARG 750W
- BESZÁMÍTÁS! MSI B650 R5 9600X 32GB DDR5 1TB SSD RX 9070XT 16GB Lian Li LANCOOL II Mesh C RGB 750W
- BESZÁMÍTÁS! Gigabyte B450M R5 3600 16GB DDR4 512GB SSD GTX 1070 8GB Zalman S3 Chieftec 700W
- BESZÁMÍTÁS! Gigabyte B360M i5 8400 16GB DDR4 512GB SSD RTX 2070 8GB RAMPAGE Shiva Adata 600W
- Lenovo ThinkPad T14 Gen1 Ryzen5 4650U Refurbished - Garancia
- ÁRGARANCIA!Épített KomPhone Ryzen 5 4500 16/32/64GB RAM RTX 5050 8GB GAMER PC termékbeszámítással
- Dell Latitude 5400,14",FHD,i5-8365U,8GB DDR4,256GB SSD,WIN11
- Steelseries Arctis Nova 1 gamer fejhallgató
- Samsung Galaxy S24 Ultra / 12/256GB / Kártyafüggetlen /12Hó garancia / Akku: 100%
Állásajánlatok
Cég: Laptopműhely Bt.
Város: Budapest

