1
0
mirror of https://github.com/samba-team/samba.git synced 2025-03-12 20:58:37 +03:00

2230 Commits

Author SHA1 Message Date
Jelmer Vernooij
f6deb3d065 r3047: Always include a \ again before the pipe name we're opening. Without a
backslash works, but is not like Windows does it.
2007-10-10 13:01:53 -05:00
Jelmer Vernooij
7771b5d8fa r3046: \\PIPE\\ is internal (not actually included on the wire) 2007-10-10 13:01:53 -05:00
Jelmer Vernooij
38e9290bcf r3045: Allow object-uuid@... binding strings 2007-10-10 13:01:53 -05:00
Stefan Metzmacher
c79bbe54b4 r3044: resolve the error code for WERR_DS_OBJ_NOT_FOUND to the name
metze
2007-10-10 13:01:53 -05:00
Jelmer Vernooij
f3da7c8b44 r3043: Use binding strings for specifying endpoints. The property for
specifying a endpoint is now also 'endpoint' instead of 'endpoints'. The
default endpoint (if none is specified) is still "ncacn_np:[\\pipe\\ifacename]",
where ifacename is the name of the interface.

Examples:

[
  uuid(60a15ec5-4de8-11d7-a637-005056a20182),
  endpoint("ncacn_np:[\\pipe\\rpcecho]", "ncacn_ip_tcp:")
]
interface rpcecho
{
	void dummy();
}

dcerpc_binding is now converted to ep_description in the server, but I hope to
completely eliminate ep_description later on.

The eventual goal of all these changes is to make it easier to add
 transports as I'm going to add support for
 ncalrpc (local RPC over named pipes) and ncacn_unix_stream (Unix sockets).
2007-10-10 13:01:53 -05:00
Stefan Metzmacher
6656518772 r3041: a start of a README/HOWTO for the samba4 build system.
(still incomplete, but should be a good start...)

can someone look for spelling and grammar mistakes...

metze
2007-10-10 13:00:01 -05:00
Jim McDonough
b1bbf0a431 r3040: Add sleeps between operations to nbench. Submitted by aliguori@us.ibm.com. 2007-10-10 13:00:01 -05:00
Andrew Tridgell
a256e71029 r3039: This solves the problem of async handlers in ntvfs backends not being
in the right state when called. For example, when we use the unixuid
handler in the chain of handlers, and a backend decides to continue a
call asynchronously then we need to ensure that the continuation
happens with the right security context.

The solution is to add a new ntvfs operation ntvfs_async_setup(),
which calls all the way down through the layers, setting up anything
that is required, and takes a private pointer. The backend wanting to
make a async calls can use ntvfs_async_setup() to ensure that the
modules above it are called when doing async processing.
2007-10-10 13:00:01 -05:00
Tim Potter
e080a2483d r3036: Add function to pull an array of structures. Abstracts away the
individual routines in ndr_spoolss_buf.c.
2007-10-10 13:00:01 -05:00
Andrew Tridgell
2894dd0ac0 r3035: if the ntvfs layers prior to us have said that we can't perform an
operation asynchronously (such as the nbench module), then ignore lock
timeouts, as they would make no sense
2007-10-10 13:00:00 -05:00
Andrew Tridgell
5ef80f034d r3034: - fixed a bug in message dispatch, when the dispatch function called messaging_deregister()
- added a pvfs_lock_close_pending() hook to remove pending locks on file close

 - fixed the private ptr argument to messaging_deregister() in pvfs_wait

 - fixed a bug in continuing lock requests after a lock that is blocking a pending lock is removed

 - removed bogus brl_unlock() call in lock continue

 - corrected error code for LOCKING_ANDX_CHANGE_LOCKTYPE

 - expanded the lock cancel test suite to test lock cancel by unlock and by close

 - added a testsuite for LOCKING_ANDX_CHANGE_LOCKTYPE
2007-10-10 13:00:00 -05:00
Jelmer Vernooij
1977932b54 r3033: Use the C struct directly if we can instead of generating a binding
string and parsing that.
2007-10-10 13:00:00 -05:00
Jelmer Vernooij
c15862e778 r3032: Somewhat stricter syntax for binding strings:
[] is now mandatory
 : after the hostname is no longer allowed

examples of allowed binding strings:

