# Springboot Security Actuator

**URL:** <https://forum.flowable.org/t/springboot-security-actuator/9113>\
**Category:** Flowable Engine\
**Created:** [March 16, 2022, 6:22am UTC](https://forum.flowable.org/t/springboot-security-actuator/9113 "2022-03-16T06:22:19Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![umutkazan](https://avatars.discourse-cdn.com/v4/letter/u/0ea827/32.png) [@umutkazan](https://forum.flowable.org/u/umutkazan)\
**Post date:** [March 16, 2022, 6:22am UTC](https://forum.flowable.org/t/springboot-security-actuator/9113/1 "2022-03-16T06:22:19Z")

</div>

Hello,

My flowable spring boot application is integrated with the keycloak right now. But I have an issue regarding actuator endpoints.

```auto
@Configuration
@EnableGlobalMethodSecurity(prePostEnabled = true)
@Profile("!nosec")
@Order(Ordered.HIGHEST_PRECEDENCE)
public class SecurityConfig extends WebSecurityConfigurerAdapter {

    @Override
    protected void configure(HttpSecurity http) throws Exception {
        http.authorizeRequests()
                .antMatchers("/actuator/**").permitAll()//health-checks and metrics internal endpoints should not require authentication
                .anyRequest().authenticated()
                .and()
                .oauth2Login(oauthLogin -> oauthLogin.permitAll())//redirect to login if no token or session is provided
                .oauth2ResourceServer(OAuth2ResourceServerConfigurer::jwt); //validate JWT Bearer token
    }

}

```

This is my Security configuration. This allows me to make request on my actuator endpoints but it gives me http 401 when I try to go to task module or one of the engines in the admin panel.

If I set Order to LOWEST\_PRECEDENCE (or just Order), since flowable’s own security classes have higher precedence, my actuator endpoints require authorization.

I would think that there must be a very simple solution for this but as I said, haven’t found one yet.

Thank you

---

<div class="post-metadata">

**Author:** ![filiphr](https://yyz1.discourse-cdn.com/flex035/user_avatar/forum.flowable.org/filiphr/32/315_2.png) [@filiphr](https://forum.flowable.org/u/filiphr)\
**Post date:** [August 17, 2022, 8:14am UTC](https://forum.flowable.org/t/springboot-security-actuator/9113/2 "2022-08-17T08:14:29Z")

</div>

Hey @umutkazan,

I would suggest you to have a look at how our [`ActuatorWebSecurityConfigurerAdapter`](https://github.com/flowable/flowable-engine/blob/89e18fdaceda8df55957fb170fcd602c3f034187/modules/flowable-ui/flowable-ui-common/src/main/java/org/flowable/ui/common/security/FlowableUiSecurityAutoConfiguration.java#L322) is configured and adapt yours.

Your question is more of a Spring Security question and not a Flowable one.

The most important part you need is a `requestMatcher` for the `HttpSecurity`. If you do not provide one, then all the requests will be handled by your security configuraiton.

Cheers,  
Filip
