allow_deny: Improve assertion code