Class SecurityConfiguration
- java.lang.Object
-
- org.springframework.security.config.annotation.web.configuration.WebSecurityConfigurerAdapter
-
- edu.cnm.deepdive.interviewprep.configuration.SecurityConfiguration
-
- All Implemented Interfaces:
SecurityConfigurer<javax.servlet.Filter,WebSecurity>
,WebSecurityConfigurer<WebSecurity>
@Configuration @EnableWebSecurity public class SecurityConfiguration extends WebSecurityConfigurerAdapter
This class handles the security configuration of our Server Application. This class gets and validates a user token from Google-Sign-in.
-
-
Constructor Summary
Constructors Constructor Description SecurityConfiguration(Converter<Jwt,? extends AbstractAuthenticationToken> converter)
This Constructor instantiates a new security configuration object.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
configure(HttpSecurity http)
JwtDecoder
jwtDecoder()
This method allows user to access a decoded and validated bearer token.-
Methods inherited from class org.springframework.security.config.annotation.web.configuration.WebSecurityConfigurerAdapter
authenticationManager, authenticationManagerBean, configure, configure, getApplicationContext, getHttp, init, setApplicationContext, setAuthenticationConfiguration, setContentNegotationStrategy, setObjectPostProcessor, setTrustResolver, userDetailsService, userDetailsServiceBean
-
-
-
-
Constructor Detail
-
SecurityConfiguration
@Autowired public SecurityConfiguration(Converter<Jwt,? extends AbstractAuthenticationToken> converter)
This Constructor instantiates a new security configuration object.- Parameters:
converter
- A Converter object.
-
-
Method Detail
-
configure
protected void configure(HttpSecurity http) throws Exception
- Overrides:
configure
in classWebSecurityConfigurerAdapter
- Throws:
Exception
-
jwtDecoder
public JwtDecoder jwtDecoder()
This method allows user to access a decoded and validated bearer token.- Returns:
- JWT Decoder object
-
-