From 22c198fa89512c76f916d7d3909d113bb32ddcd0 Mon Sep 17 00:00:00 2001 From: Fabian Frank Date: Wed, 29 Jan 2014 21:18:03 -0800 Subject: openssl: set up hooks with to perform NPN NPN is what is available in the wild today to negotiate SPDY or HTTP/2.0 connections. It is expected to be replaced by ALPN in the future. If HTTP/2.0 is negotiated, this is indicated for the entire connection and http.c is expected to initialize itself for HTTP/2.0 instead of HTTP/1.1. see: http://technotes.googlecode.com/git/nextprotoneg.html http://tools.ietf.org/html/draft-ietf-tls-applayerprotoneg-04 --- lib/urldata.h | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'lib/urldata.h') diff --git a/lib/urldata.h b/lib/urldata.h index e37971e02..1e1ef5d6b 100644 --- a/lib/urldata.h +++ b/lib/urldata.h @@ -597,6 +597,12 @@ enum upgrade101 { UPGR101_WORKING /* talking upgraded protocol */ }; +enum negotiatenpn { + NPN_INIT, /* default state */ + NPN_HTTP1_1, /* HTTP/1.1 negotiated */ + NPN_HTTP2_DRAFT09 /* HTTP-draft-0.9/2.0 negotiated */ +}; + /* * Request specific data in the easy handle (SessionHandle). Previously, * these members were on the connectdata struct but since a conn struct may @@ -1048,6 +1054,8 @@ struct connectdata { TUNNEL_COMPLETE /* CONNECT response received completely */ } tunnel_state[2]; /* two separate ones to allow FTP */ struct connectbundle *bundle; /* The bundle we are member of */ + + enum negotiatenpn negnpn; }; /* The end of connectdata. */ -- cgit v1.2.3