summaryrefslogtreecommitdiffstats
path: root/crypto/stack/stack.h
Commit message (Collapse)AuthorAgeFilesLines
* Run util/openssl-format-source -v -c .Matt Caswell2015-01-221-22/+20
| | | | Reviewed-by: Tim Hudson <[email protected]>
* Implement sk_deep_copy.Viktor Dukhovni2014-07-071-0/+1
| | | | (cherry picked from commit 66d884f06770f2daaee8016299ef7e1e3b91dfd1)
* Type-safe OBJ_bsearch_ex.Ben Laurie2008-10-141-5/+4
|
* More type-checking.Ben Laurie2008-06-041-25/+25
|
* Fix race condition when CRL checking is enabled.Dr. Stephen Henson2004-10-041-0/+1
|
* Add an extended variant of sk_find() which returns a non-NULL pointerRichard Levitte2003-04-291-0/+1
| | | | even if an exact match wasn't found.
* Safe stack reorganisation in terms of function casts.Dr. Stephen Henson2000-06-171-3/+1
| | | | | | | | | | | | After some messing around this seems to work but needs a few more tests. Working out the syntax for sk_set_cmp_func() (cast it to a function that itself returns a function pointer) was painful :-( Needs some testing to see what other compilers think of this syntax. Also needs similar stuff for ASN1_SET_OF etc etc.
* This is the first of two commits (didn't want to dump them all into theGeoff Thorpe2000-06-011-5/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | same one). However, the first will temporarily break things until the second comes through. :-) The safestack.h handling was mapping compare callbacks that externally are of the type (int (*)(type **,type **)) into the underlying callback type used by stack.[ch], which is (int (*)(void *,void *)). After some degree of digging, it appears that the callback type in the underlying stack code should use double pointers too - when the compare operations are invoked (from sk_find and sk_sort), they are being used by bsearch and qsort to compare two pointers to pointers. This change corrects the prototyping (by only casting to the (void*,void*) form at the moment it is needed by bsearch and qsort) and makes the mapping in safestack.h more transparent. It also changes from "void*" to "char*" to stay in keeping with stack.[ch]'s assumed base type of "char". Also - the "const" situation was that safestack.h was throwing away "const"s, and to compound the problem - a close examination of stack.c showed that (const char **) is not really achieving what it is supposed to when the callback is being invoked, what is needed is (const char * const *). So the underlying stack.[ch] and the mapping macros in safestack.h have all been altered to correct this. What will follow are the vast quantities of "const" corrections required in stack-dependant code that was being let "slip" through when safestack.h was discarding "const"s. These now all come up as compiler warnings.
* sk_value was also suffering from de-const-ification.Geoff Thorpe2000-05-311-1/+1
| | | | Also, add in a couple of missing declarations in pkcs7 code.
* All the little functions created by the IMPLEMENT_STACK_OF() macro willGeoff Thorpe2000-05-311-1/+1
| | | | | | | | | | | cast their type-specific STACK into a real STACK and call the underlying sk_*** function. The problem is that if the STACK_OF(..) parameter being passed in has a "const *" qualifier, it is discarded by the cast. I'm currently implementing a fix for this but in the mean-time, this is one case I noticed (a few type-specific sk_**_num() functions pass in const type-specific stacks). If there are other errors in the code where consts are being discarded, we will similarly not notice them. yuck.
* Get rid of more non-ANSI declarations.Ulf Möller2000-05-161-4/+4
|
* New options to the -verify program which can be used for chain verification.Dr. Stephen Henson1999-11-261-2/+2
| | | | | | | | Extend the X509_PURPOSE structure to include shortnames for purposed and default trust ids. Still need some extendable trust checking code and integration with the SSL and S/MIME code.
* Another safe stack.Ben Laurie1999-05-301-0/+1
|
* New functions sk_set, sk_value and sk_num to replace existing macros: this isDr. Stephen Henson1999-05-191-2/+8
| | | | to minimise the effects on existing code.
* Remove NOPROTO definitions and error code comments.Ulf Möller1999-04-261-20/+0
|
* Add functions to add certs to stacks, used for CA file/path stuff in servers.Ben Laurie1999-02-281-2/+2
|
* Import of old SSLeay release: SSLeay 0.9.0bRalf S. Engelschall1998-12-211-3/+3
|
* Import of old SSLeay release: SSLeay 0.8.1bRalf S. Engelschall1998-12-211-0/+120