1
0
mirror of https://github.com/samba-team/samba.git synced 2025-01-13 13:18:06 +03:00
Commit Graph

1740 Commits

Author SHA1 Message Date
Gerald Carter
f96242d933 r23054: Move the check for the lookup_domain of S-1-22-{1,2} before the
check for IS_DC.  Otherwise we will for example fail to lookup a
sid of S-1-22-1-780 because it has no valid struct winbindd_domain*
in the list.   Thanks to Simo for the catch.
(This used to be commit f53aa56998)
2007-10-10 12:22:17 -05:00
Gerald Carter
224239d8e3 r23048: Simo is correct in that winbind_lookup{sid,name}_async() needs
to be able to handle SIDs in the S-1-22-{1,2} domain in order
for winbindd_sid_to_uid(), et. al. to succeed.  For 3.0.25a,
we will short circuit in the sid_to_uid() family of functions
so that smbd is ok.

For 3.0.26, we need to allow winbindd to handle all types of SIDs.
(This used to be commit d70cec3196)
2007-10-10 12:22:17 -05:00
Gerald Carter
53719c6d7d r23046: Few missing merges from cleaning out the Centeris winbindd tree.
Nothing of major interest.  Will fix a few problems with one way trusts.
(This used to be commit 3d48a7e72d)
2007-10-10 12:22:17 -05:00
Michael Adam
1f907b4957 r23040: Activate the winbindd cache validation code in the
winbindd main function.

I have tested and somewhat extended the code, and it seems
to do a good job. I have possibly not caught all error
conditions though.

Michael
(This used to be commit 8c517f9aac)
2007-10-10 12:22:16 -05:00
Stefan Metzmacher
5057c595d5 r23039: merge from SAMBA_3_0_26:
use a helper function to construct the TDB_DATA key
as strlen_m() is totally wrong here anyway

metze
(This used to be commit fb77cc7fbc)
2007-10-10 12:22:16 -05:00
Volker Lendecke
4d5f58c2b9 r23015: Make message_(de)register static to messages.c
(This used to be commit a8082a3c7c)
2007-10-10 12:22:15 -05:00
Volker Lendecke
0570ce21ff r22943: More message_register -> messaging_register
(This used to be commit caece8975b)
2007-10-10 12:22:10 -05:00
Volker Lendecke
84758bd1f8 r22908: All callers of message_init now also call messaging_init. Unify those.
(This used to be commit 330946ad23)
2007-10-10 12:22:07 -05:00
Volker Lendecke
63f9607ea7 r22905: cli_send_mailslot had a message_send_pid inside
(This used to be commit 3fdfb5b7cd)
2007-10-10 12:22:06 -05:00
Günther Deschner
7c21a46afc r22904: Fix indent.
Guenther
(This used to be commit dcf5375aa4)
2007-10-10 12:22:06 -05:00
Günther Deschner
4ff2e1eb8c r22903: Now that we have the on-disc trustdomaincache with type flags we can better
decide whether it's worth to register a krb5 ticket gain handler while users
logon offline.

Guenther
(This used to be commit 203391623b)
2007-10-10 12:22:06 -05:00
Günther Deschner
83a7d9558b r22901: When an AD account has UF_DONT_REQUIRE_PREAUTH set we need to fallback to ntlm
in the kerberized PAM_AUTH.

Guenther
(This used to be commit ef8f0d3504)
2007-10-10 12:22:05 -05:00
Volker Lendecke
fb99bbe675 r22895: Convert some more calls from message_send_buf to messaging_send_buf
(This used to be commit c8b9827340)
2007-10-10 12:22:05 -05:00
Michael Adam
1f7c3007b9 r22855: fix the build
(#if inside DEBUG macro not allowed...)

Michael
(This used to be commit f0570dc3d9)
2007-10-10 12:22:03 -05:00
Michael Adam
c9b94d7170 r22848: Fix brace alignment.
(This used to be commit d909a60641)
2007-10-10 12:22:02 -05:00
Michael Adam
c580cda23c r22847: The new validate_panic function calls exit (instead of setting
a global error flag an returning), so cleanups and returns
subsequent to calls of smb_panic_fn have become unnecessary.
(This used to be commit 9d2db8c70f)
2007-10-10 12:22:02 -05:00
Michael Adam
cb47bb6d8f r22845: Modified and extended the winbindd cache validation code:
* Replaced signal catching/longjmp magic by a fork:
  Let the child do the actual validation of the entries.
  Exit code and signals are intercepted by waitpid.
* Fix logic so that also encounter of an unknown key in the
  tdb leads to an error.
* Extended status of validation is kept in a (as yet simple)
  stuct and communicated over a pipe from child to parent.
* Added two validation_ functions for two new keys.

The call of winbindd_validate_cache is still commented out
in the winbindd main loop. But I am currently testing it
and so far it seems to work fine.

The next step in my plan is to generalize the validation
mechanism to a tdb_open_log_validate function in lib/util_tdb.c.
There ist nothing very special about the cache tdb here,
and this might be useful elsewhere...

Michael
(This used to be commit 417325b9e6)
2007-10-10 12:22:01 -05:00
Volker Lendecke
b4a7b7a888 r22844: Introduce const DATA_BLOB data_blob_null = { NULL, 0, NULL }; and
replace all data_blob(NULL, 0) calls.
(This used to be commit 3d3d61687e)
2007-10-10 12:22:01 -05:00
Jeremy Allison
a4b034d195 r22812: Fix bug #3024 (and also the group varient). Patch from
Johann Hanne <jhml@gmx.net> and also Kaya Bekiro?lu <kaya.bekiroglu@isilon.com>
Jeremy.
(This used to be commit c0ba891be0)
2007-10-10 12:22:00 -05:00
Günther Deschner
67a45aa26b r22794: Add "debug_state" and "silent" to pam_winbind.conf template. Honor the silent
argument when parsing pam configuration file options.

Guenther
(This used to be commit 5b4a4df26f)
2007-10-10 12:21:57 -05:00
Simo Sorce
8ef8dab4fb r22771: One liner fix for idmap_ldap
Fixes the strange behavior we were seeing about idmap_ldap creating
a new connection for each query.

Jerry we need this in for 3.0.25
(This used to be commit 4fb3e0f655)
2007-10-10 12:21:56 -05:00
Volker Lendecke
7192160599 r22747: Fix some C++ warnings
(This used to be commit a66a04e9f1)
2007-10-10 12:21:54 -05:00
Volker Lendecke
b1e866c3b7 r22745: Add local groups to the --required-membership-sid test. This needs
merging to 3_0_26 once Michael's net conf changes have been merged. It
depends on token_utils.c.
(This used to be commit a99ab3a2ed)
2007-10-10 12:21:54 -05:00
Volker Lendecke
f50ff7345d r22744: Fix a valgrind error. parse_domain_username does not necessarily fill in
the domain.
(This used to be commit f4f0d71377)
2007-10-10 12:21:53 -05:00
Volker Lendecke
deed2831c9 r22738: Fix a debug message.
Günther, please check this!

Thanks,

Volker
(This used to be commit 8a038b8cd3)
2007-10-10 12:21:52 -05:00
Günther Deschner
2e1acc4f5a r22737: Fix crash bug (info3 is now talloced).
Guenther
(This used to be commit 08a7ee8d96)
2007-10-10 12:21:52 -05:00
Volker Lendecke
e6383f4762 r22736: Start to merge the low-hanging fruit from the now 7000-line cluster patch.
This changes "struct process_id" to "struct server_id", keeping both is
just too much hassle. No functional change (I hope ;-))

