From 10ec3f18fc3d1ab13617001a2c09a676d13784a5 Mon Sep 17 00:00:00 2001 From: Hendrik Brueckner Date: Thu, 2 Jul 2026 19:45:23 +0200 Subject: [PATCH] iucvterm/ts-shell: Correct user/group names being interpreted as regex MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit When ts-shell creates the authorization for current user, the user name and group names are interpreted as regex. This might create additional authorizations which are not permitted for current user. Correct this behavior by quoting the user name in the regex. Reviewed-by: Steffen Eiden Reviewed-by: Jan Höppner Signed-off-by: Hendrik Brueckner Signed-off-by: Jan Höppner --- iucvterm/bin/ts-shell.in | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/iucvterm/bin/ts-shell.in b/iucvterm/bin/ts-shell.in index 63c542f3..0aa0b5c9 100755 --- a/iucvterm/bin/ts-shell.in +++ b/iucvterm/bin/ts-shell.in @@ -217,7 +217,7 @@ sub loadAuthorization(\%) my ($key, $val) = split /\s*=\s*/; # read authorization configuration for user and its groups - if ($key =~ /^$cfg->{user}$/) { + if ($key =~ /^\Q$cfg->{user}\E$/) { $authorized = 1; log_debug "Found user: $key";