1
0
mirror of https://github.com/samba-team/samba.git synced 2025-02-05 21:57:51 +03:00

1176 Commits

Author SHA1 Message Date
Günther Deschner
4121ccfc3e r16939: Still clear the winbind_cache.tdb when offline logons are not enabled.
Guenther
2007-10-10 11:19:12 -05:00
Günther Deschner
ebd3c547e5 r16823: Allow to call wbinfo --domain-info="" or --domain-info="." to get domain
info for our own domain.

Guenther
2007-10-10 11:19:11 -05:00
Simo Sorce
c139a2293b r16800: correct a probable cut&paste error 2007-10-10 11:19:11 -05:00
Günther Deschner
48ab7f4681 r16790: Fix memleak.
Guenther
2007-10-10 11:19:10 -05:00
Volker Lendecke
6fa928f96a r16755: Hunting warning has some benefits....
Solaris found this one that needs to go into 3.0.23, actually munlock the
password memory.

Volker
2007-10-10 11:19:10 -05:00
Jeremy Allison
c4896b17fa r16687: Fix bugs #3901, #3902, #3903 reported by jason@ncac.gwu.edu.
Jeremy
2007-10-10 11:19:08 -05:00
Jeremy Allison
5c5ea3152f r16678: Fix bug #3898 reported by jason@ncac.gwu.edu.
Jeremy.
2007-10-10 11:19:07 -05:00
Jeremy Allison
ee2b2d96b6 r16644: Fix bug #3887 reported by jason@ncac.gwu.edu
by converting the lookup_XX functions to correctly
return SID_NAME_TYPE enums.
Jeremy.
2007-10-10 11:19:05 -05:00
Jeremy Allison
4e7262c81a r16610: Subtle one from Klocwork #2076. If multiple flags
are set in a winbindd request it might overwrite existing
state->response.extra_data.data values without freeing.
Jeremy.
2007-10-10 11:19:03 -05:00
Günther Deschner
5853525f11 r16480: (Ugly) workaround before the set_dc_type_flags & friends cleanup:
When trying to login using krb5 with a trusted domain account, we
need to make sure that our and the remote domain are AD.

Guenther
2007-10-10 11:18:56 -05:00
Günther Deschner
098a87f492 r16479: When dcip_to_name failed to get the name of the ip in saf_servername we
cannot put saf_name in the failed conn cache as it's uninitialized.
Store saf_servername (the ip) in that case.

Volker, please check.

Guenther
2007-10-10 11:18:56 -05:00
Günther Deschner
d6b52e8181 r16475: destroy talloc ctx when we weren't able to collect onlinestatus
messages.

Guenther
2007-10-10 11:18:56 -05:00
Günther Deschner
dfbe555c69 r16474: There is no point in figuring out lockout policies if we do not allow
offline logons at all.

Guenther
2007-10-10 11:18:55 -05:00
Günther Deschner
520777f794 r16473: There is no point in calling set_dc_type_and_flags() before each
pam_auth login (when using kerberos).

