Note: This bug is displayed in read-only format because
the product is no longer active in Red Hat Bugzilla.
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.
Description of problem:
ipa sudorule-add-user restricts users names to a limited variety of characters. At the very least @ and \ should be included to cover username conventions used for AD trusted users. When I try now, I see this:
[root@rhel6-1 failure1]# ipa sudorule-add-user testrule --users=adtestuser1
ipa: ERROR: invalid 'user': may only include letters, numbers, _, -, . and $
In addition Simo mentioned in an email:
We should allow any character in this case.
These are external user/group names, we do not have any control on them.
If I want to add the user ätest@foo^^bar in /etc/passwd then I should be
allowed to use it in a sudo rule
Version-Release number of selected component (if applicable):
ipa-server-3.0.0-106.20121026T1837zgitf14dd98.el6.x86_64
How reproducible:
Always
Steps to Reproduce:
1. Setup IPA Master
2. ipa sudorule-add testrule
3. ipa sudorule-add-user --users=test
Actual results:
error listed above
Expected results:
success
Additional info:
After Sumit brought up a good point, I'm modifying this request.
Instead of modifying --users option functionality, I'd like to request a new --external (or similar) option. This will allow a distinction between adding IPA users and External ones coming from other sources like AD.
I'd think we'd keep the option similar to the group-add one used when adding AD groups/users to a group in IPA.
The bugzilla doesn't have high enough priority in comparison to other bugs/RFEs for 7.4. Moving to next release. Without sufficient justification it can be moved again later.
Verified using ipa-server-4.9.1-1.module+el8.4.0+9665+c9815399.x86_64 and ipa-server-trust-ad-4.9.1-1.module+el8.4.0+9665+c9815399.x86_64 in RHEL8.4 nightly build.
Passed test_integration/test_trust.py::TestTrust::()::test_sudorules_ad_users
Passed test_integration/test_trust.py::TestTrust::()::test_sudorules_ad_groups
Passed test_integration/test_trust.py::TestTrust::()::test_sudorules_ad_runasuser
Passed test_integration/test_trust.py::TestTrust::()::test_sudorules_ad_runasuser_group
Passed test_integration/test_trust.py::TestTrust::()::test_sudorules_ad_runasgroup
Full test log is available as an attachment of this BZ.
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-2021:1846