Commit 165d8ae9 authored by Noel Alonso's avatar Noel Alonso
Browse files

Añade configuración para permitir Options request

parent 68c53dfc
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -13,7 +13,7 @@
	<modelVersion>4.0.0</modelVersion>
	<artifactId>user</artifactId>
	<packaging>jar</packaging>
	<version>0.8.0</version>
	<version>0.8.0-feature-corsAllowed</version>
	<name>User</name>
	<description>Account management and user services</description>
	
+2 −2
Original line number Diff line number Diff line
@@ -59,8 +59,7 @@ public class Oauth2SecurityConfiguration {

		@Override
		public void configure(ResourceServerSecurityConfigurer resources) {
			resources.tokenServices(tokenService())
					.resourceId(SPARKLR_RESOURCE_ID);
			resources.tokenServices(tokenService()).resourceId(SPARKLR_RESOURCE_ID);
		}

		@Override
@@ -68,6 +67,7 @@ public class Oauth2SecurityConfiguration {
			// @formatter:off

			http.anonymous().and().authorizeRequests().antMatchers("/user/actuator/**").permitAll()
					.antMatchers(HttpMethod.OPTIONS, "/**/").permitAll()
					.antMatchers(HttpMethod.GET, "/user/profile/").permitAll()
					.antMatchers(HttpMethod.GET, "/user/modules/openmodules/").permitAll()
					.antMatchers(HttpMethod.POST, "/user/register/**/").permitAll()
+2 −0
Original line number Diff line number Diff line
@@ -20,6 +20,8 @@ management.endpoints.web.exposure.include=health, info, prometheus
spring.application.name=api user
spring.aop.proxy-target-class=true

spring.mvc.dispatch-options-request=true

recaptcha.secret=secret

#oauth