1
0
mirror of https://github.com/openbsd/src.git synced 2025-01-03 06:45:37 -08:00

recognize .openbsd.randomdata section and indicate it roughly, so

that objects within it are identified as being in read-only space.
ok guenther
This commit is contained in:
deraadt 2017-12-09 06:39:04 +00:00
parent 636f8633b0
commit 06ccf07d57

View File

@ -1,4 +1,4 @@
/* $OpenBSD: elf.c,v 1.35 2017/10/27 16:47:08 mpi Exp $ */
/* $OpenBSD: elf.c,v 1.36 2017/12/09 06:39:04 deraadt Exp $ */
/*
* Copyright (c) 2003 Michael Shalayeff
@ -320,6 +320,8 @@ elf_shn2type(Elf_Ehdr *eh, u_int shn, const char *sn)
return (N_TEXT);
else if (!strcmp(sn, ELF_RODATA))
return (N_SIZE);
else if (!strcmp(sn, ELF_OPENBSDRANDOMDATA))
return (N_SIZE);
else if (!strcmp(sn, ELF_DATA))
return (N_DATA);
else if (!strcmp(sn, ELF_SDATA))