mirror of
https://github.com/QuasarApp/openssl.git
synced 2025-05-10 00:19:40 +00:00
Properties are a sequence of comma separated name=value pairs. A name without a corresponding value is assumed to be a Boolean and have the true value 'yes'. Values are either strings or numbers. Strings can be quoted either _"_ or _'_ or unquoted (with restrictions). There are no escape characters inside strings. Number are either decimal digits or '0x' followed by hexidecimal digits. Numbers are represented internally as signed sixty four bit values. Queries on properties are a sequence comma separated conditional tests. These take the form of name=value (equality test), name!=value (inequality test) or name (Boolean test for truth). Queries can be parsed, compared against a definition or merged pairwise. Reviewed-by: Matt Caswell <matt@openssl.org> Reviewed-by: Tim Hudson <tjh@openssl.org> (Merged from https://github.com/openssl/openssl/pull/8224)
84 lines
3.0 KiB
C
84 lines
3.0 KiB
C
/*
|
|
* Copyright 1995-2019 The OpenSSL Project Authors. All Rights Reserved.
|
|
*
|
|
* Licensed under the Apache License 2.0 (the "License"). You may not use
|
|
* this file except in compliance with the License. You can obtain a copy
|
|
* in the file LICENSE in the source distribution or at
|
|
* https://www.openssl.org/source/license.html
|
|
*/
|
|
|
|
#ifndef HEADER_STACK_H
|
|
# define HEADER_STACK_H
|
|
|
|
#ifdef __cplusplus
|
|
extern "C" {
|
|
#endif
|
|
|
|
typedef struct stack_st OPENSSL_STACK; /* Use STACK_OF(...) instead */
|
|
|
|
typedef int (*OPENSSL_sk_compfunc)(const void *, const void *);
|
|
typedef void (*OPENSSL_sk_freefunc)(void *);
|
|
typedef void *(*OPENSSL_sk_copyfunc)(const void *);
|
|
|
|
int OPENSSL_sk_num(const OPENSSL_STACK *);
|
|
void *OPENSSL_sk_value(const OPENSSL_STACK *, int);
|
|
|
|
void *OPENSSL_sk_set(OPENSSL_STACK *st, int i, const void *data);
|
|
|
|
OPENSSL_STACK *OPENSSL_sk_new(OPENSSL_sk_compfunc cmp);
|
|
OPENSSL_STACK *OPENSSL_sk_new_null(void);
|
|
OPENSSL_STACK *OPENSSL_sk_new_reserve(OPENSSL_sk_compfunc c, int n);
|
|
int OPENSSL_sk_reserve(OPENSSL_STACK *st, int n);
|
|
void OPENSSL_sk_free(OPENSSL_STACK *);
|
|
void OPENSSL_sk_pop_free(OPENSSL_STACK *st, void (*func) (void *));
|
|
OPENSSL_STACK *OPENSSL_sk_deep_copy(const OPENSSL_STACK *,
|
|
OPENSSL_sk_copyfunc c,
|
|
OPENSSL_sk_freefunc f);
|
|
int OPENSSL_sk_insert(OPENSSL_STACK *sk, const void *data, int where);
|
|
void *OPENSSL_sk_delete(OPENSSL_STACK *st, int loc);
|
|
void *OPENSSL_sk_delete_ptr(OPENSSL_STACK *st, const void *p);
|
|
int OPENSSL_sk_find(OPENSSL_STACK *st, const void *data);
|
|
int OPENSSL_sk_find_ex(OPENSSL_STACK *st, const void *data);
|
|
int OPENSSL_sk_push(OPENSSL_STACK *st, const void *data);
|
|
int OPENSSL_sk_unshift(OPENSSL_STACK *st, const void *data);
|
|
void *OPENSSL_sk_shift(OPENSSL_STACK *st);
|
|
void *OPENSSL_sk_pop(OPENSSL_STACK *st);
|
|
void OPENSSL_sk_zero(OPENSSL_STACK *st);
|
|
OPENSSL_sk_compfunc OPENSSL_sk_set_cmp_func(OPENSSL_STACK *sk,
|
|
OPENSSL_sk_compfunc cmp);
|
|
OPENSSL_STACK *OPENSSL_sk_dup(const OPENSSL_STACK *st);
|
|
void OPENSSL_sk_sort(OPENSSL_STACK *st);
|
|
int OPENSSL_sk_is_sorted(const OPENSSL_STACK *st);
|
|
|
|
# if !OPENSSL_API_1_1_0
|
|
# define _STACK OPENSSL_STACK
|
|
# define sk_num OPENSSL_sk_num
|
|
# define sk_value OPENSSL_sk_value
|
|
# define sk_set OPENSSL_sk_set
|
|
# define sk_new OPENSSL_sk_new
|
|
# define sk_new_null OPENSSL_sk_new_null
|
|
# define sk_free OPENSSL_sk_free
|
|
# define sk_pop_free OPENSSL_sk_pop_free
|
|
# define sk_deep_copy OPENSSL_sk_deep_copy
|
|
# define sk_insert OPENSSL_sk_insert
|
|
# define sk_delete OPENSSL_sk_delete
|
|
# define sk_delete_ptr OPENSSL_sk_delete_ptr
|
|
# define sk_find OPENSSL_sk_find
|
|
# define sk_find_ex OPENSSL_sk_find_ex
|
|
# define sk_push OPENSSL_sk_push
|
|
# define sk_unshift OPENSSL_sk_unshift
|
|
# define sk_shift OPENSSL_sk_shift
|
|
# define sk_pop OPENSSL_sk_pop
|
|
# define sk_zero OPENSSL_sk_zero
|
|
# define sk_set_cmp_func OPENSSL_sk_set_cmp_func
|
|
# define sk_dup OPENSSL_sk_dup
|
|
# define sk_sort OPENSSL_sk_sort
|
|
# define sk_is_sorted OPENSSL_sk_is_sorted
|
|
# endif
|
|
|
|
#ifdef __cplusplus
|
|
}
|
|
#endif
|
|
|
|
#endif
|