NetBSD-Bugs archive

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

Re: bin/56471: ntpd dies at startup on macppc/current, sshd randomly dies



The following reply was made to PR bin/56471; it has been noted by GNATS.

From: Christos Zoulas <christos%zoulas.com@localhost>
To: Jason Thorpe <thorpej%me.com@localhost>
Cc: Martin Husemann <martin%duskware.de@localhost>,
 gnats-bugs%netbsd.org@localhost,
 gnats-admin%netbsd.org@localhost,
 netbsd-bugs%netbsd.org@localhost
Subject: Re: bin/56471: ntpd dies at startup on macppc/current, sshd randomly
 dies
Date: Sat, 30 Oct 2021 09:14:12 -0400

 Good debugging. Let's make it look like the siginfo case then.
 
 christos
 
 > On Oct 30, 2021, at 8:48 AM, Jason Thorpe <thorpej%me.com@localhost> wrote:
 >=20
 >=20
 >> On Oct 30, 2021, at 5:42 AM, Jason Thorpe <thorpej%me.com@localhost> wrote:
 >>=20
 >>       /*
 >>        * Make sure SRR1 hasn't been maliciously tampered with. =20
 >>        */    =20
 >>       if (!PSL_USEROK_P(sc.sc_frame.srr1))
 >>               return (EINVAL);
 >>=20
 >> I=E2=80=99m pretty sure this is what is tripping in the failure case.
 >=20
 > It=E2=80=99s worth noting that the siginfo case, which was always =
 being used until very recently, simply does this:
 >=20
 >                /*
 >                 * Accept all user-settable bits without complaint;
 >                 * userland should not need to know the =
 machine-specific
 >                 * MSR value.
 >                 */
 >                tf->tf_srr1 =3D (gr[_REG_MSR] & PSL_USERMOD) | =
 PSL_USERSET;
 >=20
 > I.e. does no checking, and simply forces it to what it should be =
 (modulo accepting the user-settable bits, which in the OEA case are =
 basically FP modes and single-stepping).
 >=20
 > -- thorpej
 


Home | Main Index | Thread Index | Old Index