add login- and logout-hook support instead of implementing logging in this project

Signed-off-by: Mattias Andrée <maandree@operamail.com>