title: Disable authentication and csrf for a given path in Spring Weblux?
body: <p>I would like to enable oauth2 for the whole application except one url.</p>
  
  <p>My configuration:</p>
  
  <pre><code>@EnableWebFluxSecurity
  class SecurityConfig {
  
      @Bean
      fun securityWebFilterChain(http: ServerHttpSecurity) =
          http
              .authorizeExchange()
              .pathMatchers("/devices/**/register").permitAll()
              .and()
              .oauth2Login().and()
              .build()
  }
  </code></pre>
  
  <p>application.yml:</p>
  
  <pre><code>spring.security.oauth2.client.registration.google.client-id: ...
  spring.security.oauth2.client.registration.google.client-secret: ...
  </code></pre>
  
  <p>All the paths are being protected with oauth2 but the problem is that when I call an endpoint that is permitted <code>/devices/123/register</code> then in response I get:</p>
  
  <p><code>CSRF Token has been associated to this client</code></p>
  
  <p>Do I need to configure this path in a different way?</p>