1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-28 07:21:54 +03:00
Commit Graph

34579 Commits

Author SHA1 Message Date
Stefan Metzmacher
5b9a3a79f7 s3-waf: use NDR_NTLMSSP subsystem
metze
2010-10-25 08:16:29 +00:00
Stefan Metzmacher
ffbe1c0723 s3-waf: add NDR_STANDARD dependencies to fix the build
metze
2010-10-25 08:16:29 +00:00
Stefan Metzmacher
2b74cea5f0 s3-waf: use git to calculate the version if available
metze
2010-10-25 08:16:28 +00:00
Andrew Tridgell
986a00dcef s3-waf: fixed paths in s3 waf build for rpc_server
paths in waf rules are relative

Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2010-10-25 11:12:03 +11:00
Andrew Tridgell
ec98bb55c6 s3-waf: fixed waf configure for recent changes 2010-10-25 11:12:03 +11:00
Volker Lendecke
caf77f7c73 s3: Use cli_setpathinfo in cli_posix_unlink_internal
Autobuild-User: Volker Lendecke <vlendec@samba.org>
Autobuild-Date: Sun Oct 24 21:28:08 UTC 2010 on sn-devel-104
2010-10-24 21:28:08 +00:00
Volker Lendecke
2d51a24ba5 s3: Avoid passing down a boolean to cli_posix_unlink_internal_send 2010-10-24 20:46:28 +00:00
Volker Lendecke
28e243f7ad s3: Use cli_setpathinfo in cli_posix_chown_chmod_internal 2010-10-24 20:46:28 +00:00
Volker Lendecke
dedda3e245 s3: Use cli_setpathinfo in cli_posix_link_internal 2010-10-24 20:46:28 +00:00
Volker Lendecke
c0a6b74aa4 s3: Use tevent_req_simple_recv_ntstatus where appropriate 2010-10-24 20:46:28 +00:00
Volker Lendecke
64275ebe89 s3: Pass down a level instead of a flag to cli_posix_link_internal 2010-10-24 20:46:28 +00:00
Volker Lendecke
7b3fccd5b4 s3: Add async cli_setpathinfo 2010-10-24 20:46:28 +00:00
Volker Lendecke
40cc1a3d2e s3: Add "setea" to smbclient 2010-10-24 20:46:28 +00:00
Volker Lendecke
86cb0ad242 s3: Add "geteas" to smbclient 2010-10-24 20:46:28 +00:00
Stefan Metzmacher
cbee24b2da s3:include: move debug.c prototypes to debug.h
metze
2010-10-24 18:40:13 +00:00
Stefan Metzmacher
dbc934ee4b s3:include: move MAX_DEBUG_LEVEL from local.h to debug.h
metze
2010-10-24 18:40:13 +00:00
Volker Lendecke
172a1580d2 s3: Initialize output vars in parse_ea_blob
Autobuild-User: Volker Lendecke <vlendec@samba.org>
Autobuild-Date: Sun Oct 24 12:22:22 UTC 2010 on sn-devel-104
2010-10-24 12:22:22 +00:00
Volker Lendecke
09a1075044 s3: Remove unused cli_get_ea_list_fnum
Autobuild-User: Volker Lendecke <vlendec@samba.org>
Autobuild-Date: Sun Oct 24 10:23:29 UTC 2010 on sn-devel-104
2010-10-24 10:23:28 +00:00
Volker Lendecke
5a17d26e47 s3: Replace cli_qfileinfo_test with a call to cli_qfileinfo 2010-10-24 11:39:30 +02:00
Volker Lendecke
c095809c04 s3: Convert cli_qfileinfo_basic to cli_qfileinfo 2010-10-24 11:39:30 +02:00
Volker Lendecke
d864b1bace s3: Convert cli_qfilename to cli_qfileinfo 2010-10-24 11:39:30 +02:00
Volker Lendecke
9423257806 s3: Add async cli_qfileinfo 2010-10-24 11:39:30 +02:00
Volker Lendecke
03333fc68c s3: Rename cli_fileinfo() to cli_fileinfo_basic() 2010-10-24 11:39:29 +02:00
Jelmer Vernooij
833480d3ad s4: Rename LIBSAMBA-* to libsamba-* 2010-10-24 00:20:04 +00:00
Jelmer Vernooij
ca16d805bd s4: Rename LIBSECURITY{_SESSION,} to libsecurity{_session,} 2010-10-24 00:20:04 +00:00
Jelmer Vernooij
2933fac7c7 s4: Rename NSS_WRAPPER to nss_wrapper.
Only link to nss_wrapper when it is enabled.

Autobuild-User: Jelmer Vernooij <jelmer@samba.org>
Autobuild-Date: Sat Oct 23 23:05:44 UTC 2010 on sn-devel-104
2010-10-23 23:05:43 +00:00
Kai Blin
c320c1ab98 lib/util: Add tevent WERROR wrappers
Signed-off-by: Stefan Metzmacher <metze@samba.org>

Autobuild-User: Stefan Metzmacher <metze@samba.org>
Autobuild-Date: Sat Oct 23 07:35:28 UTC 2010 on sn-devel-104
2010-10-23 07:35:28 +00:00
Jeremy Allison
272feb7bd1 Revert "Wrap security_token_has_privilege() with a check for lp_enable_privileges(). Needed"
Not needed - privileges code prevents "enable privileges = no" from adding privileges
anyway.

This reverts commit a8b95686a7.

Autobuild-User: Jeremy Allison <jra@samba.org>
Autobuild-Date: Fri Oct 22 23:41:36 UTC 2010 on sn-devel-104
2010-10-22 23:41:36 +00:00
Jeremy Allison
a8b95686a7 Wrap security_token_has_privilege() with a check for lp_enable_privileges(). Needed
to maintain compatibility with smb.conf manpage.

Jeremy.

