Skip to content

Mutli-Tenancy Support using JWT claims #1

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
InventorSingh opened this issue Mar 20, 2020 · 0 comments
Open

Mutli-Tenancy Support using JWT claims #1

InventorSingh opened this issue Mar 20, 2020 · 0 comments

Comments

@InventorSingh
Copy link

InventorSingh commented Mar 20, 2020

Hi Greg, Thank you for the great work. I was trying this example and trying to add mutli-tenancy support in spring boot hello world application from netifi examples. I am using netifi community edition broker.

Below is my Rsocket Security Configuration:

@configuration
@EnableRSocketSecurity
public class RsocketSecurityConfig {

@Bean
PayloadSocketAcceptorInterceptor rsocketInterceptor(RSocketSecurity rsocket) {
    return rsocket
            .authorizePayload(authorize ->
                    authorize
                            .route("*").hasRole("ROLE_ADMIN")
                            .anyRequest().authenticated()
                            .anyExchange().authenticated()
            )
            .jwt(Customizer.withDefaults()).build();
}

@Bean
ReactiveJwtDecoder jwtDecoder() {
    return ReactiveJwtDecoders
            .fromIssuerLocation("http://localhost:7475/auth/realms/devnation");
}

}

But somehow security is not applied to my application. I am still able to call the hello-service form hello-client. How could I secure my services defined in protobuff with spring security rsocket?

@InventorSingh InventorSingh changed the title Mutli-Tenancy Support Mutli-Tenancy Support using JWT claims Mar 20, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant