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

20784 Commits

Author SHA1 Message Date
Kamen Mazdrashki
a409c0f037 s4-schema: Constraints on msDS-IntId attribute
This attribute can not be modified on existing schema object.

msDS-IntId is not allowed during attribute creation also.

Signed-off-by: Andrew Tridgell <tridge@samba.org>
2009-12-21 23:44:36 +11:00
Kamen Mazdrashki
4e8ad284f5 s4-schema: Set ATTID in schema cache from "msDS-IntId"
According to http://msdn.microsoft.com/en-us/library/cc223224%28PROT.13%29.aspx
some Attributes OIDs may not use prefixMap.
Setting ATTID in Schema Cache here should work, although
this code snippet should be moved in separate function.

Signed-off-by: Andrew Tridgell <tridge@samba.org>
2009-12-21 23:44:29 +11:00
Kamen Mazdrashki
14bac3a3e6 Revert "s4-drs: cope with bogus empty attributes from w2k8-r2"
This reverts commit 1287c1d115.

Next patch should fix the "not recognized ATTIDs" problem

Signed-off-by: Andrew Tridgell <tridge@samba.org>
2009-12-21 23:44:19 +11:00
Kamen Mazdrashki
ee48f583b5 s4-tort: Tests for "msDS-IntId" attribute implemented
Signed-off-by: Andrew Tridgell <tridge@samba.org>
2009-12-21 23:44:13 +11:00
Kamen Mazdrashki
c113be8526 s4-tort: Move Schema tests from ldap.py into separate module
Signed-off-by: Andrew Tridgell <tridge@samba.org>
2009-12-21 23:44:05 +11:00
Kamen Mazdrashki
d9606d64dd s4-drs: Fix bug - prefixMap is not updated when adding new OIDs.
The bug is that prefixMap is updated only memory when
adding new Classs/Attribute that has and OID not in
prefixMap already.

Signed-off-by: Andrew Tridgell <tridge@samba.org>
2009-12-21 23:43:51 +11:00
Kamen Mazdrashki
03a1451bbc s4-drstest: Don't remove temp LDB so it can be reviewed if necessary
This test makes temp directory which is not removed
so why not just leave LDB also.

Signed-off-by: Andrew Tridgell <tridge@samba.org>
2009-12-21 23:43:17 +11:00
Andrew Tridgell
452fc0d6f4 s4-repl: give a reason why the prepare commit failed 2009-12-21 23:41:09 +11:00
Andrew Tridgell
92d75a4bfb s4-kcc: don't crash with a NULL ntds connection list 2009-12-21 23:41:09 +11:00
Andrew Tridgell
60acce584b s4-repl: only try to replicate for NCs that we are a master for 2009-12-21 23:41:09 +11:00
Andrew Tridgell
87f28cc267 s4-torture: another unsigned comparison bug 2009-12-21 23:41:08 +11:00
Andrew Tridgell
ec74ffa8f0 s4-schema: a unsigned comparison bug in the schema code 2009-12-21 23:41:08 +11:00
Andrew Tridgell
d3708109a1 s4-drs: another two unsigned comparison bugs 2009-12-21 23:41:07 +11:00
Andrew Tridgell
2a4a159a84 s4-repl: lower debug level of a common message 2009-12-21 23:41:07 +11:00
Andrew Tridgell
47560bfda9 s4-dsdb: don't use a non-constant format string for a printf format 2009-12-21 23:41:06 +11:00
Andrew Tridgell
a070119de3 s4-dsdb: added DSDB_MODIFY_RELAX flag to the dsdb_module_*() calls 2009-12-21 23:41:06 +11:00
Andrew Tridgell
9d56f656d4 s4-dsdb: added dsdb_get_extended_dn_uint64() 2009-12-21 23:41:05 +11:00
Andrew Tridgell
e89a2db4f2 s4-dsdb: use varargs expression in dsdb_module_search()
Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2009-12-21 23:41:05 +11:00
Andrew Tridgell
2c88ffb8f1 s4-dsdb: added two new dsdb_get_extended_dn_*() helper functions
Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2009-12-21 23:41:04 +11:00
Andrew Tridgell
dbda2c2db5 s4-provision: added a note about where invocationIDs come from
Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2009-12-21 23:41:04 +11:00
Andrew Tridgell
882768c878 s4-dsdb: give us an invocationID when in standalone mode
To allow us to use the repl_meta_data module in standalone mode (and
thus not have two module stacks to test), we need a invocationID
stored somewhere when standalone. This creates a random one, and
stores it in @SAMBA_DSDB.

Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2009-12-21 23:41:04 +11:00
Stefan Metzmacher
fcbe8f0c80 s4:kdc: setup the local and remote tsocket_address at accept time
metze
2009-12-19 18:24:26 +01:00
Stefan Metzmacher
4dc958c7c8 s4:kdc: convert UDP based communication to tdgram_context
metze
2009-12-19 18:24:26 +01:00
Zachary Loafman
daa561d75b s4 torture: Add test to show archive bit behavior with directories
Signed-off-by: Tim Prouty <tprouty@samba.org>
2009-12-18 10:52:45 -08:00
Tim Prouty
9b869230a7 s4 torture: Fix RAW-STREAMS-DELETE to pass against samba3 2009-12-18 10:52:45 -08:00
Nadezhda Ivanova
ea365af4f5 Added freeing a successful req so it doesnt croud the ldb context 2009-12-18 17:57:08 +02:00
Nadezhda Ivanova
39616c0ea2 Added oid for AS_SYSTEM control, used to bypass access checks for system operations. 2009-12-18 15:40:11 +02:00
Andrew Tridgell
19cdcdec09 s4-dsdb: stop warnings about unknown struct GUID in prototypes
Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2009-12-18 21:03:40 +11:00
Andrew Tridgell
cb841c363a s4-ldb: fixed a valgrind error in ldbtest
we were using msg->dn after the ldb it contained had been freed

Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2009-12-18 21:03:40 +11:00
Andrew Tridgell
5d7805b07f s4-dsdb: greatly simplify the subtree_delete module
We can use dsdb_module_search() to make this much simpler

Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2009-12-18 21:03:40 +11:00
Andrew Tridgell
b3c69e76ec s4-dsdb: declare ldb_dn_update_components() 2009-12-18 21:03:39 +11:00
Andrew Tridgell
82bf0d8bc6 s4-dsdb: added ldb_dn_update_components()
This is used to udpate just the DN components of a ldb_dn, leaving the
other extended fields alone. It is needed to prevent linked attribute
updates from removing other extended components.

Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2009-12-18 21:03:39 +11:00
Andrew Tridgell
db76e65318 s4-dsdb: fixed the sort in dsdb_find_nc_root() 2009-12-18 21:03:39 +11:00
Andrew Tridgell
f392ae5169 s4-ldb: display msDS-OptionalFeatureGUID as a GUID
Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2009-12-18 21:03:39 +11:00
Andrew Tridgell
811b4054f9 s4-scripts: add a enablerecyclebin script
This can be used to enable the recyclebin on a windows box. Once we
properly implement this feature in samba we will use this to enable
the feature on ourselves as well.
2009-12-18 21:03:39 +11:00
Andrew Tridgell
20869a0bf0 s4-ldb: canonicalise the message on ldb_add
This canonicalise avoids a problem with an add that has multiple
elements with the same el->name. That is allowed by MS servers, and by
ldb, but it breaks things like the tdb backend and the repl_meta_data
RPMD handling.

Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2009-12-18 21:03:39 +11:00
Brendan Powers
7cb858e151 s4-dsdb: Add a test for adding, deleting, and appending a posixAccount objectClass to a user
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
2009-12-18 14:27:44 +11:00
Brendan Powers
08060068bf s4-dsdb: fix handling of AUX classes in objectclass_sort
This is done by sorting the classes by subClass_order, which will
check if the last structural class is valid to add (in
objectclass_do_add instead checking the last class in the list).

