Added permanent session cookie support, as discussed on issue #2.