[apparmor] [patch] aa.py: split off parse_profile_start() from parse_profile_data() and add tests

Christian Boltz apparmor at cboltz.de
Sun Mar 1 18:36:29 UTC 2015


Hello,

Am Sonntag, 1. März 2015 schrieb Christian Boltz:
> --- test-aa.py---nur-get-profile-flags  2015-03-01 17:37:24.789364744 
> +0100
> +++ test-aa.py  2015-03-01 18:41:33.062731404 +0100

That's of course utils/test/test-aa.py (which I had to diff manually 
because the import line depends on the get_profile_flags() tests patch).

> === modified file 'utils/apparmor/aa.py'
> --- utils/apparmor/aa.py        2015-02-20 20:36:55 +0000
> +++ utils/apparmor/aa.py        2015-03-01 17:42:11 +0000
> @@ -2632,6 +2642,49 @@
>      for p in profile_data.keys():
>          profiles[p] = deepcopy(profile_data[p])
>  
> +
> +def parse_profile_start(line, file, lineno, profile, hat):
> +    print (line)
> +    print("    profile %s   hat %s   file %s" % (profile, hat, file))

Please ignore those two "print" lines - I just removed them from my 
local copy of the patch ;-)

(Thanks to Kshitij for pointing this out!)


Regards,

Christian Boltz
-- 
> If there is some software side way of knowing that...
In this case special hardware, called hammer will help ;-P
[>  Carlos E. R. and Cristian Rodríguez in opensuse-factory]




More information about the AppArmor mailing list