They were being sorted by building a class tree, and adding the
classes to the list in that order. However, AUX classes usually don't
fit into that tree, so LDB_ERR_OBJECT_CLASS_VIOLATION was returned. I
have changed the behavior to sort the classes by subClass_order
instead.

Signed-off-by: Andrew Bartlett <abartlet@samba.org>
2009-12-18 14:27:44 +11:00
Brendan Powers
8b88925654 s4-dsdb: return an error if samAccountName is not specified when creating a user.
Makes sure samAccountName has been specified before adding a
user. This happened while I was trying to add a user with the
posixAccount objectclass. I forgot to specify the user objectClass,
and samba segfaulted. It now returns LDB_ERR_CONSTRAINT_VIOLATION.

Signed-off-by: Andrew Bartlett <abartlet@samba.org>
2009-12-18 14:27:43 +11:00
Brendan Powers
d99084ffdb s4-dsdb: Move get_last_structural class from descriptor.c to util.c
It can now also be used by objectclass.c

get_last_structural_class now ignores AUX classes, because they are
not structural

Signed-off-by: Andrew Bartlett <abartlet@samba.org>
2009-12-18 14:27:43 +11:00
Brendan Powers
2ad086e7f6 s4-dsdb: Add a check to prevent acl_modify from debuging a NULL message
Check to see if there were any messages passed to acl_modify before
debugging the first one. I think I caused this by some malformed
LDIF.

Signed-off-by: Andrew Bartlett <abartlet@samba.org>
2009-12-18 14:27:43 +11:00
Andrew Bartlett
c3d1e5ca0c s4:provision Give a more useful error message in guess_names
The problem here is that as we start to get 'real users' they still
decide to do silly things, like load empty but existing smb.conf
files.  Let's give them a better chance to discover what they did
wrong.

Andrew Bartlett
2009-12-18 14:27:43 +11:00
Tim Prouty
cfbf62dbfd s4 torture: RAW-STREAMS-NAMES Make sure the create time of the streams are different from the base file 2009-12-17 18:13:54 -08:00
Tim Prouty
c3582f923e s4 torture: Add RAW-STREAMS-RENAME3 to show error when trying to overwrite a stream with an open handle
A normal file overwrite in this case would return NT_STATUS_ACCESS_DENIED,
but if a stream is the target NT_STATUS_INVALID_PARAMETER is returned.
2009-12-17 18:13:48 -08:00
Tim Prouty
f8bb5a60e7 s4 torture: Parameterize streams delete behavior rather than commenting out the check. 2009-12-17 17:58:35 -08:00
Tim Prouty
f02206d933 s4 torture: RAW-STREAMS-CREATEDISP Use a normal deny mode 2009-12-17 17:58:35 -08:00
Tim Prouty
5c13a90abe s4 torture: close handle instead of using exit 2009-12-17 17:58:34 -08:00
Matthias Dieter Wallnöfer
bbec305135 s4:"samdb_set_password" - remove delete instructions
They won't work when the LDB change is done using "samdb_replace"
(consider "samr_password.c" functions).

I think this has been a relict which has been useful before the "password_hash"
module existed. Basically it itself does now the updates.
2009-12-17 20:00:19 +01:00
Günther Deschner
dc4c411242 s4-smbtorture: skip GetAliasMembership against s4.
It returns NT_STATUS_INTERNAL_DB_CORRUPTION for unknown sids and I could not
figure out why.

Guenther
2009-12-17 18:05:36 +01:00
Nadezhda Ivanova
c0883fb451 Fixed incorrect checking of PRINCIPAL_SELF permissions.
If an ace has the PRINCIPAL_SELF as trustee, this sid has to be replaced with
the onjectSid of the object being checked. PRINCIPAL_SELF is the way to grant rights
to an account over itself.
2009-12-17 17:25:11 +02:00
Günther Deschner
619ad0c6ec s4-smbtorture: add a samr_GetAliasMembership test to RPC-SAMR.
Guenther
2009-12-17 15:40:42 +01:00
Matthias Dieter Wallnöfer
1d0f364fad s4:dsdb/common/util - make NTTIME attribute wrappers use a "const" message
There is no reason to have the message non-const here.
2009-12-17 12:43:10 +01:00
Günther Deschner
a9689bb755 s4-smbtorture: fix smbtorture after setprinter IDL fixes.
Guenther
2009-12-17 10:43:32 +01:00
brendan powers
0708b2a0c9 s4-ntvfs: check if pvfs is NULL in pvfs_logoff
pvfs can be NULL if the directory a share points to does not exist. In
this case, there would be no open files, so it is safe to just return
from the function.

Signed-off-by: Andrew Tridgell <tridge@samba.org>
2009-12-17 11:48:39 +11:00
Stefan Metzmacher
fae70e1f54 s4:gensec: allow clearing local and remote address by passing NULL
metze
2009-12-16 20:34:15 +01:00
Andreas Schneider
c457d54434 s4-gensec: Remove obsolete socket_address vars and fns. 2009-12-16 20:28:39 +01:00
Andreas Schneider
1e5488859a s4-gensec: Replace gensec_get_peer_addr with new tsocket based fn. 2009-12-16 20:28:38 +01:00
Andreas Schneider
ac2d31e24c s4-gensec: Replace gensec_set_peer_addr with new tsocket based fn. 2009-12-16 20:28:38 +01:00
Andreas Schneider
8ca88042f0 s4-gensec: Replace gensec_get_my_addr with new tsocket based fn. 2009-12-16 20:28:38 +01:00
Andreas Schneider
226a9db2d9 s4-gensec: Replace gensec_set_my_addr() with new tsocket based fn. 2009-12-16 20:28:38 +01:00
Andreas Schneider
743e6363d5 s4-gensec: Added remote and local setter/getter using tsocket. 2009-12-16 20:28:37 +01:00
Andrew Tridgell
8d3fc23157 s4-dsdb: also mark the relax control non-critical when done 2009-12-16 20:56:24 +11:00
Andrew Tridgell
558a38671a s4-dsdb: it is a better pattern to mark a control as done than remove it
removing a control means it can't be seen by any other modules, which
is usually not what is wanted. Better to just mark it non-critical,
which means anyone else who wants to look at it can, but if nobody
does its not an error.
2009-12-16 20:56:24 +11:00
Andrew Tridgell
41e403adb0 s4-dsdb: when the SD_FLAGS control is set, don't remove nTSecurityDescriptor 2009-12-16 20:56:24 +11:00
Andrew Tridgell
934bb28ef3 s4-dsdb: don't actually remove the sd_flags control, just mark it non-critical
For controls that need to be seen by more than one module, it is best
to just mark them non-critical when handled, instead of removing
them. Otherwise lower modules can't see them.

