Bug 794746

Summary: Internal error : ipa config-mod addattr on user and group search fields
Product: Red Hat Enterprise Linux 6 Reporter: Jenny Severance <jgalipea>
Component: ipaAssignee: Rob Crittenden <rcritten>
Status: CLOSED ERRATA QA Contact: IDM QE LIST <seceng-idm-qe-list>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 6.3CC: mgregg, mkosek
Target Milestone: rc   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: ipa-2.2.0-8.el6 Doc Type: Bug Fix
Doc Text:
No documentation needed.
Story Points: ---
Clone Of: Environment:
Last Closed: 2012-06-20 13:18:58 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description Jenny Severance 2012-02-17 14:16:45 UTC
Description of problem:

::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
:: [   LOG    ] :: ipaconfig_addaddtr negative test - ipagroupsearchfields - only one cn allowed - 
::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::

:: [   LOG    ] :: Executing: ipa config-mod --addattr=ipagroupsearchfields=newattr
:: [   LOG    ] :: "ipa config-mod --addattr=ipagroupsearchfields=newattr" failed as expected.
:: [   LOG    ] :: ERROR: Message not as expected. GOT: ipa: ERROR: an internal error has occurred  EXP: ipa: ERROR: ipagroupsearchfields: Only one value allowed.
:: [   FAIL   ] :: Verify expected error message. (Expected 0, got 1)
:: [   LOG    ] :: Duration: 4s
:: [   LOG    ] :: Assertions: 0 good, 1 bad
:: [   FAIL   ] :: RESULT: ipaconfig_addaddtr negative test - ipagroupsearchfields - only one cn allowed - 

::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
:: [   LOG    ] :: ipaconfig_addaddtr negative test - ipausersearchfields only one cn allowed - 
::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::

:: [   LOG    ] :: Executing: ipa config-mod --addattr=ipausersearchfields=newattr
:: [   LOG    ] :: "ipa config-mod --addattr=ipausersearchfields=newattr" failed as expected.
:: [   LOG    ] :: ERROR: Message not as expected. GOT: ipa: ERROR: an internal error has occurred  EXP: ipa: ERROR: ipausersearchfields: Only one value allowed.
:: [   FAIL   ] :: Verify expected error message. (Expected 0, got 1)
:: [   LOG    ] :: Duration: 3s
:: [   LOG    ] :: Assertions: 0 good, 1 bad
:: [   FAIL   ] :: RESULT: ipaconfig_addaddtr negative test - ipausersearchfields only one cn allowed - 



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

How reproducible:
always

Steps to Reproduce:
1. tests already automated
2.
3.
  
Actual results:
ipa: ERROR: an internal error has occurred

Expected results:
ipa: ERROR: ipagroupsearchfields: Only one value allowed.

Additional info:

httpd error log trace ::

