Express middleware for request validation