ira/wip.git
13 years agodo not redefine _INT32
Matt Kraai [Wed, 1 Jul 2009 17:49:35 +0000 (10:49 -0700)]
do not redefine _INT32

13 years agos3:configure: define _LARGEFILE64_SOURCE on QNX
Matt Kraai [Wed, 1 Jul 2009 19:44:03 +0000 (12:44 -0700)]
s3:configure: define _LARGEFILE64_SOURCE on QNX

13 years agos3:pam_smbpass: fix build error on some Linux distros
Björn Jacke [Wed, 10 Jun 2009 10:31:07 +0000 (12:31 +0200)]
s3:pam_smbpass: fix build error on some Linux distros

This addresses bug #6459.

13 years agos4 docs: Git has revision SHA's, not numbers.
Jelmer Vernooij [Wed, 1 Jul 2009 12:49:18 +0000 (14:49 +0200)]
s4 docs: Git has revision SHA's, not numbers.

13 years agos4: Remove stub endpoint mapper script.
Jelmer Vernooij [Wed, 1 Jul 2009 14:54:02 +0000 (16:54 +0200)]
s4: Remove stub endpoint mapper script.

13 years agoTOSHARG: Fix typo: s/aquire/acquire/
Jelmer Vernooij [Fri, 19 Jun 2009 14:48:19 +0000 (16:48 +0200)]
TOSHARG: Fix typo: s/aquire/acquire/

13 years agopidl: Don't run compile tests inside the tree, won't work yet.
Jelmer Vernooij [Fri, 19 Jun 2009 14:17:08 +0000 (16:17 +0200)]
pidl: Don't run compile tests inside the tree, won't work yet.

13 years agos3:smbd: add marshalling layer for SMB2 Lock support
Stefan Metzmacher [Thu, 2 Jul 2009 17:26:05 +0000 (19:26 +0200)]
s3:smbd: add marshalling layer for SMB2 Lock support

metze

13 years agos4:libcli: move SMB2 lock flags to smb2_constants.h
Stefan Metzmacher [Thu, 2 Jul 2009 15:47:33 +0000 (17:47 +0200)]
s4:libcli: move SMB2 lock flags to smb2_constants.h

metze

13 years agos3:smbd: add marshalling layer for SMB2 Find (QueryDirectory) support
Stefan Metzmacher [Thu, 2 Jul 2009 10:28:58 +0000 (12:28 +0200)]
s3:smbd: add marshalling layer for SMB2 Find (QueryDirectory) support

metze

13 years agos3:smbd: add marshalling layer for SMB2 Break support (SMB 2.002 only)
Stefan Metzmacher [Thu, 2 Jul 2009 09:56:23 +0000 (11:56 +0200)]
s3:smbd: add marshalling layer for SMB2 Break support (SMB 2.002 only)

metze

13 years agos3:smbd: add marshalling layer for SMB2 SetInfo support
Stefan Metzmacher [Thu, 2 Jul 2009 09:40:07 +0000 (11:40 +0200)]
s3:smbd: add marshalling layer for SMB2 SetInfo support

metze

13 years agos3:smbd: add marshalling layer for SMB2 GetInfo support
Stefan Metzmacher [Thu, 2 Jul 2009 08:17:30 +0000 (10:17 +0200)]
s3:smbd: add marshalling layer for SMB2 GetInfo support

metze

13 years agospoolss: the flags in spoolss_PrinterInfo1 are in fact spoolss_PrinterAttributes.
Günther Deschner [Thu, 2 Jul 2009 17:39:36 +0000 (19:39 +0200)]
spoolss: the flags in spoolss_PrinterInfo1 are in fact spoolss_PrinterAttributes.

Guenther

13 years agos4-smbtorture: fix getjob test in RPC-SPOOLSS.
Günther Deschner [Wed, 1 Jul 2009 20:52:49 +0000 (22:52 +0200)]
s4-smbtorture: fix getjob test in RPC-SPOOLSS.

Guenther

13 years agodoserrors: print out some more werrors.
Günther Deschner [Wed, 1 Jul 2009 20:52:05 +0000 (22:52 +0200)]
doserrors: print out some more werrors.

Guenther