Autobuild-User: Jeremy Allison <jra@samba.org>
Autobuild-Date: Fri Oct 22 18:15:48 UTC 2010 on sn-devel-104
2010-10-22 18:15:48 +00:00
Jelmer Vernooij
c529317fe2 Lowercase socket_wrapper name.
Avoid linking against socket_wrapper outside of developer mode.

Autobuild-User: Jelmer Vernooij <jelmer@samba.org>
Autobuild-Date: Thu Oct 21 20:26:11 UTC 2010 on sn-devel-104
2010-10-21 20:26:11 +00:00
Andrew Tridgell
62d7b27808 s3-waf: mark some libraries as private
public libraries must have a vnum specified
2010-10-21 19:03:26 +11:00
Jeremy Allison
e00c2b3cdf Add code to implement SeSecurityPrivilege in net rpc rights, and in the
open and get/set NT security descriptor code.

Jeremy.

Autobuild-User: Jeremy Allison <jra@samba.org>
Autobuild-Date: Thu Oct 21 00:15:57 UTC 2010 on sn-devel-104
2010-10-21 00:15:57 +00:00
Volker Lendecke
7a194c6e5e s3: Make "unpack_pjob" static
Autobuild-User: Volker Lendecke <vlendec@samba.org>
Autobuild-Date: Wed Oct 20 16:51:04 UTC 2010 on sn-devel-104
2010-10-20 16:51:04 +00:00
Volker Lendecke
1d5cb5125c s3: Use any_nt_status_not_ok in winbind 2010-10-20 18:09:20 +02:00
Volker Lendecke
347ca8f757 s3: Add any_nt_status_not_ok
This helps avoid quite a bit of repetitive code when looking at dcerpc_xx_recv
results.
2010-10-20 18:09:20 +02:00
Jeremy Allison
e1cfca1e2e Make getpwnam_alloc() static to lib/username.c, and ensure all username lookups go
through Get_Pwnam_alloc(), which is the correct wrapper function. We were using
it *some* of the time anyway, so this just makes us properly consistent.

Jeremy.

Autobuild-User: Jeremy Allison <jra@samba.org>
Autobuild-Date: Wed Oct 20 16:02:12 UTC 2010 on sn-devel-104
2010-10-20 16:02:12 +00:00
Günther Deschner
ab01d6139f nsstest: no need for two copies of the same tool.
Guenther

Autobuild-User: Günther Deschner <gd@samba.org>
Autobuild-Date: Wed Oct 20 15:05:34 UTC 2010 on sn-devel-104
2010-10-20 15:05:33 +00:00
Günther Deschner
abb07fad04 s3-waf: more registry cleanup.
Guenher
2010-10-20 16:21:12 +02:00
Günther Deschner
d05157a470 s3-waf: convert LIBSMBCONF into a subsystem.
Guenther
2010-10-20 16:21:12 +02:00
Günther Deschner
4a2e47b74a s3-waf: move RPC_CLIENT_SCHANNEL into a subsystem.
Guenther
2010-10-20 16:21:12 +02:00
Volker Lendecke
efb22bf782 s3: Add some DEBUG
Autobuild-User: Volker Lendecke <vlendec@samba.org>
Autobuild-Date: Wed Oct 20 11:58:20 UTC 2010 on sn-devel-104
2010-10-20 11:58:20 +00:00
Volker Lendecke
da00021a7c s3: Cope with EINTR in smbd_[un]lock_socket 2010-10-20 13:14:57 +02:00
Jeremy Allison
e7d0f478ee Add deadtime detection for SMB2. Correctly update lastused timestamp across all active tcons. Should fix dfree cache not updating bug. 2010-10-19 15:13:17 -07:00
Jeremy Allison
d7f4bea394 Add SMB2 paths to smbd/conn.c. Except for conn_idle_all(), to be cleaned up next. 2010-10-19 15:13:17 -07:00
Jeremy Allison
1bd6faa8fa Copyright/whitespace/comment cleanup in preparation for adding SMB2 paths. 2010-10-19 15:13:17 -07:00
Jeremy Allison
edefaf5bed Move tcons.num_open from smb1 to sconn->num_tcons_open as this is needed for SMB2 also. 2010-10-19 15:13:17 -07:00
Andrew Bartlett
492ab4d60f s3-waf Use LIBSECRUITY subsystem from the common wscript_build
Andrew Bartlett

Autobuild-User: Andrew Bartlett <abartlet@samba.org>
Autobuild-Date: Tue Oct 19 22:06:51 UTC 2010 on sn-devel-104
2010-10-19 22:06:50 +00:00
Günther Deschner
7db20c3128 s3-waf: all subsystems complete now, no need for this loop anymore.
Kai, please check.

Guenther

Autobuild-User: Günther Deschner <gd@samba.org>
Autobuild-Date: Tue Oct 19 17:10:24 UTC 2010 on sn-devel-104
2010-10-19 17:10:24 +00:00
Günther Deschner
fa2a2d562f s3-waf: convert rpc into a subsystem.
Guenther
2010-10-19 18:26:59 +02:00
Günther Deschner
64e9f79587 s3: fix the build of idmap_adex, idmap_tdb2, idmap_hash and several vfs modules.
Guenther

Autobuild-User: Günther Deschner <gd@samba.org>
Autobuild-Date: Mon Oct 18 14:39:39 UTC 2010 on sn-devel-104
2010-10-18 14:39:39 +00:00
Günther Deschner
5845dae826 s3-waf: fix the build after libcli/security changes.
Guenther
2010-10-18 15:57:03 +02:00
Günther Deschner
203dc4f929 s3-waf: fix the build of smbtorture.
Guenther
2010-10-18 15:57:03 +02:00
Günther Deschner
10f95a4f1a s3-waf: fix pdb modules build.
Guenther
2010-10-18 15:57:03 +02:00
Stefan Metzmacher
5c82a1bb0a s3:libsmb: add pipe related NT_STATUS_RPC_* codes
metze
2010-10-18 14:50:21 +02:00
Andreas Schneider
b615b70601 s3-winbind: Fixed init order.
We need the system server info in the rpc services.

