provider-sql
provider-sql copied to clipboard
Support Authentication Plugins like authentication_ldap_simple
What problem are you facing?
I would like to create mysql (v8.0+) users identified by ldap (authentication_ldap_simple) instead of by password (mysql_native_password). Also it would be great if authenticating by auth_socket would be supported as well.
How could Crossplane help solve your problem?
This code might be changed
query := fmt.Sprintf(
"CREATE USER %s@%s IDENTIFIED BY %s%s",
mysql.QuoteValue(username),
mysql.QuoteValue(host),
mysql.QuoteValue(pw),
resourceOptions,
)
https://github.com/crossplane-contrib/provider-sql/blob/master/pkg/controller/mysql/user/reconciler.go#L261
To something like this if some plugin was provided
query := fmt.Sprintf(
"CREATE USER %s@%s IDENTIFIED WITH %s%s",
mysql.QuoteValue(username),
mysql.QuoteValue(host),
mysql.QuoteValue(plugin),
resourceOptions,
)
I would like to work in a pr if this feature is considered as desirable