SW-1. Fixes mostly for compatiblity with Windows and newest Firefox.

Also store cookies using root path.