[openssh-commits] [openssh] 04/05: upstream: Check sshauthopt_new() for NULL. bz#3425, from

git+noreply at mindrot.org git+noreply at mindrot.org
Wed Apr 27 21:33:50 AEST 2022


This is an automated email from the git hooks/post-receive script.

dtucker pushed a commit to branch master
in repository openssh.

commit 67b7c784769c74fd4d6b147d91e17e1ac1a8a96d
Author: dtucker at openbsd.org <dtucker at openbsd.org>
Date:   Tue Apr 26 07:41:44 2022 +0000

    upstream: Check sshauthopt_new() for NULL. bz#3425, from
    
    tessgauthier at microsoft.com.  ok djm@
    
    OpenBSD-Commit-ID: af0315bc3e44aa406daa7e0ae7c2d719a974483f
---
 auth.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/auth.c b/auth.c
index 58754c07..5809c0b0 100644
--- a/auth.c
+++ b/auth.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: auth.c,v 1.154 2022/02/23 11:17:10 djm Exp $ */
+/* $OpenBSD: auth.c,v 1.155 2022/04/26 07:41:44 dtucker Exp $ */
 /*
  * Copyright (c) 2000 Markus Friedl.  All rights reserved.
  *
@@ -903,7 +903,8 @@ auth_restrict_session(struct ssh *ssh)
 	debug_f("restricting session");
 
 	/* A blank sshauthopt defaults to permitting nothing */
-	restricted = sshauthopt_new();
+	if ((restricted = sshauthopt_new()) == NULL)
+		fatal_f("sshauthopt_new failed");
 	restricted->permit_pty_flag = 1;
 	restricted->restricted = 1;
 

-- 
To stop receiving notification emails like this one, please contact
djm at mindrot.org.


More information about the openssh-commits mailing list