user auth abstraction layer middleware.