Guenther
2007-10-10 11:18:55 -05:00
Jeremy Allison
e83c3e0a65 r16422: winbindd_demote_client isn't used and generates
a Klocwork issue (#1844). Remove it
Jeremy.
2007-10-10 11:18:52 -05:00
Volker Lendecke
8a5cebc19e r16361: Fix Klocwork ID 1731 1770 1771 1775 1796
Volker
2007-10-10 11:18:49 -05:00
Jeremy Allison
09c8973286 r16358: ALWAYS compile this stuff on a 64-bit box before
checking in. size_t != uint32 on a 64-bit machine.
Jeremy.
2007-10-10 11:18:48 -05:00
Günther Deschner
d8fd94648f r16349: Another fix to make winbind more robust in large domains:
We may only feed rpc_useraliases with chunks of 1024 entries.  This is
important as the token generation otherwise fails when a user is member
of more then 1024 groups.

Volker, please check.

Guenther
2007-10-10 11:17:37 -05:00
Jeremy Allison
938545f535 r16285: On a 64-bit box, size_t != uint32. Ensure we use
the right parameter type.
Jeremy.
2007-10-10 11:17:31 -05:00
Jeremy Allison
face01ef01 r16284: Start fixing up gcc4 -O6 warnings on an x86_64 box. size_t != unsigned
int
in a format string.
Jeremy.
2007-10-10 11:17:31 -05:00
Günther Deschner
5ecfaf7d50 r16222: Fix DEBUG statements.
Guenther
2007-10-10 11:17:26 -05:00
Günther Deschner
58a7c09003 r16221: No need for friednly error messages at log level 10.
Guenther
2007-10-10 11:17:26 -05:00
Volker Lendecke
b5602cc4f1 r16196: A bit of defensive programming:
Klocwork ID 1773 complained about oldest being dereferenced in line 2275 where
it could be NULL. I think you can construct extreme racy conditions where this
actually could happen.

Volker
2007-10-10 11:17:24 -05:00
Günther Deschner
65643d3172 r16192: Fix timeformats in the winbind response struct.
(pam_winbind users were forced to change a password inappropriately)

Guenther
2007-10-10 11:17:23 -05:00
Günther Deschner
e7d2b84aba r16187: Fix memleak.
Guenther
2007-10-10 11:17:23 -05:00
Günther Deschner
aeff1f0c47 r16154: Fix winbind function table typo.
Guenther
2007-10-10 11:17:23 -05:00
Günther Deschner
3a738a855d r16114: Make winbindd's group enumeration (set|get|endgrent) work again (when
enabled).

Do not bail out when a group just has 0 members.

Jeremy, please check, this has been removed with r13915.