13 years agotalloc: change TALLOC_MAGIC for version 2.0.0
Stefan Metzmacher [Thu, 2 Jul 2009 08:48:24 +0000 (10:48 +0200)]
talloc: change TALLOC_MAGIC for version 2.0.0

metze

13 years agoshow attribute values in sorted order to make comparison easier
Andrew Tridgell [Thu, 2 Jul 2009 06:19:37 +0000 (16:19 +1000)]
show attribute values in sorted order to make comparison easier

13 years agos3:smbd: add support for SMB2 Notify
Stefan Metzmacher [Mon, 29 Jun 2009 20:31:13 +0000 (22:31 +0200)]
s3:smbd: add support for SMB2 Notify

metze

13 years agos3:smbd: make change_notify_reply() more generic and hide send_nt_replies() behind...
Stefan Metzmacher [Tue, 30 Jun 2009 13:01:00 +0000 (15:01 +0200)]
s3:smbd: make change_notify_reply() more generic and hide send_nt_replies() behind a callback

This prepares change notify support for SMB2.

metze

13 years agos3:smbd: simplify the notify code a bit and always reply via change_notify_reply...
Stefan Metzmacher [Mon, 29 Jun 2009 20:17:17 +0000 (22:17 +0200)]
s3:smbd: simplify the notify code a bit and always reply via change_notify_reply() -> send_nt_replies()

metze

13 years agos3:smbd: push nttrans and trans2 responses with no data to the client
Stefan Metzmacher [Mon, 29 Jun 2009 13:38:48 +0000 (15:38 +0200)]
s3:smbd: push nttrans and trans2 responses with no data to the client

For sync replies it's not a problem, as construct_reply() will send
the response, but for async replies we would not send the reply to the client.
Currently the notify code works arround this manually, so I assume
we didn't have a bug here. But the next commits will simplify
the notify code.

metze

13 years agos3:smbd: restore the 3.0.x bahavior of send_nt_replies()
Stefan Metzmacher [Wed, 1 Jul 2009 10:56:30 +0000 (12:56 +0200)]
s3:smbd: restore the 3.0.x bahavior of send_nt_replies()

We should also set the error code, when we return no parameters or data.

metze

13 years agos3:smbd: move global notify_changes_by_mid to smbd_server_connection
Stefan Metzmacher [Tue, 30 Jun 2009 08:17:38 +0000 (10:17 +0200)]
s3:smbd: move global notify_changes_by_mid to smbd_server_connection

metze

13 years agos3:smbd: allow the offset to the path being 0 in SMB2 create
Stefan Metzmacher [Tue, 30 Jun 2009 11:25:21 +0000 (13:25 +0200)]
s3:smbd: allow the offset to the path being 0 in SMB2 create

metze

13 years agowe can't use the unique index code for samAccountName
Andrew Tridgell [Thu, 2 Jul 2009 05:57:30 +0000 (15:57 +1000)]
we can't use the unique index code for samAccountName

Using ldb unique indexes for samAccountName doesn't work with DRS as
the other DC may send us a deleted record (tombstone record), which
has the same samAccountName as an existing record. That would then
create two records in the same partition with the same samAccountName.

So we needed to put back the logic in samldb.c which explicitly
checked whether a samAccountName already exists on add

13 years agodecrypt all objects in a DRS record, not just the first one
Andrew Tridgell [Thu, 2 Jul 2009 05:33:01 +0000 (15:33 +1000)]
decrypt all objects in a DRS record, not just the first one

We found this as an object came across from w2k3 with zero values,
which caused a segv when we tried to decrypt the first value

13 years agochange talloc to 2.0.0
Andrew Tridgell [Thu, 2 Jul 2009 05:19:40 +0000 (15:19 +1000)]
change talloc to 2.0.0

This is needed to prevent samba3 and samba4 from using an ABI
incompatible system version of talloc

See ongoing discussion on the samba-technical mailing list

13 years agoChanged ldb.ERR_NO_SUCH_OBJECT to LDB_ERR_NO_SUCH_OBJECT.
Andrew Tridgell [Thu, 2 Jul 2009 04:52:25 +0000 (14:52 +1000)]
Changed ldb.ERR_NO_SUCH_OBJECT to LDB_ERR_NO_SUCH_OBJECT.

