[apparmor] [Branch ~apparmor-dev/apparmor/master] Rev 3190: fix: rlimit unit parsing for time

Christian Boltz apparmor at cboltz.de
Sat Jul 11 12:26:22 UTC 2015


Hallo Leute,

Am Samstag, 11. Juli 2015 schrieb noreply at launchpad.net:
> +B<RLIMIT TIME> = I<NUMBER> ( 'us' | 'microsecond' | 'microseconds' |
> 'ms' | 'millisecond' | 'milliseconds' | 's' | | 'sec' | 'second' |
> 'seconds' | 'm' | 'min' | 'minute' | 'minutes' | 'h' | 'hour' |
> 'hours' | 'day' | 'days' | 'week' | 'weeks' ) Only applies to RLIMIT
> of 'cpu', 'rttime'. RLIMIT 'cpu' only allows units >= 'seconds'.

Wrong ;-)

Here's the fix:


[patch] Fix rlimit time units in apparmor.d.pod

- fix double | | between 's' and 'sec'
- remove 'm' which is not supported by the code
- add missing 'd'



[ apparmor.d-fix-time-units.diff ]

=== modified file 'parser/apparmor.d.pod'
--- parser/apparmor.d.pod       2015-07-11 01:16:09 +0000
+++ parser/apparmor.d.pod       2015-07-11 12:19:40 +0000
@@ -237,7 +237,7 @@
 
 B<RLIMIT NUMBER> = number from 0 to max rlimit value. Only applies ot RLIMIT of 'ofile', 'nofile', 'locks', 'sigpending', 'nproc', 'rtprio'
 
-B<RLIMIT TIME> = I<NUMBER> ( 'us' | 'microsecond' | 'microseconds' | 'ms' | 'millisecond' | 'milliseconds' | 's' | | 'sec' | 'second' | 'seconds' | 'm' | 'min' | 'minute' | 'minutes' | 'h' | 'hour' | 'hours' | 'day' | 'days' | 'week' | 'weeks' ) Only applies to RLIMIT of 'cpu', 'rttime'. RLIMIT 'cpu' only allows units >= 'seconds'.
+B<RLIMIT TIME> = I<NUMBER> ( 'us' | 'microsecond' | 'microseconds' | 'ms' | 'millisecond' | 'milliseconds' | 's' | 'sec' | 'second' | 'seconds' | 'min' | 'minute' | 'minutes' | 'h' | 'hour' | 'hours' | 'd' | 'day' | 'days' | 'week' | 'weeks' ) Only applies to RLIMIT of 'cpu', 'rttime'. RLIMIT 'cpu' only allows units >= 'seconds'.
 
 B<RLIMIT NICE> = a number between -20 and 19. Only applies to RLIMIT of 'nice'
 





Regards,

Christian Boltz
-- 
<mancha> the latest clamav recognizes and wipes systemd.
<sarnold> pre-emptive strike before systemd-virusd replaces them? :)
[from #apparmor]




More information about the AppArmor mailing list