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 810948 - Unable to disable or enable hbacrule with --setattr [regression]
Summary: Unable to disable or enable hbacrule with --setattr [regression]
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: ipa
Version: 6.3
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: rc
: ---
Assignee: Rob Crittenden
QA Contact: IDM QE LIST
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-04-09 17:50 UTC by Jenny Severance
Modified: 2012-06-20 13:26 UTC (History)
1 user (show)

Fixed In Version: ipa-2.2.0-9.el6
Doc Type: Bug Fix
Doc Text:
No documentation needed.
Clone Of:
Environment:
Last Closed: 2012-06-20 13:26:40 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2012:0819 0 normal SHIPPED_LIVE ipa bug fix and enhancement update 2012-06-19 20:34:17 UTC

Description Jenny Severance 2012-04-09 17:50:06 UTC
Description of problem:

# ipa hbacrule-mod --setattr ipaenabledflag=1 test
ipa: ERROR: ipaEnabledFlag: value #0 invalid per syntax: Invalid syntax.

# ipa hbacrule-mod --setattr ipaenabledflag=0 test
ipa: ERROR: ipaEnabledFlag: value #0 invalid per syntax: Invalid syntax.

# ipa hbacrule-mod --setattr ipaenabledflag=FALSE test
ipa: ERROR: ipaEnabledFlag: value #0 invalid per syntax: Invalid syntax.

# ipa hbacrule-mod --setattr ipaenabledflag=TRUE test
ipa: ERROR: ipaEnabledFlag: value #0 invalid per syntax: Invalid syntax.

# ipa hbacrule-mod --setattr ipaenabledflag=False test
ipa: ERROR: ipaEnabledFlag: value #0 invalid per syntax: Invalid syntax.

# ipa hbacrule-mod --setattr ipaenabledflag=True test
ipa: ERROR: ipaEnabledFlag: value #0 invalid per syntax: Invalid syntax.

::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
:: [   LOG    ] :: ipa-hbacrule-cli-015: Negative - setattr and addattr on ipaEnabledFlag
::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::

:: [   LOG    ] :: Executing: ipa hbacrule-mod --setattr ipaenabledflag=test test
:: [   LOG    ] :: "ipa hbacrule-mod --setattr ipaenabledflag=test test" failed as expected.
:: [   PASS   ] :: Error message as expected: ipa: ERROR: invalid 'ipaenabledflag': must be True or False
:: [   PASS   ] :: Verify expected error message for --setattr on ipaEnabledFlag.
:: [   FAIL   ] :: Disable rule using setattr modification. (Expected 0, got 1)
:: [   LOG    ] :: ERROR: Expect test Enabled status to be FALSE. GOT: TRUE
:: [   PASS   ] :: Verify rule is now disabled
:: [   LOG    ] :: Executing: ipa hbacrule-mod --addattr ipaenabledflag=TRUE test
:: [   LOG    ] :: "ipa hbacrule-mod --addattr ipaenabledflag=TRUE test" failed as expected.
:: [   PASS   ] :: Error message as expected: ipa: ERROR: ipaenabledflag: Only one value allowed.
:: [   PASS   ] :: Verify expected error message for --addattr on ipaEnabledFlag.
:: [   LOG    ] :: Duration: 9s
:: [   LOG    ] :: Assertions: 5 good, 1 bad
:: [   FAIL   ] :: RESULT: ipa-hbacrule-cli-015: Negative - setattr and addattr on ipaEnabledFlag


Version-Release number of selected component (if applicable):
ipa-server-2.2.0-8.el6.x86_64

How reproducible:


Steps to Reproduce:
1.ipa hbacrule-add --desc=test test
2.ipa hbacrule-mod --setattr ipaenabledflag=FALSE test
3.
  
Actual results:
ipa: ERROR: ipaEnabledFlag: value #0 invalid per syntax: Invalid syntax.

Expected results:
Rule to be disabled

Additional info:

Comment 2 Martin Kosek 2012-04-10 10:44:49 UTC
This is a regression introduced in this patch:

https://fedorahosted.org/freeipa/changeset/241955e4ce34f491168237f5a06bcb98daf22a5a/

We do not encode parameters present only for LDAPObject and for LDAPCommand properly. I will open an upstream ticket.

Comment 3 Martin Kosek 2012-04-10 10:45:49 UTC
Upstream ticket:
https://fedorahosted.org/freeipa/ticket/2616

Comment 4 Rob Crittenden 2012-04-10 22:34:45 UTC
master: 1431c80b3c2a256bb6c10cf042f7671004695a9f

ipa-2-2: 32fa7f7a48b3d956b0ec5dbea9cd22db504a562d

Comment 7 Jenny Severance 2012-04-11 14:47:29 UTC
verified :

::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
:: [   LOG    ] :: ipa-hbacrule-cli-015: Negative - setattr and addattr on ipaEnabledFlag
::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::

:: [   LOG    ] :: Executing: ipa hbacrule-mod --setattr ipaenabledflag=test test
:: [   LOG    ] :: "ipa hbacrule-mod --setattr ipaenabledflag=test test" failed as expected.
:: [   PASS   ] :: Error message as expected: ipa: ERROR: invalid 'ipaenabledflag': must be True or False
:: [   PASS   ] :: Verify expected error message for --setattr on ipaEnabledFlag.
:: [   PASS   ] :: Disable rule using setattr modification.
:: [   LOG    ] :: test is FALSE as expected.
:: [   PASS   ] :: Verify rule is now disabled
:: [   LOG    ] :: Executing: ipa hbacrule-mod --addattr ipaenabledflag=TRUE test
:: [   LOG    ] :: "ipa hbacrule-mod --addattr ipaenabledflag=TRUE test" failed as expected.
:: [   PASS   ] :: Error message as expected: ipa: ERROR: ipaenabledflag: Only one value allowed.
:: [   PASS   ] :: Verify expected error message for --addattr on ipaEnabledFlag.
:: [   LOG    ] :: Duration: 17s
:: [   LOG    ] :: Assertions: 6 good, 0 bad
:: [   PASS   ] :: RESULT: ipa-hbacrule-cli-015: Negative - setattr and addattr on ipaEnabledFlag

version :
ipa-server-2.2.0-9.el6.x86_64

Comment 9 Martin Kosek 2012-04-25 11:47:14 UTC
    Technical note added. If any revisions are required, please edit the "Technical Notes" field
    accordingly. All revisions will be proofread by the Engineering Content Services team.
    
    New Contents:
No documentation needed.

Comment 11 errata-xmlrpc 2012-06-20 13:26:40 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.

http://rhn.redhat.com/errata/RHBA-2012-0819.html


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