Fix authorization (closes #3)