summaryrefslogtreecommitdiffstats
path: root/source3/libsmb/trusts_util.c
Commit message (Collapse)AuthorAgeFilesLines
* s3/libsmb: Free memdup'd local variableJose A. Rivera2014-02-221-0/+1
| | | | | | | | | | | | | | secrets_fetch_machine_password() sets pwd to point to memdup()'d (and thus malloc()'d) memory. This memory should be freed before we go out of scope. Change-Id: I07e575819c309fa5b85627dce2eb969bc720ce4e Coverity-Id: 1168001 Reviewed-by: Ira Cooper <ira@samba.org> Signed-off-by: Jose A. Rivera <jarrpa@redhat.com> Reviewed-by: Simo Sorce <idra@samba.org> Autobuild-User(master): Simo Sorce <idra@samba.org> Autobuild-Date(master): Sat Feb 22 00:58:23 CET 2014 on sn-devel-104
* s3:libsmb: remove unused trust_pw_find_change_and_store_it()Stefan Metzmacher2014-01-071-81/+0
| | | | | Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* s3:libsmb: add trust_pw_change()Stefan Metzmacher2014-01-071-0/+179
| | | | | | | | | This protects the password change using a domain specific g_lock, so multiple parts 'net rpc', 'rpcclient', 'winbindd', 'wbinfo --change-secret' even on multiple cluster nodes doesn't race anymore. Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* libsmb: Fix CID 1127343 Dead default in switchVolker Lendecke2013-11-111-2/+0
| | | | | | | We have checked sec_channel_type a few lines above already Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Ira Cooper <ira@samba.org>
* s3:libsmb: inline trust_pw_change_and_store_it() into ↵Stefan Metzmacher2013-10-171-35/+15
| | | | | | | | trust_pw_find_change_and_store_it() Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* s3:libsmb: remove unused change_trust_account_password()Stefan Metzmacher2013-10-171-72/+0
| | | | | | Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* s3-rpc_cli: pass down ndr_interface_table to cli_rpc_pipe_open_noauth().Günther Deschner2013-08-051-1/+1
| | | | | | | | Guenther Signed-off-by: Günther Deschner <gd@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Andreas Schneider <asn@samba.org>
* s3: use generate_random_password() instead of generate_random_str()Stefan Metzmacher2013-02-041-3/+4
| | | | | Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* s3:libsmb: s/Undefined/SMB_SIGNING_DEFAULT/Stefan Metzmacher2011-11-031-1/+1
| | | | metze
* s3-trustdomcache: make enumerate_domain_trusts() static.Günther Deschner2011-11-021-101/+0
| | | | Guenther
* s3-param Remove special case for global_myname(), rename to lp_netbios_name()Andrew Bartlett2011-06-091-2/+2
| | | | | | | | There is no reason this can't be a normal constant string in the loadparm system, now that we have lp_set_cmdline() to handle overrides correctly. Andrew Bartlett
* s3-talloc Change TALLOC_ZERO_ARRAY() to talloc_zero_array()Andrew Bartlett2011-06-091-2/+2
| | | | | Using the standard macro makes it easier to move code into common, as TALLOC_ZERO_ARRAY isn't standard talloc.
* s3-libsmb: move protos to libsmb/proto.hGünther Deschner2011-05-061-0/+1
| | | | Guenther
* More simple const fixes.Jeremy Allison2011-05-051-1/+1
|
* s3-passdb: add passdb.h where needed.Günther Deschner2011-03-301-0/+1
| | | | Guenther
* s3-rpc_client: Move client pipe functions to own header.Andreas Schneider2011-02-281-0/+1
|
* s3-libsmb: prefer dcerpc_lsa_X functions.Günther Deschner2011-02-021-14/+22
| | | | Guenther
* s3: Remove unused "retry" from cli_full_connectionVolker Lendecke2010-12-201-2/+2
|
* s3: Remove some unused variablesVolker Lendecke2010-12-201-2/+1
|
* s3-secrets: only include secrets.h when needed.Günther Deschner2010-08-051-0/+1
| | | | Guenther
* s3-libsmb: move change_trust_account_password out of smbd into libsmb.Günther Deschner2010-06-301-0/+74
| | | | Guenther
* s3:dom_sid Global replace of DOM_SID with struct dom_sidAndrew Bartlett2010-05-211-2/+2
| | | | | | | | | | This matches the structure that new code is being written to, and removes one more of the old-style named structures, and the need to know that is is just an alias for struct dom_sid. Andrew Bartlett Signed-off-by: Günther Deschner <gd@samba.org>
* s3-rpc_client: move protos to cli_lsarpc.hGünther Deschner2010-05-181-0/+1
| | | | Guenther
* s3-rpc_client: move protos to cli_netlogon.hGünther Deschner2010-05-181-0/+1
| | | | Guenther
* s3-rpc: Avoid including every pipe's client and server stubs everywhere in ↵Günther Deschner2009-11-261-0/+1
| | | | | | samba. Guenther
* Ensure all callers to the rpc_client/cli_pipe functions correctlyJeremy Allison2009-11-121-1/+1
| | | | | initialize return variables. Jeremy.
* s3: Remove debug_ctx()Volker Lendecke2009-11-031-1/+1
| | | | | | | | smbd just crashed on me: In a debug message I called a routine preparing a string that itself used debug_ctx. The outer routine also used it after the inner routine had returned. It was still referencing the talloc context that the outer debug_ctx() had given us, which the inner DEBUG had already freed.
* s3: use enum netr_SchannelType all over the place.Günther Deschner2009-10-131-2/+2
| | | | Guenther
* s3-netlogon: allow to change any type of trust account password in ↵Günther Deschner2009-10-131-6/+39
| | | | | | trust_pw_find_change_and_store_it(). Guenther
* s3-netlogon: pass down account name to remote password set functions.Günther Deschner2009-10-131-0/+3
| | | | Guenther
* Revert "s3: Attempt to fix machine password change"Volker Lendecke2009-10-051-3/+5
| | | | | | This reverts commit 20a8ea91e10af167067cc794a251265aaf489e75. Ooops, this should not have been committed.
* s3: Attempt to fix machine password changeVolker Lendecke2009-10-051-5/+3
|
* s3: Fix nonempty blank linesVolker Lendecke2009-10-051-4/+4
| | | | Signed-off-by: Günther Deschner <gd@samba.org>
* Rework Samba3 to use new libcli/auth code (partial)Andrew Bartlett2009-04-141-0/+1
| | | | | | | | | | | This commit is mostly to cope with the removal of SamOemHash (replaced by arcfour_crypt()) and other collisions (such as changed function arguments compared to Samba3). We still provide creds_hash3 until Samba3 uses the credentials code in netlogon server Andrew Bartlett
* s3: remove POLICY_HND.Günther Deschner2009-03-181-1/+1
| | | | Guenther
* Add TALLOC_CTX pointer to generate_random_str(), for consistency withJelmer Vernooij2008-10-191-3/+2
| | | | Samba 4.
* netlogon: move password change code out to rpccli_netlogon_set_trust_password.Günther Deschner2008-09-211-94/+5
| | | | Guenther
* netlogon: refactor just_change_the_password a bit.Günther Deschner2008-09-211-22/+16
| | | | Guenther
* netlogon: use init_netr_CryptPassword in "just_change_the_password"Günther Deschner2008-09-211-13/+10
| | | | Guenther
* Fix Bug #5710 and make machine account password changing work again.Günther Deschner2008-08-211-23/+52
| | | | | | | | | | When we negotiated NETLOGON_NEG_PASSWORD_SET2 we need to use NetrServerPasswordSet2 to change the machine password. Tested with NT4, W2k, W2k3 and W2k8. Guenther (This used to be commit 5820360451e4db0fad0472f814cae667b2ea51fd)
* Refactoring: Change calling conventions for cli_rpc_pipe_open_noauthVolker Lendecke2008-07-201-2/+3
| | | | | Pass in ndr_syntax_id instead of pipe_idx, return NTSTATUS (This used to be commit 9abc9dc4dc13bd3e42f98eff64eacf24b51f5779)
* Refactoring: Make cli_pipe_auth_data a pointer off rpc_pipe_clientVolker Lendecke2008-04-251-1/+1
| | | | (This used to be commit f665afaaa3eff9ef54112e08ed034a6e1bb30edc)
* Add "desthost" to rpc_pipe_clientVolker Lendecke2008-04-201-1/+1
| | | | | This reduces the dependency on cli_state (This used to be commit 783afab9c891dd7bcb78895b2a639b6f3a0edf5b)
* Fix NETLOGON credential chain with Windows 2008 all over the place.Günther Deschner2008-04-021-1/+1
| | | | | | | | | | | | In order to avoid receiving NT_STATUS_DOWNGRADE_DETECTED from a w2k8 netr_ServerAuthenticate2 reply, we need to start with the AD netlogon negotiate flags everywhere (not only when running in security=ads). Only for NT4 we need to do a downgrade to the returned negotiate flags. Tested with w2k8, w2ksp4, w2k3r2 and nt4sp6. Guenther (This used to be commit 0970369ca0cb9ae465cff40e5c75739824daf1d0)
* Add a talloc context parameter to current_timestring() to fix memleaks.Michael Adam2008-03-281-1/+1
| | | | | | | | | | | | | | current_timestring used to return a string talloced to talloc_tos(). When called by DEBUG from a TALLOC_FREE, this produced messages "no talloc stackframe around, leaking memory". For example when used from net conf. This also adds a temporary talloc context to alloc_sub_basic(). For this purpose, the exit strategy is slightly altered: a common exit point is used for success and failure. Michael (This used to be commit 16b5800d4e3a8b88bac67b2550d14e0aaaa302a9)
* Use new LSA_POLICY defines in lsa rpc server code and other places.Günther Deschner2008-02-271-1/+1
| | | | | Guenther (This used to be commit 58cca9faf9db506bd2f6eab4a99ef85153797ab2)
* Use rpccli_netr_ServerPasswordSet in "just_change_the_password()".Günther Deschner2008-02-161-1/+26
| | | | | Guenther (This used to be commit 33f91c894488687a42500e751eb9016d99d9129c)
* Use rpccli_lsa_EnumTrustDom all over the place.Günther Deschner2008-02-131-2/+26
| | | | | Guenther (This used to be commit a25e7ffbca9c2c97dd36b0596e7cb38a72aaf9d9)
* Windows 2008 (Longhorn) auth2 flag fixes.Andreas Schneider2008-01-231-1/+1
| | | | | Interop fixes for AD specific flags. Original patch from Todd Stetcher. (This used to be commit 5aadfcdaacd6f136eab9e107a88b8544e6d2105f)
* This is a large patch (sorry). Migrate from struct in_addrJeremy Allison2007-10-241-3/+3
| | | | | | | | | | | | | | to struct sockaddr_storage in most places that matter (ie. not the nmbd and NetBIOS lookups). This passes make test on an IPv4 box, but I'll have to do more work/testing on IPv6 enabled boxes. This should now give us a framework for testing and finishing the IPv6 migration. It's at the state where someone with a working IPv6 setup should (theorecically) be able to type : smbclient //ipv6-address/share and have it work. Jeremy. (This used to be commit 98e154c3125d5732c37a72d74b0eb5cd7b6155fd)