In this case we want the operational module to see the SD_FLAGS
control
2009-12-16 20:56:24 +11:00
Andrew Tridgell
9955756314 s4-ldb: show the OID of any unhandled critical controls
It isn't very useful just saying that a control is not supported,
without saying which one is the problem

Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2009-12-16 20:56:23 +11:00
Andrew Tridgell
f8320b3559 s4-ldb: fixed a transaction error on prepare_commit
when a prepare commit fails, we need to give a cancel to all modules,
not a commit!

Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2009-12-16 20:56:23 +11:00
Andrew Tridgell
e14c72877f s4-ldb: added --show-deactivated-link command line option
this adds the SHOW_DEACTIVATED_LINK control
2009-12-16 20:56:23 +11:00
Andrew Tridgell
6c2125572c s4-dsdb: added dsdb_get_deleted_objects_dn()
This is based on the code from Eduardo Lima <eduardoll@gmail.com>, but
uses the new helper functions added in the last couple of commits

Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2009-12-16 20:56:22 +11:00
Andrew Tridgell
3c1f18c5e2 s4-dsdb: added dsdb_find_nc_root()
This is based on the function of the same name from Eduardo Lima
<eduardoll@gmail.com>, but using ldb_dn_compare, to give us
comparisons consistent with what the rest of the code uses.

We will use this function in combination with dsdb_wellknown_dn() to
find the Deleted Objects container for any object.

Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2009-12-16 20:56:22 +11:00
Andrew Tridgell
7d0fdcae1e s4-dsdb: added dsdb_wellknown_dn()
This finds a wellknown object given its GUID

Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2009-12-16 20:56:22 +11:00
Andrew Tridgell
8a74633eaa s4-dsdb: added a dsdb_module_rename() call
This will be used by the replmd_delete() code

Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2009-12-16 20:56:21 +11:00
Andrew Tridgell
9fa1f96172 s4-dsdb: added dsdb_module_modify()
This is used to do a sync modify in a module

Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2009-12-16 20:56:21 +11:00
Andrew Tridgell
4b970c00ae s4-dsdb: fixed dsdb_module_dn_by_guid()
needs to ask for the DN in storage format, plus fix compilation errors
2009-12-16 20:56:21 +11:00
Andrew Tridgell
cd4574ff84 s4-dsdb: dsdb_flags should be unsigned
Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2009-12-16 20:56:21 +11:00
Andrew Tridgell
57b10b664b s4-dsdb: rename dsdb_module_search_handle_flags to dsdb_request_add_controls
This function will be used for non-search controls, like relax
2009-12-16 20:56:21 +11:00
Andrew Tridgell
951592687a s4-dsdb: added dsdb_module_dn_by_guid()
This finds a DN given a GUID, searching below the current module in
the module stack.

Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2009-12-16 20:56:20 +11:00
Andrew Tridgell
32995e84a2 s4-dsdb: use dsdb_dn_is_deleted_val()
This also moves the check to before we parse the DN, which saves some
unnecessary work

Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2009-12-16 20:56:20 +11:00
Andrew Tridgell
152f415ba8 s4-dsdb: added dsdb_dn_is_deleted_val()
This is used to determine if a extedned DN has the 'DELETED=1'
component

Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2009-12-16 20:56:20 +11:00
Andrew Tridgell
d31b6360d6 s4-ntvfs: try to fix bug 6989
bug 6989 is a rare crash that has occurred in production. My best
guess as to the cause is the talloc_free() not being specific enough
as to which parent needs to be freed.
2009-12-16 20:56:20 +11:00
Matthias Dieter Wallnöfer
e22e336f41 s4:drsuapi/getncchanges.c - Update the list of operational attributes
- Reorder them as specified in "operational.c"
- Add also the lan manager hash password attribute
2009-12-16 09:45:22 +01:00
Günther Deschner
308b50a7bb s4-smbtorture: run GetPrinterDriver2 tests against each printer's driver.
Guenther
2009-12-16 01:13:43 +01:00
Andreas Schneider
b55d07615b s4-kdc: Migrate to tsocket_address. 2009-12-15 23:34:23 +01:00
Volker Lendecke
4a19adadcc smbtorture4: Add rpc-samba3-getaliasmembership-0 2009-12-15 12:28:16 -08:00
Nadezhda Ivanova
4330efe0f2 Removed ldb_modify_ctrl from ldb, implemented as a static in ldap_backend. 2009-12-15 20:29:20 +02:00
Aravind Srinivasan
b85f6f63e6 s4 torture: Add new RAW-SEARCH test to explore strange max count behavior
Signed-off-by: Tim Prouty <tprouty@samba.org>
2009-12-15 09:51:36 -08:00
Aravind Srinivasan
8ba02d9ed9 s4 torture: Update RAW-QFILEINFO to only test info levels that are supported by the server
Signed-off-by: Tim Prouty <tprouty@samba.org>
2009-12-15 09:40:05 -08:00
Zach Loafman
5930f770d2 s4 torture: Convert RAW-OPEN to suite form 2009-12-15 09:13:24 -08:00
Tim Prouty
d732fb43a6 s4 torture: Add SHARE_DELETE to create_directory_handle
Tests explicitly checking share modes should open the dir/file
with the share mode they want to test.
2009-12-15 09:13:24 -08:00
Brian Lu
f346079083 s4:tls: fix the build on Solaris
Signed-off-by: Stefan Metzmacher <metze@samba.org>
2009-12-15 12:56:50 +01:00
Nadezhda Ivanova
4deaa84ce4 Fixed a problem with duplicate values of allowedAttributesEffective. 2009-12-15 12:02:20 +02:00
Matthieu Patou
ef5508bc78 s4: rename res/res2 to something more explicit 2009-12-15 10:04:05 +11:00
Matthieu Patou
d2ec67eb53 s4: upgradeprovision handle renaming and knownobjects 2009-12-15 10:04:05 +11:00
Matthieu Patou
fb85977d7c s4: upgradeprovision rename also when there is a mismatch on the case of name attribute
Renaming not only helps when name attribute is not here
  it also helps when the case is not the good one. So
  in order to avoid problem and have as much as possible similar provision
  we should use the rename whenever a name difference appear.