Autobuild-User: Andreas Schneider <asn@samba.org>
Autobuild-Date: Mon Oct 18 12:43:16 UTC 2010 on sn-devel-104
2010-10-18 12:43:16 +00:00
Jeremy Allison
83871d2642 Don't arbitrarily clean all parametric options in add_a_service(),
that is called from many places, not just smb.conf processing. Only
clean parametric options when doing actual smb.conf reading (or
registry equivalent).

Michael Adams, Volker, Metze, please check.

Jeremy.

Autobuild-User: Jeremy Allison <jra@samba.org>
Autobuild-Date: Sat Oct 16 06:46:19 UTC 2010 on sn-devel-104
2010-10-16 06:46:19 +00:00
Jeremy Allison
bcdf781545 Ensure we have correct parameters to use Windows ACL modules.
Autobuild-User: Jeremy Allison <jra@samba.org>
Autobuild-Date: Sat Oct 16 03:36:04 UTC 2010 on sn-devel-104
2010-10-16 03:36:04 +00:00
Jeremy Allison
06fc79f1fd Add acl_xattr:ignore system acls boolean (normally false) to allow
Samba ACL module to ignore mapping to lower POSIX layer. With this
fix Samba 3.6.x now passes RAW-ACLs (with certain smb.conf parameters
set).

Jeremy.

Autobuild-User: Jeremy Allison <jra@samba.org>
Autobuild-Date: Sat Oct 16 01:26:31 UTC 2010 on sn-devel-104
2010-10-16 01:26:30 +00:00
Jeremy Allison
cf45581cdf Add make_default_filesystem_acl() function to be used in following change to acl_xattr and acl_tdb module. 2010-10-15 17:38:22 -07:00
Jeremy Allison
1904c44ec8 Fix handling of "NULL" DACL. Map to u/g/w - rwx.
Jeremy.
2010-10-15 17:38:22 -07:00
Jeremy Allison
e031f8ae6a Fix "force unknown ACL user" to strip out foreign SIDs from POSIX ACLs if they can't be mapped. 2010-10-15 17:38:22 -07:00
Jeremy Allison
f4a9d25cfc Add debug message to get_nt_acl_internal() to see what we got. 2010-10-15 17:38:21 -07:00
Jeremy Allison
625126dc8d Fix valgrind "uninitialized read" error on "info" when returning !NT_STATUS_OK.
Jeremy.
2010-10-15 17:38:21 -07:00
Jeremy Allison
8cad5e23b6 Fix bug #7734 - When creating files with "inherit ACLs" set to true, we neglect to apply appropriate create masks.
Jeremy.
2010-10-15 17:38:21 -07:00
Jeremy Allison
92adb68637 Fix bug #7733 - Invalid client DOS attributes on create can cause incorrect unix mode_t to be generated.
It turns out a client can send an NTCreateX call for a new file, but specify
FILE_ATTRIBUTE_DIRECTORY in the attribute list. Windows silently strips this,
but we don't - causing the unix_mode() function to go through the "mode bits
for new directory" codepath, instead of the "mode bits for new file" codepath.

Jeremy.
2010-10-15 17:38:21 -07:00
Andreas Schneider
a8f26f60ec s3-rpc_server: Normalize rpc_pipe_open_interface pipe name.
Autobuild-User: Andreas Schneider <asn@samba.org>
Autobuild-Date: Fri Oct 15 12:15:45 UTC 2010 on sn-devel-104
2010-10-15 12:15:45 +00:00
Andreas Schneider
f22e6cf3b7 s3-rpc_server: Make auth_serversupplied_info const. 2010-10-15 11:34:03 +00:00
Andreas Schneider
0195f35ce1 s3-winbind: Fixed the build of idmap_rid. 2010-10-15 11:34:03 +00:00
Volker Lendecke
c2533f94b5 s3: Remove smbd_server_conn from construct_reply
Autobuild-User: Volker Lendecke <vlendec@samba.org>
Autobuild-Date: Thu Oct 14 12:35:07 UTC 2010 on sn-devel-104
2010-10-14 12:35:07 +00:00
Volker Lendecke
63e08ef885 s3: Lift smbd_server_conn from receive_smb_talloc 2010-10-14 13:53:07 +02:00
Volker Lendecke
a2db154caa s3: Lift smbd_server_conn from receive_smb_raw_talloc 2010-10-14 13:53:07 +02:00
Volker Lendecke
fa0de39551 s3: Lift smbd_server_conn from receive_smb_raw_talloc_partial_read 2010-10-14 13:53:07 +02:00
Volker Lendecke
cac60a7041 s3: Remove some explicit smbd_server_conn refs in process_smb() 2010-10-14 13:53:06 +02:00
Volker Lendecke
81bdb5910c s3: Rename "conn" to the more used "sconn" in process_smb() 2010-10-14 13:53:06 +02:00
Andrew Bartlett
a879a4610d libcli/auth Merge source4/libcli/security and util_sid.c into the common code
This should ensure we only have one copy of these core functions
in the tree.

Andrew Bartlett

Signed-off-by: Andrew Tridgell <tridge@samba.org>
2010-10-14 02:35:05 +00:00
Andrew Bartlett
8b22eefd25 libcli/security Define traditional constants in terms of IDL macros
The source3/ code uses these constants in a lot of places, and it will
take time and care to rename them, if that is desired.  Linking the
macros here will at least allow common code to use the IDL based macros,
and preserve a documentary link between the constants (other than just their value)

Andrew Bartlett