The LDB_ERR_NO_SUCH_OBJECT varient is not a defined variable. This
should improve error handling in our python code on some
systems. Unfortunately it still doesn't work on mine. I need to trap
Jelmer somewhere where he can't escape some day and force him to
divulge the deep druid secrets of python exception handling ....

13 years agofixed the pull of drs schema elements
Andrew Tridgell [Thu, 2 Jul 2009 04:49:40 +0000 (14:49 +1000)]
fixed the pull of drs schema elements

The previous code incorrectly assumed that attributes such as
subClassOf come over the wire as strings. In fact they come over as 32
bit integers which refer to goversIDs. We have to post-process these
as it sometimes happens that a governsID comes over the wire before
the record that defines what it means.

13 years agothe settings structure needs to be initialised
Andrew Tridgell [Thu, 2 Jul 2009 04:47:06 +0000 (14:47 +1000)]
the settings structure needs to be initialised

13 years agoLDB_ERR_INVALID_DN_SYNTAX doesn't exist ...
Andrew Tridgell [Thu, 2 Jul 2009 04:44:48 +0000 (14:44 +1000)]
LDB_ERR_INVALID_DN_SYNTAX doesn't exist ...

The correct name is ldb.ERR_INVALID_DN_SYNTAX

13 years agos4:param use talloc_unlink() to free iconv context holding references
Andrew Bartlett [Thu, 2 Jul 2009 04:34:07 +0000 (14:34 +1000)]
s4:param use talloc_unlink() to free iconv context holding references

13 years ago[SAMBA 4 directory] Changes "forceLogoff" and corrects the "subRefs"
Matthias Dieter Wallnöfer [Tue, 30 Jun 2009 11:44:45 +0000 (13:44 +0200)]
[SAMBA 4 directory] Changes "forceLogoff" and corrects the "subRefs"

- This changes the attribute "forceLogoff" to its' default
  values according to Windows Server 2003 R2
- Also this corrects the "subRefs" attribute of the base-DN which only refers
  to direct child partitions (and therefore not to the complete transitive closure)

13 years agoEnsure we don't use delayed writes on POSIX opened files.
Jeremy Allison [Thu, 2 Jul 2009 00:39:10 +0000 (17:39 -0700)]
Ensure we don't use delayed writes on POSIX opened files.
Don't remove pending writetime changes if no time changes
are sent in UNIX_BASIC infolevel.
Jeremy

13 years agoFix bug #6520 time stamps - e.g. last mod time is not preserved when "unix extensions...
Jeremy Allison [Wed, 1 Jul 2009 23:58:14 +0000 (16:58 -0700)]
Fix bug #6520 time stamps - e.g. last mod time is not preserved when "unix extensions=yes" are set - and using latest cifs vfs client
Cancel out any pending "sticky" writes or "last write" changes when
doing a UNIX info level set.
Jeremy.

13 years agos3:util: let parent_dirname() correctly return toplevel filenames
Stefan Metzmacher [Tue, 30 Jun 2009 14:03:11 +0000 (16:03 +0200)]
s3:util: let parent_dirname() correctly return toplevel filenames

metze

13 years agos3:onefs_open: remove unused variable passed to parent_dirname()
Stefan Metzmacher [Wed, 1 Jul 2009 10:50:00 +0000 (12:50 +0200)]
s3:onefs_open: remove unused variable passed to parent_dirname()

metze

13 years agos3:smbd: remove unused variables passed to parent_dirname()
Stefan Metzmacher [Wed, 1 Jul 2009 10:49:06 +0000 (12:49 +0200)]
s3:smbd: remove unused variables passed to parent_dirname()

metze

13 years agos3:build: remove the libgpo objects upon "make clean"
Michael Adam [Wed, 1 Jul 2009 09:29:00 +0000 (11:29 +0200)]
s3:build: remove the libgpo objects upon "make clean"

Michael

13 years agos3:build: remove ../libcli/nbt/tools/nmblookup.o and friends in make clean
Michael Adam [Wed, 1 Jul 2009 09:19:58 +0000 (11:19 +0200)]
s3:build: remove ../libcli/nbt/tools/nmblookup.o and friends in make clean

Michael

13 years agolib/util: fix order of includes in tevent_ntstatus.c
Michael Adam [Wed, 1 Jul 2009 08:51:17 +0000 (10:51 +0200)]
lib/util: fix order of includes in tevent_ntstatus.c

