BasicAuth

BasicAuth Provides basic HTTP authentication, requiring a username and password to access protected routes.

Can be applied globally or to specific routes.

Supports authentication via environment variables.

Allows custom implementation if necessary.


// Function signature
q.Use(middleware.BasicAuth(User, Password))
                        
routing.go