ncacn_np:myhost[samr]
ncacn_ip_tcp:10.0.0.1[1045]
ncacn_ip_tcp:2001:7b8:37b:1:210:dcff:fecb:a9e3[1024,sign,seal]
ncacn_np:myhost
ncacn_ip_tcp:192.168.4.2
308FB580-1EB2-11CA-923B-08002B1075A7@ncacn_ip_tcp:192.168.4.2
308FB580-1EB2-11CA-923B-08002B1075A7@ncacn_ip_tcp:192.168.4.2[,print]

Note that the last two lines are not recognized by smbtorture as a binding
 string yet. dcerpc_parse_binding() does accept them though.
2007-10-10 13:00:00 -05:00
Andrew Tridgell
d5bfc910b1 r3031: added support for lock cancelation, which effectively just triggers an early lock timeout
added support for more of the bizarre special lock offset semantics of w2k3
2007-10-10 13:00:00 -05:00
Andrew Tridgell
f732a983d4 r3030: added testing of lock cancel, and some more special offsets (locks
with the top bit set are special)
2007-10-10 13:00:00 -05:00
Andrew Tridgell
4395c0557a r3029: implemented byte range lock timeouts.
This adds a pvfs_wait_message() routine which uses the new messaging
system, event timers and talloc destructors to give a nice generic
async event handling system with a easy to use interface. The
extensions to pvfs_lock.c are based on calls to pvfs_wait_message()
routines.

We now pass all of our smbtorture locking tests, although while
writing this code I have thought of some additonal tests that should
be added, particularly for lock cancel operations. I'll work on that
soon.

This commit also extends the smbtorture lock tests to test the rather
weird 0xEEFFFFFF locking semantics that I have discovered in
win2003. Win2003 treats the 0xEEFFFFFF boundary as special, and will
give different error codes on either side of it. Locks on both sides
are allowed, the only difference is which error code is given when a
lock is denied. Anyone like to hazard a guess as to why? It has
me stumped.
2007-10-10 13:00:00 -05:00
Andrew Tridgell
2d0dfe607d r3028: use talloc_free() instead of talloc_unlink(), as the
event_context_merge() code leaves the events as grandchildren of the
events context, not children, so talloc_unlink() will not work after
the merge
2007-10-10 12:59:59 -05:00
Andrew Tridgell
6a3f356b76 r3027: got rid of some configure checks we don't need any more 2007-10-10 12:59:59 -05:00
Andrew Tridgell
8cddc610a2 r3026: - added automatic retry to messages when the servers listen queue is
full. This means callers can just "send and forget" rather than
  having to check for a temporary failure. The mechanism takes nice
  advantage of the timed events handling is our events code. A message
  will only fail now if we completely run out of some resource (such
  as memory).

- changed the test code not to do retries itself, but only to warn on real failures
2007-10-10 12:59:59 -05:00
Andrew Tridgell
a8c49a0de3 r3025: don't warn about no path in a service, as some backends (like cifs) don't need a path 2007-10-10 12:59:59 -05:00
Andrew Tridgell
54fd395025 r3024: run the *_connect() NTVFS initialisation operation as root, to allow
backends to open databases and perform any other privileged
operations that might be needed.
2007-10-10 12:59:59 -05:00
Andrew Tridgell
8380225d32 r3023: added immediate send of messages when they are first queued. This makes things a bit more efficient 2007-10-10 12:59:59 -05:00
Tim Potter
9045645ddf r3022: Work on unmarshalling arrays of structs in a buffer (Python string) for
spoolss.  Doesn't quite work yet.
2007-10-10 12:59:59 -05:00
Andrew Tridgell
2c568d4dc2 r3021: under heavy load the listen queue for messaging unix domain socket can fill up, leading to refused
connections. The caller needs to retry. This adds testing of the retry in LOCAL-MESSAGING
2007-10-10 12:59:58 -05:00
Andrew Tridgell
64514ff5b7 r3020: better error handling in socket_unix 2007-10-10 12:59:58 -05:00
Andrew Tridgell
68890247c1 r3019: make the LOCAL-MESSAGING test a 2 process test 2007-10-10 12:59:58 -05:00
Andrew Tridgell
13739b68d8 r3018: handle STATUS_MORE_ENTRIES from socket_recv() in the messaging code 2007-10-10 12:59:58 -05:00
Andrew Tridgell
1cef44505e r3017: nicer memory handling for event_context_merge() 2007-10-10 12:59:58 -05:00
Andrew Tridgell
3af06478da r3016: - converted the events code to talloc
- added the new messaging system, based on unix domain sockets. It
  gets over 10k messages/second on my laptop without any socket
  cacheing, which is better than I expected.

