zlog(ZLOG_SYSERROR,"[pool %s] failed to query apparmor confinement. Please check if \"/proc/*/attr/current\" is read and writeable.",wp->config->name);
zlog(ZLOG_SYSERROR,"[pool %s] failed to construct apparmor confinement.",wp->config->name);
return-1;
}
if(0>aa_change_profile(new_con)){
zlog(ZLOG_SYSERROR,"[pool %s] failed to change to new confinement (%s). Please check if \"/proc/*/attr/current\" is read and writeable and \"change_profile -> %s//*\" is allowed.",wp->config->name,new_con,con);
return-1;
}
free(con);
free(new_con);
}
if(wp->config->apparmor_hat){
char*con,*new_con;
if(aa_getcon(&con,NULL)==-1){
zlog(ZLOG_SYSERROR,"[pool %s] failed to query apparmor confinement. Please check if \"/proc/*/attr/current\" is read and writeable.",wp->config->name);
zlog(ZLOG_SYSERROR,"[pool %s] failed to construct apparmor confinement.",wp->config->name);
return-1;
}
if(0>aa_change_profile(new_con)){
zlog(ZLOG_SYSERROR,"[pool %s] failed to change to new confinement (%s). Please check if \"/proc/*/attr/current\" is read and writeable and \"change_profile -> %s//*\" is allowed.",wp->config->name,new_con,con);