summaryrefslogtreecommitdiffstats
path: root/source4/dsdb/common
Commit message (Collapse)AuthorAgeFilesLines
* Change uint_t to unsigned int in source4Matt Kraai2010-02-021-8/+8
| | | | Signed-off-by: Stefan Metzmacher <metze@samba.org>
* s4-dsdb: add our local cursor and sort in dsdb_load_udv_*()Andrew Tridgell2010-01-161-19/+65
| | | | This makes things much simpler for the callers
* s4-dsdb: added dsdb_load_udv_v2() and dsdb_load_udv_v1()Andrew Tridgell2010-01-161-0/+82
|
* s4-drs: Store uSNUrgent for Urgent ReplicationFernando J V da Silva2010-01-141-5/+23
| | | | | | | | When a object or attribute is created/updated/deleted, according to [MS-ADTS] 3.1.1.5.1.6, it stores the uSNUrgent on @REPLCHANGED for the partitions that it belongs. Signed-off-by: Andrew Tridgell <tridge@samba.org>
* s4:dsdb/common: fix major bug in lsa_BinaryString to ldb_val conversation.Stefan Metzmacher2010-01-131-2/+2
| | | | | | | | In lsa_BinaryString length and size are byte counts! TODO: we may need to do byte order conversion in this functions too... metze
* s4:dsdb/common: let samdb_msg_add_uint() call samdb_msg_add_int()Stefan Metzmacher2010-01-131-2/+1
| | | | | | | This is important as LDAP servers always play with int32 values and we have to encode 0x80000000 as "-2147483648" instead of "2147483648". metze
* s4:dsdb/common: let samdb_msg_add_uint64() call samdb_msg_add_int64()Stefan Metzmacher2010-01-131-2/+1
| | | | | | | | This is important as LDAP servers always play with int64 values and we have to encode 0x8000000000000000LL as "-9223372036854775808" instead of "9223372036854775808". metze
* s4-dsdb: added samdb_domain_sid_cache_only()Andrew Tridgell2010-01-101-1/+8
|
* s4-dsdb: added samdb_ldb_val_case_cmp()Andrew Tridgell2010-01-091-0/+16
|
* s4-drs: added filtering by udv in getncchangesAndrew Tridgell2010-01-091-0/+6
| | | | | | When a client supplied an uptodateness_vector, we can use it to filter what objects we return. This greatly reduces the amount of replication traffic between DCs.
* s4-dsdb: added dsdb_find_guid_attr_by_dn()Andrew Tridgell2010-01-081-5/+18
| | | | Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
* s4-dsdb: added samdb_rid_set_dn()Andrew Tridgell2010-01-081-0/+18
| | | | | | This returns the DN of our RID Set object Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
* s4-dsdb: added samdb_reference_dn()Andrew Tridgell2010-01-081-0/+62
| | | | | | | This returns a 'reference' DN, which is a link to a DN, from the specified object. It is then used by samdb_server_reference_dn() which returns the serverReference DN, and samdb_rid_manager_dn() which returns the rIDManagerReference DN.
* s4-dsdb: switched to using RMD_FLAGS instead of DELETED in extended DNsAndrew Tridgell2010-01-022-7/+46
| | | | This allows for more flags in the future
* s4-dsdb: fixed several memory leaksAndrew Tridgell2010-01-021-5/+18
| | | | need to be careful with those temporary contexts
* s4-dsdb: fixed samdb_create_foreign_security_principal() to use the ↵Andrew Tridgell2010-01-021-18/+20
| | | | | | wellknown GUID This also fixes a memory leak
* s4-dsdb: added dsdb_tombstone_lifetime()Andrew Tridgell2010-01-021-0/+26
|
* s4-dsdb: added dsdb_set_extended_dn_guid()Andrew Tridgell2010-01-021-0/+19
|
* s4-dsdb: added parse functions for DRS linked attribute blobsAndrew Tridgell2010-01-021-0/+69
|
* s4-dsdb: added dsdb_dn_is_upgraded_link_val()Andrew Tridgell2010-01-021-0/+9
| | | | | This is used to detect if a link has been stored in the w2k3 extended format
* s4-dsdb: allow the component name to be specified in dsdb_get_extended_dn_guid()Andrew Tridgell2010-01-021-2/+2
| | | | Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
* s4-dsdb-util: Execute ldb_request using LDB_CONTROL_AS_SYSTEMKamen Mazdrashki2009-12-211-0/+49
| | | | | | | This function is intended to be used when data needs to be modified skipping access checks. Signed-off-by: Andrew Tridgell <tridge@samba.org>
* s4-dsdb-util: Utility function to process ldb_request in transactionKamen Mazdrashki2009-12-211-0/+26
| | | | | | | This function is to be used later for manually crafted ldb_requests from within dsdb layer Signed-off-by: Andrew Tridgell <tridge@samba.org>
* s4-dsdb: added dsdb_get_extended_dn_uint64()Andrew Tridgell2009-12-211-3/+11
|
* s4-dsdb: added two new dsdb_get_extended_dn_*() helper functionsAndrew Tridgell2009-12-211-0/+43
| | | | Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
* s4-dsdb: fixed the sort in dsdb_find_nc_root()Andrew Tridgell2009-12-181-1/+6
|
* s4:"samdb_set_password" - remove delete instructionsMatthias Dieter Wallnöfer2009-12-171-7/+2
| | | | | | | | 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.
* s4:dsdb/common/util - make NTTIME attribute wrappers use a "const" messageMatthias Dieter Wallnöfer2009-12-171-4/+6
| | | | There is no reason to have the message non-const here.
* s4-dsdb: added dsdb_get_deleted_objects_dn()Andrew Tridgell2009-12-161-0/+22
| | | | | | | 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>
* s4-dsdb: added dsdb_find_nc_root()Andrew Tridgell2009-12-161-0/+64
| | | | | | | | | | | 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>
* s4-dsdb: added dsdb_wellknown_dn()Andrew Tridgell2009-12-161-0/+32
| | | | | | This finds a wellknown object given its GUID Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
* s4-dsdb: added dsdb_dn_is_deleted_val()Andrew Tridgell2009-12-161-0/+14
| | | | | | | This is used to determine if a extedned DN has the 'DELETED=1' component Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
* s4-dsdb: return a zero guid on error in samdb_result_guid()Andrew Tridgell2009-12-141-1/+1
|
* s4:"samdb_set_password_sid" - clean up created objects correctlyMatthias Dieter Wallnöfer2009-12-131-2/+14
| | | | | | | - 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")
* s4-dsdb: use GUID_to_ndr_blob()Andrew Tridgell2009-12-101-7/+3
|
* s4-dsdb: simplify samdb_result_guid()Andrew Tridgell2009-12-101-11/+4
|
* s4-dsdb: use GUID_from_ndr_blob() to create dsdb_get_extended_dn_guid()Andrew Tridgell2009-12-101-0/+14
|
* s4-dsdb: added dsdb_functional_level() helper functionAndrew Tridgell2009-12-091-0/+16
|
* s4:dsdb Make parentGUID handler use dsdb_module_search_dn()Andrew Bartlett2009-12-071-58/+0
| | | | | | | | | 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
* s4-drsutil: fixed a memory leak in samdb_search_countAndrew Tridgell2009-12-041-4/+5
| | | | | 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
* s4:dsdb Add function to return the CN=Aggregate schema DNAndrew Bartlett2009-11-241-0/+18
|
* s4/schema: Object(OR-Name) syntax handling for DRS callsKamen Mazdrashki2009-11-232-2/+5
| | | | OR-Name syntax through DRS calls looks like DN-Binary syntax
* s4-drs: Utility functions to deal with GUIDFernando J V da Silva2009-11-201-0/+99
| | | | | | | | dsdb_find_parentguid_by_dn() returns the parentGUID for a given DN dsdb_msg_add_guid() adds a GUID value to a given message (either objectGUID or parentGUID). Signed-off-by: Andrew Tridgell <tridge@samba.org>
* s4:samdb util - add a call for generating a correct "lDAPDisplayName"Matthias Dieter Wallnöfer2009-11-151-0/+28
| | | | | This is needed for the SAMLDB module enhancement regarding schema objects. The algorithm in pseudo code is located in MS-ADTS 3.1.1.2.3.4.
* s4-ldb: changed the DN checks for \n to warningsAndrew Tridgell2009-11-131-3/+6
| | | | | a \n is sometimes allowed in AD (eg in deleted DNs). Until we know when is really is allowed, treat it as a warning only.
* s4:dsdb Add expected value tests for most DRS syntax conversionsAndrew Bartlett2009-11-121-6/+6
| | | | | | | | I've left out those for which I could not find an expected value in my default Windows 2003 server's database, and the values that rely on the current prefix map at the time. Andrew Bartlett
* s4:dsdb Cosmetic fixes found by metze in review of dsdb_dn changesAndrew Bartlett2009-11-121-1/+2
| | | | | | | | These changes include reworking the code to call ldb_module_get_ctx() less often (avoid the function calls, particularly during the step into a complex function). Andrew Bartlett
* s4:dsdb Ensure we allow 'odd' lengths for DN+StringAndrew Bartlett2009-11-121-5/+5
| | | | | | (Found in a code review by metze) Andrew Bartlett
* s4:dsdb Add extensive tests for the behaviour of dsdb_dnAndrew Bartlett2009-11-121-0/+357
|
* s4:dsdb Add new dsdb_dn to handle DN+Binary and DN+StringAndrew Bartlett2009-11-122-0/+340
| | | | | | | This aims to replace (and is based on) the code in ldb_dn.c. It is however much stricter in the DNs it will accept. Andrew Bartlett