Skip to content
Snippets Groups Projects
Commit 38821597 authored by Frédéric Dalleau's avatar Frédéric Dalleau :sun_with_face: Committed by Simon McVittie
Browse files

apparmor-ofono: open a root-owned file

ofono runs as root, so having the "malicious" LD_PRELOAD module read
/home/user/.bash_history requires it to exercise CAP_DAC_OVERRIDE,
leading to an AppArmor denial that doesn't match what we expect. Try
to read /etc/shadow instead, and update the expected denials
accordingly.

With that change, there's no real need for the "malicious" code to use
GLib, so use stdio instead.

Apertis: https://phabricator.apertis.org/T1848



Signed-off-by: default avatarFrédéric Dalleau <frederic.dalleau@collabora.co.uk>
Reviewed-by: default avatarSimon McVittie <simon.mcvittie@collabora.co.uk>
Differential Revision: https://phabricator.apertis.org/D4388
parent 70152d17
No related branches found
No related tags found
No related merge requests found
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment