authorization cache and code