auxiliary module changed to helper block in external file
Set session time and aux functions to handle sessions.
Extracts logic from routes to helper functions