Volker
(This used to be commit 0ad4b1226c)
2007-10-10 12:21:52 -05:00
Gerald Carter
63456681da r22730: Fix password changes via pam_winbindd when using "winbind normalize names"
and the username has been munged.  Make sure to munge it back before
performing the change_password() request.
(This used to be commit ff025d451e)
2007-10-10 12:21:51 -05:00
Gerald Carter
3df5bc8728 r22727: remove outdated comment about templatre shell and homedir
(This used to be commit e8f9bd6558)
2007-10-10 12:21:51 -05:00
Gerald Carter
c473d9e47f r22726: When performing an offline logon for a user in a trusted domain,
take care not to expire the name2sid cache entry just because
that child does not know that the primary domain is offline.
(This used to be commit 0399f52a1c)
2007-10-10 12:21:51 -05:00
Gerald Carter
78c27bb770 r22725: * Don't try to update the sequence_number when offline
* Log the NTSTATUS when saving name/sid cache entry
* Allow the backend loolkup_usergroups() call in winbindd_{rpc,ads}.c
  to inform the wcache manager that the group list should not be cached
  (needed for one-way trusts).
(This used to be commit 693ab48408)
2007-10-10 12:21:50 -05:00
Gerald Carter
189b694ee9 r22724: Call an nss_info backend's init() function if the
previous call was unsuccessful.  needed for offline
logons.
(This used to be commit c3a8dc5d13)
2007-10-10 12:21:50 -05:00
Gerald Carter
215e033e82 r22720: Fixes for offline auth when using krb5_auth = yes in pam_winbind.
Assume that "NO_DOMAIN_CONTROLLERS_FOUND" means that the domain
is offline.
(This used to be commit 30f9cc52bf)
2007-10-10 12:21:50 -05:00
Gerald Carter
cf4f314fb3 r22719: Missed change for one-way trust support. Ignore password policy
settings from one trusted domain with no incoming trust path.

Guenther, I think this is ok as we only need the pw policy
to give feedback on upcoming expiration times.
(This used to be commit c79ae57388)
2007-10-10 12:21:50 -05:00
Gerald Carter
2a9c7462c7 r22717: Add Everyone and AuthenticatedUsers to the user's token
for use by the require-membership-of pam_winbind option.
(This used to be commit 11f81c5997)
2007-10-10 12:21:50 -05:00
Gerald Carter
8bbf274f07 r22716: Clarify comment in winbindd_domain structure
(This used to be commit 32fd8558bd)
2007-10-10 12:21:50 -05:00
Gerald Carter
09fee9aa18 r22715: When our primary domain does on or offline, make sure to send a msg
to the idmap child.

Also remove the check for the global offline state in child_msg_offline()
as this means we cannot mark domains offline due to network outages.
(This used to be commit 1b99e8b521)
2007-10-10 12:21:49 -05:00
Gerald Carter
c16059f1f0 r22713: Offline logon fixes for idmap manager:
(a) Ignore the negative cache when the domain is offline
(b) don't delete expired entries from the cache as these
    can be used when offline (same model as thw wcache entries)
(c) Delay idmap backend initialization when offline
    as the backend routines will not be called until we go
    online anyways.  This prevents idmap_init() from failing
    when a backend's init() function fails becuase of lack of
    network connectivity
(This used to be commit 4086ef15b3)
2007-10-10 12:21:49 -05:00
Gerald Carter
fd5ff711b6 r22712: Inform the user when logging in via pam_winbind
and the krb5 tkt cache could not be created due to clock skew.
(This used to be commit 24616f7d6b)
2007-10-10 12:21:49 -05:00
Gerald Carter
80dca03aae r22711: Fix a compile warnign in query_user(). Ensure that user_rid
is initialized.
(This used to be commit ef03042682)
2007-10-10 12:21:49 -05:00
Gerald Carter
391a72f3df r22710: Support one-way trusts.
* Rely on the fact that name2sid will work for any name
  in a trusted domain will work against our primary domain
  (even in the absense of an incoming trust path)

* Only logons will reliably work and the idmap backend
  is responsible for being able to manage id's without contacting
  the trusted domain

* "getent passwd" and "getent group" for trusted users and groups
  will work but we cannot get the group membership of a user in any
  fashion without the user first logging on (via NTLM or krb5)
  and the netsamlogon_cache being updated.
(This used to be commit dee2bce2af)
2007-10-10 12:21:49 -05:00
Gerald Carter
044f1b4a99 r22709: we can only use tschannel when commectcing to our primary (might need some fixing here for a Samba DC)
(This used to be commit 3d2123383d)
2007-10-10 12:21:48 -05:00
Gerald Carter
47761fdc30 r22708: disable saving the trusted domain list as we want to the parent daemon to manage the complete trusted domain cache
(This used to be commit 3a9152a2ac)
2007-10-10 12:21:48 -05:00
Gerald Carter
9037774927 r22707: missed merge from local tree: pass the correct state to the domain when calling the async lookupsid() routine
(This used to be commit 3d814862af)
2007-10-10 12:21:48 -05:00
Gerald Carter
dcfeb64bd2 r22706: missed one reference to domain->native_mode in the previous commit
(This used to be commit aa2ac5a194)
2007-10-10 12:21:48 -05:00
Gerald Carter
96f590807f r22705: Implement new set_dc_type_and_flags() called based on the
information return from our DC in the DsEnumerateDomainTrusts()
call.   If the fails, we callback ot the older
connect-to-the-remote-domain method.

Note that this means we can only reliably expect the native_mode
flag to be set for our own domain as this information in not
available outside our primary domain from the trusted information.
This is ok as we only really need the flag when trying to
determine to enumerate domain local groups via RPC.

Use the AD flag rather than the native_mode flag when using
ldap to obtain the seq_num for a domain.
(This used to be commit 4b4148a964)
2007-10-10 12:21:47 -05:00
Gerald Carter
7cb2a4be35 r22704: Implement three step method for enumerating domain trusts.
(a) Query our primary domain for trusts
(b) Query all tree roots in our forest
(c) Query all forest roots in trusted forests.

This will give us a complete trust topology including
domains via transitive Krb5 trusts.  We also store the
trust type, flags, and attributes so we can determine
one-way trusted domains (outgoing only trust path).
Patch for one-way trusts coming in a later check-in.

