-
Notifications
You must be signed in to change notification settings - Fork 3.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
131480: hba,rulebasedscanner: handle double quotes in HBA conf option value r=pritesh-lahoti a=souravcrl fix CRDB-39812 Epic CRDB-33829 Currently, HBA configuration cluster setting value is not fully adherent to `pg_hba.conf` and we fail to handle double quotes in HBA auth method options. This needs fixes to HBA parser and tokenizer code. Release note(security, ops): HBA configuration cluster setting `server.host_based_authentication.configuration` is currently unable to handle double quotes in authentication method option values. For example for the following HBA entry: ``` host all all all ldap ldapserver=ldap.example.com ldapport=636 ldapbasedn="ou=users,dc=example,dc=com" ldapbinddn="cn=readonly,dc=example,dc=com" ldapbindpasswd=readonly_password ldapsearchattribute=uid ldapsearchfilter="(memberof=cn=cockroachdb_users,ou=groups,dc=example,dc=com)" ``` The HBA parser fails after determining `ldapbinddn="cn=readonly,dc=example,dc=com"` as 2 separate options(`ldapbinddn=` and `cn=readonly,dc=example,dc=com`). The PR fixes this, and we are able to set the above 2 tokens as key and value respectively for the same HBA configuration option. Co-authored-by: souravcrl <[email protected]>
- Loading branch information
Showing
6 changed files
with
249 additions
and
21 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.