Skip to content

Commit

Permalink
Add CVE .gitignore, Makefile and runtest files
Browse files Browse the repository at this point in the history
Signed-off-by: Richard Palethorpe <[email protected]>
  • Loading branch information
Richard Palethorpe authored and metan-ucw committed Jul 19, 2017
1 parent b058919 commit 1140e92
Show file tree
Hide file tree
Showing 5 changed files with 36 additions and 0 deletions.
5 changes: 5 additions & 0 deletions runtest/cve
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# Tests which check for vulnerabilities by CVE number
cve-2012-0957 cve-2012-0957
cve-2016-4997 cve-2016-4997
cve-2016-5195 dirtyc0w
cve-2016-7117 cve-2016-7117
2 changes: 2 additions & 0 deletions runtest/syscalls
Original file line number Diff line number Diff line change
Expand Up @@ -1141,6 +1141,7 @@ set_tid_address01 set_tid_address01
setsid01 setsid01

setsockopt01 setsockopt01
cve-2016-4997 cve-2016-4997

settimeofday01 settimeofday01
settimeofday02 settimeofday02
Expand Down Expand Up @@ -1353,6 +1354,7 @@ umask01 umask01
uname01 uname01
uname02 uname02
uname03 uname03
cve-2012-0957 cve-2012-0957

unlink01 symlink01 -T unlink01
unlink05 unlink05
Expand Down
1 change: 1 addition & 0 deletions scenario_groups/default
Original file line number Diff line number Diff line change
Expand Up @@ -32,3 +32,4 @@ can
cpuhotplug
net.ipv6_lib
input
cve
3 changes: 3 additions & 0 deletions testcases/cve/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
cve-2012-0957
cve-2016-4997
cve-2016-7117
25 changes: 25 additions & 0 deletions testcases/cve/Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# Copyright (c) 2017 Linux Test Project
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License as
# published by the Free Software Foundation; either version 2 of
# the License, or (at your option) any later version.
#
# This program is distributed in the hope that it would be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.

top_srcdir ?= ../..

include $(top_srcdir)/include/mk/testcases.mk

CFLAGS += -D_GNU_SOURCE

cve-2014-0196: LDFLAGS += -lpthread -lutil -lrt
cve-2016-7117: LDFLAGS += -lpthread -lrt

include $(top_srcdir)/include/mk/generic_leaf_target.mk

0 comments on commit 1140e92

Please sign in to comment.