"wbinfo -m" now lists all domains in the domain_list() as held
by the main winbindd process.
(This used to be commit 9cf6068f1e)
2007-10-10 12:21:47 -05:00
Gerald Carter
879b843627 r22703: Convert winbindd_getgrgid() and winbindd_getgetpwnam()
to use the same code path after we resolve the name/gid to
a SID.  Use the async lookupname/lookupsid interface.
(This used to be commit d12b8147d6)
2007-10-10 12:21:47 -05:00
Gerald Carter
6ef504d71f r22702: Convert both lookup name and lookup sid to follow the
same heuristic.  First try our DC and then try a DC in the
root of our forest.  Use a temporary state since
winbindd_lookupXXX_async() is called from various winbindd
API entry points.

Note this will break the compile.  That will be fixed in the
next commit.
(This used to be commit b442644bac)
2007-10-10 12:21:47 -05:00
Gerald Carter
4b7123bba7 r22700: Add a simple wcache TRUSTDOM api for maintaing a complete
list of trusted domains without requiring each winbindd process
to aquire this on its own.  This is needed for various idmap
plugins and for dealing with different trust topoligies.

list_trusted_domain() patches coming next.
(This used to be commit 2da62a3d96)
2007-10-10 12:21:47 -05:00
Simo Sorce
327e232e40 r22677: One line fix to make net idmap restore work again
Jerry, please add this for 3.0.25 final
(This used to be commit e04ca2d7f8)
2007-10-10 12:19:54 -05:00
Jeremy Allison
f1d8c4da23 r22675: Simo's patch for 0 size allocation. Still need
to examine parse_misc.c fix.
Jeremy.
(This used to be commit 80d981265c)
2007-10-10 12:19:54 -05:00
Günther Deschner
e468268335 r22666: Expand kerberos_kinit_password_ext() to return NTSTATUS codes and make
winbindd's kerberized pam_auth use that.

Guenther
(This used to be commit 0f436eab5b)
2007-10-10 12:19:54 -05:00
Günther Deschner
b213b35e08 r22647: Avoid leaking a full info3 structure on each winbindd cached login by making
netsamlogon_cache_get() return a talloc'ed structure.

Guenther
(This used to be commit 5b149967cc)
2007-10-10 12:19:52 -05:00
Simo Sorce
b48096e546 r22646: segfault fix in idmap_ldap.c from 3_0_25
(This used to be commit 565d7d0b18)
2007-10-10 12:19:52 -05:00
Günther Deschner
c74c6f722f r22643: Don't clear cached U/SID and UG/SID entries when we want to logon offline.
Guenther
(This used to be commit 37f9f466fd)
2007-10-10 12:19:52 -05:00
Günther Deschner
bdbe2a955b r22636: Fix logic bug.
We certainly don't want to crash winbind on each sucessfull
centry_uint{8,16,32,64} read.

Jeremy, please check :-)

Guenther
(This used to be commit bfcd10766b)
2007-10-10 12:19:51 -05:00
James Peach
3972121063 r22633: Fix typo in debug message.
(This used to be commit 4c58b6b194)
2007-10-10 12:19:51 -05:00
Jeremy Allison
56a5d05b8b r22590: Make TALLOC_ARRAY consistent across all uses.
That should be it....
Jeremy.
(This used to be commit 603233a98b)
2007-10-10 12:19:49 -05:00
Jeremy Allison
be8b0685a5 r22589: Make TALLOC_ARRAY consistent across all uses.
Jeremy.
(This used to be commit 8968808c3b)
2007-10-10 12:19:49 -05:00
Volker Lendecke
2a5eee9de5 r22553: Fix the build
(This used to be commit 561f3c67f4)
2007-10-10 12:19:44 -05:00
Jeremy Allison
12ba88574b r22542: Move over to using the _strict varients of the talloc
calls. No functional changes. Looks bigger than it is :-).
Jeremy.
(This used to be commit f6fa3080fe)
2007-10-10 12:19:44 -05:00
Günther Deschner
0d1c821700 r22511: Remove unused LDAPMessage.
Guenther
(This used to be commit 31a193b02a)
2007-10-10 12:19:41 -05:00
James Peach
3dff331a1d r22507: Wrap the method of obtaining sockets to listen on.
(This used to be commit e027322b76)
2007-10-10 12:19:40 -05:00
Gerald Carter
b9c4009037 r22473: Correct fix for setting a default compat tdb idmap backend.
Previous code would always fill in "idmap backend = tdb"
even if you defined idmap domains.  My fault.  I should
have tested the original patch more before committing.
(This used to be commit a60c3f6a5a)
2007-10-10 12:19:37 -05:00
Günther Deschner
2713a9ca0e r22466: Fix build warning.
Guenther
(This used to be commit d6f259e918)
2007-10-10 12:19:36 -05:00
Günther Deschner
fa2756c944 r22461: Use ranged LDAP queries in lookup_usergroups_member() and start to optinmize
lookup_groupmem(). In the later, at least try to avoid those massive LDAP
dn_lookups by looking in the cache before.

Guenther
(This used to be commit eb1566869c)
2007-10-10 12:19:35 -05:00
Gerald Carter
da158ad6a2 r22447: Patch from Ying Li <ying.li2@hp.com> to default tdb idmap
plugin when neither idmap domains nor idmap backend have
been defined.
(This used to be commit 2fa12753da)
2007-10-10 12:19:34 -05:00
Gerald Carter
026852b47a r22444: * Validate a SID before trying to convert it to a uid/gid via the public
winbindd interface