Guenther
2007-10-10 11:17:21 -05:00
Günther Deschner
8759a00fed r16080: Re-add accidentially excluded in-forest domain trusts (fixes bug #3823).
Guenther
2007-10-10 11:17:20 -05:00
Günther Deschner
3c9416c2be r15985: Adding "own-domain" switch to wbinfo which is handy from time to time.
Guenther
2007-10-10 11:17:16 -05:00
Günther Deschner
29758ea1c4 r15984: Correctly handle the case when there is no configuration file for
pam_winbind.

Guenther
2007-10-10 11:17:16 -05:00
Günther Deschner
216125fe13 r15983: Honour the krb5 principal name change (of the new ads join code) in the
kerberized winbind pam_auth.

Guenther
2007-10-10 11:17:16 -05:00
Günther Deschner
3f5a2e49c1 r15982: Fix confusing order of DEBUG statements in winbindds pam_auth.
Guenther
2007-10-10 11:17:16 -05:00
Günther Deschner
4addabd054 r15977: Fillup the password_policy method in winbindd for winbindd_passdb. This
should make pam_winbind work again on a Samba PDC (and fix Bug #3800).

Guenther
2007-10-10 11:17:16 -05:00
Günther Deschner
2678582c6c r15976: Set our internal domains to "online" by default in winbindd.
Guenther
2007-10-10 11:17:16 -05:00
Volker Lendecke
b1244e7906 r15904: This does two things:
Fix more potential segfaults when something on our way to a DC connection
fails.

We can not continue if dcip_to_name() fails. With

192.168.234.100 nt4pdc
192.168.234.100 windows#1c
192.168.234.100 windows#1b

in the lmhosts file when nt4pdc is rebooted, we do find the DC's IP address,
we can connect to TCP 139 while it is booting but anything else fails. So we
fall back to put the IP address into domain->dcname. When the DC is fully up
later on we try to do the auth2 against \\192.168.234.100 which gives
INVALID_COMPUTER_NAME. And we never get out of this loop again.

Fix this.

Jerry, maybe you can take a look.

Thanks,

Volker
2007-10-10 11:17:12 -05:00
Volker Lendecke
c8a8204c74 r15845: Ok. This was a tough one. If for some reason the tconX fails towards a domain
controller the next time we connect this child ran into a segfault because it
tried to reference a half-baked connection.

Volker
2007-10-10 11:17:11 -05:00
Gerald Carter
39f7ff75a7 r15842: patch from volker to instruct winbindd to find a trusted DC on its own when runing on a Samba DC (since we don't implement the getdcname() call that well 2007-10-10 11:17:10 -05:00
Volker Lendecke
e4a2cb4b91 r15705: Fix bug number 3788. Thanks to Jeff Wright.
Volker
2007-10-10 11:17:09 -05:00
Günther Deschner
7d766b5505 r15698: An attempt to make the winbind lookup_usergroups() call in security=ads
more scalable:

The most efficient way is to use the "tokenGroups" attribute which gives
the nested group membership. As this attribute can not always be
retrieved when binding with the machine account (the only garanteed way
to get the tokenGroups I could find is when the machine account is a
member of the "Pre Win2k Access" builtin group).

Our current fallback when "tokenGroups" failed is looking for all groups
where the userdn was in the "member" attribute. This behaves not very
well in very large AD domains.

The patch first tries the "memberOf" attribute on the user's dn in that
case and directly retrieves the group's sids by using the LDAP Extended
DN control from the user's object.

The way to pass down the control to the ldap search call is rather
painfull and probably will be rearranged later on.

Successfully tested on win2k sp0, win2k sp4, wink3 sp1 and win2k3 r2.

Guenther
2007-10-10 11:17:08 -05:00
Günther Deschner
52423e01dc r15697: I take no comments as no objections :)
Expand the "winbind nss info" to also take "rfc2307" to support the
plain posix attributes LDAP schema from win2k3-r2.

This work is based on patches from Howard Wilkinson and Bob Gautier
(and closes bug #3345).

Guenther
2007-10-10 11:17:08 -05:00
Jeremy Allison
256ae3a16b r15675: Man pages say never look at the fd_set after a select
if it returned -1 (treat as undefined). Ensure we obey
this.
Jeremy.
2007-10-10 11:17:06 -05:00
Günther Deschner
206cdbb8e9 r15634: Prevent passwords of winbindd's list of credential caches from beeing
swapped to disc using mlock(). (patch was reviewed by Jeremy).

Guenther
2007-10-10 11:17:04 -05:00
Günther Deschner
181fa02497 r15632: Remove length limitation from the winbind cache cleanup traversal.
Guenther
2007-10-10 11:17:04 -05:00
Volker Lendecke
3762effca5 r15562: Attempt to fix Coverity bug # 283 2007-10-10 11:17:01 -05:00
Günther Deschner
bf077fb226 r15546: When debugging is enabled be just a little more verbose in logging in
pam_winbind.

Guenther
2007-10-10 11:16:57 -05:00
Gerald Carter
4c4ea7b20f r15543: New implementation of 'net ads join' to be more like Windows XP.
The motivating factor is to not require more privileges for
the user account than Windows does when joining a domain.

The points of interest are

* net_ads_join() uses same rpc mechanisms as net_rpc_join()
* Enable CLDAP queries for filling in the majority of the
  ADS_STRUCT->config information
* Remove ldap_initialized() from sam/idmap_ad.c and
  libads/ldap.c
* Remove some unnecessary fields from ADS_STRUCT
* Manually set the dNSHostName and servicePrincipalName attribute
  using the machine account after the join

Thanks to Guenther and Simo for the review.

Still to do:

* Fix the userAccountControl for DES only systems
* Set the userPrincipalName in order to support things like
  'kinit -k' (although we might be able to just use the sAMAccountName
  instead)
* Re-add support for pre-creating the machine account in
  a specific OU
2007-10-10 11:16:57 -05:00
Günther Deschner
4da79bd10c r15541: Only ever store a user's password in a WINBINDD_CCACHE_ENTRY struct when
we have a reason to do so.

Guenther
2007-10-10 11:16:57 -05:00
Jeremy Allison
2e65fcc9de r15539: Use portable wrapper functions instead of seteuid
directly in winbindd.
Jeremy.
2007-10-10 11:16:56 -05:00
Günther Deschner
9dac3ab328 r15528: Make the existance of the /etc/security/pam_winbind.conf file
non-critical and fallback to only parse the argv options in that case.

Guenther
2007-10-10 11:16:56 -05:00
Günther Deschner
3546187bb4 r15526: Avoid double \n.
Guenther
2007-10-10 11:16:56 -05:00