Commit bce6a32
selinux: fix avdcache auditing
commit f92d542 upstream.
The per-task avdcache was incorrectly saving and reusing the
audited vector computed by avc_audit_required() rather than
recomputing based on the currently requested permissions and
distinguishing the denied versus allowed cases. As a result,
some permission checks were not being audited, e.g.
directory write checks after a previously cached directory
search check.
Cc: stable@vger.kernel.org
Fixes: dde3a5d ("selinux: move avdcache to per-task security struct")
Signed-off-by: Stephen Smalley <stephen.smalley.work@gmail.com>
[PM: line wrap tweaks]
Signed-off-by: Paul Moore <paul@paul-moore.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>1 parent 2ffaa7a commit bce6a32
2 files changed
Lines changed: 14 additions & 21 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3207 | 3207 | | |
3208 | 3208 | | |
3209 | 3209 | | |
3210 | | - | |
3211 | 3210 | | |
3212 | | - | |
| 3211 | + | |
3213 | 3212 | | |
3214 | 3213 | | |
3215 | 3214 | | |
3216 | 3215 | | |
3217 | | - | |
3218 | | - | |
| 3216 | + | |
3219 | 3217 | | |
3220 | 3218 | | |
3221 | 3219 | | |
| |||
3227 | 3225 | | |
3228 | 3226 | | |
3229 | 3227 | | |
3230 | | - | |
3231 | | - | |
3232 | | - | |
| 3228 | + | |
3233 | 3229 | | |
3234 | 3230 | | |
3235 | 3231 | | |
| |||
3250 | 3246 | | |
3251 | 3247 | | |
3252 | 3248 | | |
| 3249 | + | |
3253 | 3250 | | |
3254 | 3251 | | |
3255 | 3252 | | |
| |||
3271 | 3268 | | |
3272 | 3269 | | |
3273 | 3270 | | |
3274 | | - | |
3275 | | - | |
3276 | | - | |
3277 | | - | |
| 3271 | + | |
| 3272 | + | |
| 3273 | + | |
| 3274 | + | |
3278 | 3275 | | |
3279 | 3276 | | |
3280 | | - | |
3281 | | - | |
3282 | 3277 | | |
3283 | 3278 | | |
3284 | | - | |
3285 | | - | |
3286 | | - | |
3287 | | - | |
3288 | | - | |
| 3279 | + | |
| 3280 | + | |
3289 | 3281 | | |
3290 | 3282 | | |
| 3283 | + | |
| 3284 | + | |
| 3285 | + | |
3291 | 3286 | | |
3292 | 3287 | | |
3293 | 3288 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
32 | 32 | | |
33 | 33 | | |
34 | 34 | | |
35 | | - | |
36 | | - | |
37 | | - | |
| 35 | + | |
38 | 36 | | |
39 | 37 | | |
40 | 38 | | |
| |||
0 commit comments