Environment variables

Once Apache SSL is installed, a number of new environment variables will appear and can be used in CGI scripts (see Chapter 13). They are shown in Table 11-1.

Table 11-1. Apache v1.3 environment variables

Variable

Value type

Description

HTTPS

flag

HTTPS being used

HTTPS_CIPHER

string

SSL/TLS cipherspec

SSL_CIPHER

string

The same as HTTPS_CIPHER

SSL_PROTOCOL_VERSION

string

Self explanatory

SSL_SSLEAY_VERSION

string

Self explanatory

HTTPS_KEYSIZE

number

Number of bits in the session key

HTTPS_SECRETKEYSIZE

number

Number of bits in the secret key

SSL_CLIENT_DN

string

DN in client’s certificate

SSL_CLIENT_ x509

string

Component of client’s DN, where x509 is a component of an X509 DN

SSL_CLIENT_I_DN

string

DN of issuer of client’s certificate

SSL_CLIENT_I_ x509

string

Component of client’s issuer’s DN, where x509 is a component of an X509 DN

SSL_SERVER_DN

string

DN in server’s certificate

SSL_SERVER_ x509

string

Component of server’s DN, where x509 is a component of an X509 DN

SSL_SERVER_I_DN

string

DN of issuer of server’s certificate

SSL_SERVER_I_ x509

string

Component of server’s issuer’s DN, where x509 is a component of an X509 DN

SSL_CLIENT_CERT

string

Base64 encoding of client cert

SSL_CLIENT_CERT_CHAIN_ n

string

Base64 encoding of client cert chain

Get Apache: The Definitive Guide, 3rd Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.