Set sessions variables.

Fixes #1