Added email submission to secured routes

This commit is contained in:
neviyn 2020-01-10 12:04:51 +00:00
parent e647e853d5
commit 6a6ceb7c87

View File

@ -40,7 +40,7 @@ class CustomWebSecurityConfigurerAdapter : WebSecurityConfigurerAdapter() {
@Throws(Exception::class)
override fun configure(http: HttpSecurity) {
http.csrf().disable().authorizeRequests()
.antMatchers(HttpMethod.POST, "/api/site", "/api/tutor", "/api/observation", "/api/grpob/start", "/api/grpob/complete").authenticated()
.antMatchers(HttpMethod.POST, "/api/site", "/api/tutor", "/api/observation", "/api/grpob/start", "/api/grpob/complete", "/api/observations/email").authenticated()
.anyRequest().permitAll()
.and()
.httpBasic()
@ -70,4 +70,4 @@ class MyBasicAuthenticationEntryPoint : BasicAuthenticationEntryPoint() {
realmName = "Security"
super.afterPropertiesSet()
}
}
}