- added a LOCAL-MESSAGING torture test
2007-10-10 12:59:57 -05:00
Andrew Tridgell
b367209a9f r3015: fixed typo noticed by abartlett 2007-10-10 12:59:57 -05:00
Andrew Tridgell
283e38aeb2 r3014: got rid of the old intra-smbd messaging system in preparation for the new one 2007-10-10 12:59:57 -05:00
Andrew Tridgell
6f4926d846 r3013: added support for unix domain sockets in the generic socket library. I
will shortly be using this for a rewrite of the intra-smbd messaging
library, which is needed to get lock timeouts working properly (and
share modes, oplocks etc)
2007-10-10 12:59:57 -05:00
Andrew Tridgell
58a92abd88 r3012: added initial support for byte range locking in the posix vfs. This is
enough for us to pass locktest, but does not yet support lock timeouts
and some of the other esoteric features.
2007-10-10 12:59:57 -05:00
Andrew Tridgell
f4a91be635 r3011: separated the locktest code into a separate module in smbtorture 2007-10-10 12:59:57 -05:00
Tim Potter
b19dc6cd9c r3010: Do some more PyInt vs PyLong checks. 2007-10-10 12:59:57 -05:00
Tim Potter
89da7a9196 r3009: Fix up unmarshall functions to return Python dict instead of a NTSTATUS.
We can now unmarshall a single printer returned from an EnumPrinters.
2007-10-10 12:59:56 -05:00
Tim Potter
7c5ada63bf r3007: uint32 values need to be stored in Python longs, as on 32-bit machines
Python ints can only hold int32 values.
2007-10-10 12:59:56 -05:00
Jelmer Vernooij
5c46747c36 r3006: Poptify 2007-10-10 12:59:56 -05:00
Andrew Tridgell
04e1171996 r3005: added talloc wrappers around tdb_open() and ldb_connect(), so that the
caller doesn't have to worry about the constraint of only opening a
database a single time in a process. These wrappers will ensure that
only a single open is done, and will auto-close when the last instance
is gone.

When you are finished with a database pointer, use talloc_free() to
close it.

note that this code does not take account of the threads process
model, and does not yet take account of symlinks or hard links to tdb
files.
2007-10-10 12:59:56 -05:00
Andrew Tridgell
247421ee64 r3004: removed some unused functions 2007-10-10 12:59:56 -05:00
Tim Potter
4bc497a299 r3001: Expose unmarshalling functions for structures marked "public" in the
idl.  This allows us to pass a buffer of bytes returned from a spoolss
call and convert it to a Python dictionary.  Works for enumprinters level
1!
2007-10-10 12:59:56 -05:00
Jeremy Allison
93efa87040 r2997: Added delete on close tests for readonly files.
Jeremy.
2007-10-10 12:59:56 -05:00
Tim Potter
558076cc8d r2994: More cleanups. Move the generation of NTSTATUS and WERROR exceptions
from inside a swig %exception block and into the argout typemap.  This
will allow us to wrap functions that don't require exception handling, and
also get rid of some ugly code in dcerpc.i
2007-10-10 12:59:55 -05:00
Stefan Metzmacher
23a2c5c158 r2993: fix comment
metze
2007-10-10 12:59:55 -05:00
Stefan Metzmacher
757f67c08b r2992: drsuapi uses WERROR not NTSTATUS
metze
2007-10-10 12:59:55 -05:00
Stefan Metzmacher
98ca7640c5 r2991: add drsuapi_DsGetDomainControllerInfo() idl and torture test
metze
2007-10-10 12:59:55 -05:00
Jelmer Vernooij
7c823f886a r2990: Add support to pidl for autogenerating ndr_size_*() functions. Adding
the [gensize] property to a struct or union will make pidl generate a
ndr_size_*() function.

(not all nasty bits of NDR are completely covered yet by the
 ndr_size*() functions, support for those will be added when necessary)

I also have a local patch (not applied now) that simplifies the pidl output
and eliminates the number of functions required. It would, however, make
pidl more complex.
2007-10-10 12:59:55 -05:00
Andrew Tridgell
d8152f8961 r2989: fix the printing of unions with negative cases when :print is used 2007-10-10 12:59:55 -05:00
Andrew Tridgell
21ed51d47f r2988: this should fix support for negative switch levels in PIDL 2007-10-10 12:59:55 -05:00
Andrew Tridgell
24122eb93e r2987: added support for signed 32 bit integers in pidl 2007-10-10 12:59:54 -05:00