OSDN Git Service

Add stack canaries / strcpy tests.
authorNick Kralevich <nnk@google.com>
Fri, 11 Jan 2013 01:12:29 +0000 (17:12 -0800)
committerNick Kralevich <nnk@google.com>
Fri, 11 Jan 2013 18:52:36 +0000 (10:52 -0800)
commitdcab1b2c76a498c56bc00024613386de8b4b2aae
tree6d7eb1ea166186df3092552b190b4485658b3e68
parentbfde0b6fd9e5de545746ab963d3a05ed2a8014f6
Add stack canaries / strcpy tests.

Add a test to ensure that stack canaries are working
correctly. Since stack canaries aren't normally generated
on non-string functions, we have to enable stack-protector-all.

Add a test to ensure that an out of bounds strcpy generates
a runtime failure.

Change-Id: Id0d3e59fc4b9602da019e4d35c5c653e1a57fae4
tests/Android.mk
tests/stack_protector_test.cpp
tests/string_test.cpp