Bugzilla – Bug 127893
Can't use /proc/pid/attr/current to set confinement of tasks started before apparmor loaded
Last modified: 2005-10-25 04:58:18 UTC
Normally, you can write "setprofile /name/of/profile" to /proc/pid/attr/current from an unconfined root process to change which profile a currently running process is confined by, but this doesn't currently work on processes that were already running before the apparmor module was loaded, even though it claims to. # ps -AZ | grep gaim unconstrained 9878 ? 00:00:03 gaim # echo -n "setprofile /opt/gnome/bin/gaim" > /proc/9878/attr/current # tail -2 /var/log/messages Oct 12 01:11:51 daedalus kernel: SubDomain: sd_setprocattr_setprofile: task gaim(9878) has no subdomain Oct 12 01:11:51 daedalus kernel: SubDomain: sd_setprocattr_setprofile: Switching task gaim(9878) profile unconstrained active unconstrained to new profile /opt/gnome/bin/gaim # cat /proc/9878/attr/current unconstrained # ps -AZ | grep gaim unconstrained 9878 ? 00:00:03 gaim
Fixed in r5484