Changeset c301152 in mod_gnutls for include/mod_gnutls.h.in


Ignore:
Timestamp:
Apr 24, 2005, 6:21:50 PM (14 years ago)
Author:
Paul Querna <chip@…>
Branches:
debian/master, debian/stretch-backports, jessie-backports, master, msva, upstream
Children:
7ba803b
Parents:
46b85d8
Message:
  • move hooks to gnutls_hooks.c
  • use 'mgs_' as the prefix for all symbols, instead of mixed prefixes.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • include/mod_gnutls.h.in

    r46b85d8 rc301152  
    6363typedef enum
    6464{
    65     mod_gnutls_cache_none,
    66     mod_gnutls_cache_dbm,
     65    mgs_cache_none,
     66    mgs_cache_dbm,
    6767#if HAVE_APR_MEMCACHE
    68     mod_gnutls_cache_memcache
     68    mgs_cache_memcache
    6969#endif
    70 } mod_gnutls_cache_e;
     70} mgs_cache_e;
    7171
    7272typedef struct
    7373{
    7474    int client_verify_mode;
    75 } mod_gnutls_dirconf_rec;
     75} mgs_dirconf_rec;
    7676
    7777typedef struct
     
    8989    int cert_types[16];
    9090    apr_time_t cache_timeout;
    91     mod_gnutls_cache_e cache_type;
     91    mgs_cache_e cache_type;
    9292    const char* cache_config;
    9393    const char* rsa_params_file;
    9494    const char* dh_params_file;
    9595    int client_verify_mode;
    96 } mod_gnutls_srvconf_rec;
     96} mgs_srvconf_rec;
    9797
    9898typedef struct {
    9999    int length;
    100100    char *value;
    101 } mod_gnutls_char_buffer_t;
     101} mgs_char_buffer_t;
    102102
    103103typedef struct
    104104{
    105     mod_gnutls_srvconf_rec *sc;
     105    mgs_srvconf_rec *sc;
    106106    conn_rec* c;
    107107    gnutls_session_t session;
     
    112112    apr_read_type_e input_block;
    113113    ap_input_mode_t input_mode;
    114     mod_gnutls_char_buffer_t input_cbuf;
     114    mgs_char_buffer_t input_cbuf;
    115115    char input_buffer[AP_IOBUFSIZE];
    116116
     
    124124    int status;
    125125    int non_https;
    126 } mod_gnutls_handle_t;
     126} mgs_handle_t;
    127127
    128128/** Functions in gnutls_io.c **/
    129129
    130130/**
    131  * mod_gnutls_filter_input will filter the input data
     131 * mgs_filter_input will filter the input data
    132132 * by decrypting it using GnuTLS and passes it cleartext.
    133133 *
     
    138138 * @return result status
    139139 */
    140 apr_status_t mod_gnutls_filter_input(ap_filter_t * f,
     140apr_status_t mgs_filter_input(ap_filter_t * f,
    141141                                     apr_bucket_brigade * bb,
    142142                                     ap_input_mode_t mode,
     
    145145
    146146/**
    147  * mod_gnutls_filter_output will filter the encrypt
     147 * mgs_filter_output will filter the encrypt
    148148 * the incoming bucket using GnuTLS and passes it onto the next filter.
    149149 *
     
    152152 * @return result status
    153153 */
    154 apr_status_t mod_gnutls_filter_output(ap_filter_t * f,
     154apr_status_t mgs_filter_output(ap_filter_t * f,
    155155                                      apr_bucket_brigade * bb);
    156156
    157157
    158158/**
    159  * mod_gnutls_transport_read is called from GnuTLS to provide encrypted
     159 * mgs_transport_read is called from GnuTLS to provide encrypted
    160160 * data from the client.
    161161 *
     
    165165 * @return size   length of the data stored in buffer
    166166 */
    167 ssize_t mod_gnutls_transport_read(gnutls_transport_ptr_t ptr,
     167ssize_t mgs_transport_read(gnutls_transport_ptr_t ptr,
    168168                                  void *buffer, size_t len);
    169169
    170170/**
    171  * mod_gnutls_transport_write is called from GnuTLS to
     171 * mgs_transport_write is called from GnuTLS to
    172172 * write data to the client.
    173173 *
     
    177177 * @return size   length of the data written
    178178 */
    179 ssize_t mod_gnutls_transport_write(gnutls_transport_ptr_t ptr,
     179ssize_t mgs_transport_write(gnutls_transport_ptr_t ptr,
    180180                                   const void *buffer, size_t len);
    181181
    182182
    183 int mod_gnutls_rehandshake(mod_gnutls_handle_t * ctxt);
     183int mgs_rehandshake(mgs_handle_t * ctxt);
    184184
    185185
     
    188188 * Init the Cache after Configuration is done
    189189 */
    190 int mod_gnutls_cache_post_config(apr_pool_t *p, server_rec *s,
    191                                  mod_gnutls_srvconf_rec *sc);
     190int mgs_cache_post_config(apr_pool_t *p, server_rec *s,
     191                                 mgs_srvconf_rec *sc);
    192192/**
    193193 * Init the Cache inside each Process
    194194 */
    195 int mod_gnutls_cache_child_init(apr_pool_t *p, server_rec *s,
    196                                 mod_gnutls_srvconf_rec *sc);
     195int mgs_cache_child_init(apr_pool_t *p, server_rec *s,
     196                                mgs_srvconf_rec *sc);
    197197/**
    198198 * Setup the Session Caching
    199199 */
    200 int mod_gnutls_cache_session_init(mod_gnutls_handle_t *ctxt);
     200int mgs_cache_session_init(mgs_handle_t *ctxt);
    201201
    202202#define GNUTLS_SESSION_ID_STRING_LEN \
     
    210210 * @param strsize The Maximum Length that can be stored in str
    211211 */
    212 char *mod_gnutls_session_id2sz(unsigned char *id, int idlen,
     212char *mgs_session_id2sz(unsigned char *id, int idlen,
    213213                                char *str, int strsize);
     214
    214215
    215216/* Configuration Functions */
     
    240241void *mgs_config_dir_create(apr_pool_t *p, char *dir);
    241242
     243
     244/* mod_gnutls Hooks. */
     245
     246int mgs_hook_pre_config(apr_pool_t * pconf,
     247                        apr_pool_t * plog, apr_pool_t * ptemp);
     248
     249int mgs_hook_post_config(apr_pool_t * p, apr_pool_t * plog,
     250                         apr_pool_t * ptemp,
     251                         server_rec * base_server);
     252
     253void mgs_hook_child_init(apr_pool_t *p, server_rec *s);
     254
     255const char *mgs_hook_http_scheme(const request_rec * r);
     256
     257apr_port_t mgs_hook_default_port(const request_rec * r);
     258
     259int mgs_hook_pre_connection(conn_rec * c, void *csd);
     260
     261int mgs_hook_fixups(request_rec *r);
     262
     263int mgs_hook_authz(request_rec *r);
     264
    242265#endif /*  __mod_gnutls_h_inc */
Note: See TracChangeset for help on using the changeset viewer.