Bug 206260

Summary: Samba fails to recognise valid users = @netgroup under LDAP and no YP
Product: Red Hat Enterprise Linux 4 Reporter: Jose Plans <jplans>
Component: sambaAssignee: Simo Sorce <ssorce>
Status: CLOSED ERRATA QA Contact: David Lawrence <dkl>
Severity: medium Docs Contact:
Priority: medium    
Version: 4.4CC: jplans, samba-bugs-list
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: RHEA-2007-0698 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2007-11-15 16:14:42 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
Patch fixing the problem, adding lib/username.c for rev < 13494. none

Description Jose Plans 2006-09-13 10:21:14 UTC
Description of problem:

Samba administrators cannot let members of a netgroup to be allowed to access
files on the share when the NIS domain is empty or not defined.

When using :
       ----
  valid users = @netgroup
       ----

Syslog will report :
       ----
     lib/access.c:check_access(318)
       check_access: no hostnames in host allow/deny list.
     lib/access.c:check_access(329)
       Allowed connection from  (xxx.xxx.xxx.xxx)
     lib/username.c:user_in_netgroup_list(298)
       Unable to get default yp domain
     [..]
     smbd/service.c:make_connection(331)
       Invalid username/password for testdrw [sa_gadav]
     smbd/error.c:error_packet(113)
       error packet at smbd/reply.c(166) cmd=117 (SMBtconX) NT_STATUS_WRONG_PASSWORD
       ----

However if the administrator sets a user from that netgroup, then it's fine.
Applying patches from samba3 rev.17408 makes the problem disappear, Committed to
samba 23c.

>
http://viewcvs.samba.org/cgi-bin/viewcvs.cgi/branches/SAMBA_3_0/source/lib/access.c?rev=17408&r1=7139&r2=17408

Version-Release number of selected component (if applicable):
samba < 3.0.23c

How reproducible:
Always.

Additional info:
Volker removed from lib/username.c ( BOOL user_in_netgroup () ) in revision
13494, therefore the patch also applies lib/username.c as 3.0.10 is prior to
that change.
Patch attached.

    Jose

Comment 1 Jose Plans 2006-09-13 10:21:18 UTC
Created attachment 136144 [details]
Patch fixing the problem, adding lib/username.c for rev < 13494.

Comment 2 RHEL Program Management 2007-05-09 09:38:40 UTC
This request was evaluated by Red Hat Product Management for inclusion in a Red
Hat Enterprise Linux maintenance release.  Product Management has requested
further review of this request by Red Hat Engineering, for potential
inclusion in a Red Hat Enterprise Linux Update release for currently deployed
products.  This request is not yet committed for inclusion in an Update
release.

Comment 6 errata-xmlrpc 2007-11-15 16:14:42 UTC
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on the solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHEA-2007-0698.html