Bug 1660489 - Fact imports erroneously cause audits to be created
Summary: Fact imports erroneously cause audits to be created
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Satellite
Classification: Red Hat
Component: Audit Log
Version: 6.4
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: 6.5.0
Assignee: satellite6-bugs
QA Contact: Roman Plevka
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2018-12-18 12:58 UTC by Lukas Zapletal
Modified: 2020-07-01 11:41 UTC (History)
6 users (show)

Fixed In Version: foreman-1.20.0
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2019-05-14 12:39:36 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Foreman Issue Tracker 25331 0 High Closed Fact imports erranously cause audits to be created 2020-07-07 16:21:58 UTC
Red Hat Product Errata RHSA-2019:1222 0 None None None 2019-05-14 12:39:46 UTC

Description Lukas Zapletal 2018-12-18 12:58:15 UTC
For very fact import an audit record is written although nothing changes.

#<Audited::Audit id: 8238963, auditable_id: 30056, auditable_type: "Nic::Managed", user_id: 4, user_type: nil, username: "API Admin", action: "update", audited_changes: {"attrs"=>[{"mtu"=>"1500", "netmask"=>"255.255.224.0", "netmask6"=>"ffff:ffff:ffff:ffff::", "network"=>"172.22.0.0", "network6"=>"fe80::"}, {"mtu"=>1500, "netmask"=>"255.255.224.0", "netmask6"=>"ffff:ffff:ffff:ffff::", "network"=>"172.22.0.0", "network6"=>"fe80::"}]}, version: 7, comment: nil, associated_id: 23973, associated_type: "Host::Base", request_uuid: "7263349c-f216-415a-8721-f7464856031e", created_at: "2018-10-29 10:08:25", remote_address: "1.2.3.4", auditable_name: "xxxxx...", associated_name: "xxxx...">

This creates unnecessary load on Satellite 6.4+. Please z-stream.

Comment 3 Lukas Zapletal 2018-12-18 12:59:25 UTC
This is oneliner, please cherry pick. Small change, big performance impact.

https://github.com/theforeman/foreman/pull/6198

Comment 4 Roman Plevka 2019-03-21 10:11:44 UTC
VERIFIED
6.5.0 snap #20
despite multiple PUT requests to the /facts endpoint, these no longer produce audit records

Comment 6 errata-xmlrpc 2019-05-14 12:39:36 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHSA-2019:1222


Note You need to log in before you can comment on or make changes to this bug.