HADOOP-11337. KeyAuthorizationKeyProvider access checks need to be done atomically. Contributed by Dian Fu.

(cherry picked from commit 9fa29902575ac3774bf3728e7bcde7f3eefb1d4c)