Signed-off-by: Andrew Tridgell <tridge@samba.org>
2010-10-14 02:35:05 +00:00
Andrew Bartlett
949541cc6f libcli/security Move source3/lib/util_seaccess.c into the common code
Signed-off-by: Andrew Tridgell <tridge@samba.org>
2010-10-14 02:35:05 +00:00
Andrew Bartlett
058daa1cf5 s3-acl Use uint32_t for counting the ACEs
Signed-off-by: Andrew Tridgell <tridge@samba.org>
2010-10-14 02:35:04 +00:00
Andrew Bartlett
a040466d0d s3-acl Merge source4-supported privileges into se_access_check
This will shortly be the common se_access_check function.

Andrew Bartlett

Signed-off-by: Andrew Tridgell <tridge@samba.org>
2010-10-14 02:35:04 +00:00
Andrew Bartlett
7c6105ec27 s3-util_nttoken.c Also copy the rights_mask when copying a security_token
These are unused in source3/ code at the moment, but it would be
unfortunate if that were to change, and this function not be updated.

Andrew Bartlett

Signed-off-by: Andrew Tridgell <tridge@samba.org>
2010-10-14 02:35:04 +00:00
Andrew Bartlett
170b345e0c s3-auth Use security_token_debug() from common code
This prints the security token including the privileges as strings
instead of just a bitmap.

Andrew Bartlett

Signed-off-by: Andrew Tridgell <tridge@samba.org>
2010-10-14 02:35:04 +00:00
Andrew Bartlett
58cf83732a s3-auth use security_token_has_sid() from the common code
The wrapper call is left here to avoid changing semantics for
the NULL parameter case.

Andrew Bartlett

Signed-off-by: Andrew Tridgell <tridge@samba.org>
2010-10-14 02:35:04 +00:00
Andrew Bartlett
deb7c02436 s3 Replace is_sid_in_token() with security_token_has_sid() from common code
The two routines are identical, so there is no need to keep both.

Andrew Bartlett

Signed-off-by: Andrew Tridgell <tridge@samba.org>
2010-10-14 02:35:04 +00:00
Christian Ambach
beb5afea54 s3:gpfs: Add support for the gpfs_ftruncate call
ported from the v3-4-ctdb branch to master
This used to be commit 1f138cc9f4a

Autobuild-User: Volker Lendecke <vlendec@samba.org>
Autobuild-Date: Wed Oct 13 13:34:25 UTC 2010 on sn-devel-104
2010-10-13 13:34:25 +00:00
Christian Ambach
22018b8b88 s3:vfs:gpfs convert sharemodes/leases parameter
convert gpfs:sharemodes and gpfs:leases parameters from a global setting
to a per share setting
2010-10-13 12:53:16 +00:00
Christian Ambach
9e4a386d67 s3:vfs:syncops add option to disable module per share
add an option to disable the syncops module completely for a
share with
  syncops:disable = true
2010-10-13 12:53:16 +00:00
Christian Ambach
c1dad16ede s3:vfs:syncops make it possible to specify syncops:onclose per share
convert the onclose option of the vfs_syncops module from a
global option to a service-specific one

as preparation for further flags, use a struct to store in the VFS handle
instead of just the onclose flag
2010-10-13 12:53:16 +00:00
Michael Adam
cda2db5edf s3:registry: fix some trailing spaces in reg_backend_db
Autobuild-User: Michael Adam <obnox@samba.org>
Autobuild-Date: Tue Oct 12 14:15:42 UTC 2010 on sn-devel-104
2010-10-12 14:15:42 +00:00
Andrew Bartlett
f768b32e37 libcli/security Provide a common, top level libcli/security/security.h
This will reduce the noise from merges of the rest of the
libcli/security code, without this commit changing what code
is actually used.

This includes (along with other security headers) dom_sid.h and
security_token.h

Andrew Bartlett

Autobuild-User: Andrew Bartlett <abartlet@samba.org>
Autobuild-Date: Tue Oct 12 05:54:10 UTC 2010 on sn-devel-104
2010-10-12 05:54:10 +00:00
Jeremy Allison
6f6094076f Make the vfs_acl_xattr and other modules work with NULL SD's. Fix
the "protected" inheritance problem (bleeding up from the POSIX
layer).

Jeremy

Autobuild-User: Jeremy Allison <jra@samba.org>
Autobuild-Date: Tue Oct 12 00:57:41 UTC 2010 on sn-devel-104
2010-10-12 00:57:41 +00:00
Jeremy Allison
6f4e782c53 Canonicalize incoming and outgoing ACLs.
Jeremy.
2010-10-11 17:10:28 -07:00
Jeremy Allison
71d9f51b4e Make the posix ACL module cope with a NULL incoming DACL and a
missing owner/group.

Jeremy.
2010-10-11 17:07:54 -07:00
Günther Deschner
33c6a4eb8a s3-spoolss: add more userlevel info validation to _spoolss_OpenPrinterEx.
Guenther
2010-10-11 14:31:06 +00:00
Günther Deschner
025290e9bf s3-spoolss: let set_printer_hnd_name return WERROR.
Guenther
2010-10-11 14:31:06 +00:00
Günther Deschner
c8a295ab7f s3-spoolss: convert open_printer_hnd to return WERROR.
Guenther
2010-10-11 14:31:06 +00:00
Günther Deschner
fe724c70d2 s3-spoolss: fix set_printer_hnd_name() to match torture test.
Guenther
2010-10-11 14:31:06 +00:00
Jeremy Allison
9e1e581120 More neccessary const.
Autobuild-User: Jeremy Allison <jra@samba.org>
Autobuild-Date: Sat Oct  9 01:47:25 UTC 2010 on sn-devel-104
2010-10-09 01:47:25 +00:00
Volker Lendecke
615482a83d s3: Hang the isilon kernel oplocks off the NULL context
All I see is a fd_event that does not need a special destructor.

Tim, Steven, I've added the #error as well for you to remove after review.

Thanks,

Volker