[Fri Feb 17 09:10:27 2012] [error] ipa: INFO: admin: config_mod(addattr=(u'ipagroupsearchfields=newattr',), rights=False, all=False, raw=False, version=u'2.26'): AttributeError
[Fri Feb 17 09:10:29 2012] [error] ipa: ERROR: non-public: AttributeError: 'list' object has no attribute 'split'
[Fri Feb 17 09:10:29 2012] [error] Traceback (most recent call last):
[Fri Feb 17 09:10:29 2012] [error]   File "/usr/lib/python2.6/site-packages/ipaserver/rpcserver.py", line 232, in wsgi_execute
[Fri Feb 17 09:10:29 2012] [error]     result = self.Command[name](*args, **options)
[Fri Feb 17 09:10:29 2012] [error]   File "/usr/lib/python2.6/site-packages/ipalib/frontend.py", line 438, in __call__
[Fri Feb 17 09:10:29 2012] [error]     ret = self.run(*args, **options)
[Fri Feb 17 09:10:29 2012] [error]   File "/usr/lib/python2.6/site-packages/ipalib/frontend.py", line 696, in run
[Fri Feb 17 09:10:29 2012] [error]     return self.execute(*args, **options)
[Fri Feb 17 09:10:29 2012] [error]   File "/usr/lib/python2.6/site-packages/ipalib/plugins/baseldap.py", line 1203, in execute
[Fri Feb 17 09:10:29 2012] [error]     ldap, dn, entry_attrs, attrs_list, *keys, **options
[Fri Feb 17 09:10:29 2012] [error]   File "/usr/lib/python2.6/site-packages/ipalib/plugins/config.py", line 218, in pre_callback
[Fri Feb 17 09:10:29 2012] [error]     fields = entry_attrs[k].split(',')
[Fri Feb 17 09:10:29 2012] [error] AttributeError: 'list' object has no attribute 'split'
[Fri Feb 17 09:10:29 2012] [error] ipa: INFO: admin: config_mod(addattr=(u'ipausersearchfields=newattr',), rights=False, all=False, raw=False, version=u'2.26'): AttributeError
[Fri Feb 17 09:10:31 2012] [error] ipa: ERROR: non-public: AttributeError: 'list' object has no attribute 'split'
[Fri Feb 17 09:10:31 2012] [error] Traceback (most recent call last):
[Fri Feb 17 09:10:31 2012] [error]   File "/usr/lib/python2.6/site-packages/ipaserver/rpcserver.py", line 232, in wsgi_execute
[Fri Feb 17 09:10:31 2012] [error]     result = self.Command[name](*args, **options)
[Fri Feb 17 09:10:31 2012] [error]   File "/usr/lib/python2.6/site-packages/ipalib/frontend.py", line 438, in __call__
[Fri Feb 17 09:10:31 2012] [error]     ret = self.run(*args, **options)
[Fri Feb 17 09:10:31 2012] [error]   File "/usr/lib/python2.6/site-packages/ipalib/frontend.py", line 696, in run
[Fri Feb 17 09:10:31 2012] [error]     return self.execute(*args, **options)
[Fri Feb 17 09:10:31 2012] [error]   File "/usr/lib/python2.6/site-packages/ipalib/plugins/baseldap.py", line 1203, in execute
[Fri Feb 17 09:10:31 2012] [error]     ldap, dn, entry_attrs, attrs_list, *keys, **options
[Fri Feb 17 09:10:31 2012] [error]   File "/usr/lib/python2.6/site-packages/ipalib/plugins/config.py", line 218, in pre_callback
[Fri Feb 17 09:10:31 2012] [error]     fields = entry_attrs[k].split(',')
[Fri Feb 17 09:10:31 2012] [error] AttributeError: 'list' object has no attribute 'split'

Comment 1 Rob Crittenden 2012-02-17 18:44:05 UTC
Upstream ticket:
https://fedorahosted.org/freeipa/ticket/2407

Comment 2 Rob Crittenden 2012-04-04 14:53:57 UTC
fixed upstream

master: 8a7d7aaf810503befc174ce0465a08d086e47b91

ipa-2-2: 241955e4ce34f491168237f5a06bcb98daf22a5a

Comment 6 Martin Kosek 2012-04-24 11:52:18 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 7 Jenny Severance 2012-05-01 14:16:26 UTC
results with beta ipa-2.2.0-8.el6 ::

::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
:: [   LOG    ] :: ipaconfig_addaddtr negative test - ipagroupsearchfields - only one allowed
::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::

:: [   LOG    ] :: Executing: ipa config-mod --addattr=ipagroupsearchfields=newattr
:: [   LOG    ] :: "ipa config-mod --addattr=ipagroupsearchfields=newattr" failed as expected.
:: [   PASS   ] :: Error message as expected: ipa: ERROR: ipagroupsearchfields: Only one value allowed.
:: [   PASS   ] :: Verify expected error message.
:: [   LOG    ] :: Verifies bugzilla https://bugzilla.redhat.com/show_bug.cgi?id=794746
:: [   LOG    ] :: Duration: 6s
:: [   LOG    ] :: Assertions: 2 good, 0 bad
:: [   PASS   ] :: RESULT: ipaconfig_addaddtr negative test - ipagroupsearchfields - only one allowed

::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
:: [   LOG    ] :: ipaconfig_addaddtr negative test - ipausersearchfields only one allowed
::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::

:: [   LOG    ] :: Executing: ipa config-mod --addattr=ipausersearchfields=newattr
:: [   LOG    ] :: "ipa config-mod --addattr=ipausersearchfields=newattr" failed as expected.
:: [   PASS   ] :: Error message as expected: ipa: ERROR: ipausersearchfields: Only one value allowed.
:: [   PASS   ] :: Verify expected error message.
:: [   LOG    ] :: Verifies bugzilla https://bugzilla.redhat.com/show_bug.cgi?id=794746
:: [   LOG    ] :: Duration: 6s
:: [   LOG    ] :: Assertions: 2 good, 0 bad
:: [   PASS   ] :: RESULT: ipaconfig_addaddtr negative test - ipausersearchfields only one allowed


results with ipa-server-2.2.0-11.el6 ::

::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
:: [   LOG    ] :: Add additional allowed user object class
::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::

