summaryrefslogtreecommitdiffstats
path: root/source3/libsmb
Commit message (Collapse)AuthorAgeFilesLines
* s3-dsgetdcname: print IP address for LDAP ping.Günther Deschner2014-02-131-1/+3
| | | | | | | Guenther Signed-off-by: Günther Deschner <gd@samba.org> Reviewed-by: Andreas Schneider <asn@samba.org>
* param: rename lp function and variable from "cli_minprotocol" to ↵Garming Sam2014-02-073-3/+3
| | | | | | | | "client_min_protocol" Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* param: rename lp function and variable from "cli_maxprotocol" to ↵Garming Sam2014-02-072-2/+2
| | | | | | | | "client_max_protocol" Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* param: rename lp function and variable from 'piddir' to 'pid_directory'Garming Sam2014-02-071-1/+1
| | | | | | Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* param: rename lp function and variable from 'passwordserver' to ↵Garming Sam2014-02-071-1/+1
| | | | | | | | 'password_server' Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* 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>
* libcli/smb: move source3/libsmb/cli_np_tstream.c to tstream_smbXcli_np.cStefan Metzmacher2014-01-072-1389/+0
| | | | | | | This code is generic enough to have it in the top level now. Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Andreas Schneider <asn@samba.org>
* s3:libsmb: add a TSTREAM_CLI_NP_DESIRED_ACCESS define as collection of ↵Stefan Metzmacher2014-01-071-2/+14
| | | | | | | individual flags Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Andreas Schneider <asn@samba.org>
* s3:libsmb: add tstream_cli_np_ref as protection to talloc_free(smbXcli_conn)Stefan Metzmacher2014-01-071-0/+34
| | | | | | | This makes sure that we don't have dangling pointers. Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Andreas Schneider <asn@samba.org>
* s3:libsmb: do not use cli_state internally within cli_np_tstreamGregor Beck2014-01-072-96/+124
| | | | | | Signed-off-by: Gregor Beck <gbeck@sernet.de> Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Andreas Schneider <asn@samba.org>
* s3:libsmb: let cli_np_tstream use smb1cli_readxGregor Beck2014-01-071-6/+9
| | | | | | Signed-off-by: Gregor Beck <gbeck@sernet.de> Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Andreas Schneider <asn@samba.org>
* s3:libsmb: let cli_np_tstream use smb1cli_writexGregor Beck2014-01-071-8/+9
| | | | | | Signed-off-by: Gregor Beck <gbeck@sernet.de> Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Andreas Schneider <asn@samba.org>
* s3:libsmb: let cli_np_tstream use smb1cli_closeGregor Beck2014-01-071-10/+29
| | | | | | Signed-off-by: Gregor Beck <gbeck@sernet.de> Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Andreas Schneider <asn@samba.org>
* s3:libsmb: let cli_np_tstream use smb1cli_transGregor Beck2014-01-071-14/+19
| | | | | | Signed-off-by: Gregor Beck <gbeck@sernet.de> Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Andreas Schneider <asn@samba.org>
* s3:libsmb: let cli_np_tstream use smb1cli_ntcreatexGregor Beck2014-01-071-11/+17
| | | | | | Signed-off-by: Gregor Beck <gbeck@sernet.de> Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Andreas Schneider <asn@samba.org>
* s3:libsmb fix a compiler warningChristian Ambach2013-12-121-1/+1
| | | | | | | about a potentially uninitialized variable Signed-off-by: Christian Ambach <ambi@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* s3-libsmb: Fix a memory leak in get_pdc_ip().Andreas Schneider2013-12-061-0/+1
| | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* s3-libsmb: Fix scanf format in parse_ace().Andreas Schneider2013-11-151-3/+3
| | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* s3-libsmb: Use the right macro to set uint16_t attr.Andreas Schneider2013-11-151-1/+1
| | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* s3-client: smbclient shows no error if deleting a directory with del failedJeremy Allison2013-11-143-4/+28
| | | | | | | | | | | | | | | | | BUG: https://bugzilla.samba.org/show_bug.cgi?id=10260 In SMB1 the server filters by attribute requested, in SMB2 there is no attribute sent. Emulate this on the client to provide the same ABI to callers. In SMB1 the server returns NT_STATUS_NO_SUCH_FILE if FindFirst finds no files. Emulate this on the client. Signed-off-by: Jeremy Allison <jra@samba.org> Reviewed-by: Andreas Schneider <asn@samba.org> Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org> Autobuild-Date(master): Thu Nov 14 21:23:07 CET 2013 on sn-devel-104
* libsmb: Fix CID 242665 Out-of-bounds accessVolker Lendecke2013-11-131-3/+7
| | | | | | | | | | | Coverity is confused by the dual-use of "pss" as an array of size 1. This is not strictly a bug here, but it is admittedly a small subtlety. It should fix a whole bunch of Coverity issues. Normally I would resist to change our code in response to a deficient static checker, but here I would vote for this compromise. Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Andreas Schneider <asn@samba.org>
* libsmb: Fix CID 241313 Array compared against 0Volker Lendecke2013-11-111-4/+2
| | | | | | | userinfo->passwrd is not a pointer, no point in checking for !=NULL Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Ira Cooper <ira@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: SMBC_getatr() if no method worked, try all methods again on next ↵Gregor Beck2013-10-301-3/+5
| | | | | | | | attempt Signed-off-by: Gregor Beck <gbeck@sernet.de> Reviewed-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* s3:libsmb: cli_qpathinfo3 use cli_qpathinfo2 for smb2Gregor Beck2013-10-301-1/+7
| | | | | | | | | cli_qpathinfo3 only works (and is only needed as fallback so far) for smb1. Use cli_qpathinfo2 in the smb2 case to make it universally usable. Signed-off-by: Gregor Beck <gbeck@sernet.de> Reviewed-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* s3:libsmb: SMBC_getatr use pathinfo3 for second tryGregor Beck2013-10-302-0/+14
| | | | | | | | | The pathinfo2 call might fail against NetApp because it is sending broken packages. Signed-off-by: Gregor Beck <gbeck@sernet.de> Reviewed-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* s3:libsmb: SMBC_getatr do not let ino undefined on successGregor Beck2013-10-301-0/+3
| | | | | | Signed-off-by: Gregor Beck <gbeck@sernet.de> Reviewed-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* s3:libsmb: SMBC_getatr try pathinfo2 only onceGregor Beck2013-10-301-1/+2
| | | | | | Signed-off-by: Gregor Beck <gbeck@sernet.de> Reviewed-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* s3:libsmb: add function cli_qpathinfo3()Gregor Beck2013-10-302-0/+61
| | | | | | | | | This is a reimplemantation of cli_qpathinfo2 without the use of info level SMB_QFILEINFO_ALL_INFO which leads to broken responses from NetApp. Signed-off-by: Gregor Beck <gbeck@sernet.de> Reviewed-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* s3:libsmb: add function cli_qpathinfo_standard()Gregor Beck2013-10-302-0/+53
| | | | | | Signed-off-by: Gregor Beck <gbeck@sernet.de> Reviewed-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* s3:libsmb: pass creation or birth time in cli_qpathinfo_basic()Gregor Beck2013-10-301-0/+1
| | | | | | Signed-off-by: Gregor Beck <gbeck@sernet.de> Reviewed-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* s3:libsmb: call smbXcli_tcon_set_fs_attributes() directlyStefan Metzmacher2013-10-171-4/+8
| | | | | | | | | | | | | We should try to set all attributes we got and not just FILE_CASE_SENSITIVE_SEARCH. Bug: https://bugzilla.samba.org/show_bug.cgi?id=10200 Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Michael Adam <obnox@samba.org> Autobuild-User(master): Michael Adam <obnox@samba.org> Autobuild-Date(master): Thu Oct 17 19:02:03 CEST 2013 on sn-devel-104
* s3:libsmb: remove unused cli_state->case_sensitiveStefan Metzmacher2013-10-171-3/+6
| | | | | | | Bug: https://bugzilla.samba.org/show_bug.cgi?id=10200 Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* s3:libsmb: remove unused cli_state->dfsrootStefan Metzmacher2013-10-171-6/+0
| | | | | | | Bug: https://bugzilla.samba.org/show_bug.cgi?id=10200 Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* s3:libsmb: add SMB2/3 support to cli_dfs_get_referral()Stefan Metzmacher2013-10-171-17/+56
| | | | | | | Bug: https://bugzilla.samba.org/show_bug.cgi?id=10200 Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* s3/libsmb: make use of smbXcli_tcon_is_dfs_share()Stefan Metzmacher2013-10-172-3/+26
| | | | | | | Bug: https://bugzilla.samba.org/show_bug.cgi?id=10200 Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* s3/libsmb: Use smbXcli_conn_dfs_supported instead of test on CAP_DFSLuk Claes2013-10-173-3/+3
| | | | | | | | Bug: https://bugzilla.samba.org/show_bug.cgi?id=10200 Signed-off-by: Luk Claes <luk@debian.org> Reviewed-by: Michael Adam <obnox@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org>
* s3:libsmb: don't pass down FLAG_CASELESS_PATHNAMES and FLAGS2_DFS_PATHNAMES ↵Stefan Metzmacher2013-10-172-43/+0
| | | | | | | | | | | anymore They're now handled at the smbXcli_conn and smbXcli_tcon layer. Bug: https://bugzilla.samba.org/show_bug.cgi?id=10200 Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* s3:libsmb: call smbXcli_tcon_{get,set}_fs_attributes() from ↵Stefan Metzmacher2013-10-171-0/+17
| | | | | | | | | cli_set_case_sensitive() Bug: https://bugzilla.samba.org/show_bug.cgi?id=10200 Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* s3:libsmb: make use of smb1cli_tcon_set_values()Stefan Metzmacher2013-10-171-2/+17
| | | | | | | Bug: https://bugzilla.samba.org/show_bug.cgi?id=10200 Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* s3/libsmb: Use smbXcli_conn_use_unicode instead of smb1 specific testLuk Claes2013-10-171-1/+1
| | | | | | Signed-off-by: Luk Claes <luk@debian.org> Reviewed-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Michael Adam <obnox@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>
* cli_np_tstream: remove unused tstream_cli_np_get_cli_state()Gregor Beck2013-10-172-10/+0
| | | | | | | Signed-off-by: Gregor Beck <gbeck@sernet.de> Reviewed-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* s3-auth: also load schannel module from auth_generic_client_prepare().Günther Deschner2013-09-191-1/+2
| | | | | | | | Guenther Signed-off-by: Günther Deschner <gd@samba.org> Pair-Programmed-With: Andreas Schneider <asn@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org>
* s3: libsmb SMB2 wrapper layer. cli_smb2_get_ea_list_path() failed to close ↵Jeremy Allison2013-09-171-0/+4
| | | | | | | | | file on exit. Found at SNIA SDC plugfest. Signed-off-by: Jeremy Allison <jra@samba.org> Reviewed-by: Volker Lendecke <vl@samba.org>
* s3: libsmb : The short name length is only a one byte field.Jeremy Allison2013-09-171-1/+1
| | | | | | | | | | | The next byte is "undefined" and some vendors set this to 0xff (discovered in SNIA SDC lab tests). Signed-off-by: Jeremy Allison <jra@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org> Autobuild-User(master): Stefan Metzmacher <metze@samba.org> Autobuild-Date(master): Tue Sep 17 12:27:18 CEST 2013 on sn-devel-104
* lib: Use "mem_ctx" arg in gencache_getVolker Lendecke2013-09-053-11/+11
| | | | | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Signed-off-by: Jeremy Allison <jra@samba.org> Autobuild-User(master): Jeremy Allison <jra@samba.org> Autobuild-Date(master): Thu Sep 5 20:09:21 CEST 2013 on sn-devel-104
* Add a talloc context to sitename_fetch().Jeremy Allison2013-09-053-15/+15
| | | | | Signed-off-by: Jeremy Allison <jra@samba.org> Reviewed-by: Volker Lendecke <vl@samba.org>