diff options
Diffstat (limited to 'options.h')
-rw-r--r-- | options.h | 46 |
1 files changed, 45 insertions, 1 deletions
@@ -5,7 +5,7 @@ * packet encryption, packet authentication, and * packet compression. * - * Copyright (C) 2002-2009 OpenVPN Technologies, Inc. <sales@openvpn.net> + * Copyright (C) 2002-2010 OpenVPN Technologies, Inc. <sales@openvpn.net> * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 @@ -97,6 +97,14 @@ struct connection_entry int socks_proxy_port; bool socks_proxy_retry; #endif + +# define CE_DISABLED (1<<0) +#if HTTP_PROXY_FALLBACK +# define CE_HTTP_PROXY_FALLBACK (1<<1) + time_t ce_http_proxy_fallback_timestamp; /* time when fallback http_proxy_options was last updated */ +#endif + + unsigned int flags; }; struct remote_entry @@ -114,6 +122,7 @@ struct connection_list { int len; int current; + int n_cycles; bool no_advance; struct connection_entry *array[CONNECTION_LIST_SIZE]; }; @@ -126,6 +135,14 @@ struct remote_list #endif +#if HTTP_PROXY_FALLBACK +struct hpo_store +{ + struct http_proxy_options hpo; + char server[80]; +}; +#endif + /* Command line options */ struct options { @@ -162,14 +179,22 @@ struct options struct connection_entry ce; #ifdef ENABLE_CONNECTION + char *remote_ip_hint; struct connection_list *connection_list; struct remote_list *remote_list; + bool force_connection_list; #endif #ifdef GENERAL_PROXY_SUPPORT struct auto_proxy_info *auto_proxy_info; #endif +#if HTTP_PROXY_FALLBACK + bool http_proxy_fallback; + struct http_proxy_options *http_proxy_override; + struct hpo_store *hpo_store; /* used to store dynamic proxy info given by management interface */ +#endif + bool remote_random; const char *ipchange; const char *dev; @@ -440,6 +465,7 @@ struct options const char *pkcs12_file; const char *cipher_list; const char *tls_verify; + const char *tls_export_cert; const char *tls_remote; const char *crl_file; @@ -483,6 +509,9 @@ struct options within n seconds of handshake initiation. */ int handshake_window; + /* Field used to be the username in X509 cert. */ + char *x509_username_field; + /* Old key allowed to live n seconds after new key goes active */ int transition_window; @@ -495,6 +524,10 @@ struct options /* Allow only one session */ bool single_session; +#ifdef ENABLE_PUSH_PEER_INFO + bool push_peer_info; +#endif + bool tls_exit; #endif /* USE_SSL */ @@ -710,4 +743,15 @@ connection_list_set_no_advance (struct options *o) #endif } +#if HTTP_PROXY_FALLBACK + +struct http_proxy_options * +parse_http_proxy_fallback (struct context *c, + const char *server, + const char *port, + const char *flags, + const int msglevel); + +#endif /* HTTP_PROXY_FALLBACK */ + #endif |