<feed xmlns='http://www.w3.org/2005/Atom'>
<title>wireguard-openbsd/lib/csu/amd64, branch master</title>
<subtitle>WireGuard implementation for the OpenBSD kernel</subtitle>
<id>https://git.zx2c4.com/wireguard-openbsd/atom/lib/csu/amd64?h=master</id>
<link rel='self' href='https://git.zx2c4.com/wireguard-openbsd/atom/lib/csu/amd64?h=master'/>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-openbsd/'/>
<updated>2020-10-15T16:30:21Z</updated>
<entry>
<title>crt0 MD _dl_exit() performs syscall to SYS_exit directly, but then</title>
<updated>2020-10-15T16:30:21Z</updated>
<author>
<name>deraadt</name>
<email>deraadt@openbsd.org</email>
</author>
<published>2020-10-15T16:30:21Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-openbsd/commit/?id=2bc3a8c076b486ad5cb1adf52ac1373fba054b0a'/>
<id>urn:sha1:2bc3a8c076b486ad5cb1adf52ac1373fba054b0a</id>
<content type='text'>
some of these functions were returning.  That makes the +1word address
a fairly strong and easily located gadget.  Put a hard-trap
instruction after the syscall.  This remains a gadget for 'terminal
system' calls (such as execve), but hey that's why we have pledge w/o
"exec" throughout the tree.
Quite surprisingly, hppa's delay-slot load of SYS_exit makes it the
safest of the bunch, not that this helps anyone.
ok kettenis
</content>
</entry>
<entry>
<title>use symbolic SYS_exit instead of the value 1</title>
<updated>2020-10-14T22:11:18Z</updated>
<author>
<name>deraadt</name>
<email>deraadt@openbsd.org</email>
</author>
<published>2020-10-14T22:11:18Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-openbsd/commit/?id=9c558c1181d4532fa3a04595bff127adc23ef057'/>
<id>urn:sha1:9c558c1181d4532fa3a04595bff127adc23ef057</id>
<content type='text'>
ok kettenis
</content>
</entry>
<entry>
<title>Rearrange C runtime bits: now that ld.so exports environ and __progname,</title>
<updated>2016-03-20T02:32:39Z</updated>
<author>
<name>guenther</name>
<email>guenther@openbsd.org</email>
</author>
<published>2016-03-20T02:32:39Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-openbsd/commit/?id=5af055cd66b5450a4935ae30e5716331ca3b13d5'/>
<id>urn:sha1:5af055cd66b5450a4935ae30e5716331ca3b13d5</id>
<content type='text'>
move their definitions and initialization in static links to libc.a
Make crt0 always invoke a new func _csu_finish() in libc to process the auxv
and to either register the ld.so cleanup function (in dynamic links) or
initialize environ and __progname and do MC_DISABLE_KBIND (in static links).
In libc, get pagesize from auxv; cache that between getpagesize() and
sysconf(_SC_PAGESIZE)

ok mpi@ "good time" deraadt@
</content>
</entry>
<entry>
<title>In static binaries, invoke kbind() once to disable it.</title>
<updated>2015-09-01T05:40:06Z</updated>
<author>
<name>guenther</name>
<email>guenther@openbsd.org</email>
</author>
<published>2015-09-01T05:40:06Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-openbsd/commit/?id=0a8a9c346022d9ea9d2d120f75edf8549c4915cf'/>
<id>urn:sha1:0a8a9c346022d9ea9d2d120f75edf8549c4915cf</id>
<content type='text'>
With much assistance from miod@
ok deraadt@@
</content>
</entry>
<entry>
<title>Introduce new csu0 variant for -static -pie binaries to use called</title>
<updated>2014-12-22T03:51:08Z</updated>
<author>
<name>kurt</name>
<email>kurt@openbsd.org</email>
</author>
<published>2014-12-22T03:51:08Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-openbsd/commit/?id=b7d44ead2528d548ebe369571fb766478149400a'/>
<id>urn:sha1:b7d44ead2528d548ebe369571fb766478149400a</id>
<content type='text'>
rcsu0.o where the initial 'r' is for relocatable. rcsu0.o performs
self-relocation on static pie binaries by calling a slightly modified
copy of ld.so's _dl_boot_bind() in boot.h.

