Fix authorization (issue #3554)