2009-12-15 10:04:04 +11:00
Matthieu Patou
3357319620 s4: reorder action to permit old provision to be correctly upgraded 2009-12-15 10:04:04 +11:00
Endi Sukma Dewata
f871de7def s4:provision - Remap conflicting thumbnailPhoto and thumbnailLogo OID's. 2009-12-15 10:04:04 +11:00
Andrew Tridgell
9260396bbc s4-dsdb: added REVEAL_INTERNALS flag to dsdb_module_search_handle_flags() 2009-12-14 22:29:58 +11:00
Andrew Tridgell
7f6b524bf6 s4-devel: support vampire_ad.sh with no initial smb.conf 2009-12-14 22:29:58 +11:00
Andrew Tridgell
b11b22752a s4-loadparm: call reload_charcnv() also for a missing smb.conf
bin/net vampire with a missing smb.conf would segfault as the iconv
convenience pointer had not been setup.
2009-12-14 22:29:58 +11:00
Andrew Tridgell
7f16da7473 s4-dsdb: return a zero guid on error in samdb_result_guid() 2009-12-14 22:29:58 +11:00
Andrew Tridgell
bb009412d3 heimdal: work around differences between GNU and XSI strerror_r()
This is a fairly ugly workaround, but then again, strerror_r() is a
very ugly mess.
2009-12-14 22:29:57 +11:00
Andrew Tridgell
665e57f956 s4-dsdb: use the reveal control to hide/show extended DN components
When reveal is set, then we show deleted linked attributes and all
linkked attribute components. When not set we show a normal extended
DN.
2009-12-14 22:29:57 +11:00
Andrew Tridgell
e3c2309dcd s4-ldb: added new ldb_dn extended components for linked attributes
These will store linked attribute replication meta data
2009-12-14 22:29:57 +11:00
Andrew Tridgell
0d76df9953 s4-ldb: added a function to filter extended components of a ldb_dn
We need to be able to filter out components that should not be exposed
to users
2009-12-14 22:29:57 +11:00
Andrew Tridgell
725e25a206 s4-ldb: added a new "reveal" control
This control will allow inspection of internal ldb values, which would
normally be stripped before being presented to users. The first use
will be stripping linked attribute meta data extended components.
2009-12-14 22:29:57 +11:00
Andrew Tridgell
56b90acbf6 s4-ldb: sort the linearized extended DN by component name
This will make life easier when handling deleted linked attributes
2009-12-14 22:29:57 +11:00
Matthieu Patou
155bdea7b2 torture: add new tests for dfsblobs
Signed-off-by: Stefan Metzmacher <metze@samba.org>
2009-12-14 10:58:32 +01:00
Günther Deschner
801fbd0569 s4-smbtorture: check whether a returned buffer size is a multiple of 4 in RPC-SPOOLSS.
This gives a good indication where our IDL (and the s3 spoolss implementation) is still wrong.

Guenther
2009-12-14 10:37:41 +01:00
Matthias Dieter Wallnöfer
f8c34c4df1 s4:"samdb_set_password_sid" - clean up created objects correctly
- We should clean up such "helper" objects created in this function to don't
  have them around until "mem_ctx" is destroyed
- Remove a from my view pointless comment "This is a password set, not change"
  since an external argument "user_change" decides this ("modify" or "(re)set")
2009-12-13 16:13:34 +01:00
Matthias Dieter Wallnöfer
1788abba14 s4:operational LDB module - cosmetic - reorder an attribute list
This matches the default handling order in the "password_hash" module (it's nice
to have this consistent).
2009-12-12 17:59:05 +01:00
Matthias Dieter Wallnöfer
5767b1dacc s4:utils/oLschema2ldif.c - remove (now) unused variables 2009-12-11 20:20:02 +01:00
Matthias Dieter Wallnöfer
31321ac868 s4:libnet/libnet_become_dc - Fix a small glitch in "becomeDC_drsuapi1_add_entry_send"
We shouldn't use the now uninitialised "status" variable anymore.
2009-12-11 11:19:32 +01:00
Günther Deschner
dc71d1c29d s4-smbtorture: add more spoolss_EnumPrinterKey tests for local NDR test.
Guenther
2009-12-10 22:49:15 +01:00
Günther Deschner
ce33967f4a s4-smbtorture: fix and extend enum printerkey test.
Guenther
2009-12-10 17:48:50 +01:00
Nadezhda Ivanova
56b754e09a Implementation of sDRightsEffective, allowedAttributesEffective and allowedChildClassesEffective.
Behavior as documented in WSPP and tested. Needs optimisation though.
2009-12-10 15:49:53 +02:00
Andrew Tridgell
c59372b0b8 s4-ldb: fixed 2 bugs in ldb_dn_set_extended_component()
The first bug was that setting a component twice could cause it to
appear twice in the DN.

The second bug was that using an existing ldb_val from a previous call
of ldb_dn_get_extended_component() as an argument to
ldb_dn_set_extended_component() would cause a valgrind error (as the
array the val pointed into will change).
2009-12-10 17:51:30 +11:00
Andrew Tridgell
62dc7f6b2d s4-libcli: GUID_from_ndr_blob() is strict about the blob size
We need to create a blob of the right length
2009-12-10 17:51:30 +11:00
Andrew Tridgell
c7c97b61ae s4-schema: use GUID_to_ndr_blob() 2009-12-10 17:51:29 +11:00
Andrew Tridgell
d35b7d0aa4 s4-schema: use binsearch.h 2009-12-10 17:51:29 +11:00
Andrew Tridgell
261ba40e77 s4-dsdb: use GUID_to_ndr_blob() 2009-12-10 17:51:29 +11:00
Andrew Tridgell
215cc5a9ed s4-ldb: use GUID_to_ndr_blob() 2009-12-10 17:51:29 +11:00
Andrew Tridgell
982228605f s4-libnet: use GUID_to_ndr_blob() 2009-12-10 17:51:28 +11:00
Andrew Tridgell
b4ea96ecd9 s4-libcli: use GUID_to_ndr_blob() 2009-12-10 17:51:28 +11:00
Andrew Tridgell
33cbe9c631 s4-server: use GUID_to_ndr_blob() in cldap and smb servers 2009-12-10 17:51:28 +11:00
Andrew Tridgell
2493776f59 s4-ldb: simplify ldif handlers using new GUID functions 2009-12-10 17:51:27 +11:00
Andrew Tridgell
d337cefa92 s4-dsdb: simplify samdb_result_guid() 2009-12-10 17:51:27 +11:00
Andrew Tridgell
56b887e5b9 s4-dsdb: simplify linked attributes code using GUID functions 2009-12-10 17:51:27 +11:00
Andrew Tridgell
81bc561330 s4-dsdb: simplify schema code using new GUID functions 2009-12-10 17:51:27 +11:00
Andrew Tridgell
f01ea8bf58 s4-smb2: use new GUID function in smb2 negprot 2009-12-10 17:51:27 +11:00
Andrew Tridgell
498f2b879a s4-libcli: use new GUID functions in libcli 2009-12-10 17:51:26 +11:00
Andrew Tridgell
08e8988bd8 s4-dsdb: use GUID_from_ndr_blob() to create dsdb_get_extended_dn_guid() 2009-12-10 17:51:26 +11:00
Günther Deschner
d2f13dd688 s4-smbtorture: enhance spoolss_EnumPrinterKey torture test.
This demonstrates that s3 still does not have that call implemented correctly.

