[apparmor] test failures in test-aa-easyprof.py
Tyler Hicks
tyhicks at canonical.com
Mon Dec 4 18:51:14 UTC 2017
Hi - Please put me in the To or CC headers next time you directly
address me in an email. I don't always have time to read every piece of
mail that hits this list and this is a subject that I'd typically skip
in those times.
On 12/03/2017 08:16 AM, Christian Boltz wrote:
> Hello,
>
> I get several failures from test-aa-easyprof.py, for example
>
> ======================================================================
> ERROR: test_output_directory_single (__main__.T)
> Test output_directory (single)
> ----------------------------------------------------------------------
> Traceback (most recent call last):
> File "test-aa-easyprof.py", line 2439, in test_output_directory_single
> easyp.output_policy(params, dir=out_dir)
> File "/home/cb/apparmor/git/apparmor/utils/apparmor/easyprof.py", line 696, in output_policy
> policy = self.gen_policy(**params)
> File "/home/cb/apparmor/git/apparmor/utils/apparmor/easyprof.py", line 690, in gen_policy
> raise AppArmorException("Invalid policy")
> apparmor.easyprof.AppArmorException: 'Invalid policy'
>
>
> There's a total of 50 errors, all with 'Invalid policy'.
>
> git bisect tracked this down to
>
>
> 7ab65fa5f13c774088d64c3881df798c63d87a44 is the first bad commit
> commit 7ab65fa5f13c774088d64c3881df798c63d87a44
> Author: Tyler Hicks <tyhicks at canonical.com>
> Date: Thu Mar 2 21:24:33 2017 +0000
>
> utils: Set parser executable path according to USE_SYSTEM make variable
>
> if USE_SYSTEM is not set, the utils make check target will instruct
> test-aa-easyprof.py to provide the path of the in-tree parser executable
> to aa-easyprof.
>
> If USE_SYSTEM is set, the default parser path (/sbin/apparmor_parser or
> the result of `which apparmor_parser`) is used.
>
> The test-aa-easyprof.py script receives the parser path by checking the
> __AA_PARSER environment variable. This environment variable is strictly
> used by the test script and not any user-facing code so two leading
> underscores were used.
>
> Signed-off-by: Tyler Hicks <tyhicks at canonical.com>
> Acked-by: Christian Boltz <apparmor at cboltz.de>
> Acked-by: Seth Arnold <seth.arnold at canonical.com>
>
> :040000 040000 870632a03f5f6b013312ed6e68ac0a13c54573a7 b6b046c11c47cb5ed2dbe125ed45c19e5c3e9114 M utils
>
>
> The "fix" is make -C parser but I'd prefer to have a Makefile
> dependency instead of confusing and misleading test failures ;-)
>
> Tylor, since you broke it, can you please submit a fix for trunk and 2.11? ;-)
https://gitlab.com/apparmor/apparmor/merge_requests/25
Tyler
> (based on the commit date, I'd guess that older releases aren't affected)
>
> Also, a better error message than 'Invalid policy' would be helpful ;-)
>
>
> Regards,
>
> Christian Boltz
>
>
>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 801 bytes
Desc: OpenPGP digital signature
URL: <https://lists.ubuntu.com/archives/apparmor/attachments/20171204/8af0dad5/attachment.sig>
More information about the AppArmor
mailing list