cleaned up authorization scheme for ease of debugging
cleaned up authorization scheme and added notes for ease of debugging