Guenther
2009-12-09 15:34:45 +01:00
Andrew Tridgell
0fca76e577 s4-dsdb: added dsdb_functional_level() helper function 2009-12-09 18:18:26 +11:00
Andrew Tridgell
732c701c52 s4-drs: ensure we fill in ncRoot_dn in getncchanges
Signed-off-by: Andrew Tridgell <tridge@samba.org>
2009-12-09 18:18:26 +11:00
Andrew Tridgell
16eb25b35b s4-drs: use parentGUID attribute in getncchanges
Now that parentGUID is reliable again, use it instead
of building our own

Signed-off-by: Andrew Tridgell <tridge@samba.org>
2009-12-09 18:18:25 +11:00
Andrew Tridgell
4bb2958f16 s4-ldb: fixed nested searches inside ldb modules
We need to keep a search count in ltdb to allow for nesting
of searches inside a module

Signed-off-by: Andrew Tridgell <tridge@samba.org>
2009-12-09 18:18:25 +11:00
Andrew Tridgell
e5a478d3a2 s4-ldb: added a missing ltdb_unlock_read() 2009-12-09 18:18:25 +11:00
Andrew Tridgell
33976711e3 s4-dsdb: use dsdb_module_search_dn in repl_meta_data
This allows us to search below the current module. That
will be important when we start using the results of this
search to get the linked attributes meta data right
2009-12-09 18:18:25 +11:00
Andrew Tridgell
707cd30cda s4-dsdb: fixed steal of parentGUID for empty msg
msg->elements could be NULL before we add parentGUID
2009-12-09 18:18:25 +11:00
Andrew Bartlett
18530985ec s4: On the way to alpha11 2009-12-09 11:52:41 +11:00
Andrew Bartlett
100e249c79 This is alpha10 2009-12-09 00:16:17 +11:00
Stefan Metzmacher
dd650edff2 s4:selftest: skip SMB2-ACLS for now
metze
2009-12-08 13:50:16 +01:00
Stefan Metzmacher
33ecfb05a4 s4:selftest: run RAW-STREAMS again
metze
2009-12-08 13:50:16 +01:00
Stefan Metzmacher
d3d2e3988f RAW-STREAMS: convert failing tests to torture api
This is needed as we want to mark failing tests as
known failures.

metze
2009-12-08 13:50:15 +01:00
Günther Deschner
5e8e5dfe88 s4-smbtorture: make level 8 the reference for PrinterDriverEnum test.
Guenther
2009-12-08 11:51:09 +01:00
Günther Deschner
35c067782b s4-smbtorture: fill in COMPARE_STRING_ARRAY macro in spoolss driver test.
Guenther
2009-12-08 10:37:13 +01:00
Stefan Metzmacher
ed5c3372de s4:selftest: use ${selftest_prefix} instead of hardcoded st/
metze
2009-12-08 09:19:35 +01:00
Andrew Tridgell
52083a8547 s4-selftest: show the test summary at the end of 'make test' in the build farm
This should make it easier to see what tests are failing with what
parameters
2009-12-08 15:59:10 +11:00
Andrew Tridgell
29c87ef830 s4-heimdal: fixed a use-after-free heimdal bug
This caused samba4kinit to segfault on some systems
2009-12-08 15:16:13 +11:00
Andrew Tridgell
cc9d4d5181 s4-drs: use -r to ldbdel in unvampire devel script
This ensures we delete any nTDSConnection objects
2009-12-08 14:43:50 +11:00
Andrew Tridgell
ff984cdfac s4-ldb: fixed ldbdel with -r (recursive deletion)
We need to delete the deepest DNs first
2009-12-08 14:43:50 +11:00
Andrew Bartlett
b2d8e1118d s4:build Bump ldb and tdb required versions.
Hopefully this will ensure we don't get an older version from the system.
2009-12-08 14:07:45 +11:00
Tim Prouty
1bf825b6f8 s4 torture: Cleanup RAW-ACLS a bit
Don't check SEC_DESC_DACL_AUTO_INHERITED right now
Disable RAW-ACLS-INHERITFLAGS for the short term
Update samba4's knownfail accordingly
2009-12-07 17:59:28 -08:00
Andrew Tridgell
978dc61b56 s4-selftest: don't consider spoolss failures to be an error in s4 2009-12-08 12:39:11 +11:00
Kamen Mazdrashki
f1d9382b18 s4/smbstreams: Fix memory use after free.
The bug is that sometimes 'streams' is parent for 'new_name'.
With this said, 'new_name' must be dupped before 'streams'
pointer is freed.

Signed-off-by: Andrew Tridgell <tridge@samba.org>
2009-12-08 12:39:11 +11:00
Kamen Mazdrashki
bf7cc3262e krb5: Fix leaked hx509_context pointer
Signed-off-by: Andrew Tridgell <tridge@samba.org>
2009-12-08 12:39:10 +11:00
Tim Prouty
105eb95a57 s4 quicktest: exclude raw-streams from quicktest until bug is fixed 2009-12-07 16:54:17 -08:00
Tim Prouty
f717a79eff s4 torture: Add a new torture:hide_on_access_denied parameter
It appears some newer versions of windows return
NT_STATUS_OBJECT_NAME_NOT_FOUND on a createfile when access is denied
rather than NT_STATUS_ACCESS_DENIED.  I'm not sure how this translates
to directory enumeration yet, but for now make this a parameter that
can be checked in the various torture tests.

This also gets RAW-ACLS and SMB2-CREATE passing against win7.
2009-12-07 16:54:17 -08:00
Tim Prouty
f4aa47b5ab s4 torture: win 7 doesn't like the sequential_only flag for directories
Remove it for now
2009-12-07 16:54:16 -08:00
Zack Kirsch
d252d23ff1 s4 torture: Port RAW-ACLS tests to SMB2
- The smblsa calls had to be commented out for now and should be fixed
  later, but they aren't crucial to the test.
- The first two tests from RAW-ACLS were already ported to
  torture_smb2_setinfo() and test_create_acl(). Modifications were
  made similar to the RAW-ACLS changes.
- test_sd_get_set() was ported, but does not pass against XP or Vista;
  it is not added to the SMB2-ACLS test suite.
- printf -> torture_comment / torture_warning / torture_result
2009-12-07 16:54:16 -08:00
Zack Kirsch
8ceb428c55 s4 torure: Add SMB2 utility functions
- Add a torture_setup_dir() equivalent in SMB2, called smb2_util_setup_dir().
- Add verify_sd() and verify_attrib() helper functions for SMB2.
2009-12-07 16:54:16 -08:00
Zack Kirsch
1724273ab9 s4 torture: RAW-ACL Improvements
- Change RAW-ACLS test suite so each test can be run individually.
- Add verify_sd() and verify_attrib() helper functions.
- Change test_nttrans_create() to work for both files and directories.
- Fix a segfault in test_inheritance() when the test errors out early.
- test_sd_get_set() does not pass against XP or Vista, so it is no longer added
  to the RAW-ACLS test suite.