ipa: ERROR: an internal error has occurred
:: [   FAIL   ] :: Add additional allowed objectclass (Expected 0, got 1)
:: [   FAIL   ] :: User object classes not as expected. 
ipa: ERROR: ipauserobjectclasses does not contain 'sambasamaccount'
:: [   FAIL   ] :: Running 'ipa config-mod --delattr=ipauserobjectclasses=sambasamaccount' (Expected 0, got 1)

::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
:: [   LOG    ] :: Add additional allowed group object class
::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::

ipa: ERROR: an internal error has occurred
:: [   FAIL   ] :: Add additional allowed objectclass (Expected 0, got 1)
:: [   FAIL   ] :: Group objectclasses not as expected. 
ipa: ERROR: ipagroupobjectclasses does not contain 'posixgroup'
:: [   FAIL   ] :: Running 'ipa config-mod --delattr=ipagroupobjectclasses=posixgroup' (Expected 0, got 1)


/var/log/httpd/error_log ::
[Tue May 01 10:13:16 2012] [error] ipa: INFO: admin: group_del((u'mygroup',), continue=False): SUCCESS
[Tue May 01 10:14:44 2012] [error] ipa: ERROR: non-public: TypeError: can only concatenate tuple (not "list") to tuple
[Tue May 01 10:14:44 2012] [error] Traceback (most recent call last):
[Tue May 01 10:14:44 2012] [error]   File "/usr/lib/python2.6/site-packages/ipaserver/rpcserver.py", line 320, in wsgi_execute
[Tue May 01 10:14:44 2012] [error]     result = self.Command[name](*args, **options)
[Tue May 01 10:14:44 2012] [error]   File "/usr/lib/python2.6/site-packages/ipalib/frontend.py", line 438, in __call__
[Tue May 01 10:14:44 2012] [error]     ret = self.run(*args, **options)
[Tue May 01 10:14:44 2012] [error]   File "/usr/lib/python2.6/site-packages/ipalib/frontend.py", line 716, in run
[Tue May 01 10:14:44 2012] [error]     return self.execute(*args, **options)
[Tue May 01 10:14:44 2012] [error]   File "/usr/lib/python2.6/site-packages/ipalib/plugins/baseldap.py", line 1278, in execute
[Tue May 01 10:14:44 2012] [error]     ldap, dn, entry_attrs, attrs_list, *keys, **options
[Tue May 01 10:14:44 2012] [error]   File "/usr/lib/python2.6/site-packages/ipalib/plugins/config.py", line 233, in pre_callback
[Tue May 01 10:14:44 2012] [error]     + self.api.Object[obj].possible_objectclasses))
[Tue May 01 10:14:44 2012] [error] TypeError: can only concatenate tuple (not "list") to tuple
[Tue May 01 10:14:44 2012] [error] ipa: INFO: admin: config_mod(addattr=(u'ipauserobjectclasses=sambasamaccount',), rights=False, all=False, raw=False, version=u'2.34'): TypeError
[Tue May 01 10:15:33 2012] [error] ipa: ERROR: non-public: TypeError: can only concatenate tuple (not "list") to tuple
[Tue May 01 10:15:33 2012] [error] Traceback (most recent call last):
[Tue May 01 10:15:33 2012] [error]   File "/usr/lib/python2.6/site-packages/ipaserver/rpcserver.py", line 320, in wsgi_execute
[Tue May 01 10:15:33 2012] [error]     result = self.Command[name](*args, **options)
[Tue May 01 10:15:33 2012] [error]   File "/usr/lib/python2.6/site-packages/ipalib/frontend.py", line 438, in __call__
[Tue May 01 10:15:33 2012] [error]     ret = self.run(*args, **options)
[Tue May 01 10:15:33 2012] [error]   File "/usr/lib/python2.6/site-packages/ipalib/frontend.py", line 716, in run
[Tue May 01 10:15:33 2012] [error]     return self.execute(*args, **options)
[Tue May 01 10:15:33 2012] [error]   File "/usr/lib/python2.6/site-packages/ipalib/plugins/baseldap.py", line 1278, in execute
[Tue May 01 10:15:33 2012] [error]     ldap, dn, entry_attrs, attrs_list, *keys, **options
[Tue May 01 10:15:33 2012] [error]   File "/usr/lib/python2.6/site-packages/ipalib/plugins/config.py", line 233, in pre_callback
[Tue May 01 10:15:33 2012] [error]     + self.api.Object[obj].possible_objectclasses))
[Tue May 01 10:15:33 2012] [error] TypeError: can only concatenate tuple (not "list") to tuple

Comment 8 Jenny Severance 2012-05-01 16:47:47 UTC
closing bug verified in 2.2.0-8 and opening new bug for new errors.

Comment 10 errata-xmlrpc 2012-06-20 13:18:58 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