instaclustr / cassandra-ldap

LDAP Authenticator for Apache Cassandra
Apache License 2.0
24 stars 16 forks source link

Automatically Add LDAP Users to Role #34

Closed dave-pollock closed 1 year ago

dave-pollock commented 1 year ago

This PR adds a configuration option default_role_membership, which causes new LDAP users to be added to an existing Cassandra role when they first log in. This way they can be granted a default permission set.

When the configuration option is not set, there is no change to existing behaviour.

There's quite a lot of code duplication here because I didn't want to deviate from the patterns already followed in the project.

@smiklosovic let me know if you have any concerns

smiklosovic commented 1 year ago

Oh wow what a patch ... thanks!

I will have time probably next week to go over this.

smiklosovic commented 1 year ago

looks good at first sight ... just cover the formatting and minor issues and we should be golden

dave-pollock commented 1 year ago

@smiklosovic I've made adjustments based on your feedback. Let me know if there's anything else.

smiklosovic commented 1 year ago

I ve merged it. Thanks!