From: Dariusz Michaluk Date: Mon, 7 May 2018 09:10:44 +0000 (+0200) Subject: Merge branch 'tizen' into nether X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=refs%2Fchanges%2F05%2F178005%2F1;hp=-c;p=platform%2Fcore%2Ftest%2Fsecurity-tests.git Merge branch 'tizen' into nether Change-Id: Ibbe2fd16bc7f4576d27bae7e9a1893d8ec04dc91 --- ebe27cef1d61c3fb976579d997f195421bc1ed25 diff --combined CMakeLists.txt index 2687162,01ce9fb..ea0f922 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@@ -1,4 -1,4 +1,4 @@@ -# Copyright (c) 2012-2015 Samsung Electronics Co., Ltd All Rights Reserved +# Copyright (c) 2012-2017 Samsung Electronics Co., Ltd All Rights Reserved # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@@ -15,7 -15,6 +15,7 @@@ # @file CMakeLists.txt # @author Bartlomiej Grzelewski (b.grzelewski@samsung.com) # @author Pawel Polawski (p.polawski@partner.samsung.com) +# @author Piotr Sawicki (p.sawicki2@partner.samsung.com) # @brief # @@@ -65,7 -64,6 +65,7 @@@ IF(BUILD_ALL_TESTS SET(BUILD_CYNARA ON) SET(BUILD_WEB ON) SET(BUILD_YACA ON) + SET(BUILD_NETHER ON) ENDIF(BUILD_ALL_TESTS) # If supported for the target machine, emit position-independent code,suitable @@@ -102,7 -100,9 +102,9 @@@ ENDIF(NOT DEFINED SHARE_INSTALL_PREFIX ############################# Targets names ################################### + SET(TARGET_CKM_TEST_COMMON "ckm-test-common") SET(TARGET_CKM_TESTS "ckm-tests") + SET(TARGET_CKM_PRIVILEGED_TESTS "ckm-privileged-tests") SET(TARGET_CKMI_TESTS "ckm-integration-tests") SET(COMMON_TARGET_TEST "tests-common") diff --combined packaging/security-tests.manifest index 3dfa317,a6ecbcd..790c851 --- a/packaging/security-tests.manifest +++ b/packaging/security-tests.manifest @@@ -1,17 -1,12 +1,13 @@@ - - - - - + + diff --combined packaging/security-tests.spec index ed63dd2,f96f79b..4145d08 --- a/packaging/security-tests.spec +++ b/packaging/security-tests.spec @@@ -21,6 -21,7 +21,7 @@@ BuildRequires: pkgconfig(libpcrecpp BuildRequires: pkgconfig(libxml-2.0) BuildRequires: pkgconfig(sqlite3) BuildRequires: pkgconfig(libwebappenc) + BuildRequires: pkgconfig(openssl) BuildRequires: cynara-devel BuildRequires: libcynara-creds-dbus-devel BuildRequires: libcynara-creds-gdbus-devel @@@ -32,8 -33,6 +33,8 @@@ BuildRequires: pkgconfig(security-privi Requires: perf Requires: gdb Requires: diffutils +Requires: iproute2 +Requires: toybox-symlinks-ping %global ckm_test_dir %{?TZ_SYS_SHARE:%TZ_SYS_SHARE/ckm-test/}%{!?TZ_SYS_SHARE:/usr/share/ckm-test/} %global ckm_rw_data_dir %{?TZ_SYS_DATA:%TZ_SYS_DATA/ckm/}%{!?TZ_SYS_DATA:/opt/data/ckm/} @@@ -85,10 -84,6 +86,10 @@@ echo "security-tests postinst done ... /usr/bin/security-tests.sh /usr/bin/security-tests-all.sh /usr/bin/test-performance-check.sh +/usr/bin/setup-nether-tests-nns.sh +/usr/bin/teardown-nether-tests-nns.sh +/usr/bin/setup-nether-tests-dns.sh +/usr/bin/teardown-nether-tests-dns.sh /etc/dbus-1/system.d/security-tests.conf @@@ -104,9 -99,10 +105,11 @@@ %attr(755, security_test_user,users) %{TZ_SYS_HOME}/security_test_user/apps_rw/* /usr/bin/cynara-test /usr/bin/ckm-tests + /usr/bin/ckm-privileged-tests + /usr/bin/ckm-tests-on-onlycap.sh /usr/bin/ckm-integration-tests /usr/bin/yaca-test +/usr/bin/nether-tests %{ckm_test_dir}/* /etc/security-tests /usr/lib/security-tests/cynara-tests/plugins/single-policy/* diff --combined src/security-tests.sh index b86c61e,89be46f..6490ac6 --- a/src/security-tests.sh +++ b/src/security-tests.sh @@@ -1,7 -1,7 +1,7 @@@ #!/bin/sh ##################################################################### - # Copyright (c) 2012-2017 Samsung Electronics Co., Ltd All Rights Reserved + # Copyright (c) 2012-2018 Samsung Electronics Co., Ltd All Rights Reserved # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@@ -42,9 -42,14 +42,14 @@@ case $1 i ;; "ckm") echo "=========================================================================" - echo "KEY MANAGER TESTS" + echo "KEY MANAGER UNPRIVILEGED TESTS" echo - ckm-tests "${@:2}" + ARGS="${@:2}" + su - owner -c "ckm-tests $ARGS" + echo "=========================================================================" + echo "KEY MANAGER PRIVILEGED TESTS" + echo + ckm-tests-on-onlycap.sh $ARGS ;; "yaca") echo "=========================================================================" @@@ -52,17 -57,11 +57,17 @@@ echo yaca-test "${@:2}" ;; +"nether") + echo "=========================================================================" + echo "NETHER TESTS" + echo + nether-tests "${@:2}" + ;; *) echo "Correct using:" echo " security_test.sh " echo - echo "modules: smack, security-manager, cynara, ckm, yaca" + echo "modules: smack, security-manager, cynara, ckm, yaca, nether" ;; esac