replace.h needs to be included first.

Michael

13 years agofixed the talloc testsuite for the recent changes
Andrew Tridgell [Wed, 1 Jul 2009 06:36:29 +0000 (16:36 +1000)]
fixed the talloc testsuite for the recent changes

13 years agoa talloc_realloc() to zero size needs to use an unambiguous free
Andrew Tridgell [Wed, 1 Jul 2009 06:36:10 +0000 (16:36 +1000)]
a talloc_realloc() to zero size needs to use an unambiguous free

13 years agos3/docs: Fix typo.
Matt Kraai [Wed, 1 Jul 2009 06:18:11 +0000 (08:18 +0200)]
s3/docs: Fix typo.

This fixes bug #6519.

13 years agoremoved a generated file
Andrew Tridgell [Wed, 1 Jul 2009 05:15:13 +0000 (15:15 +1000)]
removed a generated file

13 years agouse a talloc_reparent in a very ugly way
Andrew Tridgell [Wed, 1 Jul 2009 05:13:49 +0000 (15:13 +1000)]
use a talloc_reparent in a very ugly way

this works around some terrible use of talloc in the libnet code

13 years agouse the new talloc_reparent in two places
Andrew Tridgell [Wed, 1 Jul 2009 04:53:32 +0000 (14:53 +1000)]
use the new talloc_reparent in two places

13 years agochanges to remove the ambiguity in talloc_free() and talloc_steal()
Andrew Tridgell [Wed, 1 Jul 2009 04:53:01 +0000 (14:53 +1000)]
changes to remove the ambiguity in talloc_free() and talloc_steal()

These changes follow from the discussions on samba-technical. The
changes are in several parts, and stem from the inherent ambiguity
that was in talloc_free() and talloc_steal() when the pointer that is
being changes has more than one parent, via references.

The changes are:

 1) when you call talloc_free() on a pointer with more than one parent
 the free will fail, and talloc will log an error to stderr like this:

    ERROR: talloc_free with references at some/foo.c:123
   reference at other/bar.c:201
   reference at other/foobar.c:641

 2) Similarly, when you call talloc_steal() on a pointer with more
 than one parent, the steal will fail and talloc will log an error to
 stderr like this:

    ERROR: talloc_steal with references at some/foo.c:123
   reference at other/bar.c:201

 3) A new function talloc_reparent() has been added to change a parent
 in a controlled fashion. You need to supply both the old parent and
 the new parent. It handles the case whether either the old parent was
 a normal parent or a reference

The use of stderr in the logging is ugly (and potentially dangerous),
and will be removed in a future patch. We'll need to add a debug
registration function to talloc.

13 years agogensec_start now steals the auth_context
Andrew Tridgell [Wed, 1 Jul 2009 04:08:43 +0000 (14:08 +1000)]
gensec_start now steals the auth_context

13 years agoA rather strange varient of talloc_unlink
Andrew Tridgell [Wed, 1 Jul 2009 04:08:13 +0000 (14:08 +1000)]
A rather strange varient of talloc_unlink

A dcerpc request may have a reference from a still completing async
callback, but we now consider the request to be complete. We want to
lose the main parent, leaving just the reference, if any.

13 years agoanother case that should use py_talloc_reference
Andrew Tridgell [Wed, 1 Jul 2009 04:06:56 +0000 (14:06 +1000)]
another case that should use py_talloc_reference

13 years agouse py_talloc_reference instead of py_talloc_import
Andrew Tridgell [Wed, 1 Jul 2009 04:06:38 +0000 (14:06 +1000)]
use py_talloc_reference instead of py_talloc_import

This is one of the few cases where we want the object to be owned by
both the python object and C code

13 years agopy_talloc_import now uses a steal, so this free is incorrect
Andrew Tridgell [Wed, 1 Jul 2009 04:05:53 +0000 (14:05 +1000)]
py_talloc_import now uses a steal, so this free is incorrect

13 years agofixed use of reference in pytalloc
Andrew Tridgell [Wed, 1 Jul 2009 04:05:17 +0000 (14:05 +1000)]
fixed use of reference in pytalloc

The previous code caused memory leaks, and also caused situations
where talloc_free could be called on pointers with multiple parents

