Better handling of authorization headers