mirror of
https://gitlab.com/apparmor/apparmor
synced 2025-08-31 22:35:35 +00:00
handle_binfmt: resolve symlinks in library paths
This should happen rarely, but nevertheless it can happen - and since AppArmor needs the symlink target in the profile, we have to resolve all symlinks. Acked-by: Kshitij Gupta <kgupta8592@gmail.com>
This commit is contained in:
@@ -391,6 +391,7 @@ def handle_binfmt(profile, path):
|
|||||||
reqs = get_reqs(path)
|
reqs = get_reqs(path)
|
||||||
while reqs:
|
while reqs:
|
||||||
library = reqs.pop()
|
library = reqs.pop()
|
||||||
|
library = get_full_path(library) # resolve symlinks
|
||||||
if not reqs_processed.get(library, False):
|
if not reqs_processed.get(library, False):
|
||||||
if get_reqs(library):
|
if get_reqs(library):
|
||||||
reqs += get_reqs(library)
|
reqs += get_reqs(library)
|
||||||
|
Reference in New Issue
Block a user