code: func SetAuthProxyHeaders(req *http.Request, username string, groups []string, extra map[string][]string) {
  	req.Header.Del("X-Remote-User")
  	req.Header.Del("X-Remote-Group")
  	for key := range req.Header {
  		if strings.HasPrefix(strings.ToLower(key), strings.ToLower("X-Remote-Extra-")) {
  			req.Header.Del(key)
  		}
  	}
  
  	req.Header.Set("X-Remote-User", username)
  	for _, group := range groups {
  		req.Header.Add("X-Remote-Group", group)
  	}
  	for key, values := range extra {
  		for _, value := range values {
  			req.Header.Add("X-Remote-Extra-"+headerKeyEscape(key), value)
  		}
  	}
  }
docs: // SetAuthProxyHeaders stomps the auth proxy header fields.  It mutates its argument.