#1864962: Change assumption that site is not secured
General code rewrite.
First, full tested beta release.
First release.