Change main HSTS URI in navigation-policy-decision-requested scope (#146).
authorDaniel Carl <danielcarl@gmx.de>
Tue, 25 Nov 2014 21:53:16 +0000 (22:53 +0100)
committerDaniel Carl <danielcarl@gmx.de>
Tue, 25 Nov 2014 21:53:16 +0000 (22:53 +0100)
commita54abf6b118f033cd25523e530cb0816d8184f8c
tree8285e03817eb23af457ecf55d807ddd4b764cd44
parentf101056ec15d3749ecc2b3b5dfbaa8d7483aa6b4
Change main HSTS URI in navigation-policy-decision-requested scope (#146).

In case a URL is rewritten to http for a host that is a known hsts host, the
soup session feature rewrites the uri to https like expected. But webkit does
not honor the changed scheme and port and does still return the http uri in
webkit_web_view_get_uri().
To avoid irritations, the URI of the main request is checked in scope of
navigation-policy-decision-requested event. If the uri must be changed, the
changed uri is used for webkit_web_view_load_uri() to start a new request.
src/hsts.c
src/hsts.h
src/main.c