Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/netbsd-1-4]: src/sys/arch/vax/vax Apply patch (requested by ragge):



details:   https://anonhg.NetBSD.org/src/rev/edbae1cb5e38
branches:  netbsd-1-4
changeset: 469863:edbae1cb5e38
user:      he <he%NetBSD.org@localhost>
date:      Thu Dec 16 22:49:20 1999 +0000

description:
Apply patch (requested by ragge):
  In process_write_regs(), no checks were made to which bits in
  the PSL that was altered. This means that the traced process
  could gain any hardware privileges.

diffstat:

 sys/arch/vax/vax/machdep.c |  5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)

diffs (19 lines):

diff -r 1967d9ba9ca0 -r edbae1cb5e38 sys/arch/vax/vax/machdep.c
--- a/sys/arch/vax/vax/machdep.c        Thu Dec 16 22:45:02 1999 +0000
+++ b/sys/arch/vax/vax/machdep.c        Thu Dec 16 22:49:20 1999 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: machdep.c,v 1.76.2.1 1999/04/16 16:26:01 chs Exp $  */
+/* $NetBSD: machdep.c,v 1.76.2.2 1999/12/16 22:49:20 he Exp $   */
 
 /*
  * Copyright (c) 1994, 1998 Ludd, University of Lule}, Sweden.
@@ -770,7 +770,8 @@
        tf->fp = regs->fp;
        tf->sp = regs->sp;
        tf->pc = regs->pc;
-       tf->psl = regs->psl;
+       tf->psl = (regs->psl|PSL_U|PSL_PREVU) &
+           ~(PSL_MBZ|PSL_IS|PSL_IPL1F|PSL_CM); /* Allow compat mode? */
        return 0;
 }
 



Home | Main Index | Thread Index | Old Index