- Minor fixes to test_inheritance().
- New INHERITFLAGS test, which tests the auto inheritance flags a bit more.
- printf -> torture_comment / torture_warning / torture_result
2009-12-07 16:54:16 -08:00
Tim Prouty
919440a2aa s4 torture: Convert RAW-STREAMS to a set of test suites rather than a monolithic test 2009-12-07 16:52:16 -08:00
Tim Prouty
6bc8a2bf0a s4 torture: Update RAW-RENAME to pass against win7 2009-12-07 16:52:15 -08:00
Tim Prouty
cd72301efa s4 torture: Add a new RAW-STREAMS test to simulate the summary tab 2009-12-07 16:52:15 -08:00
Tim Prouty
5d66d43667 s4 torture: Fix the streams create disposition tests to actually return an error on failure 2009-12-07 16:52:15 -08:00
Steven Danneman
47f5aac39d s4/torture: add test for zero byte read contention with byte range locks 2009-12-07 16:10:25 -08:00
Steven Danneman
995b4800f8 s4/libcli: add define for exclusive lock mode 2009-12-07 16:10:24 -08:00
Steven Danneman
b4c72e44a8 s4/torture: fix >80 column spacing issues 2009-12-07 16:10:24 -08:00
Aravind Srinivasan
0c42d65d7c s4/torture: add delete-on-close test for directories
This test opens a directory with delete on close, opens it again,
and checks to make sure that the second open returned with
NT_STATUS_DELETE_PENDING.
2009-12-07 16:10:24 -08:00
Günther Deschner
8de6f7178c s4-smbtorture: disable some spoolss printerdata tests which s3 does not pass at the moment.
Guenther
2009-12-07 14:42:13 +01:00
Günther Deschner
123d8d1c2c s4-smbtorture: fix RPC-SPOOLSS after _spoolss_SetPrinterDataEx IDL change.
Guenther
2009-12-07 14:42:13 +01:00
Andrew Bartlett
9b0780cf00 s4:dsdb Use ldb_match_msg_objectclass in operational.c
This avoids not only a possibly non-portable compiler expression, but
also the need to look up the schema each time.

Andrew Bartlett
2009-12-07 15:28:51 +11:00
Andrew Bartlett
54ea4b17f0 s4:ldb Add a function to match a message against an objectClass
(as objectClass will always be a case insensitive ascii string, we can
make a much simpler match function here than for the general case).

Andrew Bartlett
2009-12-07 15:27:43 +11:00
Andrew Bartlett
b2db28b634 s4:ldap.py Improve testsuite for primaryGroupToken behaviour
This tries to show that the domain object should not have a
primaryGroupToken, for example.  (This passes against the old and new
code, as the failure case requires an object with an objectSid, and
exactly one group in it's subtree.  Sadly I don't know of a valid structure
that I can construct to test this).

Andrew Bartlett
2009-12-07 13:08:06 +11:00
Andrew Bartlett
354b80b3ae s4:dsdb Make primaryGroupToken calculation more efficient and correct
The original code here would do a subtree search under each object,
attempting to determine if it was a group.  This was incorrect, and
inefficient - we just need to ask for the objectClass attribute, and
check that value before returning the group's RID.

(Much of this patch reworks operational.c to allow a search for 2
attributes for this calculation).

Andrew Bartlett
2009-12-07 13:07:56 +11:00
Andrew Bartlett
45cd4c93fb s4:dsdb Make parentGUID handler use dsdb_module_search_dn()
This avoids doing a new search from the top of the module stack.

This also removes the helper function dsdb_find_parentguid_by_dn()
which is now unused.

Andrew Bartlett
2009-12-07 13:07:03 +11:00
Andrew Bartlett
a4725f5880 s4:build torturedir and -DTORTUREDIR is unused
(And made building RPMs much more difficult for JHT)
2009-12-07 13:07:03 +11:00
Andrew Bartlett
972ee4b97b s4:dsdb Hide the LM password by default too 2009-12-07 13:07:03 +11:00
Kamen Mazdrashki
9b265a68cc s4-ldif: Fix memory leek in ldb_ldif_write() 2009-12-05 16:57:40 -05:00
Jeremy Allison
1d3942c534 Make smbtorture4 match Windows behavior.
Jeremy.
2009-12-04 14:02:52 -08:00
Günther Deschner
02fe863039 s4-smbtorture: heavily expand printerdata tests in RPC-SPOOLSS.
Including new tests for:
- spoolss_SetPrinterDataEx
- spoolss_DeletePrinterDataEx
- spoolss_DeletePrinterKey

Guenther
2009-12-04 12:55:52 +01:00
Andrew Tridgell
be78d4a70d s4-ldb: fixed show_deleted module not to corrupt parse trees
The show_deleted module was using a static private ptr in the module
to hold a parse tree to save on parsing. The code caused this
static ptr to change with each search, which caused incorrect
searches and numerous valgrind errors.

This patch replaces it with a hand-built parse tree.
2009-12-04 17:49:19 +11:00
Andrew Tridgell
ced3eef776 s4-drsutil: fixed a memory leak in samdb_search_count
In general functions that don't return any memory should not take a memory context.
Otherwise it is too easy to have a bug like this where memory is leaked
2009-12-04 17:49:19 +11:00
Zachary Loafman
4f6d5d0b86 s4 torture: Convert create_complex_file to use BASIC_INFO instead of deprecated command
Signed-off-by: Tim Prouty <tprouty@samba.org>
2009-12-03 20:46:29 -08:00
Zachary Loafman
3507350ad2 s4 torture: Fix call to smbcli_open
Signed-off-by: Tim Prouty <tprouty@samba.org>
2009-12-03 20:46:29 -08:00
Zachary Loafman
a3df55b26f s4 torture: Make RAW-SEARCH pass against win7
Signed-off-by: Tim Prouty <tprouty@samba.org>
2009-12-03 20:46:25 -08:00
Zachary Loafman
2dc5bd19d4 s4 torture: Parameterize WRITE_AND_CLOSE support
Signed-off-by: Tim Prouty <tprouty@samba.org>
2009-12-03 20:21:22 -08:00
Zachary Loafman
f26a500d9f s4 torture: Add lockread_supported based off of CAP_LOCK_AND_READ
Signed-off-by: Tim Prouty <tprouty@samba.org>
2009-12-03 20:21:22 -08:00
Zachary Loafman
5882282dea s4 torture: Allow READ to be parameterized, add more readx tests
Signed-off-by: Tim Prouty <tprouty@samba.org>
2009-12-03 20:21:22 -08:00
Zachary Loafman
60d9828ade s4-torture: Allow the legacy DENY_FCB/DENY_DOS share modes to be ignored
Signed-off-by: Tim Prouty <tprouty@samba.org>
2009-12-03 19:07:54 -08:00
Tim Prouty
5c857768d1 s4 selftest/quicktest: Update known failures for the sfileinfo and oplock changes
Two new samba4 bugs have been filed for the two corresponding known
failures.  For the short term raw.sfileinfo had to be removed from
quicktest.  It is no longer an individual test, but a test-suite and
quicktest can only run top level tests.
2009-12-03 18:54:52 -08:00
Tim Prouty
15e1c61027 s4 torture: Add a new RAW-OPLOCK test: BATCH26
Try a rename with a wide-open share mode on an already open file
and the there is still share mode contention.  For the reason why
see:

