Modification about smack label of db file belong to process. 63/20663/2 accepted/tizen/common/20140519.230052 accepted/tizen/mobile/20140602.132536 submit/tizen/20140516.061019
authorjooseong.lee <jooseong.lee@samsung.com>
Mon, 12 May 2014 00:57:58 +0000 (09:57 +0900)
committerjooseong lee <jooseong.lee@samsung.com>
Mon, 12 May 2014 00:57:43 +0000 (17:57 -0700)
[Problem]
Most db files have 'floor' label.  Because these are created during image creation time.
Therefore no process can write the dbs (since 'floor' label allows only read and execute)

[Solution]
Modify smack label of the db files based on condition below referring three domain model
Condition1. Assign domain of process which creates db files
Condition2. Assign domain of process accesses db files.

Change-Id: Idd4a2e446c5d7db4b93777a871f2478055a0818e
Signed-off-by: jooseong.lee <jooseong.lee@samsung.com>
packaging/ail.spec

index 7f061d3..20cbf7f 100755 (executable)
@@ -80,6 +80,7 @@ mkdir -p %{TZ_SYS_DB}
 
 update_DAC_for_db_file %{TZ_SYS_DB}/.app_info.db
 update_DAC_for_db_file %{TZ_SYS_DB}/.app_info.db-journal
+chsmack -a 'User' %{TZ_SYS_DB}/.app_info.db*
 
 %postun
 /sbin/ldconfig