RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 1859213 - AVC denial during ipa-adtrust-install --add-agents
Summary: AVC denial during ipa-adtrust-install --add-agents
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 8
Classification: Red Hat
Component: ipa
Version: 8.3
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: rc
: ---
Assignee: Thomas Woerner
QA Contact: ipa-qe
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2020-07-21 13:26 UTC by Sergey Orlov
Modified: 2021-09-03 15:13 UTC (History)
10 users (show)

Fixed In Version: ipa-4.8.7-8.el8
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2020-11-04 02:51:20 UTC
Type: Bug
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Fedora Pagure freeipa issue 8436 0 None None None 2020-07-29 12:45:01 UTC
Red Hat Product Errata RHSA-2020:4670 0 None None None 2020-11-04 02:51:37 UTC

Description Sergey Orlov 2020-07-21 13:26:23 UTC
The bug is created as a copy of https://bugzilla.redhat.com/show_bug.cgi?id=1820298 (versions and AVC messages updated):

Description of problem:
When configuring an AD trust agent, the command ipa-adtrust-install --add-agents is unable to configure the additional agent.

Version-Release number of selected component (if applicable):
ipa-server-4.8.7-4.module+el8.3.0+7221+eedbd403
selinux-policy-3.14.3-48.el8

How reproducible:
Always

Steps to Reproduce:
1. install ipa master with ipa-server-install
2. install ipa replica with ipa-replica-install
3. run ipa-adtrust-install --add-sids --a password --enable-compat --add-agents
When the command prompts for configuration of additional masters, answer yes

Actual results:
The command fails to configure the replica as a trust agent and prints:
WARNING: you MUST manually enable the Schema compatibility Plugin and 

WARNING: you MUST restart (both "ipactl restart" and "systemctl restart sssd")
the following IPA masters in order to activate them to serve information about
users from trusted forests:

<replica-fqdn>

Expected results:
The command should succeed.


Additional info:
ipa-adtrust-install launches a remote command on the replica though IPA XMLRPC. This command is using oddjob to execute a CLI but when SE linux is in enforcing mode, this mechanism fails with the following AVC:

time->Tue Jul 21 09:21:25 2020
type=PROCTITLE msg=audit(1595337685.098:640): proctitle=2F7573722F7362696E2F6F64646A6F6264002D6E002D70002F7661722F72756E2F6F64646A6F62642E706964002D7400333030
type=SYSCALL msg=audit(1595337685.098:640): arch=c000003e syscall=59 success=no exit=-13 a0=56160271e4d0 a1=561602720e20 a2=56160272ea90 a3=0 items=0 ppid=9514 pid=10077 auid=4294967295 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 tty=(none) ses=4294967295 comm="oddjobd" exe="/usr/sbin/oddjobd" subj=system_u:system_r:oddjob_t:s0-s0:c0.c1023 key=(null)
type=AVC msg=audit(1595337685.098:640): avc:  denied  { transition } for  pid=10077 comm="oddjobd" path="/usr/libexec/ipa/oddjob/org.freeipa.server.trust-enable-agent" dev="vda1" ino=1741562 scontext=system_u:system_r:oddjob_t:s0-s0:c0.c1023 tcontext=system_u:system_r:httpd_t:s0 tclass=process permissive=0

On Fedora 31+, freeipa delivers his own selinux policy and the following line was added in selinux/ipa.fc to fix the issue:

/usr/libexec/ipa/oddjob/org\.freeipa\.server\.trust-enable-agent  --  gen_context(system_u:object_r:ipa_helper_exec_t,s0)

Comment 19 errata-xmlrpc 2020-11-04 02:51:20 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 (Moderate: idm:DL1 and idm:client security, bug fix, and enhancement update), 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-2020:4670


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