Persona + JWT auth

while working on it i also did quite some refactoring
@acorbi could you please do some manual testing?