[Issue#] N/A
[Bug] Patches applied in different version in RSA and private repository
[Cause] Developers not careful enough about applying patches in both places
[Solution] Move missing bits of code
[Verification] Build
Change-Id: If1f65e07b44e1a2ad40f9d67f0ae211511948632
if(added == NULL)
goto error;
+ ret = generate_random_cookie(added->cookie, SECURITY_SERVER_COOKIE_LEN);
+ if(ret != SECURITY_SERVER_SUCCESS)
+ {
+ SEC_SVR_DBG("Error on making random cookie: %d", ret);
+ free(added);
+ added = NULL;
+ goto error;
+ }
+
/* Check SMACK label */
if (smack_check())
{
ret = smack_new_label_from_socket(sockfd, &smack_label);
if (ret != 0)
- {
- SEC_SVR_DBG("Error checking peer label: %d", ret);
- free(added);
- added = NULL;
- goto error;
- }
+ {
+ SEC_SVR_DBG("Error checking peer label: %d", ret);
+ free(added);
+ added = NULL;
+ goto error;
+ }
}
/* Check SMACK label */
}
}
- added->path = exe;
- exe = NULL;
added->permission_len = perm_num;
added->pid = pid;
added->permissions = permissions;
const char * const LABEL_SECURITY_SERVER_API_DATA_SHARE = "security-server::api-data-share";
-const char * const LABEL_SECURITY_SERVER_API_DATA_SHARE = "security-server::api-data-share";
-
/* Set cookie as a global variable */
cookie_list *c_list;
pthread_mutex_t cookie_mutex;