The new approach is to have two functions:

  py_talloc_import : steals the pointer, so it becomes wholly owned by
                     the python object
  py_talloc_reference: uses a reference, so it is owned by both python
                     and C

13 years agouse a talloc_unlink() as ops may have a reference
Andrew Tridgell [Wed, 1 Jul 2009 04:02:37 +0000 (14:02 +1000)]
use a talloc_unlink() as ops may have a reference

13 years agofixed the reference to the global_schema
Andrew Tridgell [Wed, 1 Jul 2009 04:02:12 +0000 (14:02 +1000)]
fixed the reference to the global_schema

13 years agoremoved a redundent talloc_steal
Andrew Tridgell [Wed, 1 Jul 2009 04:01:44 +0000 (14:01 +1000)]
removed a redundent talloc_steal

13 years agofixed the use of talloc_steal in ntlmssp_server
Andrew Tridgell [Wed, 1 Jul 2009 04:01:24 +0000 (14:01 +1000)]
fixed the use of talloc_steal in ntlmssp_server

The previous use of talloc_steal could cause a steal of a pointer that
had references. This ensures that doesn't happen

13 years agofixed rpc smb code to not reply on talloc_free being a function pointer
Andrew Tridgell [Wed, 1 Jul 2009 03:59:52 +0000 (13:59 +1000)]
fixed rpc smb code to not reply on talloc_free being a function pointer

The upcoming talloc_free/talloc_reference changes change talloc_free
to be a macro. These two bits of code relied on it being a function
pointer

13 years ago[SAMBA 4 directory] Corrects the "systemFlags" attributes
Matthias Dieter Wallnöfer [Tue, 30 Jun 2009 11:54:45 +0000 (13:54 +0200)]
[SAMBA 4 directory] Corrects the "systemFlags" attributes

Set the values like Windows Server 2003 R2.

13 years ago[SAMBA 4 directory] Adds the complete "objectclass path" to our self-created DC object
Matthias Dieter Wallnöfer [Tue, 30 Jun 2009 11:52:39 +0000 (13:52 +0200)]
[SAMBA 4 directory] Adds the complete "objectclass path" to our self-created DC object

Found after some comparisons against Windows Server 2003 R2.

13 years ago[SAMBA 4 directory] Adds the object version and "systemFlags" attribute to the displa...
Matthias Dieter Wallnöfer [Tue, 30 Jun 2009 11:34:09 +0000 (13:34 +0200)]
[SAMBA 4 directory] Adds the object version and "systemFlags" attribute to the display specifiers

The object version showed up in the Windows 2003 Server R2 AD.
The "systemFlags" attribute has been set to the right value.

13 years agos3 docs: Add documentation for 'kerberos method' and 'dedicated keytab file' parameters
Tim Prouty [Tue, 30 Jun 2009 23:59:57 +0000 (16:59 -0700)]
s3 docs: Add documentation for 'kerberos method' and 'dedicated keytab file' parameters

13 years agoFix bug #6496 - MS-DFS: cannot follow multibyte char link name.
SATOH Fumiyasu [Tue, 30 Jun 2009 22:29:08 +0000 (15:29 -0700)]
Fix bug #6496 - MS-DFS: cannot follow multibyte char link name.
consumed_ucs is the number of bytes
of the UCS2 path consumed not counting any
terminating null. We need to convert
back to unix charset and count again
to get the number of bytes consumed from
the incoming path.

13 years agos3-netlogon: remove unneeded fstrings from netlogon server.
Günther Deschner [Tue, 30 Jun 2009 15:18:47 +0000 (17:18 +0200)]
s3-netlogon: remove unneeded fstrings from netlogon server.

Guenther

13 years agoumount.cifs: don't build it by default
Jeff Layton [Tue, 30 Jun 2009 19:03:13 +0000 (15:03 -0400)]
umount.cifs: don't build it by default

Now that the sanity checks for mount.cifs default to matching the
behavior of /bin/mount, then there is virtually no need for umount.cifs.
The only exception is when someone enables the loose setuid behavior in
mount.cifs.

If an unprivileged user mounts a share that isn't in /etc/fstab, then
/bin/mount won't allow that user to unmount it. In that situation,
umount.cifs will be necessary to allow unmounting the share.

