lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <Yv4dKABja9CxqcDS@worktop.programming.kicks-ass.net>
Date:   Thu, 18 Aug 2022 13:06:16 +0200
From:   Peter Zijlstra <peterz@...radead.org>
To:     Pengfei Xu <pengfei.xu@...el.com>
Cc:     Josh Poimboeuf <jpoimboe@...nel.org>,
        "Yang, Weijiang" <weijiang.yang@...el.com>,
        "Su, Heng" <heng.su@...el.com>, linux-kernel@...r.kernel.org,
        Josh Poimboeuf <jpoimboe@...hat.com>, pbonzini@...hat.com,
        x86@...nel.org
Subject: Re: [PATCH] x86/kvm, objtool: Avoid fastop ENDBR from being sealed

On Thu, Aug 18, 2022 at 03:38:45PM +0800, Pengfei Xu wrote:
>   And this "Missing ENDBR: andw_ax_dx+0x0/0x10 [kvm]" issue was
>   reproduced again after ran syzkaller 5min on ADL-P.

Ha, indeed :/

> > > +/*
> > > + * Create a dummy function pointer reference to prevent objtool from marking
> > > + * the function as needing to be "sealed" (i.e. ENDBR converted to NOP by
> > > + * apply_ibt_endbr()).
> > > + */
> > > +#define IBT_NOSEAL(fname)				\
> > > +	".pushsection .discard.endbr.noseal\n\t"	\
> > > +	_ASM_PTR fname "\n\t"				\
> > > +	".popsection\n\t"
> > > +

objtool/check.c:validate_ibt():

                if (!strncmp(sec->name, ".discard", 8)                  ||
		    ...)
		    continue;

So yeah, that'll just get ignored. So at the very least we need to
special case this section.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