diff options
author | Alexey Botchkov <holyfoot@askmonty.org> | 2018-08-30 14:51:15 +0400 |
---|---|---|
committer | Alexey Botchkov <holyfoot@askmonty.org> | 2018-08-30 14:51:15 +0400 |
commit | 2ad51a0bd8380fba3d03a4cebd43860329b7fbaa (patch) | |
tree | 63a60ffe1b745db52cc2a4cb8e5693e7cd81f9fc /plugin | |
parent | 104089e182f31524d85409bd59f1889e36d4636a (diff) | |
download | mariadb-git-2ad51a0bd8380fba3d03a4cebd43860329b7fbaa.tar.gz |
MDEV-17095 pam_user_map module throws syntax error if group name contains backslash.
Let '\\' and '/' symbols to be part of a group name.
Diffstat (limited to 'plugin')
-rw-r--r-- | plugin/auth_pam/mapper/pam_user_map.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/plugin/auth_pam/mapper/pam_user_map.c b/plugin/auth_pam/mapper/pam_user_map.c index c03ea12be74..e1d11acabb9 100644 --- a/plugin/auth_pam/mapper/pam_user_map.c +++ b/plugin/auth_pam/mapper/pam_user_map.c @@ -189,13 +189,15 @@ int pam_sm_authenticate(pam_handle_t *pamh, int flags, s++; } from= s; - skip(isalnum(*s) || (*s == '_') || (*s == '.') || (*s == '-') || (*s == '$')); + skip(isalnum(*s) || (*s == '_') || (*s == '.') || (*s == '-') || + (*s == '$') || (*s == '\\') || (*s == '/')); end_from= s; skip(isspace(*s)); if (end_from == from || *s++ != ':') goto syntax_error; skip(isspace(*s)); to= s; - skip(isalnum(*s) || (*s == '_') || (*s == '.') || (*s == '-') || (*s == '$')); + skip(isalnum(*s) || (*s == '_') || (*s == '.') || (*s == '-') || + (*s == '$')); end_to= s; if (end_to == to) goto syntax_error; |