Changeset 411d286 in mod_gnutls for src/gnutls_proxy.c


Ignore:
Timestamp:
May 31, 2020, 5:18:44 AM (13 months ago)
Author:
Fiona Klute <fiona.klute@…>
Branches:
asyncio, master
Children:
7e29705
Parents:
d827d0c
Message:

Store session tickets for proxy connections in the session cache

The cache key is stored in the session context because it will be
needed for every proxy connection: For checking if there is a cached
ticket (not implemented yet), and to store new tickets if any.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/gnutls_proxy.c

    rd827d0c r411d286  
    396396
    397397
    398 char *mgs_proxy_ticket_id(mgs_handle_t *ctxt, apr_pool_t *pool)
     398gnutls_datum_t mgs_proxy_ticket_id(mgs_handle_t *ctxt, apr_pool_t *pool)
    399399{
    400400    apr_pool_t *tmp;
     
    413413     */
    414414    const char *peer_hostname = get_proxy_sni_name(ctxt);
    415     return apr_psprintf(
    416         tmp, "proxy:%s:%s:%d",
    417         ctxt->c->base_server->server_hostname,
    418         peer_hostname ? peer_hostname : ctxt->c->client_ip,
    419         ctxt->c->client_addr->port);
     415    gnutls_datum_t key;
     416    key.data = (unsigned char *)
     417        apr_psprintf(tmp, "proxy:%s:%s:%d",
     418                     ctxt->c->base_server->server_hostname,
     419                     peer_hostname ? peer_hostname : ctxt->c->client_ip,
     420                     ctxt->c->client_addr->port);
     421    key.size = strlen((const char*) key.data);
     422    return key;
    420423}
    421424
Note: See TracChangeset for help on using the changeset viewer.