The first arch implementatation is also included for amd64 where
__start calls _dl_boot_bind() and then calls ___start(). Includes
parts from kettenis@ to help get R_X86_64_64 relocations working
and proper handling for undefined weak symbols.

This is the first part of several to get static pie self-relocating
binaries working. binutils, gcc and kernel changes are forthcoming
to complete the solution, then per-arch implementations are needed
for MD_RCRT0_START in csu.

okay kettenis@ pascal@ deraadt@
</content>
</entry>
<entry>
<title>Merge Makefiles, moving the build up a level and putting the CPU-specific</title>
<updated>2014-11-12T02:31:47Z</updated>
<author>
<name>guenther</name>
<email>guenther@openbsd.org</email>
</author>
<published>2014-11-12T02:31:47Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-openbsd/commit/?id=6b88410476671be99ce8e616cd4ff5d028d907d2'/>
<id>urn:sha1:6b88410476671be99ce8e616cd4ff5d028d907d2</id>
<content type='text'>
build flags into conditionals in the Makefile, fixing a few inconsistencies
in the process.

\o/ miod@
</content>
</entry>
<entry>
<title>Merge the per-arch crt0.c files into common_elf/crt0.c, with MD macros in</title>
<updated>2013-12-03T06:21:40Z</updated>
<author>
<name>guenther</name>
<email>guenther@openbsd.org</email>
</author>
<published>2013-12-03T06:21:40Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-openbsd/commit/?id=453b49cd27aaae4d675fbaa755fa5bd0af309909'/>
<id>urn:sha1:453b49cd27aaae4d675fbaa755fa5bd0af309909</id>
<content type='text'>
the md_init.h files.

Worked out with and ok miod@; ok matthew@
</content>
</entry>
<entry>
<title>The kernel and ld.so pass 0 in %rdx for use as the cleanup callback</title>
<updated>2013-11-10T18:49:34Z</updated>
<author>
<name>guenther</name>
<email>guenther@openbsd.org</email>
</author>
<published>2013-11-10T18:49:34Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-openbsd/commit/?id=6b5b642243e83baf9d847ab668df4d93d8dfd2e5'/>
<id>urn:sha1:6b5b642243e83baf9d847ab668df4d93d8dfd2e5</id>
<content type='text'>
for about a year, so it's safe to add the test and atexit() call.
While here, drop the no-longer-used obj and ps_strings and the
asm to set those up, switch from sys/param.h to limits.h, and ANSIfy.

ok kettenis@
</content>
</entry>
<entry>
<title>Pass install the -S option to avoid a window where the target isn't</title>
<updated>2011-11-08T10:37:09Z</updated>
<author>
<name>guenther</name>
<email>guenther@openbsd.org</email>
</author>
<published>2011-11-08T10:37:09Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-openbsd/commit/?id=f949d8e248f8c29054e838804ee72695d2b88423'/>
<id>urn:sha1:f949d8e248f8c29054e838804ee72695d2b88423</id>
<content type='text'>
executable (by mode or content), which can trip up builds with 'make -j'
(The generic fix is in share/mk/*; some Makefiles have their own INSTALL lines)

ok millert@ deraadt@
</content>
</entry>
<entry>
<title>Make sure everything run from .init and .fini sections gets a properly aligned</title>
<updated>2011-03-30T19:15:03Z</updated>
<author>
<name>kettenis</name>
<email>kettenis@openbsd.org</email>
</author>
<published>2011-03-30T19:15:03Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-openbsd/commit/?id=e76b0f7db23de89a573b3094b08a35b4d1f81c80'/>
<id>urn:sha1:e76b0f7db23de89a573b3094b08a35b4d1f81c80</id>
<content type='text'>
stack.

ok deraadt@, fgsch@
</content>
</entry>
</feed>
