<feed xmlns='http://www.w3.org/2005/Atom'>
<title>openbsd/src/lib/libc, branch libressl-v3.5.0</title>
<subtitle>A mirror of https://github.com/libressl/openbsd.git
</subtitle>
<id>https://git.lua4.win/openbsd/atom?h=libressl-v3.5.0</id>
<link rel='self' href='https://git.lua4.win/openbsd/atom?h=libressl-v3.5.0'/>
<link rel='alternate' type='text/html' href='https://git.lua4.win/openbsd/'/>
<updated>2022-02-06T00:29:02+00:00</updated>
<entry>
<title>remove please from manual pages</title>
<updated>2022-02-06T00:29:02+00:00</updated>
<author>
<name>jsg</name>
<email></email>
</author>
<published>2022-02-06T00:29:02+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/openbsd/commit/?id=330276f39a5e0d5b539d5e8e3e247384f82cbde2'/>
<id>urn:sha1:330276f39a5e0d5b539d5e8e3e247384f82cbde2</id>
<content type='text'>
ok jmc@ sthen@ millert@
</content>
</entry>
<entry>
<title>refer to longindex as an argument, not a field;</title>
<updated>2022-01-06T18:58:24+00:00</updated>
<author>
<name>jmc</name>
<email></email>
</author>
<published>2022-01-06T18:58:24+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/openbsd/commit/?id=bee4e7d6cff50954827dda49f2f9ca3cc0f570b4'/>
<id>urn:sha1:bee4e7d6cff50954827dda49f2f9ca3cc0f570b4</id>
<content type='text'>
from uwe@netbsd -r1.22

ok millert
</content>
</entry>
<entry>
<title>Update to reflect changes over the last six years</title>
<updated>2021-12-25T01:13:44+00:00</updated>
<author>
<name>guenther</name>
<email></email>
</author>
<published>2021-12-25T01:13:44+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/openbsd/commit/?id=53c5e2cba9eff61f67c99cd18ea5209d02611f16'/>
<id>urn:sha1:53c5e2cba9eff61f67c99cd18ea5209d02611f16</id>
<content type='text'>
</content>
</entry>
<entry>
<title>lsearch(3): reimplement using lfind(3)</title>
<updated>2021-12-08T22:06:28+00:00</updated>
<author>
<name>cheloha</name>
<email></email>
</author>
<published>2021-12-08T22:06:28+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/openbsd/commit/?id=8b24559bc32a8fcd130978a513c42659ebf278de'/>
<id>urn:sha1:8b24559bc32a8fcd130978a513c42659ebf278de</id>
<content type='text'>
lsearch(3) is really just lfind(3) with an additional branch to append
the key if lfind(3) fails.  If we get rid of the underlying
linear_base() function and move the search portion into lfind(3) and
the key-copying portion into lsearch(3) we get smaller and simpler
code.

Misc. notes:

- We do not need to keep the historical comment about errno.  lsearch(3)
  is pure computation and does not set errno.  That's really all you
  need to know.  The specification reserves no errors, either.

- We are using lfind(3) internally now, so it switches from
  PROTO_DEPRECATED to PROTO_NORMAL in hidden/search.h and needs
  DEF_WEAK in stdlib/lsearch.c.

With advice from guenther@ on symbol housekeeping in libc.

Thread: https://marc.info/?l=openbsd-tech&amp;m=163885187632449&amp;w=2

ok millert@
</content>
</entry>
<entry>
<title>lsearch(3): append key to array with memmove(3) instead of memcpy(3)</title>
<updated>2021-12-07T04:01:45+00:00</updated>
<author>
<name>cheloha</name>
<email></email>
</author>
<published>2021-12-07T04:01:45+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/openbsd/commit/?id=cfc78852fcba382d04261ab49ed38b22e811e417'/>
<id>urn:sha1:cfc78852fcba382d04261ab49ed38b22e811e417</id>
<content type='text'>
If the key overlaps the end of the array, memcpy(3) mutates the key
and copies a corrupted value into the end of the array.

If we use memmove(3) instead we at least end up with a clean copy of
the key at the end of the array.  This is closer to the intended
behavior.

With input from millert@ and deraadt@.

Thread: https://marc.info/?l=openbsd-tech&amp;m=163880307403606&amp;w=2

