Fix use-after-free error (#1409433)
This commit is contained in:
parent
38869a3406
commit
dd8e5419eb
@ -288,7 +288,7 @@ diff -up openssh/monitor.c.role-mls openssh/monitor.c
|
||||
if (buffer_get_char(&b) != SSH2_MSG_USERAUTH_REQUEST)
|
||||
fail++;
|
||||
cp = buffer_get_cstring(&b, NULL);
|
||||
+ if ((r = strchr(p, '/')) != NULL)
|
||||
+ if ((r = strchr(cp, '/')) != NULL)
|
||||
+ *r = '\0';
|
||||
xasprintf(&userstyle, "%s%s%s", authctxt->user,
|
||||
authctxt->style ? ":" : "",
|
||||
|
Loading…
Reference in New Issue
Block a user