fix login/logout api
add session on core application