Autobuild-User: Volker Lendecke <vlendec@samba.org>
Autobuild-Date: Fri Oct  8 20:48:11 UTC 2010 on sn-devel-104
2010-10-08 20:48:11 +00:00
Volker Lendecke
703e438599 s3: Hang the irix kernel oplocks off the NULL ctx
Just a fd_event to be cleaned up. The pipe is closed implicitly.
2010-10-08 21:11:46 +02:00
Volker Lendecke
613a0b6c00 s3: Hang the linux kernel oplocks off the NULL ctx
The destructor that is called removes the signal handler. But at process
exit the signal handling is lost anyway.
2010-10-08 21:11:46 +02:00
Volker Lendecke
ef96bfe885 s3: Call printer_list_parent_init in the parent
Simo, please check!
2010-10-08 21:11:46 +02:00
Volker Lendecke
812580736a s3: Remove talloc_autofree_context() from get_printer_list_db()
Another db that does not need explicit closing
2010-10-08 21:11:45 +02:00
Volker Lendecke
1e98d5859d s3: Remove talloc_autofree_context() from loadparm.c
None of these uses requires a special destructor
2010-10-08 21:11:45 +02:00
Volker Lendecke
220aa311d1 s3: Add a little test for the echo responder 2010-10-08 21:11:45 +02:00
Volker Lendecke
5e482aeebf s3: Implement echo_TestSleep 2010-10-08 21:11:45 +02:00
Volker Lendecke
b5ed09c3af Move talloc_enable_null_tracking() to the s3 daemons 2010-10-08 21:11:45 +02:00
Günther Deschner
4e9508172d s3-waf: slowly getting modules to match how they look like in old build.
Guenther

Autobuild-User: Günther Deschner <gd@samba.org>
Autobuild-Date: Fri Oct  8 09:31:01 UTC 2010 on sn-devel-104
2010-10-08 09:31:01 +00:00
Volker Lendecke
7915142848 s3: Fix input check in is_encrypted_packet
Autobuild-User: Volker Lendecke <vlendec@samba.org>
Autobuild-Date: Fri Oct  8 07:40:52 UTC 2010 on sn-devel-104
2010-10-08 07:40:51 +00:00
Jeremy Allison
cd04af78d5 Fix bug 7716 - acl_xattr and acl_tdb modules don't store unmodified copies of security descriptors.
As pointed out by an OEM, the code within smbd/posix_acl.c, even though passed
a const pointer to a security descriptor, still modifies the ACE entries within
it (which are not const pointers).

This means ACLs stored in the extended attribute by the acl_xattr module have
already been modified by the POSIX acl layer, and are not the original intent
of storing the "unmodified" ACL from the client.

Use dup_sec_desc to make a copy of the incoming ACL on talloc_tos() - that
is what is then modified inside smbd/posix_acl.c, leaving the original ACL
to be correctly stored in the xattr.

Jeremy.

Autobuild-User: Jeremy Allison <jra@samba.org>
Autobuild-Date: Fri Oct  8 00:37:53 UTC 2010 on sn-devel-104
2010-10-08 00:37:53 +00:00
Volker Lendecke
fd9effce2b s3: Fix the async echo responder for netbios keepalives
This fixes a crash in the echo responder when the client started to send the
NetBIOS-Level 0x85-style keepalive packets. We did not correctly check the
packet length, so the code writing the signing seqnum overwrote memory after
the malloc'ed area for the 4 byte keepalive packet.

Autobuild-User: Jeremy Allison <jra@samba.org>
Autobuild-Date: Thu Oct  7 19:47:35 UTC 2010 on sn-devel-104
2010-10-07 19:47:35 +00:00
Günther Deschner
d8c86a7f77 s3-spoolss: make it possible to have and announce a [prnproc$] share on the printserver.
Guenther

Autobuild-User: Günther Deschner <gd@samba.org>
Autobuild-Date: Thu Oct  7 16:09:14 UTC 2010 on sn-devel-104
2010-10-07 16:09:14 +00:00
Günther Deschner
12112d545c s3-rpcclient: add openprinter_ex command.
Guenther
2010-10-07 17:26:00 +02:00
Günther Deschner
b7683a2c9d samr: for correctness, rename samr_RidTypeArray to samr_RidAttrArray.
Guenther

Autobuild-User: Günther Deschner <gd@samba.org>
Autobuild-Date: Thu Oct  7 12:04:32 UTC 2010 on sn-devel-104
2010-10-07 12:04:32 +00:00
Günther Deschner
71ab8f326b s3-samr: fix _samr_QueryGroupMember().
that array contains attributes, not sid types.

Guenther
2010-10-07 13:24:22 +02:00
Ira Cooper
fdad0328e4 s3: Adding TCP_KEEPALIVE_THRESHOLD and TCP_KEEPALIVE_ABORT_THRESHOLD to the list of accepted socket settings.
These are both exclusive to Solaris/OpenSolaris.

Autobuild-User: Jeremy Allison <jra@samba.org>
Autobuild-Date: Thu Oct  7 00:26:39 UTC 2010 on sn-devel-104
2010-10-07 00:26:39 +00:00
Jeremy Allison
0cec0f0912 Fix crash in SMB2 rename found by gentest. We must always have an lcomp
in the destination struct for a rename, so set the flag appropriately.

Jeremy.
2010-10-06 22:59:15 +00:00
Volker Lendecke
342c79e265 s3: Make the write end of the echo responder pipe non-blocking
Without this, we can get a writable pipe end, but the writev call on the pipe
will block.

Autobuild-User: Volker Lendecke <vlendec@samba.org>
Autobuild-Date: Wed Oct  6 13:57:30 UTC 2010 on sn-devel-104
2010-10-06 13:57:30 +00:00
Andrew Tridgell
312d0977a2 s3-build: use the simpler "make bin/smbtorture" for s4 torture
and the same for bin/ndrdump