Signed-off-by: Jeff Layton <jlayton@samba.org>
Acked-by: Steve French <smfrench@us.ibm.com>
13 years agoFix bug #6431 - local groups from 3.0 setups no longer found.
Volker Lendecke [Tue, 30 Jun 2009 18:42:15 +0000 (11:42 -0700)]
Fix bug #6431 - local groups from 3.0 setups no longer found.
Search for groups without group suffix, group suffix is only used for new entries.

13 years agos3-spoolss: Bug #6512. Fix support for enumerating user forms.
Günther Deschner [Tue, 30 Jun 2009 11:12:01 +0000 (13:12 +0200)]
s3-spoolss: Bug #6512. Fix support for enumerating user forms.

Found while testing Xerox WorkCentre 133 PCL driver, now also tested with
torture test.

Guenther

13 years agos4-smbtorture: Test for newly added form with enum call in RPC-SPOOLSS.
Günther Deschner [Tue, 30 Jun 2009 11:11:16 +0000 (13:11 +0200)]
s4-smbtorture: Test for newly added form with enum call in RPC-SPOOLSS.

Guenther

13 years agos4-smbtorture: remove trailing whitespace from RPC-SPOOLSS.
Günther Deschner [Tue, 30 Jun 2009 09:38:41 +0000 (11:38 +0200)]
s4-smbtorture: remove trailing whitespace from RPC-SPOOLSS.

Guenther

13 years agoRework the kerberos-notes.txt in order and format
Don Davis [Tue, 30 Jun 2009 08:12:02 +0000 (18:12 +1000)]
Rework the kerberos-notes.txt in order and format

This reworks the notes file to be less stream-of-consciousness and more
task for porting, with a very particular focus on a potential port of
Samba4 to use MIT Kerberos.

Signed-off-by: Andrew Bartlett <abartlet@samba.org>
13 years agos4:ldb Allow rootdse module to build without ldb_private.h
Andrew Bartlett [Tue, 30 Jun 2009 05:30:13 +0000 (15:30 +1000)]
s4:ldb Allow rootdse module to build without ldb_private.h

It seems quite reasonable to allow modules to re-initialise the set of
cached DNs on the ldb context.

Andrew Bartlett

13 years agos4: dsdb Avoid using the internal ldb_private.h header
Andrew Bartlett [Tue, 30 Jun 2009 05:12:29 +0000 (15:12 +1000)]
s4: dsdb Avoid using the internal ldb_private.h header

This job is not complete (the partition module remains a unfinished
task), but now we do use the private ldb headers much less.

Andrew Bartlett

13 years agos4:heimdal Allow KRB5_NT_ENTERPRISE names in all DB lookups
Andrew Bartlett [Tue, 30 Jun 2009 02:11:14 +0000 (12:11 +1000)]
s4:heimdal Allow KRB5_NT_ENTERPRISE names in all DB lookups

The previous code only allowed an KRB5_NT_ENTERPRISE name (an e-mail
list user principal name) in an AS-REQ.  Evidence from the wild
(Win2k8 reportadely) indicates that this is instead valid for all
types of requests.

While this is now handled in heimdal/kdc/misc.c, a flag is now defined
in Heimdal's hdb so that we can take over this handling in future (once we start
using a system Heimdal, and if we find out there is more to be done
here).

Andrew Bartlett

13 years agos4:kdc Only get the lp_ctx once for a LDB_fetch()
Andrew Bartlett [Tue, 30 Jun 2009 02:06:38 +0000 (12:06 +1000)]
s4:kdc Only get the lp_ctx once for a LDB_fetch()

13 years agoRework hdb-samba4 to remove useless abstractions.
Andrew Bartlett [Tue, 30 Jun 2009 00:29:30 +0000 (10:29 +1000)]
Rework hdb-samba4 to remove useless abstractions.

The function LDB_lookup_principal() has been eliminated, and it's
contents spread back to it's callers.  Removing the abstraction makes
the code clearer.

Also ensure we never pass unescaped user input to a LDB search
function.

Andrew Bartlett

13 years agos4:dsdb Explain the parsing steps for userPrincipalName cracknames calls
Andrew Bartlett [Tue, 30 Jun 2009 00:19:19 +0000 (10:19 +1000)]
s4:dsdb Explain the parsing steps for userPrincipalName cracknames calls

