User level smack check for rm_livebox, rm_shortcut
authorSung-jae Park <nicesj.park@samsung.com>
Tue, 25 Jun 2013 02:41:37 +0000 (11:41 +0900)
committerSung-jae Park <nicesj.park@samsung.com>
Tue, 25 Jun 2013 02:41:37 +0000 (11:41 +0900)
Change-Id: Ic02a1c42e96e6cb665632a9425a2369ef69c39ef

src/shortcut_service.c

index b5b1d82..14f840c 100644 (file)
@@ -112,12 +112,12 @@ static int service_thread_main(struct tcb *tcb, struct packet *packet, void *dat
 
                /* Need to send reply packet */
                DbgPrint("%p REQ: Command: [%s]\n", tcb, command);
-               if (!strcmp(command, "add_livebox")) {
+               if (!strcmp(command, "add_livebox") || !strcmp(command, "rm_livebox")) {
                        ret = security_server_check_privilege_by_sockfd(tcb_fd(tcb), "data-provider-master::shortcut.livebox", "w");
                        if (ret == SECURITY_SERVER_API_ERROR_ACCESS_DENIED) {
                                ErrPrint("SMACK:Access denied\n");
                        }
-               } else if (!strcmp(command, "add_shortcut")) {
+               } else if (!strcmp(command, "add_shortcut") || !strcmp(command, "rm_shortcut")) {
                        ret = security_server_check_privilege_by_sockfd(tcb_fd(tcb), "data-provider-master::shortcut.shortcut", "w");
                        if (ret == SECURITY_SERVER_API_ERROR_ACCESS_DENIED) {
                                ErrPrint("SMACK:Access denied\n");