Autobuild-User: Andrew Tridgell <tridge@samba.org>
Autobuild-Date: Wed Oct  6 12:58:21 UTC 2010 on sn-devel-104
2010-10-06 12:58:21 +00:00
Andrew Tridgell
8a56f8ddb1 s3-spoolss: added another intermittent failure to knownfail
Autobuild-User: Andrew Tridgell <tridge@samba.org>
Autobuild-Date: Wed Oct  6 11:55:00 UTC 2010 on sn-devel-104
2010-10-06 11:55:00 +00:00
Jeremy Allison
77622acadd Fix crash in SMB2 rename found by gentest. We must always have an lcomp
in the destination struct for a rename, so set the flag appropriately.

Jeremy.

Autobuild-User: Jeremy Allison <jra@samba.org>
Autobuild-Date: Wed Oct  6 00:29:51 UTC 2010 on sn-devel-104
2010-10-06 00:29:51 +00:00
Günther Deschner
cef5a36cd1 selftest: make it more obvious we only expect the printjob tests to fail.
Guenther
2010-10-05 22:55:30 +02:00
Günther Deschner
a578ac028f s3-waf: add slightly different mkbuildoptions awk script for waf.
This allows to run make test (w/o smbtorture4 for now) using waf.

Guenther

Autobuild-User: Günther Deschner <gd@samba.org>
Autobuild-Date: Tue Oct  5 18:24:55 UTC 2010 on sn-devel-104
2010-10-05 18:24:55 +00:00
Günther Deschner
e481b66374 s3-waf: use more of the NDR_ subsystems.
Guenther
2010-10-05 19:43:38 +02:00
Jeremy Allison
4618e25c95 Fix bug 7704 - Possible error in fix to rpc_server/srv_spoolss_nt.c.
From pjb1008@cam.ac.uk - Service numbers start from 0.

Autobuild-User: Jeremy Allison <jra@samba.org>
Autobuild-Date: Tue Oct  5 17:32:34 UTC 2010 on sn-devel-104
2010-10-05 17:32:34 +00:00
Günther Deschner
505eaa9493 s3-selftest: enable smb2 torture tests against samba3.
Guenther

Autobuild-User: Günther Deschner <gd@samba.org>
Autobuild-Date: Tue Oct  5 14:38:07 UTC 2010 on sn-devel-104
2010-10-05 14:38:07 +00:00
Günther Deschner
caeb819861 s3-reg_parse: fix uninitialized variable in srprs_key().
Guenther
2010-10-05 13:09:05 +00:00
Günther Deschner
0a1ce77e29 s3-libndr: handle NDR_ERR_IPV6ADDRESS case in ndr_errstr().
Guenther
2010-10-05 13:09:05 +00:00
Günther Deschner
4aa8aaa6d2 s3-waf: convert NSS_INFO into a subsystem.
We don't do the fancy symlinking to idmap modules though.

Guenther

Autobuild-User: Günther Deschner <gd@samba.org>
Autobuild-Date: Tue Oct  5 10:50:53 UTC 2010 on sn-devel-104
2010-10-05 10:50:53 +00:00
Günther Deschner
d10a601ce0 s3-waf: add RPCCLI_WINREG subsystem.
Guenther
2010-10-05 10:10:19 +00:00
Volker Lendecke
ea08cd280c s3: Stop using the write cache after an oplock break
Autobuild-User: Volker Lendecke <vlendec@samba.org>
Autobuild-Date: Tue Oct  5 10:09:38 UTC 2010 on sn-devel-104
2010-10-05 10:09:38 +00:00
Volker Lendecke
515c8f0289 s3: Fix a pointer error
It is not universally guaranteed that an enum is represented as a uint32_t.

This starts to be THE BUG (tm) in Samba. What can I do to explain this
to people a bit better? It seems that the verbose explanations I put into
the recent checkins fixing similar bugs are not clear enough.

Anybody who does is not 100% clear about what this patch fixes please
contact me directly so that we can talk it through on the phone to agree
on a wording that everybody can understand.

Thanks,