13 years agos4-smbtorture: use torture_comment & torture_warning in RPC samr tests.
Günther Deschner [Mon, 29 Jun 2009 21:42:58 +0000 (23:42 +0200)]
s4-smbtorture: use torture_comment & torture_warning in RPC samr tests.

Guenther

13 years agos3:build: check for external liblua, link lua statically if using internal lib
Michael Adam [Mon, 29 Jun 2009 21:23:07 +0000 (23:23 +0200)]
s3:build: check for external liblua, link lua statically if using internal lib

So liblua is treated the same way as libtalloc and libtdb.

Michael

13 years agos4-smbtorture: correctly test comment behaviour in RPC-SAMR-USERS against s3.
Günther Deschner [Tue, 23 Jun 2009 22:24:03 +0000 (00:24 +0200)]
s4-smbtorture: correctly test comment behaviour in RPC-SAMR-USERS against s3.

Guenther

13 years agos3-pdb_tdb: give 'unknown_str' the proper name 'comment' and set comment in passdb.
Günther Deschner [Tue, 23 Jun 2009 22:23:09 +0000 (00:23 +0200)]
s3-pdb_tdb: give 'unknown_str' the proper name 'comment' and set comment in passdb.

pdb_{get,set}_comment were already existing in the API but were never used.

Guenther

13 years agos3:pdb_ads: we need to make the fd for tldap/tsocket non-blocking
Stefan Metzmacher [Mon, 29 Jun 2009 14:31:31 +0000 (16:31 +0200)]
s3:pdb_ads: we need to make the fd for tldap/tsocket non-blocking

metze

13 years agos3:fix build of old linux quota system and other unixes' quota implementation
Michael Adam [Mon, 29 Jun 2009 14:26:42 +0000 (16:26 +0200)]
s3:fix build of old linux quota system and other unixes' quota implementation

By fixing the use of struct stat_ex.

Michael

13 years agos3:lib/sysquotas: fix usage of SMB_STRUCT_STAT (struct stat_ex).
Michael Adam [Mon, 29 Jun 2009 14:11:13 +0000 (16:11 +0200)]
s3:lib/sysquotas: fix usage of SMB_STRUCT_STAT (struct stat_ex).

This fixes the build with quotas / configure time detection
of sys_quota interface.

Michael

13 years agolib/util: fix building tevent_ntstatus without config.h
Michael Adam [Mon, 29 Jun 2009 13:39:46 +0000 (15:39 +0200)]
lib/util: fix building tevent_ntstatus without config.h

(when called from places with "#define NO_CONFIG_H" set, such as configure)

 Michael

13 years agotsocket/bsd: also ask for TEVENT_FD_READ when we want to write into a stream socket
Stefan Metzmacher [Mon, 29 Jun 2009 11:13:05 +0000 (13:13 +0200)]
tsocket/bsd: also ask for TEVENT_FD_READ when we want to write into a stream socket

Otherwise we would not notice a broken connection.

metze

13 years agotsocket/bsd: more correctly check if the cached tevent_fd is still valid
Stefan Metzmacher [Mon, 29 Jun 2009 11:05:27 +0000 (13:05 +0200)]
tsocket/bsd: more correctly check if the cached tevent_fd is still valid

I some cases the pointer value of tevent_context is the same again,
if we do something like:

ev1 = tevent_context_init();
...
fde = tevent_add_fd(ev1, fd, TEVENT_FD_READ...);
...
talloc_free(ev1);
...
ev2 = tevent_context_init();

if (ev1 == ev2) {
/* this can happen! */
}

if (tevent_fd_get_flags(fde) == 0) {
/* this is always true */
}

But the "talloc_free(ev1)" will set fde->event_ctx to NULL
and tevent_fd_get_flags() will always return 0.

metze

13 years agos3-selftest: add RPC-SAMR-MACHINE-AUTH to list of test to run against s3.
Günther Deschner [Mon, 29 Jun 2009 12:34:49 +0000 (14:34 +0200)]
s3-selftest: add RPC-SAMR-MACHINE-AUTH to list of test to run against s3.

Guenther

13 years agos4-smbtorture: add RPC-SAMR-MACHINE-AUTH test.
Günther Deschner [Fri, 26 Jun 2009 14:53:51 +0000 (16:53 +0200)]
s4-smbtorture: add RPC-SAMR-MACHINE-AUTH test.

