Re: cc claims ISO C99 support, but %n printf format specifier calls abort()

2022-12-16 Thread Jeremie Courreges-Anglas
On Fri, Dec 16 2022, Vincent Lefevre wrote: > On 2022-12-15 18:56:15 -0700, Theo de Raadt wrote: >> There are almost no %n left in the software ecosystem. If we are able >> to make this crossing, everyone else is also capable, and eventually >> will. Just like with gets(). > > FYI, this breaks

Re: cc claims ISO C99 support, but %n printf format specifier calls abort()

2022-12-16 Thread Theo de Raadt
That could almost be an entry for calendars.openbsd Dec 16 Vincent Lefevre arrives and tries to educate the OpenBSD developers about format string vulnerabilities, which they have been fixing since 1996 Vincent Lefevre wrote: > On 2022-12-16 09:03:39 -0700, Theo de

Re: cc claims ISO C99 support, but %n printf format specifier calls abort()

2022-12-16 Thread Vincent Lefevre
On 2022-12-16 09:03:39 -0700, Theo de Raadt wrote: > Vincent Lefevre wrote: > > > BTW, if developers use an untrusted format string, then sprintf() > > is unsafe too (possible buffer overflow), and at some point, > > printf() too. > > what are you trying to say? According to

Re: cc claims ISO C99 support, but %n printf format specifier calls abort()

2022-12-16 Thread Theo de Raadt
Vincent Lefevre wrote: > BTW, if developers use an untrusted format string, then sprintf() > is unsafe too (possible buffer overflow), and at some point, > printf() too. what are you trying to say? are you trying to say everyone including you should review and audit and re-audit all of them?

Re: cc claims ISO C99 support, but %n printf format specifier calls abort()

2022-12-16 Thread Theo de Raadt
Well they need to respond, or openbsd ports needs a diff. Vincent Lefevre wrote: > On 2022-12-15 18:56:15 -0700, Theo de Raadt wrote: > > There are almost no %n left in the software ecosystem. If we are able > > to make this crossing, everyone else is also capable, and eventually > > will.

Re: cc claims ISO C99 support, but %n printf format specifier calls abort()

2022-12-16 Thread Stuart Henderson
On 2022/12/16 10:50, Vincent Lefevre wrote: > On 2022-12-15 18:56:15 -0700, Theo de Raadt wrote: > > There are almost no %n left in the software ecosystem. If we are able > > to make this crossing, everyone else is also capable, and eventually > > will. Just like with gets(). > > FYI, this

Re: cc claims ISO C99 support, but %n printf format specifier calls abort()

2022-12-16 Thread Vincent Lefevre
On 2022-12-15 18:56:15 -0700, Theo de Raadt wrote: > There are almost no %n left in the software ecosystem. If we are able > to make this crossing, everyone else is also capable, and eventually > will. Just like with gets(). FYI, this breaks GMP, whose configure script insists on %n being

Re: cc claims ISO C99 support, but %n printf format specifier calls abort()

2022-12-15 Thread Theo de Raadt
This falls into the catagory of "bummer". We will continue to break all applications that use %n, because we haven't found a single use of %n is that is safe. and %n uses are completely trivial to replace. There are almost no %n left in the software ecosystem. If we are able to make this