OSDN Git Service

apparmor: isolate policy backwards compatibility to its own file
authorJohn Johansen <john.johansen@canonical.com>
Mon, 22 Aug 2022 05:48:32 +0000 (22:48 -0700)
committerJohn Johansen <john.johansen@canonical.com>
Mon, 3 Oct 2022 21:49:03 +0000 (14:49 -0700)
commitcaa9f579ca7255e9d6c25f072447d895c5928c97
treeb9751e8f8fa2b95416d6e2691c54ef2ac6dca4a7
parentae6d35ed0a481824a8730c39d5b319c8a76ea00e
apparmor: isolate policy backwards compatibility to its own file

The details of mapping old policy into newer policy formats clutters
up the unpack code and makes it possible to accidentally use old
mappings in code, so isolate the mapping code into its own file.

This will become more important when the dfa remapping code lands,
as it will greatly expand the compat code base.

Signed-off-by: John Johansen <john.johansen@canonical.com>
security/apparmor/Makefile
security/apparmor/include/policy_compat.h [new file with mode: 0644]
security/apparmor/include/policy_unpack.h
security/apparmor/policy_compat.c [new file with mode: 0644]
security/apparmor/policy_unpack.c