Move old hook to server_chain
Rename "hooks/requests" to "hooks/server_chain".
Make `login` library function to perform login and sid change.
Add "Security policy" global setting.

Used to switch HTTP-only, HTTPS-only, and HTTPS-for-registered.
Drop deprecated global setting translations.
Rewrite HTTP/HTTPS switcher hook.