Volker
2010-10-04 11:43:47 +02:00
Volker Lendecke
b958f98152 s3: Attempt to get the Tru64 build a bit further 2010-10-04 11:04:25 +02:00
Günther Deschner
279e0c9610 spoolss: fill in spoolss_SetPort IDL.
Guenther
2010-10-04 09:29:47 +02:00
Volker Lendecke
79a4be4f77 s3: Remove smbd_server_conn from msg_force_tdis 2010-10-03 18:17:09 +02:00
Volker Lendecke
e128b23165 s3: Remove smbd_server_conn from process_blocking_lock_cancel_message 2010-10-03 18:17:09 +02:00
Volker Lendecke
c0eb35c0a2 s3: Remove smbd_server_conn from smb1 receive_unlock_msg 2010-10-03 18:17:09 +02:00
Volker Lendecke
db607331d3 s3: Remove smbd_server_conn from msg_file_was_renamed 2010-10-03 18:17:09 +02:00
Volker Lendecke
3cf3d54fbc s3: Remove smbd_server_conn from validate_my_share_entries 2010-10-03 18:17:09 +02:00
Volker Lendecke
924357ab52 s3: Remove smbd_server_conn from msg_close_file 2010-10-03 18:17:09 +02:00
Volker Lendecke
898f7c9603 s3: Remove smbd_server_conn from smb2 receive_unlock_msg 2010-10-03 18:17:08 +02:00
Volker Lendecke
554f5e7c60 s3: Remove smbd_server_conn from process_kernel_oplock_break 2010-10-03 18:17:08 +02:00
Volker Lendecke
5d1d575e87 s3: Remove smbd_server_conn from process_oplock_break_message 2010-10-03 18:17:08 +02:00
Volker Lendecke
35d6d44e5a s3: Remove smbd_server_conn from process_oplock_async_level2_break_message 2010-10-03 18:17:08 +02:00
Volker Lendecke
1d3aa74e4c s3: Lift smbd_server_conn from initial_break_processing 2010-10-03 18:17:08 +02:00
Volker Lendecke
fb2f0c5bdd s3: Add msg_ctx_to_sconn 2010-10-03 18:17:08 +02:00
Volker Lendecke
4a768fbef7 s3: I thought I had compiled this.... 2010-10-03 13:22:03 +02:00
Volker Lendecke
48dccbf2b5 s3: Move #define VALGRIND to config.h
This fixes the valgrind overrun in the tdb jenkins hash
2010-10-03 12:03:36 +02:00
Volker Lendecke
ff48f7c00c s3: Attempt to fix the IRIX build 2010-10-03 10:54:28 +02:00
Volker Lendecke
97b76364e7 s3: Attempt to fix a ton of warnings on the build farm 2010-10-03 10:51:08 +02:00
Volker Lendecke
c87d4e5ddb s3: Remove talloc_autofree_context() from dmapi.c
This is a place where an explicit dmapi_destroy_session would be needed. But we
don't use a destructor for this.
2010-10-03 10:45:57 +02:00
Volker Lendecke
414cd919ff s3: Remove talloc_autofree_context() from unexpected.c
Same argument as in 997a64f6fb: If tdb_close() was needed at exit
time, we'd have more severe problems by now.
2010-10-03 10:45:57 +02:00
Volker Lendecke
da0ef65e04 s3: Remove talloc_autofree_context() from srv_samr_nt.c
The dispinfo structs need to survive within a process across pipe opens,
but they don't have a special destructor
2010-10-03 10:45:57 +02:00
Volker Lendecke
41b54a8931 s3: Remove talloc_autofree_context from pdb_interface
None of the pdb backends have special destructors that need to be run at
program exit.
2010-10-03 10:45:56 +02:00
Volker Lendecke
24f1893b5d s3: Attempt to fix the non-ads build 2010-10-03 00:17:44 +02:00
Volker Lendecke
13756d0e80 s3: Attempt to fix bug 7665
Quite a few of our internal routines put stuff on talloc_tos() these days.
In top-level netapi routines, properly allocate a stackframe and clean it
again. Also, don't leak memory in the rpccli_ callers onto the libnetapi
context.
2010-10-02 12:02:02 +02:00
Günther Deschner
d17a6f0493 s3-spoolss: Strip off ", DrvConvert" and ",LocalOnly" in OpenPrinterEx as seen from Win7 clients.
These suffixes and their meaning are not documented (yet).

Guenther
2010-10-02 00:42:52 +02:00
Andreas Schneider
455bbd5e1e s3-spoolss: Fixed print job access. 2010-10-02 00:04:45 +02:00
Andreas Schneider
b3fd5e11e5 s3-spoolss: Fixed print_access_check server_info. 2010-10-02 00:04:45 +02:00
Steven Danneman
100843ac23 s3:smbd: Increase unsupported IOCTL debug message to 2
Even printing once per connection, level 0 was too spammy with
Windows clients frequently sending FSCTL_GET_OBJECT_ID which
is unsupported.
2010-10-01 13:31:33 -07:00
Steven Danneman
455fccf86b s3:events: Call all ready fd event handlers on each iteration of the main loop
Previously, only one fd handler was being called per main message loop
in all smbd child processes.

In the case where multiple fds are available for reading the fd
corresponding to the event closest to the beginning of the event list
would be run.  Obviously this is arbitrary and could cause unfairness.

Usually, the first event fd is the network socket, meaning heavy load
of client requests can starve out other fd events such as oplock
or notify upcalls from the kernel.

In this patch, I have changed the behavior of run_events() to unset
any fd that it has already called a handler function, as well
as decrement the number of fds that were returned from select().
This allows the caller of run_events() to iterate it, until all
available fds have been handled.

I then changed the main loop in smbd child processes to iterate
run_events().  This way, all available fds are handled on each wake
of select, while still checking for timed or signalled events between
each handler function call.  I also added an explicit check for
EINTR from select(), which previously was masked by the fact that
run_events() would handle any signal event before the return code
was checked.

This required a signature change to run_events() but all other callers
should have no change in their behavior.  I also fixed a bug in
run_events() where it could be called with a selrtn value of -1,
doing unecessary looping through the fd_event list when no fds were
available.

Also, remove the temporary echo handler hack, as all fds should be
treated fairly now.
2010-10-01 13:31:33 -07:00
Günther Deschner
a88a7c76de s3-dcerpc: no point for printing NDR twice for internal pipes in log level 10.
Guenther
2010-10-01 22:30:22 +02:00
Günther Deschner
0ff7e0c998 samba: share readline wrappers among all buildsystems.
Guenther
2010-10-01 22:30:22 +02:00
Günther Deschner
405b7d843f s3-readline: move cmd_history to smbclient, the only user.
Guenther
2010-10-01 22:30:22 +02:00
Günther Deschner
b38d0542e1 samba: share select wrappers.
Guenther
2010-10-01 22:30:22 +02:00
Jelmer Vernooij
21475df35d s3-selftest: fix prefix in subunit output. 2010-10-01 18:49:40 +02:00
Jelmer Vernooij
f70a98605e s3: Add subunit-test target. 2010-10-01 18:49:40 +02:00
Jelmer Vernooij
9af570a2ef s3-configure: Require at least version 1.2.6 of external TDB, which has
TDB_INCOMPATIBLE_HASH.
2010-10-01 18:49:40 +02:00
Günther Deschner
3975203a02 s3-spoolss: fix do_drv_upgrade_printer() which must have been broken since the
days we moved away from fstrings.

Guenther
2010-10-01 08:33:47 +02:00
Günther Deschner
fa3264f89b s3-net: better handle obscure 0x80070002 error reply when trying to update an
not yet published printer.