ok millert@
</content>
</entry>
<entry>
<title>bsearch(3): support arrays with more than INT_MAX elements</title>
<updated>2021-12-02T20:58:01+00:00</updated>
<author>
<name>cheloha</name>
<email></email>
</author>
<published>2021-12-02T20:58:01+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/openbsd/commit/?id=6cb312a90e0db659665950da1acb2da29d74cadf'/>
<id>urn:sha1:6cb312a90e0db659665950da1acb2da29d74cadf</id>
<content type='text'>
The "lim" variable needs to be a size_t to match nmemb, otherwise we
get undefined behavior when nmemb exceeds INT_MAX.

Prompted by a blog post by Joshua Bloch:

https://ai.googleblog.com/2006/06/extra-extra-read-all-about-it-nearly.html

Fixed by Chris Torek a long time ago:

https://svnweb.freebsd.org/csrg/lib/libc/stdlib/bsearch.c?revision=51742&amp;view=markup

ok millert@
</content>
</entry>
<entry>
<title>A few sys/param.h annotations lacked ALIGNBYTES</title>
<updated>2021-11-29T03:20:37+00:00</updated>
<author>
<name>deraadt</name>
<email></email>
</author>
<published>2021-11-29T03:20:37+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/openbsd/commit/?id=3ff0ca30be40ac85767c463af5dda1f3a1c9fe6e'/>
<id>urn:sha1:3ff0ca30be40ac85767c463af5dda1f3a1c9fe6e</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Niels agreed to remove the advertising clause; switching these</title>
<updated>2021-11-29T01:04:45+00:00</updated>
<author>
<name>djm</name>
<email></email>
</author>
<published>2021-11-29T01:04:45+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/openbsd/commit/?id=26fe11ace67d4e0ce03ce92e7f81761878ac7047'/>
<id>urn:sha1:26fe11ace67d4e0ce03ce92e7f81761878ac7047</id>
<content type='text'>
to 3-term BSD license.
</content>
</entry>
<entry>
<title>Describe what RES_USE_DNSSEC does and how it's affected by trust-ad</title>
<updated>2021-11-24T20:06:32+00:00</updated>
<author>
<name>jca</name>
<email></email>
</author>
<published>2021-11-24T20:06:32+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/openbsd/commit/?id=757c7646fbdf4543d7d64d84a70fae57d5aa6849'/>
<id>urn:sha1:757c7646fbdf4543d7d64d84a70fae57d5aa6849</id>
<content type='text'>
ok florian@
</content>
</entry>
<entry>
<title>Implement rfc6840 (AD flag processing) if using trusted name servers</title>
<updated>2021-11-22T20:18:27+00:00</updated>
<author>
<name>jca</name>
<email></email>
</author>
<published>2021-11-22T20:18:27+00:00</published>
<link rel='alternate' type='text/html' href='https://git.lua4.win/openbsd/commit/?id=ca02920211b601ee0c85b3f9e9730859d617b1c2'/>
<id>urn:sha1:ca02920211b601ee0c85b3f9e9730859d617b1c2</id>
<content type='text'>
libc can't do DNSSEC validation but it can ask a "security-aware"
resolver to do so.  Let's send queries with the AD flag set when
appropriate, and let applications look at the AD flag in responses in
a safe way, ie clear the AD flag if the resolvers aren't trusted.
By default we only trust resolvers if resolv.conf(5) only lists name
servers on localhost - the obvious candidates being unwind(8) and
unbound(8).  For non-localhost resolvers, an admin who trusts *all the
name servers* listed in resolv.conf(5) *and the network path leading to
them* can annotate this with "options trust-ad".

AD flag processing gives ssh -o VerifyHostkeyDNS=Yes a chance to fetch
SSHFP records in a secure manner, and tightens the situation for other
applications, eg those using RES_USE_DNSSEC for DANE.  It should be
noted that postfix currently assumes trusted name servers by default and
forces RES_TRUSTAD if available.

RES_TRUSTAD and "options trust-ad" were first introduced in glibc by
Florian Weimer.  Florian Obser (florian@) contributed various
improvements, fixed a bug and added automatic trust for name servers on
localhost.

ok florian@ phessler@
</content>
</entry>
</feed>
