[apparmor] [PATCH] genprof: Use important message as an explanation
Goldwyn Rodrigues
rgoldwyn at suse.de
Fri Jul 14 12:14:14 UTC 2017
While performing genprof, The message to start and scan the program
is mentioned in a separate important message, while it can be
presented as a part of the explanation of the PromptQuestion.
While this will not change the output of text mode, this will help
yast be more expressive.
Note, it would miss logging the message under debug_logger.debug() as
a part of UI_Important.
Signed-off-by: Goldwyn Rodrigues <rgoldwyn at suse.com>
diff --git a/utils/aa-genprof b/utils/aa-genprof
index c9415e10..4029066a 100755
--- a/utils/aa-genprof
+++ b/utils/aa-genprof
@@ -126,8 +126,6 @@ atexit.register(restore_ratelimit)
aaui.UI_Info(_('\nBefore you begin, you may wish to check if a\nprofile already exists for the application you\nwish to confine. See the following wiki page for\nmore information:')+'\nhttp://wiki.apparmor.net/index.php/Profiles')
-aaui.UI_Important(_('Please start the application to be profiled in\nanother window and exercise its functionality now.\n\nOnce completed, select the "Scan" option below in \norder to scan the system logs for AppArmor events. \n\nFor each AppArmor event, you will be given the \nopportunity to choose whether the access should be \nallowed or denied.'))
-
syslog = True
logmark = ''
done_profiling = False
@@ -150,6 +148,7 @@ while not done_profiling:
q.headers = [_('Profiling'), program]
q.functions = ['CMD_SCAN', 'CMD_FINISHED']
q.default = 'CMD_SCAN'
+ q.explanation = _('Please start the application to be profiled in\nanother window and exercise its functionality now.\n\nOnce completed, select the "Scan" option below in \norder to scan the system logs for AppArmor events. \n\nFor each AppArmor event, you will be given the \nopportunity to choose whether the access should be \nallowed or denied.')
ans, arg = q.promptUser('noexit')
if ans == 'CMD_SCAN':
More information about the AppArmor
mailing list