Bug 1214418

Summary: yast2 apparmor: crash when choosing "
Product: [openSUSE] openSUSE Tumbleweed Reporter: Christian Boltz <suse-beta>
Component: YaST2Assignee: E-mail List <yast2-maintainers>
Status: RESOLVED FIXED QA Contact: Jiri Srain <jsrain>
Severity: Normal    
Priority: P5 - None CC: suse-beta
Version: Current   
Target Milestone: ---   
Hardware: Other   
OS: Other   
Whiteboard:
Found By: --- Services Priority:
Business Priority: Blocker: ---
Marketing QA Status: --- IT Deployment: ---
Attachments: y2log
full y2logs

Description Christian Boltz 2023-08-20 16:10:22 UTC
Created attachment 868897 [details]
y2log

Precondition: make sure you have an "exec" event in your audit.log, for example by adding the following (made-up) line to your /var/log/audit/audit.log:

type=AVC msg=audit(1692535178.922:9306963): apparmor="ALLOWED" operation="exec" class="file" profile="ping" name="/usr/bin/cat" pid=25489 comm="hello" requested_mask="x" denied_mask="x" fsuid=1000 ouid=0 target="ping//null-/usr/bin/cat"


Then
- start yast2 apparmor
- select "Scan Audit logs"
- click "Launch"
- when asked for the execute mode, choose "Named"
- in the following dialog ("transition to local profile?), click "yes"
- get the following error dialog:

===
Internal error. Please report a bug report with logs.
Run save_y2logs to get complete logs.

Caller: /usr/share/YaST2/lib/apparmor/apparmor_ui_dialog.rb:128:in `run'

Details: uninitialized constant AppArmor::GetStringDialog::Label
===

Only y2log (attached) got updated while reproducing this bug.
Comment 1 Stefan Hundhammer 2023-08-20 16:50:13 UTC
Christian, you know the deal: We need the full y2logs tarball produced by the "save_y2logs" script, not some randomly selected single file.

It's in the FAQ since 20+ years.
Comment 2 Christian Boltz 2023-08-20 17:28:35 UTC
Created attachment 868898 [details]
full y2logs

As you wish ;-) - here are the full logs.

In case you wonder - I have AppArmor 4.0 alpha2 installed. The json format didn't change since 3.1.x *), therefore this shouldn't be relevant for this bug. Nevertheless, if you want me to double-check, i can temporarily downgrade to the official Tumbleweed packages.

*) The question I asked in yast-devel a few weeks ago only affects cases where aa-logprof crashes on startup, which is not the case here.
Comment 4 Michal Filka 2023-08-22 09:21:58 UTC
(hopefully) fixed in yast2-apparmor 4.6.2