Guenther
2010-10-01 08:33:46 +02:00
Günther Deschner
21576e3f8c s3-net: make sure we dont crash when publishing a single printer.
Guenther
2010-10-01 08:33:46 +02:00
Günther Deschner
5cb5e0aa98 s3-spoolss: make sure we dont crash on NULL setprinter level2 elements as seen from win7.
Guenther
2010-10-01 08:33:46 +02:00
Günther Deschner
48fca54a29 s3-spoolss: dont overwrite location change notify.
Guenther
2010-10-01 08:33:46 +02:00
Andrew Tridgell
62d87f8f88 s3-selftest: added samba3.posix_s3.rpc.spoolss.printer to knownfail
this fails intermittently on sn-devel. Guenther suggested adding it to
knownfail

Autobuild-User: Andrew Tridgell <tridge@samba.org>
Autobuild-Date: Fri Oct  1 04:37:36 UTC 2010 on sn-devel-104
2010-10-01 04:37:36 +00:00
Volker Lendecke
bad98e37e7 s3: Add "smbcontrol winbindd ip-dropped <local-ip>"
This is supposed to improve the winbind reconnect time after an ip address
has been moved away from a box. Any kind of HA scenario will benefit from
this, because winbindd does not have to wait for the TCP timeout to kick in
when a local IP address has been dropped and DC replies are not received
anymore.
2010-09-30 14:30:33 +02:00
Volker Lendecke
10f0c785c7 s3: Re-introduce a procid_self()
Giving the parent pid to reinit_after_fork is not a good idea....
None of the other callers do this, checked it.
2010-09-30 14:29:56 +02:00
Volker Lendecke
c7c4d84550 s3: Fix a typo in dump-domain-list smbcontrol usage msg 2010-09-30 13:17:45 +02:00
Günther Deschner
c82d6c0b96 s3-spoolss: make sure to exit early and with the appropriate error code in
_spoolss_GetPrinterDriver2.

Guenther
2010-09-30 02:59:36 +02:00
Günther Deschner
3797d48b76 s3-spoolss: Fix servername/printername handling which turns out to be very important to get right.
Guenther
2010-09-30 02:59:35 +02:00
Günther Deschner
9dcd5e6c8f s3-waf: add basic make test infrastructure, not able to test yet.
Guenther
2010-09-29 08:54:00 +02:00
Günther Deschner
bea8035c22 s3-waf: clean up socket-wrapper and nss-wrapper a little.
Guenther
2010-09-29 08:49:39 +02:00
Günther Deschner
292801bdf3 s3-waf: add vlp binary.
Guenther
2010-09-29 08:48:49 +02:00
Günther Deschner
ec33a87d58 s3-printing: skip metadata entry when traversing printerlist.
We were creating a new printer (with a very broken name) out of the
lasttimestamp entry all the time.

Simo, please check.

Guenther
2010-09-29 01:23:54 +02:00
Günther Deschner
46774388dc s3-waf: add in a little hack to deal with the ECHO rpc module for non-developer builds.
This will be removed once we have the rpc modules subsystem in place.

Guenther
2010-09-28 22:55:18 +02:00
Andrew Tridgell
cd3eddbb59 waf: we don't need the preprocessor recursion limit any more
thanks to ita for this
2010-09-28 11:36:40 -07:00
Günther Deschner
9d3046f098 s3-waf: add AUTH_SCRIPT module to AUTH subsystem (which is build as shared
module by default).

Guenther
2010-09-28 20:03:54 +02:00
Günther Deschner
2cf5c661c6 s3-waf: add vfs_linux_xfs_sgid to the list of default shared modules.
Guenther
2010-09-28 20:03:54 +02:00
Volker Lendecke
a3e211ca3f s3: Attempt to fix bug 7518
If select returns -1, we can't rely on the fd sets. The current code might loop
endlessly because when putting an invalid fd (the closed socket?) on the read
set, a select implementation might choose not to touch it but directly return
with EINVAL. Thus run_events will see the socket readable, which leads to a
"return true", and thus a NT_STATUS_RETRY -> same game again.

We should never get into this situation, but to me the logfiles given in bug
7518 do not reveal enough information to understand how this can happen.
2010-09-28 19:22:50 +02:00
Volker Lendecke
51bc104c5c s3: Increase the debuglevel for connection termination msgs 2010-09-28 10:40:17 +02:00
Günther Deschner
2a1891a9d6 s3-waf: fix dependencies in most of our module subsystems.
Guenther
2010-09-28 09:41:54 +02:00
Günther Deschner
5fcd0471e5 s3-waf: add pam_smbpass.
Guenther
2010-09-28 09:41:54 +02:00
Günther Deschner
07697fa053 s3-auth_util: make sure the system server info actually contains S-1-5-18.
Without this, all security descriptor checks for the winreg spoolss backend fail
and make our spoolss system in its current shape basically unusable.

Andreas, please check.

Guenther
2010-09-28 09:40:57 +02:00
Günther Deschner
314d738f90 s3-printing: remove unused old structs.
Guenther
2010-09-28 09:40:57 +02:00
Volker Lendecke
94dc2c106b s3: Lift smbd_messaging_context() from open_sockets_smbd() 2010-09-28 07:36:18 +02:00
Volker Lendecke
790ad3d1a4 s3: Remove two calls to procid_self() 2010-09-28 07:36:18 +02:00
Volker Lendecke
886b5b67ee s3: Remove talloc_autofree_context() from myhostname()
No destructor needed, so we can as well use the NULL context
2010-09-28 07:36:18 +02:00
Volker Lendecke
49b4d2e652 s3: Remove some remaining files.c globals to sconn 2010-09-28 07:36:18 +02:00
Volker Lendecke
d26d79b640 s3: Remove talloc_autofree_context() from files.c 2010-09-28 07:36:18 +02:00
Volker Lendecke
eadc4b5b78 s3: Lift smbd_server_conn from file_find_fd 2010-09-28 07:36:18 +02:00
Volker Lendecke
54f7b70212 s3: Remove smbd_server_conn from file_fsp 2010-09-28 07:36:18 +02:00
Volker Lendecke
3009178ee5 s3: Slightly simplify file_fnum
req==NULL should never happen, see the comment
2010-09-28 07:36:18 +02:00