summaryrefslogtreecommitdiff
path: root/source4/dsdb/schema/schema_syntax.c
AgeCommit message (Collapse)AuthorFilesLines
2013-09-26dsdb: Convert the full string from UTF16 to UTF8, including embedded NULLsAndrew Bartlett1-1/+1
Bug: https://bugzilla.samba.org/show_bug.cgi?id=8077 Note that this doesn't fix the userParameters problem completely, but it doesn't truncate the userParameters value anymore. Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org> Autobuild-User(master): Stefan Metzmacher <metze@samba.org> Autobuild-Date(master): Thu Sep 26 22:05:12 CEST 2013 on sn-devel-104
2013-09-22dsdb: Use WERR_DS_ATT_NOT_DEF_IN_SCHEMA for failed schema lookupsAndrew Bartlett1-28/+28
Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
2012-06-22s4-schema: generalized time use its own syntax nowMatthieu Patou1-1/+0
2012-04-29Add some debug for FOOBAR return case as they are hard to diagnoseMatthieu Patou1-0/+3
Autobuild-User: Matthieu Patou <mat@samba.org> Autobuild-Date: Sun Apr 29 09:08:15 CEST 2012 on sn-devel-104
2011-10-12s3:utils change data_blob_dup_talloc() to take a DATA_BLOB by valueGregor Beck1-2/+2
Signed-off-by: Michael Adam <obnox@samba.org>
2011-08-25s4-dsdb: fixed calls to ldb_val_string_cmp()Andrew Tridgell1-2/+2
wrong order of arguments
2011-08-09s4-dsdb: fixed booling conversion to check value lengthAndrew Tridgell1-11/+14
this ensures we don't look past the end of the data Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2011-08-09s4-dsdb: add auto-normalisation of attributesAndrew Tridgell1-3/+9
this auto-normalises some attributes when they are added/modified. The list that we auto-normalise is currently: Boolean INT32 INTEGER UTC_TIME This fixes a problem with groupType being stored in an unnormalised form Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2011-07-13dsdb: fixed special case of zero NTTIMEAndrew Tridgell1-0/+20
we can't convert 0 NTTIME via a unix time_t Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2011-06-22s4-schema: avoid segfaulting if id3.guid is NULLMatthieu Patou1-2/+1
2011-06-22s4-dsdb: don't add zero GUID to BINARY_DNAndrew Tridgell1-9/+11
When converting from DRS to ldb format for a BINARY_DN, don't add the GUID extended DN element if the GUID is all zeros. Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2011-06-17s4-dsdb: if we don't have a remote schema, then use the local oneAndrew Tridgell1-2/+8
this allows the use of drsuapi_to_ldb() on all attributes for the local database
2011-04-07dsdb:schema/schema_syntax.c - correctly check error code of ↵Matthias Dieter Wallnöfer1-2/+1
"ldb_string_utc_to_time" This one doesn't set ERRNO. An error happens if the result is "0". Reviewed-by: abartlet
2011-04-07dsdb:schema/schema_syntax.c - add some empty value checks on validate functionsMatthias Dieter Wallnöfer1-0/+9
They are needed since the check in "ldb_msg_sanity_check" will be removed. Reviewed-by: abartlet
2011-03-29Ensure convert_string_XXX is always called with a valid converted_size pointer.Jeremy Allison1-2/+4
Preparation for cleaning up this API. Autobuild-User: Jeremy Allison <jra@samba.org> Autobuild-Date: Tue Mar 29 21:01:49 CEST 2011 on sn-devel-104
2011-03-24charcnv: removed the allow_badcharcnv and allow_bad_conv options to ↵Andrew Tridgell1-5/+5
convert_string*() we shouldn't accept bad multi-byte strings, it just hides problems Autobuild-User: Andrew Tridgell <tridge@samba.org> Autobuild-Date: Thu Mar 24 01:47:26 CET 2011 on sn-devel-104
2011-02-10ldb: use #include <ldb.h> for ldbAndrew Tridgell1-2/+2
thi ensures we are using the header corresponding to the version of ldb we're linking against. Otherwise we could use the system ldb for link and the in-tree one for include Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2010-12-21s4:dsdb/schema/schema_* - adaptions needed for removed "const" on OIDsMatthias Dieter Wallnöfer1-1/+1
2010-12-15s4-dsdb_schema: Handle remote ATTIDs based on msDs-IntId valueKamen Mazdrashki1-4/+17
If we get such an msDs-IntId value, then we should just use it, there is no mapping available for such values
2010-12-15s4-schema_syntax: Log error message when ↵Kamen Mazdrashki1-1/+5
_dsdb_syntax_OID_oid_drsuapi_to_ldb() fails I haven't found a way to test this function during replication so far, but when I do, it will be useful to notice this error in the log file
2010-12-15s4-schema_syntax: We should use make_ATTID function when converting ↵Kamen Mazdrashki1-1/+1
remote-ATTID to local one We may have no prefix for the remote ATTID (remote OID strictly speaking) So this is the place for us to update our local prefixMap adding a prefix for the numeric OID we've recived
2010-12-15s4-schema_syntax: Use remote prefixMap to map remote ATTID to local oneKamen Mazdrashki1-5/+13
in dsdb_attribute_drsuapi_to_ldb() function. drsuapi_DsReplicaAttribute *in parameter come from remote DC so we can't rely on in->attid to map it directly to an dsdb_attribute in our local schema cache
2010-12-02s4-dsdb/syntax: Map remote ATTIDs for Class OID syntaxKamen Mazdrashki1-0/+6
Autobuild-User: Kamen Mazdrashki <kamenim@samba.org> Autobuild-Date: Thu Dec 2 18:47:59 CET 2010 on sn-devel-104
2010-12-02s4-dsdb_syntax: Be a little bit more chatty when we can't an ATTID in our cacheKamen Mazdrashki1-1/+3
2010-12-01s4-dsdb/syntax: Map remote ATTIDs for Attribute OID syntaxKamen Mazdrashki1-0/+6
2010-12-01s4-dsdb/syntax: Implement Remote-ATTID to Local-ATTID mapping functionKamen Mazdrashki1-0/+35
2010-11-11s4-repl: Propagate remote prefixMap in DRSUAPI data conversion functionsKamen Mazdrashki1-0/+2
2010-11-11s4-dsdb_syntax: Warning message that we can't find requested ATTID in Schema ↵Kamen Mazdrashki1-0/+1
Cache
2010-11-11s4-dsdb_syntax: Use remote prefixMap to handle generic cases in ↵Kamen Mazdrashki1-2/+7
drsuapi_to_ldb conversions
2010-11-11s4-dsdb_syntax: Add remote prefixMap member for dsdb_syntax conversionsKamen Mazdrashki1-0/+2
2010-11-01s4-dsdb_schema: Use DRSUAPI_ATTID_INVALID instead of 0xFFFFFFFF magic valueKamen Mazdrashki1-25/+25
Autobuild-User: Kamen Mazdrashki <kamenim@samba.org> Autobuild-Date: Mon Nov 1 00:36:20 UTC 2010 on sn-devel-104
2010-10-31idl: Use DRSUAPI_ATTID_ prefix instead of DRSUAPI_ATTRIBUTE_ for ATTID valuesKamen Mazdrashki1-33/+33
Those values are actually ATTID values and such, they are used for ATTIDs for Attributes, Classes and Syntaxes.
2010-10-26s4-dsdb_syntax: *_OID_oid_ldb_to_drsuapi() functions should useKamen Mazdrashki1-6/+6
dsdb_schema_pfm_attid_from_oid() instead of dsdb_schema_pfm_make_attid() as those functions are supposed to return ATTIDs only for OIDs we already know about (i.e. are in prefixMap) Autobuild-User: Kamen Mazdrashki <kamenim@samba.org> Autobuild-Date: Tue Oct 26 22:44:36 UTC 2010 on sn-devel-104
2010-10-22s4-dsdb_syntax: Setup "String(Case Sensitive)" syntaxKamen Mazdrashki1-3/+10
Currently it is mapped to Octet String LDAP syntax for comparison purposes. According to LDAP rfc we should be using same comparison as Directory String (LDB_SYNTAX_DIRECTORY_STRING), but case sensitive. But according to ms docs binary compare should do the job: http://msdn.microsoft.com/en-us/library/cc223200(v=PROT.10).aspx Autobuild-User: Kamen Mazdrashki <kamenim@samba.org> Autobuild-Date: Fri Oct 22 22:19:50 UTC 2010 on sn-devel-104
2010-10-21s4-dsdb/schema_syntax: Separate validation for numericoid OID valuesKamen Mazdrashki1-3/+47
This implementation doesn't use prefixMap/Schema to validate numericoid OIDs. We may not have this OID yet, so I see no point checking schema for if we have it. Side effect of using prefixMap/Schema for validating numericoids is that we mistakenly add the OID to the prefixMap. This led to a corrupted prefixMap in LDB. Autobuild-User: Kamen Mazdrashki <kamenim@samba.org> Autobuild-Date: Thu Oct 21 23:32:26 UTC 2010 on sn-devel-104
2010-08-19s4-drs: ATTIDs for deleted attributes should be based on msDs-IntId value if ↵Kamen Mazdrashki1-2/+2
it exists
2010-08-19s4-dsdb: No need for dsdb_syntax_one_DN_drsuapi_to_ldb() to be publicKamen Mazdrashki1-3/+3
It is intended to be used in schema_syntax.c module
2010-08-19s4-dsdb-syntax: ATTID should be msDs-IntId value for the attributeSchema objectKamen Mazdrashki1-14/+52
in case object replicated is not in Schema NC and attributeSchema object has msDs-IntId attribute value set
2010-08-19s4: fix few comment typosKamen Mazdrashki1-1/+1
2010-08-19s4-schema_syntax.c: Fix white spaces and alignmentKamen Mazdrashki1-55/+56
2010-08-19s4-dsdb: Use dsdb_syntax_ctx in *_drsuapi_to_ldb functionsKamen Mazdrashki1-53/+38
2010-08-19s4-dsdb: Use dsdb_syntax_ctx in *_ldb_to_drsuapi functionsKamen Mazdrashki1-51/+36
2010-08-19s4-dsdb: Use dsdb_syntax_ctx in *_validate_ldb functionsKamen Mazdrashki1-59/+35
2010-08-19s4-dsdb: Add context structure for dsdb_syntax conversion functionsKamen Mazdrashki1-0/+13
This structure is intended to hold context-dependent data. Syntax-conversion and object-conversion functions need that data to convert objects and attributes from drs-to-ldb and ldb-to-drs correctly. For instance: ATTID value depends on whether we are converting object from partition different that Schema partition.
2010-06-15s4:dsdb Allow the setting an override on the schemaAndrew Bartlett1-6/+20
The change here is to try and convert a per the previous rules, but if we don't know a particular OID as a attributeID, then store it as an OID (for example). This allows known values to be converted as before, but still copes with unknown values. Andrew Bartlett Signed-off-by: Kamen Mazdrashki <kamenim@samba.org>
2010-06-07s4:remove the "validate_update" LDB module - the task is now handled by the ↵Matthias Dieter Wallnöfer1-13/+0
far more complete "objectclass_attrs" LDB module
2010-05-18s3: Remove use of iconv_convenience.Jelmer Vernooij1-2/+1
2010-05-18Finish removal of iconv_convenience in public API's.Jelmer Vernooij1-16/+12
2010-04-22s4-dsdb: added dsdb_get_extended_dn_sid()Andrew Tridgell1-12/+5
This will be used by the RODC code Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2010-03-07s4:schema_syntax.c - Change also here counters to "unsigned" where neededMatthias Dieter Wallnöfer1-44/+44
Counters which are used in the way "for (i = 0; array[i] != NULL; i++)" I modified to "unsigned" since for sure we don't want to have negative array indexes there. There were many counter variables typed "uint32_t". This isn't fully correct since those count LDB objects. The amount is saved in a "num_*" variable which is "unsigned" without a bitlength specification. Therefore change also these counters to be plain "unsigned".