* Add nss_info/*so files to the RHEL/Fedora packaging
(This used to be commit 1787fcb8c1)
2007-10-10 12:19:34 -05:00
Gerald Carter
d27d6e822e r22430: Add SID validate to sid2uid() and sid2gid() public entry points in winbindd
(This used to be commit 0890cb941e)
2007-10-10 12:19:34 -05:00
James Peach
44f5211c17 r22418: Support running under launchd. We abstract the method of obtaining
sockets to listen on a little, because in the launchd case these
are provided for us. We also add an idle timeout so that a daemon
can exit after a period of inactivity.
(This used to be commit fc8589a337)
2007-10-10 12:19:33 -05:00
James Peach
8a22b1f0ea r22417: Refactor the various daemon run-mode options to make the semantics
of the various flags explicit.
(This used to be commit 19c929c633)
2007-10-10 12:19:33 -05:00
Günther Deschner
04a70aaf1c r22402: Fix build warning.
Guenther
(This used to be commit bf9131fed3)
2007-10-10 12:19:32 -05:00
Simo Sorce
2d8fbef151 r22393: fix cut&paste error
(This used to be commit 70878d6985)
2007-10-10 12:19:31 -05:00
Simo Sorce
39888067e3 r22392: Remove leftover potentially segfaulty code.
Check we are online before actually trying to connect anywhere
(This used to be commit ff5e0b2986)
2007-10-10 12:19:30 -05:00
Gerald Carter
36da6cb584 r22390: Patchset sent to samba-technical to address the winbind
loop when allocating a new id for a SID:

auth_util.patch		Revert create_local_token() to
			the 3.0.24 codebase

idmap_type.patch	Have the caller fillin the
			id_map.xid.type field when
			resolving a SID so that if we allocate
			a new id, we know what type to use

winbindd_api.patch	Remove the WINBINDD_SIDS_TO_XIDS calls
			from the public winbindd interface
			for the 3.0.25 release

idmap_rid.patch		Cleanup the idmap_rid backend to not
			call back into winbindd to resolve
			the SID in order to verify it's type.
(This used to be commit 3b24dae9e7)
2007-10-10 12:19:30 -05:00
Simo Sorce
20086f66cc r22388: clearer message, thanks David
(This used to be commit 7961476784)
2007-10-10 12:19:29 -05:00
Simo Sorce
d7c8710a1d r22348: 3_0 as well
(This used to be commit ad57434faf)
2007-10-10 12:19:28 -05:00
Simo Sorce
01be4914b3 r22343: Commit to 3_0 as well after adapting the patch.
(tdb_delete_bystring instead of tdb_delete is used here)
(This used to be commit ee40cead09)
2007-10-10 12:19:27 -05:00
Gerald Carter
b066668b74 r22340: Fix another segfault in idmap_ldap.c caused by setting the iterator
LDAPMessage * to NULL on each loop rotation.
(This used to be commit 356dd0dd3a)
2007-10-10 12:19:27 -05:00
Stefan Metzmacher
f718428845 r22313: as discussed with simo:
remove the only usage of backup_tdb() in samba3.
As backup_tdb() will go completely soon.

metze
(This used to be commit 363d1d676c)
2007-10-10 12:19:25 -05:00
Stefan Metzmacher
a8c6250274 r22298: move ZERO_*, ARRAY_SIZE and PTR_DIFF macros into libreplace
metze
(This used to be commit 8a7d2e633b)
2007-10-10 12:19:24 -05:00
Gerald Carter
615f025654 r22283: Remove very old bug where we assigned the online mode of
the domain to queried to our own domain.
(This used to be commit 2abeec5768)
2007-10-10 12:19:24 -05:00
Simo Sorce
0dd0aab2bc r22230: Let's just cast here, the 2 calls have different allocation mechanisms.
We just let domname and name hang on the mem ctx until the call returns,
and the context will be destroyed.

Simo.
(This used to be commit c38d8396c5)
2007-10-10 12:19:21 -05:00
Volker Lendecke
3e819bd22c r22214: Fix incompatible pointer type warnings. Simo, please check and merge to 3_0_25
if appropriate.

Volker
(This used to be commit 6a4f6c5177)
2007-10-10 12:19:20 -05:00
Jeremy Allison
731df24607 r22211: Don't return a value from void functions !
Jeremy.
(This used to be commit 1dd8d3a723)
2007-10-10 12:19:20 -05:00
Jeremy Allison
91be3a9ed6 r22210: Fix typo in testing for non-centry entries.
Jeremy.
(This used to be commit b89ecbcac6)
2007-10-10 12:19:20 -05:00
Jeremy Allison
c7d136dcac r22209: Fix the storage of time_t -> make it 64 bits (use the
same load/store function as NTTIME). Add a version number
string to the winbindd cache so we can tell if it needs
upgrading. THIS WILL DELETE ANY EXISTING winbindd_cache.tdb
on first startup regardless of offline auth status. Once
this is done we're in good shape though.
Jeremy.
(This used to be commit c52c7f91af)
2007-10-10 12:19:19 -05:00
Jeremy Allison
a2bab163be r22207: Fill in the validation functions. Now to test...
Jeremy.
(This used to be commit fc2b9e860e)
2007-10-10 12:19:19 -05:00
Jeremy Allison
127cc73034 r22206: Added boilerplate to be filled in for other validation functions.
Jeremy.
(This used to be commit 9be463eb0c)
2007-10-10 12:19:19 -05:00
Jeremy Allison
23e575c4b7 r22205: Add some flesh to the bones of the cache validation code.
Jeremy
(This used to be commit b773ea2c8a)
2007-10-10 12:19:19 -05:00
Simo Sorce
59523f55a9 r22204: Workaround to quickly close bug #4508
This hack makes thing work, but we will need to try again to
make the getpw* calls fully async, that's the real fix.
(This used to be commit 2552859b3d)
2007-10-10 12:19:19 -05:00
Jeremy Allison
9f41ff47d0 r22202: Volker is clever :-). Use TDB_NOMMAP to prevent any wild pointer
problems when validating the winbindd cache. Wish I'd have
thought of that.
Jeremy.
(This used to be commit 6b0a8cbbb8)
2007-10-10 12:19:19 -05:00
Gerald Carter
d1491cc500 r22173: BUG 4491, 4501: Additional fixes for protecting against
crashes in allocate_id().

BUG 4501: Fix segv in idmap_ad caused by resetting the
entry iterator when parsing search results.
(This used to be commit bd6ebbfb9f)
2007-10-10 12:19:18 -05:00
Gerald Carter
330985ebb5 r22159: BUG 4501 (second half of fix): Just disable the
uid/gid allocation if no idmap alloca backend has been
defined and we are not using a 3.0.24 idmap backend
compatible configuration.
(This used to be commit 0b700456f4)
2007-10-10 12:19:18 -05:00
Gerald Carter
43401cf93b r22158: BUG 4501 (partial): Fix a crash caused by not using the
nss_info_{rfc2307,sfu} plugin with idmap_ad.
(This used to be commit f640f056bf)
2007-10-10 12:19:17 -05:00
Gerald Carter
ccb99cafa7 r22110: don't cache the S-1-22-{1,2} domain SID/uig/gid lookups in idmap_cache
(This used to be commit adfc2d3165)
2007-10-10 12:19:13 -05:00
Simo Sorce
ca70c3cde7 r22109: Readonly is automatically set in the generic init code, let's just log the fact there
and remove the specific, but redundant, code in idmap_ad.c
(This used to be commit f127803734)
2007-10-10 12:19:13 -05:00
Gerald Carter
06ec19e2fb r22069: BUG 4447: Fix compile failure on AIX 5.2 (patch from William Jojo <jojowil@hvcc.edu>)
(This used to be commit c1cb6d059b)
2007-10-10 12:19:09 -05:00
Gerald Carter
3bdd0e3650 r22066: Ensure that winbind can resolve SIDs in the S-1-22-{1,2}
domain to a uid.gid using the idmap_passdb backend.
(This used to be commit fc1aeee52d)
2007-10-10 12:19:09 -05:00
Gerald Carter
01c8809f76 r22061: Fix the krb5 user ticket refresh event timeout in winbindd
(This used to be commit 4a99b89618)
2007-10-10 12:19:07 -05:00
Jeremy Allison
ce3c830f15 r22015: Fix for memory leak from Steven Danneman <steven.danneman@isilon.com>
Jeremy.
(This used to be commit 61a1574f50)
2007-10-10 12:19:02 -05:00
Stefan Metzmacher
bc2b6436d0 r22009: change TDB_DATA from char * to unsigned char *
and fix all compiler warnings in the users

metze
(This used to be commit 3a28443079)
2007-10-10 12:19:00 -05:00
Stefan Metzmacher
56ba447668 r22001: change prototype of dump_data(), so that it takes unsigned char * now,
which matches what samba4 has.

also fix all the callers to prevent compiler warnings

metze
(This used to be commit fa322f0cc9)
2007-10-10 12:18:59 -05:00
Stefan Metzmacher
4b0c9a0084 r21986: make use of tdb_*_bystring() and string_term_tdb_data()
to avoid creating the TDB_DATA struct from strings "by hand"

metze
(This used to be commit 08d23a1c4f)
2007-10-10 12:18:56 -05:00
Stefan Metzmacher
5060393272 r21985: make use of string_tdb_data()
to avoid creating the TDB_DATA struct from strings "by hand"

metze
(This used to be commit a8bc20d67f)
2007-10-10 12:18:56 -05:00
Stefan Metzmacher
ef0a0f9b2b r21984: make use of tdb_*_bystring() and string_term_tdb_data()
to avoid creating the TDB_DATA struct from strings "by hand"

metze
(This used to be commit 91301f7347)
2007-10-10 12:18:56 -05:00
Herb Lewis
dfc4a8b2b2 r21957: minor formatting fix
(This used to be commit 99b9570ebe)
2007-10-10 12:18:52 -05:00
Volker Lendecke
8a2b73a58a r21941: Attempt to fix bug 4460
(This used to be commit d1b8f00c12)
2007-10-10 12:18:51 -05:00
Gerald Carter
5b105eaf7c r21940: Sorry Volker, I have to revert your revert in r21935.
We can talk about this later if you still feel that strongly
but I need to fix the build for now.
(This used to be commit c7df0cad82)
2007-10-10 12:18:50 -05:00
Volker Lendecke
719f4657e8 r21935: Revert obviously not sufficiently tested code -- sorry for the pain. I am afraid I was basically off the net for the day
(This used to be commit 08c29abc03)
2007-10-10 12:18:50 -05:00
Gerald Carter
e68ea1283d r21933: Change the write_sock() call in pam_winbind_request()
to not request a privileged pipe operation for everything
as this cannot be done from a process running under the
context of a user (e.g. screensaver).

Thanks to Danilo Almeida <dalmeida@centeris.com> for the help
in pointing out the change to write_sock().
(This used to be commit 80790f935a)
2007-10-10 12:18:50 -05:00
Jeremy Allison
820184bdcc r21927: Removed unused variable.
Jeremy.
(This used to be commit 2d951c91a5)
2007-10-10 12:18:49 -05:00
Simo Sorce
a38b34aa3b r21919: now that the local passdb abd BUILTIN have been blacklisted and they always
point to the passdb module, remove this comment and move the explanation in
the dimap_ad man page.

Simo.
(This used to be commit 58d2ec00d2)
2007-10-10 12:18:49 -05:00
Gerald Carter
b44d53e307 r21918: Reverting this change as it is now causing aborts() in
find_builtin_domain().    This all needs more testing
before anyone starts changing these lookup routines again.
(This used to be commit add225e1c8)
2007-10-10 12:18:48 -05:00
Gerald Carter
3f85405be0 r21913: fix one bug in build 717: correctly check the return from sid_peek_check_rid() when trying to find a matching domain
(This used to be commit c63bc30037)
2007-10-10 12:18:48 -05:00
Gerald Carter
f8c2960d45 r21905: Rename
idmap expire time 	-> idmap cache time
  idmap negative time	-> idmap negative cache time
(This used to be commit aac2d0af5e)
2007-10-10 12:18:48 -05:00
Günther Deschner
ed360fe5e5 r21887: Fix annoying bug where in a pam_close_session (or a pam_setcred with the
PAM_DELETE_CREDS flag set) any user could delete krb5 credential caches.
Make sure that only root can do this.

Jerry, Jeremy, please check.

Guenther
(This used to be commit 947a59a849)
2007-10-10 12:18:44 -05:00
Gerald Carter
52d5e2a935 r21884: * Blacklist BUILTIN and MACHINE domains from the
idmap domains as these should only be handled by the
  winbindd_passdb.c backend

* Allow the alloc init to fail for backwards compatible
  configurations like

     idmap backend = ad
     idmap uid = 1000-100000
	....

* Remove the deprecated flags from idmap backend, et. al.
  These are mutually exclusive with the new configuration
  options (idmap domains).  Logging annoying messages
  about deprecated parameters is confusing.  So we'll try
  this apprpach for now.
(This used to be commit 5e30807b4e)
2007-10-10 12:18:44 -05:00
James Peach
b4f19aea18 r21881: Make sure we are very specific when testing whether a backand can handle a
particular SID. Make sure that the passdb backend will accept the same set
range of local SIDs that the idmap system sends it.

Simo, Jerry - this is a 3_0_25 candidate. Can you please review?
(This used to be commit 86a70adb6a)
2007-10-10 12:18:43 -05:00
Volker Lendecke
3fdef9433a r21878: Fix a bug with smbd serving a windows terminal server: If winbind decides smbd
to be idle it might happen that smbd needs to do a winbind operation (for
example sid2name) as non-root. This then fails to get the privileged
pipe. When later on on the same connection another authentication request
comes in, we try to do the CRAP auth via the non-privileged pipe.

This adds a winbindd_priv_request_response() request that kills the existing
winbind pipe connection if it's not privileged.

Volker
(This used to be commit e5741e27c4)
2007-10-10 12:18:42 -05:00
Volker Lendecke
00b73df552 r21873: This is winbindd_pam.c, not pam_winbind.c :-)
(This used to be commit e1fbfbe1c4)
2007-10-10 12:18:41 -05:00
Volker Lendecke
22cc1dce41 r21872: Fix a debug message
(This used to be commit fcec3d1c46)
2007-10-10 12:18:41 -05:00
Gerald Carter
815fdf23c7 r21860: Fixes for "winbind normalize names" functionality:
* Fix getgroups() call called using a normalized name
* Fix some more name mappings that could cause for example
  a user to be unable to unlock the screen as the username
  would not match in the PAM authenticate call.
(This used to be commit 505fc669a1)
2007-10-10 12:18:39 -05:00
Volker Lendecke
0d91334fe7 r21784: Replace smb_register_idle_event() with event_add_timed(). This fixes winbind
who did not run the idle events to drop ldap connections.

Volker
(This used to be commit af3308ce5a)
2007-10-10 12:18:33 -05:00
Herb Lewis
b1fc114fdc r21775: make messages more understandable - don't leave part dangling after newline
(This used to be commit f57e4f8ada)
2007-10-10 12:18:31 -05:00
Herb Lewis
80a216970d r21704: open sockets immediately in process_loop
(This used to be commit 51b96ba79c)
2007-10-10 12:18:23 -05:00
Gerald Carter
cfecca614f r21636: Was almost right before. We have to specify the short domain name to get the
Krb5 config stuff to work in the server affinity settings.
(This used to be commit 518052be38)
2007-10-10 12:18:19 -05:00
Gerald Carter
a4db672e26 r21633: First real fix from me found during the bug hunt.
ads_cached_connection() does not call get_dc_name()
before ads_connect() and therefore does not setup
the environment to look at krb5.conf.DOMAIN file
before sending the TGT request.  The failure I'm seeing
occurs ni a multi-DC domain where we get back preuath
failed after we just joined the domain.
(This used to be commit 256f36dce3)
2007-10-10 12:18:18 -05:00
Gerald Carter
5f24668961 r21632: Remove ununsed variable
(This used to be commit 82dc19f844)
2007-10-10 12:18:18 -05:00
Gerald Carter
377bb74101 r21626: Fix memory leak on error path noticed by
SATOH Fumiyasu <fumiya@samba.gr.jp>
(This used to be commit d68b2910c8)
2007-10-10 12:18:18 -05:00
Simo Sorce
1983759266 r21623: Fix copy/paste error
(This used to be commit 0de7472428)
2007-10-10 12:18:18 -05:00
Gerald Carter
9b568ecdc4 r21622: Fix bad merge caught by James.
(This used to be commit 05886edb35)
2007-10-10 12:18:18 -05:00
Gerald Carter
b1f4259cd5 r21616: Delay initialization of idmap and nss_info backends until necessary
so they can honor the offline logon state.
(This used to be commit 15b13dfe81)
2007-10-10 12:18:18 -05:00
Gerald Carter
6fb6adba27 r21615: don't wait until the last second to try to renew a Krb5 ticket as it is took late
(This used to be commit 5575845952)
2007-10-10 12:18:17 -05:00
Gerald Carter
5e88cb83b1 r21614: The memset() called on aligned memory was causing crashes
on x86_64 Linux boxes.  Since it is not needed, just use malloc()
on Linux.
(This used to be commit 3644bd9996)
2007-10-10 12:18:17 -05:00
Gerald Carter
aaa3a9a329 r21613: perform variable subsitution on home directories and shells provided by the nss_info backend
(This used to be commit a9028612a3)
2007-10-10 12:18:17 -05:00
Gerald Carter
2c51e492f9 r21612: Make pam_winbind do the same username fixup on AIX as the WINBINDD
LAM module does to work around a system that does not support
>8 character usernames.  Without the change, pam_winbind tries
to authenticate _#uid in the domain.
(This used to be commit 7f0ba72e05)
2007-10-10 12:18:17 -05:00
Gerald Carter
85f769dbb4 r21611: I'm not entirely sure about this patch but it is working.
su - DOM\user was unable to set the process crendentials
without listing the "id" and other attributes in the attrlist[].
More fixes to come, but I didn't want this to get lost.
(This used to be commit 4c53d300fa)
2007-10-10 12:18:17 -05:00
Jeremy Allison
8e00e9d7a6 r21609: Fix memory leaks in error code paths (and one in winbindd_group.c).
Patch from Zack Kirsch <zack.kirsch@isilon.com>.
Jeremy.
(This used to be commit df07a662e3)
2007-10-10 12:18:16 -05:00
Simo Sorce
e9e6af5951 r21606: Implement escaping function for ldap RDN values
Fix escaping of DN components and filters around the code
Add some notes to commandline help messages about how to pass DNs

revert jra's "concistency" commit to nsswitch/winbindd_ads.c, as it was
incorrect.
The 2 functions use DNs in different ways.

- lookup_usergroups_member() uses the DN in a search filter,
and must use the filter escaping function to escape it
Escaping filters that include escaped DNs ("\," becomes "\5c,") is the
correct way to do it (tested against W2k3).

- lookup_usergroups_memberof() instead uses the DN ultimately as a base dn.
Both functions do NOT need any DN escaping function as DNs can't be reliably
escaped when in a string form, intead each single RDN value must be escaped
separately.

DNs coming from other ldap calls (like ads_get_dn()), do not need escaping as
they come already escaped on the wire and passed as is by the ldap libraries

DN filtering has been tested.
For example now it is possible to do something like:
'net ads add user joe#5' as now the '#' character is correctly escaped when
building the DN, previously such a call failed with Invalid DN Syntax.

Simo.
(This used to be commit 5b4838f62a)
2007-10-10 12:18:16 -05:00
Jeremy Allison
2546b63f73 r21566: If we're going to be broken, at least be *consistently*
broken :-). This will do until Simo fixes the escape
calls properly.
Jeremy.
(This used to be commit b7d91ec1b2)
2007-10-10 12:18:14 -05:00
Herb Lewis
bdc612a098 r21548: prevent segv (reference to -1 element of array)
(This used to be commit b5fd72282d)
2007-10-10 12:18:12 -05:00
Günther Deschner
6af7f33bbb r21537: Avoid to trigger the confusing "cached entry differs." warning when
there is just no cache around for a user.

Guenther
(This used to be commit a6c249b592)
2007-10-10 12:18:11 -05:00
Jeremy Allison
3f3a3a23ce r21530: Don't code with jet-lag and Volker looking over your
shoulder.... Correct fix for warning :-)
Jeremy.
(This used to be commit 773001870d)
2007-10-10 12:18:10 -05:00
Jeremy Allison
8e9ce06f35 r21529: Fix warning from bad cast.
Jeremy.
(This used to be commit 34675624e2)
2007-10-10 12:18:10 -05:00
Gerald Carter
56c1d7e507 r21525: Go ahead and checkin the mlock() & memalign() fixes so
others don't get stuck with the winbindd hang.
Still waiting on additional confirmation from Guenther
that this fixes thes issues he was observing as well.
But it's been running in my local tree for a day without
problems.
(This used to be commit 0d2b80c6c4)
2007-10-10 12:18:10 -05:00
Simo Sorce
fa5e0a238c r21508: Fix memleak in new idmap_tdb, thanks Herb.
Jerry please check.

Simo.
(This used to be commit a5354aa9a0)
2007-10-10 12:18:09 -05:00
Gerald Carter
43c290639b r21505: make sure mlock()'d memory is aligned on a page boundary
(This used to be commit 52e6a2ceab)
2007-10-10 12:18:08 -05:00
Günther Deschner
9684e353a1 r21500: Fix inappropriate creation of a krb5 ticket refreshing event when a user
changed a password via pam_chauthtok. Only do this if

a) a user logs on using an expired password (or a password that needs to
be changed immediately) or

b) the user itself changes his password.

Also make sure to delete the in-memory krb5 credential cache (when a
user did not request a FILE based cred cache).

Finally honor the krb5 settings in the first pam authentication in the
chauthtok block (PAM_PRELIM_CHECK). This circumvents confusion when
NTLM samlogon authentication is still possible with the old password after
the password has been already changed (on w2k3 sp1 dcs).

Guenther
(This used to be commit c3005c48cd)
2007-10-10 12:18:08 -05:00
Jeremy Allison
7f981b457f r21474: Ensure trustdom_cache_shutdown() gets called
on terminate. Pointed out by Herb.
Jeremy.
(This used to be commit 08998b74a5)
2007-10-10 12:18:07 -05:00
Günther Deschner
83dce23550 r21454: Fix debug typo.
Guenther
(This used to be commit 5c4a58ff3a)
2007-10-10 12:18:05 -05:00
Günther Deschner
aa12597000 r21450: No need to TALLOC_FREE twice here.
Guenther
(This used to be commit ad063d9a94)
2007-10-10 12:18:04 -05:00
Herb Lewis
9162cb7684 r21399: need to zero the request and response structures
(This used to be commit aa8f306fa5)
2007-10-10 12:18:02 -05:00
Herb Lewis
6432e901c7 r21397: revert accidential commit
(This used to be commit 9fe5f78857)
2007-10-10 12:18:02 -05:00
Herb Lewis
2b30279169 r21396: fix wbinfo --lookup-rids command
allow detection of libbiconv if all others fail - need for FreeBSD
(This used to be commit 7acc9421b0)
2007-10-10 12:18:02 -05:00
Günther Deschner
4a18f37f22 r21394: Prevent nscd crash due to potential NULL pointer dereference in
_nss_winbind_initgroups_dyn() on an empty group list.

Guenther
(This used to be commit 155b9e7c74)
2007-10-10 12:18:01 -05:00
Günther Deschner
637b01b63d r21387: Another important fix for non-AD domains:
Avoid assigning 0 as primary group id for users in NSS calls.
Jerry, please check.

Guenther
(This used to be commit 03f5f7d014)
2007-10-10 12:18:01 -05:00
Günther Deschner
ca072a9998 r21382: Important fix for winbind when using non-AD domains.
Jeremy, I'm afraid you removed the "domain->initialized" from the
set_dc_types_and_flags() call when the connect to PI_LSARPC_DS failed
(with rev. 19148).

This causes now that init_dc_connection_network is called again and
again which in turn rescans the DC each time (which of course fails each
time with NT_STATUS_BUFFER_TOO_SMALL). Just continue with the
non-PI_LSARPC_DS scan so that the domain is initialized properly.

Guenther
(This used to be commit c6f63a08f5)
2007-10-10 12:17:59 -05:00
Günther Deschner
1b16e8cbf9 r21358: Some more debugging for _nss_winbind_initgroups_dyn() on Linux.
Guenther
(This used to be commit 639b7989b3)
2007-10-10 12:17:58 -05:00
Günther Deschner
8bbe400c56 r21357: Fix typo.
Guenther
(This used to be commit e3c3258379)
2007-10-10 12:17:58 -05:00
Günther Deschner
c13e862d0e r21353: In the turn of tracking down nss_winbind related bugs on Linux:
print NSS_STATUS code with DEBUG_NSS when leaving a function.

Guenther
(This used to be commit 53ecd63d94)
2007-10-10 12:17:58 -05:00
Günther Deschner
5876136754 r21336: Fix indent (as pointed out by Volker).
Guenther
(This used to be commit dcbf7a1250)
2007-10-10 12:17:56 -05:00
Günther Deschner
3a46604800 r21318: Fix Bug #4225.
Cached logon with pam_winbind should work now also for NT4 and samba3
domains.

Guenther
(This used to be commit b2f9115482)
2007-10-10 12:17:56 -05:00
Günther Deschner
6dd654c381 r21310: Fix invalid printfs in pam_winbind.
Guenther
(This used to be commit 5a7b2fccb3)
2007-10-10 12:17:55 -05:00
Günther Deschner
826aa64c45 r21309: Add PRINTF_ATTRIBUTE checks for log statements.
Guenther
(This used to be commit 968dfcc821)
2007-10-10 12:17:55 -05:00
Günther Deschner
8e589ea7f2 r21308: Fix some typos and ensure to null terminate the correct strings.
Guenther
(This used to be commit 16c90f30b9)
2007-10-10 12:17:54 -05:00
Gerald Carter
b5114650cf r21284: Fix some unitilized variable warnings pointed out by Volker.
(This used to be commit 5c3edad860)
2007-10-10 12:17:54 -05:00
Günther Deschner
69cee2a3ec r21240: Fix longstanding Bug #4009.
For the winbind cached ADS LDAP connection handling
(ads_cached_connection()) we were (incorrectly) assuming that the
service ticket lifetime equaled the tgt lifetime. For setups where the
service ticket just lives 10 minutes, we were leaving hundreds of LDAP
connections in CLOSE_WAIT state, until we fail to service entirely with
"Too many open files".

Also sequence_number() in winbindd_ads.c needs to delete the cached LDAP
connection after the ads_do_search_retry() has failed to submit the
search request (although the bind succeeded (returning an expired
service ticket that we cannot delete from the memory cred cache - this
will get fixed later)).

Guenther
(This used to be commit 7e1a84b722)
2007-10-10 12:17:50 -05:00
Herb Lewis
d4e430d0c7 r21231: get rid of unused defines that cause a redefined warning
(This used to be commit 509ae5ffa1)
2007-10-10 12:17:49 -05:00
Jeremy Allison
50b3dbef68 r21228: Fix for fd leak on error path. Thanks to
dleonard@vintela.com for this fix !
Jeremy.
(This used to be commit 70b5db7d8c)
2007-10-10 12:17:49 -05:00
Gerald Carter
e7d2f46229 r21182: * Refactor the code to obtain the LDAP connection credentials
from both idmap_ldap_{alloc,db}_init()
* Fix the backwards compat support in idmap_ldap.c
* Fix a spelling error in the idmap_fetch_secret() function name
(This used to be commit 615a104356)
2007-10-10 12:17:46 -05:00
Gerald Carter
d3b3e02881 r21180: fix backwards compatible idmap backends parameter parsing
(This used to be commit 01af19cc9d)
2007-10-10 12:17:46 -05:00
Günther Deschner
317d005142 r21161: Another fix for pam_winbind: Move the entire pwd expiry handling into
the PAM_SUCCESS block.

Guenther
(This used to be commit f4a704745c)
2007-10-10 12:17:44 -05:00
Günther Deschner
7440e4255c r21160: Some more pam_winbind fixes:
* Consolidate all pam_winbind password expiry warnings in the one
_pam_send_password_expiry_message() call.
* Also convert some more NTSTATUS codes to error messages.
* Add paranoia check to only do all the post-processing after PAM_SUCCESS.

Guenther
(This used to be commit 02713f314b)
2007-10-10 12:17:44 -05:00
Günther Deschner
902a6e1da1 r21159: Cleanup pam_sm_chauthtok() in pam_winbind:
Set info3 strings, krb5ccname and returned username after we changed a
password and sucessfully re-authenticated afterwards. In that case we
ended up without this information.

Guenther
(This used to be commit 034d42ba72)
2007-10-10 12:17:44 -05:00
Günther Deschner
dbb9450312 r21158: Add _pam_setup_krb5_env() and _pam_warn_logon_type() functions for
pam_winbind.

Guenther
(This used to be commit 1feb961577)
2007-10-10 12:17:44 -05:00
Günther Deschner
462893a7be r21155: Forgot one _PAM_LOG_STATE_DATA_STRING call (only in 3_0).
Guenther
(This used to be commit 86b34cd5d6)
2007-10-10 12:17:44 -05:00
Günther Deschner
0cf5662363 r21154: Add PAM_WINBIND_LOGONSERVER, also merge the various pam_set_data calls.
Guenther
(This used to be commit 97a0b1b794)
2007-10-10 12:17:43 -05:00
Günther Deschner
44512030b1 r21152: Correctly omit pam conversations when PAM_SILENT has been set by the
calling application.

Guenther
(This used to be commit ebfae9a671)
2007-10-10 12:17:43 -05:00
Gerald Carter
a252038187 r21151: applying patches for CVE-2007-045[34]
(This used to be commit 1d46b2ae34)
2007-10-10 12:17:43 -05:00
Günther Deschner
3a0e9a5462 r21149: Only say we are a groupmember for the optimized (rid 513) membership
lookup when we actually are. Although the Linux nss winbind backend
protects against num_mem != 0 && buf == NULL.

Guenther
(This used to be commit a9ac4630b4)
2007-10-10 12:17:43 -05:00
Günther Deschner
a90034f5aa r21146: Fix debug typos.
Guenther
(This used to be commit cdef1d00b8)
2007-10-10 12:17:43 -05:00
Günther Deschner
c622130a7d r21145: Convert some int to BOOL in pam_winbind (only in 3_0).
Guenther
(This used to be commit 1b82c5fa0e)
2007-10-10 12:17:42 -05:00
Günther Deschner
0b2bbb2704 r21144: Create more accurate warning message when the pam_winbind chauthtok has
received NT_STATUS_PASSWORD_RESTRICTION.

Guenther
(This used to be commit 2ac9cb3bbd)
2007-10-10 12:17:42 -05:00
Günther Deschner
4aa7205c3d r21143: Fix wrong check for pam error codes for getpwnam and lookup winbind
requests in pam_winbind (Bug #4094).

Inspired by fix from Lars Heete.

Guenther
(This used to be commit 88e2185d29)
2007-10-10 12:17:42 -05:00
Gerald Carter
4c484662d6 r21130: Don't mix SAFE_FREE() and TALLOC_FREE().
(This used to be commit 5c36d67d27)
2007-10-10 12:17:41 -05:00
Günther Deschner
48191ddec6 r21122: Simplify code in pam_winbind a bit.
Guenther
(This used to be commit 08ca5ea6f1)
2007-10-10 12:17:40 -05:00
Gerald Carter
e005f8b014 r21112: fix const compile warning
(This used to be commit 6b754f7c96)
2007-10-10 12:17:39 -05:00
Günther Deschner
f2b8db93c4 r21106: We neither need a account lockout policy handler nor a check domain
online handler for internal (local SAM, BUILTIN) childs. Jeremy, please
check.

Guenther
(This used to be commit 7d0e2e7068)
2007-10-10 12:17:38 -05:00
Jeremy Allison
91cf91e028 r21101: Remove "unused" warning from Jerry's code. We still
have a build failure in 3.0.24 in event_add_timed ?
Jeremy
(This used to be commit ede30a8b4b)
2007-10-10 12:17:37 -05:00
Günther Deschner
8162d5ef3a r21098: When get_dc_name_via_netlogon() in get_dcs() fails to find a trusted DC
we may not just assume that we look for our own realm's dcs next.

Guenther
(This used to be commit bf0c4ce7b1)
2007-10-10 12:17:37 -05:00
Gerald Carter
a94b044a5c r21070: * Add the new boolean 'winbind normalize names' option as discussed
on the samba-technical ml.  The replacement character is hardcoded
  as a '_' for now.
(This used to be commit bd8238417b)
2007-10-10 12:17:32 -05:00
Volker Lendecke
caf8c6a76b r21064: The core of this patch is
void message_register(int msg_type,
                      void (*fn)(int msg_type, struct process_id pid,
-                                void *buf, size_t len))
+                                void *buf, size_t len,
+                                void *private_data),
+                     void *private_data)
 {
        struct dispatch_fns *dfn;

So this adds a (so far unused) private pointer that is passed from
message_register to the message handler. A prerequisite to implement a tiny
samba4-API compatible wrapper around our messaging system. That itself is
necessary for the Samba4 notify system.

Yes, I know, I could import the whole Samba4 messaging system, but I want to
do it step by step and I think getting notify in is more important in this
step.

Volker
(This used to be commit c8ae60ed65)
2007-10-10 12:17:32 -05:00
Günther Deschner
c51e4c3440 r21056: Moving the set_domain_online_request to fork_domain_child() (formerly
lived in trustdom_recv().

Jeremy, this is the better place I think but please check.

Guenther
(This used to be commit beed8b8b32)
2007-10-10 12:17:30 -05:00
Gerald Carter
400f419580 r21036: Fix the ad nss info backend to not abort the search when called outside the idmap daemon
(This used to be commit 57160e3dd9)
2007-10-10 12:17:29 -05:00
Günther Deschner
4a5868f3ca r21033: To make the logs a bit more readable let the winbind dc connect child
write to a separate logfile.

Guenther
(This used to be commit 0313edc0d6)
2007-10-10 12:17:28 -05:00
Günther Deschner
b979bf5686 r21020: Some pam_winbind fixes:
* make debug_state also configurable from the config file
* minor code cleanup

Guenther
(This used to be commit c562095953)
2007-10-10 12:17:28 -05:00
Günther Deschner
74f38589b3 r21019: Fix typo.
Guenther
(This used to be commit adb40884e0)
2007-10-10 12:17:28 -05:00
Günther Deschner
a6f30ced0a r21018: Removing the set_domain_online_request again in trustdom_recv().
Jeremy, we really can't do that. There are setups with hundred and more
trusted domains out there, I have one customer who tells me it takes
more then half an hour for him after winbind is up and running. That
request registers the check_domain_online_handler which in turn forks
off the child immediately. Also discussed with Volker.

Guenther
(This used to be commit ccd4812c0b)
2007-10-10 12:17:27 -05:00