summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* s4-dsdb: Add/Update SCHEMA_SEQ_NUM key in the metadata.tdb after schemaUpdateNowMatthieu Patou2012-06-224-2/+43
| | | | | The idea is to signal to other process accessing the database that the schema was forced to be reloaded and so they should reload as well.
* s4-drs: if schema has changed during replication notify other process that ↵Matthieu Patou2012-06-221-0/+55
| | | | they have to reload the schema
* s4-dsdb: move schema_load at the top of module stackMatthieu Patou2012-06-221-1/+1
|
* s4-extended: do not try to fix if there is no schemaMatthieu Patou2012-06-221-0/+4
|
* s4-schema: keep track of the timestamp of the most recently changed/created ↵Matthieu Patou2012-06-223-1/+13
| | | | object
* s4-schema: generalized time use its own syntax nowMatthieu Patou2012-06-221-1/+0
|
* ldb: lay foundation for proper utc/generalized time handlingMatthieu Patou2012-06-223-5/+42
| | | | | | | We use to handle UTCtime and generalized time the same way. The thing is that it's not the case, they are different in the way they are set (most of the time) with different format and also stored and return in different format too.
* s4-drsuapi: Fix a const warningMatthieu Patou2012-06-221-1/+1
|
* s4-drsuapi: rework the crackname implementation of functionnal namesMatthieu Patou2012-06-221-24/+122
|
* s4-dsdb-linkedattributes: register the VERIFY_NAME control, handle it when ↵Matthieu Patou2012-06-221-10/+97
| | | | | | | | | we are a GC In theory when presented this control and not a GC we should use the specified name as the DC to contact for cross-domain link verification. But for the moment we don't support this so we just fail when we have this control and are not a GC.
* s4-ldap: handle VERIFY_NAME control encoding/decodingMatthieu Patou2012-06-221-0/+96
|
* ldb: add the VERIFY_NAME controlMatthieu Patou2012-06-222-0/+68
|
* s4-dsdb: support otherWellKnownObjectsMatthieu Patou2012-06-221-24/+31
|
* s4-dsdb: Try to avoid much of the time a db search for msDS-IntIDMatthieu Patou2012-06-223-14/+97
| | | | | | | | | | | We search in the schema if we have already this intid (using dsdb_attribute_by_attributeID_id because in the range 0x80000000 0xBFFFFFFFF, attributeID is a DSDB_ATTID_TYPE_INTID). If so generate another random value. If not check if the highest USN in the database for the schema partition is the one that we know. If so it means that's only this ldb context that is touching the schema in the database. If not it means that's someone else has modified the database while we are doing our changes too (this case should be very bery rare) in order to be sure do the search in the database.
* dsdb-schema: do not reload more often than schema_reload_intervalMatthieu Patou2012-06-225-4/+65
| | | | | | | | | | | | | Samba 4 use to try to reload the schema every time dsdb_get_schema was called (which could be 20+ time per ldb request). Now we only reload at most every xx seconds (xx being the value of dsdb:"schema_reload_interval" or 120). The timestamp of the last reloaded schema is kept in the dsdb_schema object. There is also a timestamp in the ldb_context, that is used by the LDAP server to know if it has to reload the schema after handling the request. This is used to allow that the schema will be immediately reload after a schemaUpdateNow request has been issued, the reload can't occur in the handling of the LDAP request itself because we have a transaction autostarted.
* s4-dsdb: fix a warning about unused variableMatthieu Patou2012-06-221-3/+0
|
* s3: Correct documentation of case sensitiveOlaf Flebbe2012-06-221-1/+1
| | | | | | | this fixes bug #8552 Autobuild-User(master): Björn Jacke <bj@sernet.de> Autobuild-Date(master): Fri Jun 22 21:59:59 CEST 2012 on sn-devel-104
* s3-vfs_gpfs: Fix bug #9003, posix acl on gpfsVolker Lendecke2012-06-221-2/+2
| | | | | | | | | | | | | gpfs2smb_acl can leave errno!=0 around even if it returned a correct result!=NULL. We can only rely on errno being set if another error condition (in this case result==NULL) indicates an error. If result!=NULL, errno is undefined and can be anything. This leads to SAFE_FREE(result) further down even in the success case. Signed-off-by: Stefan Metzmacher <metze@samba.org> Autobuild-User(master): Stefan Metzmacher <metze@samba.org> Autobuild-Date(master): Fri Jun 22 19:27:39 CEST 2012 on sn-devel-104
* s3: Give machine password changes 10 minutes of timeVolker Lendecke2012-06-221-0/+13
| | | | | | | This is what we do at domain join time as well, see lib/netapi/joindomain.c:141 Signed-off-by: Stefan Metzmacher <metze@samba.org>
* s3:torture:smb2: pass smb2-session-reconnect test (add generosity in error case)Michael Adam2012-06-221-7/+21
| | | | | | | | samba checks tree before file, so we get a STATUS_NETWORK_NAME_DELETED instead STATUS_FILE_CLOSED when operating on a file handle on a invalid tree id. Signed-off-by: Stefan Metzmacher <metze@samba.org>
* dbwrap: don't ignore the result of dbwrap_parse_record in dbwrap_fetch_int32()Stefan Metzmacher2012-06-221-1/+5
| | | | | | | metze Autobuild-User(master): Stefan Metzmacher <metze@samba.org> Autobuild-Date(master): Fri Jun 22 17:10:52 CEST 2012 on sn-devel-104
* dbwrap: intialize state.status in dbwrap_fetch_int32()Stefan Metzmacher2012-06-221-0/+2
| | | | | | | This might not be needed, but it makes it more clear that we won't use uninitialized memory, it the callback was not triggered. metze
* dbwrap: Convert fetch_int32 to dbwrap_parse_recordVolker Lendecke2012-06-221-13/+24
| | | | | | | Now dbwrap_fetch_int32 is used in smbd/locking/posix.c is used a lot more often than before. Signed-off-by: Stefan Metzmacher <metze@samba.org>
* s3: Remove reduce_windows_lock_ref_count, used only onceVolker Lendecke2012-06-221-8/+2
| | | | Signed-off-by: Stefan Metzmacher <metze@samba.org>
* s3: Make reduce_windows_lock_ref_count staticVolker Lendecke2012-06-222-2/+2
| | | | Signed-off-by: Stefan Metzmacher <metze@samba.org>
* s3: Use dbwrap_util for windows_lock_ref_countVolker Lendecke2012-06-221-94/+21
| | | | Signed-off-by: Stefan Metzmacher <metze@samba.org>
* dbwrap: Add dbwrap_fetch_int32Volker Lendecke2012-06-222-3/+11
| | | | Signed-off-by: Stefan Metzmacher <metze@samba.org>
* dbwrap: Add dbwrap_change_int32_atomicVolker Lendecke2012-06-222-9/+21
| | | | Signed-off-by: Stefan Metzmacher <metze@samba.org>
* script/autobuild: fix path to random-sleep.shStefan Metzmacher2012-06-221-8/+8
| | | | metze
* selftest/knownfail: mark ^samba4.raw.session.expire1 as knownfailStefan Metzmacher2012-06-221-0/+1
| | | | | Autobuild-User(master): Stefan Metzmacher <metze@samba.org> Autobuild-Date(master): Fri Jun 22 15:03:16 CEST 2012 on sn-devel-104
* s4:torture/raw: add raw.session.expire1Stefan Metzmacher2012-06-221-0/+200
| | | | | | | This demonstrates the interaction of CAP_DYNAMIC_REAUTH and NT_STATUS_NETWORK_SESSION_EXPIRED. metze
* s3:smbd: fix warning in smbd_tevent_trace_callback() without profile supportStefan Metzmacher2012-06-221-0/+5
| | | | metze
* s3:serverid: don't ignore the result of dbwrap_parse_record()Stefan Metzmacher2012-06-221-1/+6
| | | | metze
* s4:torture/smb2: run smb2.session.reauth5 in a subdirectoryStefan Metzmacher2012-06-221-14/+77
| | | | | | | | | This way we can give anonymous full access to the directory. metze Autobuild-User(master): Stefan Metzmacher <metze@samba.org> Autobuild-Date(master): Fri Jun 22 11:30:06 CEST 2012 on sn-devel-104
* tdb: don't use err.h in tests.Rusty Russell2012-06-2221-22/+1
| | | | | | | | | | It's not portable. While we could use ccan/err, it seems overkill since we actually only use it in one test (I obviously cut & paste the #include). Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> Autobuild-User(master): Rusty Russell <rusty@rustcorp.com.au> Autobuild-Date(master): Fri Jun 22 09:22:28 CEST 2012 on sn-devel-104
* tdb: make TDB_NOSYNC merely disable sync.Rusty Russell2012-06-223-15/+20
| | | | | | | | | | | | | | | | (As suggested by Stefan Metzmacher, based on the change to ntdb.) Since commit ec96ea690edbe3398d690b4a953d487ca1773f1c, we handle the case where a process dies during a transaction commit. Unfortunately, TDB_NOSYNC means this no longer works, as it disables the recovery area as well as the actual msync/fsync. We should do everything except the syncs. This also means we can do a complete test with $TDB_NO_FSYNC set; just to get more complete coverage, we disable it explicitly for one test (where we override the actual sync calls anyway). Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
* dbwrap: dbwrap_hash_size().Rusty Russell2012-06-227-0/+12
| | | | | | | Implemented for ntdb and tdb; falls back to 0 for others. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
* dbwrap: dbwrap_name().Rusty Russell2012-06-227-1/+11
| | | | | | | | Useful for debug messages: particularly once we start switching between .tdb and .ntdb files. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
* dbwrap: dbwrap_transaction_start_nonblock().Rusty Russell2012-06-224-0/+26
| | | | | | | | Implemented for ntdb and tdb; falls back to the blocking variant for others. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
* dbwrap: dbwrap_fetch_locked_timeout().Rusty Russell2012-06-224-0/+52
| | | | | | | | Implemented for ntdb and tdb; falls back to the non-timeout variant for others. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
* dbwrap: add dbwrap_check() function.Rusty Russell2012-06-224-0/+31
| | | | | Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
* dbwrap: dbwrap_local_open()Rusty Russell2012-06-226-3/+96
| | | | | | | | This simply opens a tdb: it will eventually switch depending on the extension. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
* dbwrap: remove get_flags().Rusty Russell2012-06-227-49/+2
| | | | | | | | | | | | The flags returned were TDB-specific: this was only used for detecting the endianness of obsolete databases (the conversion code was put in in 2003, with reference to Samba 2.3). It's easier to remove it than to translate the NTDB flags to TDB flags, and it's a really weird thing to ask for anyway. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
* util_tdb: move timeout chainlock variants from source3/lib/util/util_tdb.cRusty Russell2012-06-226-90/+122
| | | | | | | We're about to use them for dbwrap. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
* util: util_ntdb ntdb_fetch_int32/ntdb_store_int32 and ntdb_add_int32_atomicRusty Russell2012-06-222-0/+89
| | | | | | | | | Similar to the util_tdb versions, but return the error code. ntdb_add_int32_atomic seems a clearer name than tdb_change_int32_atomic. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
* util: util_ntdb.c gets NTDB_ERROR => NTSTATUS map.Rusty Russell2012-06-222-0/+49
| | | | | | | Very similar to the tdb version. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
* util: util_ntdb.c gains bystring functions.Rusty Russell2012-06-222-1/+85
| | | | | | | | Very similar to the util_tdb versions, but these return the error. I've only implemented those functions actually used. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
* util: ntdb_new() supports NTDB_CLEAR_IF_FIRST.Rusty Russell2012-06-222-1/+99
| | | | | | | | | There are various issues with NTDB_CLEAR_IF_FIRST which makes it better if we don't have to use it, but much of the code does, so we fake up support here. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
* util: util_ntdb.cRusty Russell2012-06-223-0/+168
| | | | | | | | | | | | | | The first function is ntdb_new: this is preferred over ntdb_open, as it makes the ntdb_context returned (and all NTDB_DATA returned from ntdb_fetch) valid talloc pointers. The API is very similar to tdb_wrap_open(). Note that we handle $TDB_NO_FSYNC here, since ntdb doesn't do that hack (and it's great for speeding up testing!). Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
* ntdb: take advantage of direct access across expand.Rusty Russell2012-06-221-33/+15
| | | | | | | This means we no longer have to unmap if we want to compare a record. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>