http://social.msdn.microsoft.com/Forums/en-US/os_fileservices/thread/3ca14dc9-da1f-4786-a8f7-a86e9903db0c

Msft's anser:

   After further review, The reason for server to fail with sharing
   violation is that the windows server that executes a path-based
   rename request opens the file for DELETE access, but only with
   FILE_SHARED_READ as ShareAccess .  Therefore, the existing
   open(frame 76), which has shared read/write/delete , is compatible
   with the Windows servers access mode (DELETE), but Windows servers
   open is not compatible with access mode in existing open.

   Note that it is correct to state that the logic in Windows server
   could have been written to allow shared read/write/delete in which
   case it would succeed as you mention. The behavior here is
   historical based on the existing implementation.
2009-12-03 18:54:52 -08:00
Tim Prouty
8f7e5732ef s4 torture: Close the third handle in RAW-OPLOCK-BATCH22 2009-12-03 18:54:52 -08:00
Tim Prouty
522d6bc588 s4 torture: Convert an error to a warning in RAW-OPLOCK-BATCH22
Some servers choose to mark a client as bad if they fail an oplock
break request by timing out (win7 is an example).  Once the client is
marked as bad, future oplock requests will timeout instantly.  This
causes subsequent runs of this test to fail, so rather than erroring
out as a failure, a warning is printed instead.

There is also a bug in w2k3 where it was incorrectly returning
contending a share mode lock.  It worked in XP and has been re-fixed
in win7.

This can also now be run against samba3.
2009-12-03 18:54:52 -08:00
Tim Prouty
b14da4f7c5 s4 torture: Add a few more windows target types 2009-12-03 18:54:52 -08:00
Tim Prouty
fc7832602d s4 torture: Convert to a more modern version of read in RAW-OPLOCK-BATCH4 2009-12-03 18:54:52 -08:00
Tim Prouty
af8b7857ca s4 torture: Allow some implementations to break from level1 to none with two breaks 2009-12-03 18:54:52 -08:00
Günther Deschner
2f0548fd98 s4-smbtorture: check more WERRORs in RPC-SPOOLSS.
Guenther
2009-12-03 23:48:59 +01:00
Günther Deschner
4e20a6f83b s4-smbtorture: call test_EnumPrinterDrivers with architecture in RPC-SPOOLSS.
Guenther
2009-12-03 22:16:24 +01:00
Matthias Dieter Wallnöfer
80e066112c s4:operational LDB module - Fix usage of LDB constants 2009-12-03 12:51:16 +01:00
Matthias Dieter Wallnöfer
fed6ac05d0 s4:ntvfs/posix/pvfs_streams - Fix "discard const" warning
I removed one "const" in front of a string declaration to achieve this.

Signed-off-by: Andrew Tridgell <tridge@samba.org>
2009-12-03 21:46:31 +11:00
Matthias Dieter Wallnöfer
1a855eb741 s4:ntvfs/posix/pvfs_resolve - Fix "discard const" warning
I removed two "const"s in front of string declarations to achieve this.

Signed-off-by: Andrew Tridgell <tridge@samba.org>
2009-12-03 21:46:31 +11:00
Steven Danneman
76be0f6a11 s4/selftest: knownfail some locking tests until bugs are fixed 2009-12-02 17:55:34 -08:00
Steven Danneman
48358b3eaa s4/torture: add multiple lock cancel test
See what happens when we have multiple outstanding lock requests and
we try to cancel both of them within a single LockingAndX.

On Windows, it seems only the first lock in the array is cancelled,
and the second is left pending.  Though, this behavior goes against
the MS-CIFS spec.
2009-12-02 17:28:52 -08:00
Steven Danneman
ad9c5a7b88 s4/torture: add addition multiple lock tests
* test that 2 locks in a single LockAndX are transactional
* test that 1 unlock and 1 lock in a single LockAndX are not
  transactional
* test that SMB2 doesn't like mixed lock/unlock in a single
  PDU
2009-12-02 17:28:52 -08:00
Steven Danneman
dfbb92e2a1 s4/torture: fix build warnings by removing unecessary const 2009-12-02 17:28:51 -08:00
Steven Danneman
438b7c41ae s4/torture: Add target functionality parameters to SMBv1 BRL tests
Abstract the server requirements to pass some BRL tests.

* The new default for >64bit lock tests, is that the server should
  return STATUS_INVALID_LOCK_RANGE.
* Add parameter for targets that don't implement DENY_DOS
2009-12-02 17:28:51 -08:00
Günther Deschner
450211b610 s4-smbtorture: be very strict in checking spools_EnumPrinterKey results.
Guenther
2009-12-03 01:04:02 +01:00
Andrew Tridgell
8d7a43fed7 s4-drs: fixed UDV and overlapping sync calls in DRS
When windows abandons a DRS sync, it will sometimes re-use the same bind handle for
a new sync. This means we need to check the DN of the sync and blank the getnc_state
if the DN has changed.

This also fixes the UDV to use the highest uSN for the partition, not for
the whole SAM.
2009-12-03 10:27:59 +11:00
Andrew Tridgell
b65b88740c s4-drs: fixed updating of uSNChanged in replmd_modify
Updating of uSNChanged broke in a recent change
2009-12-03 10:27:59 +11:00
Günther Deschner
5f60855ba2 samba-spoolss: use spoolss_StringArray2 in spoolss_EnumPrinterKey.
This should finally resolve the endian issues we were seeing on sparc and is
much cleaner for spoolss clients and servers.

Guenther
2009-12-02 14:56:17 +01:00
Tim Prouty
4e8b6c5992 s4 torture: Change oplock to use passthrough for exclusive3/batch11
In light of the INVALID_LEVEL that is seen for RAW_SFILEINFO_END_OF_FILE_INFO
requests on a path, I'm changing these back to using the passthrough
RAW_SFILEINFO_END_OF_FILE_INFORMATION to test the oplock break behavior as
originally intended
2009-12-01 11:12:51 -08:00
Tim Prouty
5035a90005 s4 torture: Update RAW-SFILEINFO-END-OF-FILE to test some additional corner cases
It turns out setting the end-of-file with Trans2SetPathInfo using the
snia spec's info level will attempt to open the file, enforcing share
modes, but then subsequentlys fail the setpathinfo with a dos error of
INVALID_LEVEL.  Doing a Trans2SetFileInfo with either end-of-file info
level succeeds as expected.
2009-12-01 11:12:51 -08:00
Tim Prouty
5a934fd8da Revert "s4 torture: Allow onefs to be checked like samba3 and samba4"
This reverts commit 98f595036e.

