]> git.ipfire.org Git - thirdparty/openssh-portable.git/commitdiff
upstream commit
authordjm@openbsd.org <djm@openbsd.org>
Thu, 30 Jul 2015 23:09:15 +0000 (23:09 +0000)
committerDamien Miller <djm@mindrot.org>
Sun, 2 Aug 2015 09:59:25 +0000 (19:59 +1000)
fix pty permissions; patch from Nikolay Edigaryev; ok
 deraadt

Upstream-ID: 40ff076d2878b916fbfd8e4f45dbe5bec019e550

sshpty.c

index 7bb76416370dfd121f9a88517bef9f1675bad58b..15da8c649746fbb9216c96d2250ef49efcbe7643 100644 (file)
--- a/sshpty.c
+++ b/sshpty.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: sshpty.c,v 1.29 2014/09/03 18:55:07 djm Exp $ */
+/* $OpenBSD: sshpty.c,v 1.30 2015/07/30 23:09:15 djm Exp $ */
 /*
  * Author: Tatu Ylonen <ylo@cs.hut.fi>
  * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland
@@ -197,7 +197,7 @@ pty_setowner(struct passwd *pw, const char *tty)
        /* Determine the group to make the owner of the tty. */
        grp = getgrnam("tty");
        gid = (grp != NULL) ? grp->gr_gid : pw->pw_gid;
-       mode = (grp != NULL) ? 0622 : 0600;
+       mode = (grp != NULL) ? 0620 : 0600;
 
        /*
         * Change owner and mode of the tty as required.