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 1583725 - SSSD AD uses LDAP filter to detect POSIX attributes stored in AD GC also for regular AD DC queries
Summary: SSSD AD uses LDAP filter to detect POSIX attributes stored in AD GC also for ...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: sssd
Version: 7.5
Hardware: All
OS: Linux
high
high
Target Milestone: rc
: ---
Assignee: Jakub Hrozek
QA Contact: sssd-qe
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2018-05-29 14:37 UTC by Thorsten Scherf
Modified: 2022-03-13 15:02 UTC (History)
11 users (show)

Fixed In Version: sssd-1.16.2-5.el7
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2018-10-30 10:42:30 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github SSSD sssd issues 4760 0 None closed SSSD AD uses LDAP filter to detect POSIX attributes stored in AD GC also for regular AD DC queries 2021-02-11 08:40:35 UTC
Red Hat Product Errata RHSA-2018:3158 0 None None None 2018-10-30 10:43:34 UTC

Description Thorsten Scherf 2018-05-29 14:37:05 UTC
Description of problem:
SSSD uses the following LDAP query to detect if the AD Global Catalog (GC) server can be used to retrieve POSIX attributes:

'(|(&(uidNumber=*)(objectClass=user))(&(gidNumber=*)(objectClass=group)))'  

The filter is used with a sizelimit of '1' but AD is not properly honoring the sizelimit. This issue is tracked in BZ #1582975. 

The other issue is that this query should only go to the Global Catalog server but with the current version of SSSD we do see this query also going to regular AD DCs. 

Version-Release number of selected component (if applicable):
sssd-1.16.0-19.el7.x86_64

Steps to Reproduce:
1. Configure SSSD with AD provider.
2. Create an AD account with POSIX attributes
3. Login into the SSSD client using this account

Actual results:
The LDAP query listed above goes to a regular AD DC. Because of the issue reported in BZ #1582975 it might happen that SSSD runs into a timeout and the next server is contacted. This might end up in an infinite loop until the search can be completed.


Expected results:
LDAP query goes only to AD GC server.

Additional info:
This is a possible regression.

Comment 2 Jakub Hrozek 2018-06-07 03:31:25 UTC
Upstream ticket:
https://pagure.io/SSSD/sssd/issue/3754

Comment 3 Jakub Hrozek 2018-06-28 09:25:18 UTC
* master: 5e1641b

Comment 8 Dan Lavu 2018-08-20 15:23:16 UTC
Verified against sssd-1.16.2-12.el7.x86_64

# Testing a user with posix attributes

(Mon Aug 20 11:09:01 2018) [sssd[be[sssd2012r2.com]]] [ad_check_gc_usability_send] (0x0400): Checking for POSIX attributes in GC
(Mon Aug 20 11:09:01 2018) [sssd[be[sssd2012r2.com]]] [sdap_print_server] (0x2000): Searching 10.8.63.92:389
(Mon Aug 20 11:09:01 2018) [sssd[be[sssd2012r2.com]]] [sdap_get_generic_ext_step] (0x0400): calling ldap_search_ext with [(&(objectclass=attributeSchema)(|(cn=uidNumber)(cn=gidNumber)))][CN=Schema,CN=Configuration,DC=sssd2012r2,DC=com].
(Mon Aug 20 11:09:01 2018) [sssd[be[sssd2012r2.com]]] [sdap_get_generic_ext_step] (0x1000): Requesting attrs: [cn]
(Mon Aug 20 11:09:01 2018) [sssd[be[sssd2012r2.com]]] [sdap_get_generic_ext_step] (0x1000): Requesting attrs: [isMemberOfPartialAttributeSet]
(Mon Aug 20 11:09:01 2018) [sssd[be[sssd2012r2.com]]] [sdap_get_generic_ext_step] (0x2000): ldap_search_ext called, msgid = 10
(Mon Aug 20 11:09:01 2018) [sssd[be[sssd2012r2.com]]] [sdap_op_add] (0x2000): New operation 10 timeout 6
(Mon Aug 20 11:09:01 2018) [sssd[be[sssd2012r2.com]]] [sdap_process_result] (0x2000): Trace: sh[0x55faa87a7280], connected[1], ops[0x55faa87b8270], ldap[0x55faa87a3460]
(Mon Aug 20 11:09:01 2018) [sssd[be[sssd2012r2.com]]] [sdap_process_result] (0x2000): Trace: end of ldap_result list
(Mon Aug 20 11:09:01 2018) [sssd[be[sssd2012r2.com]]] [be_ptask_online_cb] (0x0400): Back end is online
(Mon Aug 20 11:09:01 2018) [sssd[be[sssd2012r2.com]]] [be_ptask_enable] (0x0080): Task [SUDO Smart Refresh]: already enabled
(Mon Aug 20 11:09:01 2018) [sssd[be[sssd2012r2.com]]] [sdap_process_result] (0x2000): Trace: sh[0x55faa87a7280], connected[1], ops[0x55faa87b8270], ldap[0x55faa87a3460]
(Mon Aug 20 11:09:01 2018) [sssd[be[sssd2012r2.com]]] [sdap_process_message] (0x4000): Message type: [LDAP_RES_SEARCH_ENTRY]
(Mon Aug 20 11:09:01 2018) [sssd[be[sssd2012r2.com]]] [sdap_parse_entry] (0x1000): OriginalDN: [].
(Mon Aug 20 11:09:01 2018) [sssd[be[sssd2012r2.com]]] [sdap_parse_range] (0x2000): No sub-attributes for [netlogon]
(Mon Aug 20 11:09:01 2018) [sssd[be[sssd2012r2.com]]] [sdap_process_result] (0x2000): Trace: sh[0x55faa87a7280], connected[1], ops[0x55faa87b8270], ldap[0x55faa87a3460]
(Mon Aug 20 11:09:01 2018) [sssd[be[sssd2012r2.com]]] [sdap_process_message] (0x4000): Message type: [LDAP_RES_SEARCH_RESULT]
(Mon Aug 20 11:09:01 2018) [sssd[be[sssd2012r2.com]]] [sdap_get_generic_op_finished] (0x0400): Search result: Success(0), no errmsg set
(Mon Aug 20 11:09:01 2018) [sssd[be[sssd2012r2.com]]] [sdap_op_destructor] (0x2000): Operation 9 finished


# Testing a user with no posix attributes 

(Mon Aug 20 11:09:01 2018) [sssd[be[sssd2012r2.com]]] [ad_check_gc_usability_search_done] (0x0080): Cannot get isMemberOfPartialAttributeSet(Mon Aug 20 11:09:01 2018) [sssd[be[sssd2012r2.com]]] [ad_check_gc_usability_search_done] (0x0080): Cannot get isMemberOfPartialAttributeSet(Mon Aug 20 11:09:01 2018) [sssd[be[sssd2012r2.com]]] [ad_disable_gc] (0x0040): POSIX attributes were requested but are not present on the server side. Global Catalog lookups will be disabled

Comment 10 errata-xmlrpc 2018-10-30 10:42:30 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-2018:3158


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