[apparmor] [PATCH 3/5] Make setprocattr more abstract so it will work for any pid

Kees Cook kees.cook at canonical.com
Tue Jul 12 19:01:06 UTC 2011


Hi John,

On Tue, Jul 12, 2011 at 11:49:03AM -0700, John Johansen wrote:
> -	rc = setprocattr("/proc/%d/attr/exec", buf, len);
> +	rc = setprocattr(aa_gettid(), "/proc/%d/attr/exec", buf, len);
> [...]
> -	rc = setprocattr("/proc/%d/attr/current", buf, pos - buf);
> +	rc = setprocattr(aa_gettid(), "/proc/%d/attr/current", buf, pos - buf);

Shouldn't these be "exec" and "current", not the whole path?

-Kees

-- 
Kees Cook
Ubuntu Security Team



More information about the AppArmor mailing list