This test talks to a DC as a joined workstation member - in the same way
winbindd does, in particular the calls used in this test's query pattern
will all request for SEC_FLAG_MAXIMUM_ALLOWED access_mask
(which pretty much all of samba's client code does as well).

In fact this test verifies that winbind can correctly talk to a samba dc using
samr dcerpc calls.

Guenther

13 years agos4-smbtorture: add torture_suite_add_machine_workstation_rpc_iface_tcase.
Günther Deschner [Fri, 26 Jun 2009 14:51:53 +0000 (16:51 +0200)]
s4-smbtorture: add torture_suite_add_machine_workstation_rpc_iface_tcase.

Unlike torture_suite_add_machine_bdc_rpc_iface_tcase() which joins as a BDC
(ACB_SRVTRUST) this joins as a member workstation (ACB_WSTRUST).

Guenther

13 years agomount.cifs: don't pass text ro/rw options to kernel
Jeff Layton [Mon, 29 Jun 2009 10:16:38 +0000 (06:16 -0400)]
mount.cifs: don't pass text ro/rw options to kernel

/bin/mount strips off the ro/rw options after setting the MS_RDONLY
flag appropriately. Make mount.cifs do the same thing.

Signed-off-by: Jeff Layton <jlayton@samba.org>
13 years agoFix ndrdump to use a common setup_logging() API
Andrew Bartlett [Mon, 29 Jun 2009 10:12:23 +0000 (20:12 +1000)]
Fix ndrdump to use a common setup_logging() API

By adding a new common setup_logging_stdout() API, we no longer need to abuse the ABI compatability between the different setup_logging() calls in Samba3 and Samba4's DEBUG() subsystems.

The revert of 49a6d757b4d944cd22c91b2838beb83f04fbe1e9 works with this
to fix bug 6211.

Andrew Bartlett

13 years agoRevert "s4:debug: make setup_logging() a bit more compatible with samba3"
Andrew Bartlett [Mon, 29 Jun 2009 09:57:57 +0000 (19:57 +1000)]
Revert "s4:debug: make setup_logging() a bit more compatible with samba3"

The problem is that the enum was previously a 'rachet', that is, it
would only reset to a level higher than it was previouly set to.
Changing the order broke file-based logging for our production sites.

This reverts commit 49a6d757b4d944cd22c91b2838beb83f04fbe1e9.

13 years agoAdds the impersonation level in ntcreatex requests to SAMBA 3 misc torture test
Matthias Dieter Wallnöfer [Sat, 20 Jun 2009 20:47:19 +0000 (22:47 +0200)]
Adds the impersonation level in ntcreatex requests to SAMBA 3 misc torture test

Specifies the impersonation level according to the reporter commit in bug #6283

13 years agoFix bug 6514: net gives unhelpful "lp_load failed" when it's missing smb.conf
David Markey [Mon, 29 Jun 2009 06:12:03 +0000 (08:12 +0200)]
Fix bug 6514: net gives unhelpful "lp_load failed" when it's missing smb.conf

13 years agoCorrect some typos in the LDB partition module
Matthias Dieter Wallnöfer [Sat, 27 Jun 2009 12:16:19 +0000 (14:16 +0200)]
Correct some typos in the LDB partition module

13 years agoSAMDB: Don't check for "sAMAccountName" twice
Matthias Dieter Wallnöfer [Sat, 27 Jun 2009 11:38:38 +0000 (13:38 +0200)]
SAMDB: Don't check for "sAMAccountName" twice

13 years agoEnhancement of "simple ldap map" with "systemFlags" attribute
Matthias Dieter Wallnöfer [Tue, 23 Jun 2009 16:27:26 +0000 (18:27 +0200)]
Enhancement of "simple ldap map" with "systemFlags" attribute

Enhance the simple ldap map to support also the "systemFlags" attribute in the
correct way.

13 years agoldb: Properly handle NULL when copying attr lists.
Andrew Kroeger [Tue, 23 Jun 2009 12:26:17 +0000 (07:26 -0500)]
ldb: Properly handle NULL when copying attr lists.

When copying an attribute list, ensure the list itself is not NULL before
attempting to access elements of the list.