mirror of
https://git.haproxy.org/git/haproxy.git/
synced 2026-01-29 14:01:50 +01:00
REORG: move the crt-list structures in their own .h
Move the structure definitions specifics to the crt-list in types/ssl_crtlist.h.
This commit is contained in:
parent
336c4bbb08
commit
be21b663cd
59
include/types/ssl_crtlist.h
Normal file
59
include/types/ssl_crtlist.h
Normal file
@ -0,0 +1,59 @@
|
||||
/*
|
||||
* include/types/ssl_crtlist.h
|
||||
* crt-list structures
|
||||
*
|
||||
* Copyright (C) 2020 HAProxy Technologies, William Lallemand <wlallemand@haproxy.com>
|
||||
*
|
||||
* This library is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU Lesser General Public
|
||||
* License as published by the Free Software Foundation, version 2.1
|
||||
* exclusively.
|
||||
*
|
||||
* This library is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* Lesser General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU Lesser General Public
|
||||
* License along with this library; if not, write to the Free Software
|
||||
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
#ifndef _TYPES_SSL_CRTLIST_H
|
||||
#define _TYPES_SSL_CRTLIST_H
|
||||
#ifdef USE_OPENSSL
|
||||
|
||||
#include <common/mini-clist.h>
|
||||
|
||||
#include <types/listener.h>
|
||||
|
||||
/* list of bind conf used by struct crtlist */
|
||||
struct bind_conf_list {
|
||||
struct bind_conf *bind_conf;
|
||||
struct bind_conf_list *next;
|
||||
};
|
||||
|
||||
/* This structure is basically a crt-list or a directory */
|
||||
struct crtlist {
|
||||
struct bind_conf_list *bind_conf; /* list of bind_conf which use this crtlist */
|
||||
unsigned int linecount; /* number of lines */
|
||||
struct eb_root entries;
|
||||
struct list ord_entries; /* list to keep the line order of the crt-list file */
|
||||
struct ebmb_node node; /* key is the filename or directory */
|
||||
};
|
||||
|
||||
/* a file in a directory or a line in a crt-list */
|
||||
struct crtlist_entry {
|
||||
struct ssl_bind_conf *ssl_conf; /* SSL conf in crt-list */
|
||||
unsigned int linenum;
|
||||
unsigned int fcount; /* filters count */
|
||||
char **filters;
|
||||
struct crtlist *crtlist; /* ptr to the parent crtlist */
|
||||
struct list ckch_inst; /* list of instances of this entry, there is 1 ckch_inst per instance of the crt-list */
|
||||
struct list by_crtlist; /* ordered entries */
|
||||
struct list by_ckch_store; /* linked in ckch_store list of crtlist_entries */
|
||||
struct ebpt_node node; /* key is a ptr to a ckch_store */
|
||||
};
|
||||
|
||||
#endif /* USE_OPENSSL */
|
||||
#endif /* _TYPES_SSL_CRTLIST_H */
|
||||
@ -27,6 +27,8 @@
|
||||
#include <ebmbtree.h>
|
||||
#include <eb64tree.h>
|
||||
|
||||
#include <types/ssl_crtlist.h>
|
||||
|
||||
#include <common/hathreads.h>
|
||||
#include <common/mini-clist.h>
|
||||
#include <common/openssl-compat.h>
|
||||
@ -225,33 +227,6 @@ struct ckch_inst {
|
||||
struct list by_crtlist_entry; /* chained in crtlist_entry list of inst */
|
||||
};
|
||||
|
||||
/* list of bind conf used by struct crtlist */
|
||||
struct bind_conf_list {
|
||||
struct bind_conf *bind_conf;
|
||||
struct bind_conf_list *next;
|
||||
};
|
||||
|
||||
/* This structure is basically a crt-list or a directory */
|
||||
struct crtlist {
|
||||
struct bind_conf_list *bind_conf; /* list of bind_conf which use this crtlist */
|
||||
unsigned int linecount; /* number of lines */
|
||||
struct eb_root entries;
|
||||
struct list ord_entries; /* list to keep the line order of the crt-list file */
|
||||
struct ebmb_node node; /* key is the filename or directory */
|
||||
};
|
||||
|
||||
/* a file in a directory or a line in a crt-list */
|
||||
struct crtlist_entry {
|
||||
struct ssl_bind_conf *ssl_conf; /* SSL conf in crt-list */
|
||||
unsigned int linenum;
|
||||
unsigned int fcount; /* filters count */
|
||||
char **filters;
|
||||
struct crtlist *crtlist; /* ptr to the parent crtlist */
|
||||
struct list ckch_inst; /* list of instances of this entry, there is 1 ckch_inst per instance of the crt-list */
|
||||
struct list by_crtlist; /* ordered entries */
|
||||
struct list by_ckch_store; /* linked in ckch_store list of crtlist_entries */
|
||||
struct ebpt_node node; /* key is a ptr to a ckch_store */
|
||||
};
|
||||
|
||||
#if HA_OPENSSL_VERSION_NUMBER >= 0x1000200fL
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user