commit - 5f060a33e967f5e1293714d94467e63788042e55
commit + 339101e22f878189d88b482747c9fe560dbfd9d6
blob - b03bc01a1a75e5ca7f6df8148ab33f956aac4de5
blob + 3fde7a2e9d23fbb44d973d5e1289801f8bca40d3
--- web/server.go
+++ web/server.go
fn := func(w http.ResponseWriter, req *http.Request) {
username, password, ok := req.BasicAuth()
if !ok || len(username) == 0 || len(password) == 0 {
+ w.Header().Set("WWW-Authenticate", `Basic realm="mailmux"`)
jerror(w, "unauthorised", http.StatusUnauthorized)
return
}