Implement setting process label for the given application 07/24407/2
authorJacek Bukarewicz <j.bukarewicz@samsung.com>
Fri, 11 Jul 2014 13:40:00 +0000 (15:40 +0200)
committerJacek Bukarewicz <j.bukarewicz@samsung.com>
Tue, 15 Jul 2014 14:54:39 +0000 (16:54 +0200)
commitc04544c3f90a5bc93ebab58971f24042aeeaa95d
treedd51291248ee01c42153d28a8bd40b5ce67496a9
parente22c8b9318cfb9efaed5456950b57860b0f2fb47
Implement setting process label for the given application

This change introduces functions for setting smack label for
application process. They are intended to be used by the app launcher
on application start.

2 variants have been implemented:
1) security_manager_set_process_label_from_binary
   Function extracts smack label from the given application binary and sets
   it for the current process
2) security_manager_set_process_label_from_appid
   Function computes smack label for given application id and sets it for
   current process

Change-Id: I4dfbaf133ec43e292f4ba54023b96a57df439562
Signed-off-by: Jacek Bukarewicz <j.bukarewicz@samsung.com>
12 files changed:
src/client/CMakeLists.txt
src/client/client-common.cpp
src/client/client-security-manager.cpp
src/client/include/client-common.h
src/common/CMakeLists.txt
src/common/include/smack-common.h [new file with mode: 0644]
src/common/smack-common.cpp [new file with mode: 0644]
src/include/security-manager.h
src/server/service/include/smack-labels.h
src/server/service/installer.cpp
src/server/service/smack-labels.cpp
src/server/service/smack-rules.cpp