No longer necessary
2009-12-01 11:12:51 -08:00
Tim Prouty
66bf780e6e s4 torture: Change RAW-SFILEINFO-END-OF-FILE to check for share modes by default
Since the windows behavior appears to be a bug, only check for
the windows-style share mode bug if target=<windows variant> is
specified
2009-12-01 11:12:51 -08:00
Tim Prouty
2738e31674 s4 torture: Move target macros to a common header instead of redefining them in multiple files 2009-12-01 11:12:51 -08:00
Matthias Dieter Wallnöfer
2d1bd87f73 s4:torture/raw/lock - Fix "discard const" warnings by introducing "discard_const_p"s 2009-12-01 16:48:47 +11:00
Matthias Dieter Wallnöfer
262d26d05a s4:torture/nbt/wins - Add more casts 2009-12-01 16:48:38 +11:00
Matthias Dieter Wallnöfer
58a5e764a9 s4:torture/nbench/nbench - Add a cast before "str_list_make_shell" 2009-12-01 16:48:22 +11:00
Matthias Dieter Wallnöfer
8b4499942e s4:torture/ldap/ldap_sort - Add some casts to suppress warnings 2009-12-01 16:48:14 +11:00
Matthias Dieter Wallnöfer
7be99d3735 s4:schema - Make some more (result) variables const and fix up warnings with "discard_const_p" 2009-12-01 16:48:02 +11:00
Endi S. Dewata
9ce7e9ab84 s4:kdc - Merged kdc_tcp_accept() and kpasswdd_tcp_accept().
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
2009-12-01 16:41:02 +11:00
Endi S. Dewata
0c89a6f2aa s4:kdc - Merged kdc_add_kdc_socket() and kdc_add_kpasswd_socket().
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
2009-12-01 16:40:57 +11:00
Endi S. Dewata
bd17df71b5 s4 - Create default modules directory.
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
2009-12-01 16:40:52 +11:00
Endi S. Dewata
c93fc3a10a s4:kdc - Disable KDC port when it's set to 0.
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
2009-12-01 16:40:44 +11:00
Andrew Bartlett
183ea8220a Merge commit 'origin/master' into abartlet-devel 2009-12-01 16:12:53 +11:00
Andrew Bartlett
d58413d331 On our way to Samba4 alpha10! 2009-12-01 16:06:59 +11:00
Andrew Bartlett
ca2c645156 Fix build of Samba4 from tarball generated by mkrelease.sh
Revert "Remove RFC's from the release tarballs to make the lives of the Debian"

This reverts commit eda7f35bc8.

These files are essential to the Samba4 build.

Andrew Bartlett
2009-12-01 14:43:55 +11:00
Andrew Tridgell
83c106e084 s4-ldb: the '1' form of extended_dn search is easier to read
The '1' form gives GUIDs and SIDs in the ascii form as normally used
for display.
2009-12-01 12:36:23 +11:00
Andrew Bartlett
5203128130 This is alpha9 2009-12-01 12:27:09 +11:00
Andrew Bartlett
a88f086d96 s4:setup Adjust upgradeprovision blackbox test now we don't have --targetdir 2009-12-01 12:17:56 +11:00
Matthieu Patou
1d0d78ab3d s4: Remove targetdir as it can cause some trouble and can be replaced by an adapted -s smb.conf
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
2009-12-01 12:17:52 +11:00
Matthieu Patou
fe1291227f s4: Handle the case in secrets.ldb without name attribute
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
2009-12-01 12:17:46 +11:00
Matthieu Patou
4861ad57fb s4: don't forget to update defaultSecurityDescriptor
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
2009-12-01 12:17:41 +11:00
Matthieu Patou
bf2c1e9c4f s4: load the domain level of the current provision and create a provision with the same domain level
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
2009-12-01 12:17:32 +11:00
Andrew Bartlett
f65360840a s4:ldap.py Add test of namingContext behaviour after tridge found a bug
Tridge found that the partitions.c module was being initialised twice,
and setting the partitions into the rootDSE twice.

Andrew Bartlett
2009-12-01 12:17:00 +11:00
Volker Lendecke
6aef5e591f Fix bug 6546: Avoid accessing buf[-1] if NUL byte comes from fgets 2009-11-30 21:48:59 +01:00
Fernando J V da Silva
7399c04fd0 s4-drs: Test situations for runtime constructed parentGUID
Includes the following verifications for the constructed parentGUID:
- Checks if it returns nothing when there is no parent object
- Ensures that attributes mentioned after the parentGUID
are returned correctly (this avoid a bug pointed out by Tridge
during sync constructed parentGUID development)

Signed-off-by: Andrew Tridgell <tridge@samba.org>
2009-11-30 21:17:28 +11:00
Fernando J V da Silva
71e29cbf56 s4-drs: Using dsdb_msg_add_guid() utility function
Uses the dsdb_msg_add_guid() to add any kind of GUID attribute
to a ldb_message in several places of samba4 code.

Signed-off-by: Andrew Tridgell <tridge@samba.org>
2009-11-30 21:17:27 +11:00
Crístian Deives
1cf48022af s4-drs: add deletion of old connections
the nTDSConnection objects that are not needed anymore will be deleted.
the function kccsrv_delete_connection wasn't tested yet.

Signed-off-by: Andrew Tridgell <tridge@samba.org>
2009-11-30 20:22:13 +11:00
Crístian Deives
bed9efa6cd s4-ldb: changed ldb_msg_add_dn() to ldb_msg_add_linearized_dn()
this makes the usage clearer

Signed-off-by: Andrew Tridgell <tridge@samba.org>
2009-11-30 20:22:13 +11:00
Crístian Deives
7ca2ceb333 s4-drs: Create connection obejct (nTDSConnection)
create nTDSConnection objects to match the list of servers

Signed-off-by: Andrew Tridgell <tridge@samba.org>
2009-11-30 20:22:13 +11:00
Andrew Tridgell
8331b4c4f8 s4-ldb: check for -ve value for page size
This comes from a tip from Howard Chu. Apparently some clients
will send a -ve page size value.
2009-11-30 18:15:31 +11:00
Andrew Tridgell
a5e0f433de s4-dsdb: don't call ldb_next_init() twice in objectclass module 2009-11-30 16:49:36 +11:00
Matthias Dieter Wallnöfer
51bedf9395 lib/registry/util.c - Reorder the registry datatypes of the conversion functions
This is absolutely cosmetic and makes the code easier to comprehend.
2009-11-29 14:58:41 +01:00
Matthias Dieter Wallnöfer
df1d42fc1b Revert "s4:registry/util - Don't include the trailing '\0' in the internal data format but add it on the back-conversion to a string"
This reverts commit 7d400715e9.

"convert_string_talloc_convenience" does always add the NULL termination. Didn't
know that. Thanks Jelmer for pointing out!
2009-11-29 14:51:50 +01:00
Matthias Dieter Wallnöfer
b973c50836 s4:upgrade_from_s3 - Move it back to "setup"
Suggested by Jelmer
2009-11-28 19:25:12 +01:00
Matthias Dieter Wallnöfer
f0686645a9 s4:setup/provision - Rework
- Revert change in "ask" - was previously correct
- Readd accidentally removed checks for non-null realm and domainname
- On interactive mode perform only one "ask" call per question
- Inform the user about the unset administrator password
2009-11-28 18:59:33 +01:00
Matthias Dieter Wallnöfer
3ca61d9a01 s4:upgrade.py - remove my copyright
First I wanted to add also other changes but then I didn't introduce them.
Therefore remove my copyright again.
2009-11-28 18:50:27 +01:00