aboutsummaryrefslogtreecommitdiffstats
path: root/lib/inets/test
diff options
context:
space:
mode:
authorIngela Anderton Andin <[email protected]>2016-04-20 22:13:45 +0200
committerIngela Anderton Andin <[email protected]>2016-04-21 17:30:24 +0200
commite1e8233759f835025f15da302f2a37ff6845d600 (patch)
treecbf0a7de9400b15dc83daea8045751159f5555c2 /lib/inets/test
parentafe72bfc1448ff426c38eceb7412f69e973aef62 (diff)
downloadotp-e1e8233759f835025f15da302f2a37ff6845d600.tar.gz
otp-e1e8233759f835025f15da302f2a37ff6845d600.tar.bz2
otp-e1e8233759f835025f15da302f2a37ff6845d600.zip
inets: Add peer_cert to ESI environment
Diffstat (limited to 'lib/inets/test')
-rw-r--r--lib/inets/test/httpd_SUITE.erl14
1 files changed, 13 insertions, 1 deletions
diff --git a/lib/inets/test/httpd_SUITE.erl b/lib/inets/test/httpd_SUITE.erl
index 1d8a603981..93520c1cb4 100644
--- a/lib/inets/test/httpd_SUITE.erl
+++ b/lib/inets/test/httpd_SUITE.erl
@@ -755,7 +755,11 @@ esi(Config) when is_list(Config) ->
%% Check "ErlScriptNoCache" directive (default: false)
ok = http_status("GET /cgi-bin/erl/httpd_example:get ",
Config, [{statuscode, 200},
- {no_header, "cache-control"}]).
+ {no_header, "cache-control"}]),
+ ok = http_status("GET /cgi-bin/erl/httpd_example:peer ",
+ Config, [{statuscode, 200},
+ {header, "peer-cert-exist", peer(Config)}]).
+
%%-------------------------------------------------------------------------
mod_esi_chunk_timeout(Config) when is_list(Config) ->
ok = httpd_1_1:mod_esi_chunk_timeout(?config(type, Config),
@@ -2065,3 +2069,11 @@ response_default_headers() ->
{"X-Frame-Options", "SAMEORIGIN"},
%% Override built-in default
{"Date", "Override-date"}].
+
+peer(Config) ->
+ case proplists:get_value(type, Config) of
+ ssl ->
+ "true";
+ _ ->
+ "false"
+ end. \ No newline at end of file