Re: How to handle servername indication with openssl library from server

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



if this is a C++ program, be sure to use C linkage for the callback e.g.

extern "C" {
    static int ssl_servername_cb(SSL *ssl, int *ad, void *arg)
    {
        if (ssl == NULL)
            return SSL_TLSEXT_ERR_NOACK;
    
        const char* servername = SSL_get_servername(ssl, TLSEXT_NAMETYPE_host_name);
        printf("ServerName: %s\n", servername);
    }

}

That is all I can think of.

-- 
Dr Everett (Skip) Carter skip@xxxxxxxxxxx
Taygeta Scientific Inc 607 Charles Ave Seaside CA 93955 831-641-0645 x103

Attachment: signature.asc
Description: This is a digitally signed message part


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux