Move the stack protector to a new "secure" directory

As part of the code refactoring to support FORTIFY_SOURCE we want
a new subdirectory "secure" to keep the files related to security.
Move the stack protector functions to this new directory.

No functional change.

Differential Review:	https://reviews.freebsd.org/D3333
This commit is contained in:
Pedro F. Giffuni 2015-08-14 03:03:13 +00:00
parent 6a182dddd9
commit fe0d386cf3
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=286760
7 changed files with 27 additions and 5 deletions

View File

@ -95,6 +95,7 @@ NOASM=
.include "${LIBC_SRCTOP}/stdtime/Makefile.inc"
.include "${LIBC_SRCTOP}/string/Makefile.inc"
.include "${LIBC_SRCTOP}/sys/Makefile.inc"
.include "${LIBC_SRCTOP}/secure/Makefile.inc"
.include "${LIBC_SRCTOP}/rpc/Makefile.inc"
.include "${LIBC_SRCTOP}/uuid/Makefile.inc"
.include "${LIBC_SRCTOP}/xdr/Makefile.inc"

View File

@ -0,0 +1,12 @@
# $FreeBSD$
#
# libc sources related to security
.PATH: ${LIBC_SRCTOP}/secure
# Sources common to both syscall interfaces:
SRCS+= \
stack_protector.c \
stack_protector_compat.c
SYM_MAPS+= ${LIBC_SRCTOP}/secure/Symbol.map

View File

@ -0,0 +1,14 @@
/*
* $FreeBSD$
*/
/*
* It'd be nice to have this automatically generated, but we don't
* know to what version they will eventually belong, so for now
* it has to be manual.
*/
FBSD_1.0 {
__chk_fail;
__stack_chk_fail;
__stack_chk_guard;
};

View File

@ -21,8 +21,6 @@ PSEUDO+= _clock_gettime.o _gettimeofday.o
# Sources common to both syscall interfaces:
SRCS+= \
stack_protector.c \
stack_protector_compat.c \
__error.c \
interposing_table.c

View File

@ -56,7 +56,6 @@ FBSD_1.0 {
bind;
chdir;
chflags;
__chk_fail;
chmod;
chown;
chroot;
@ -281,8 +280,6 @@ FBSD_1.0 {
sigwaitinfo;
socket;
socketpair;
__stack_chk_fail;
__stack_chk_guard;
stat;
statfs;
swapoff;