func BasicAuthHeader(username, password string) http.Header {
	auth := username + ":" + password
	encoded := "Basic " + base64.StdEncoding.EncodeToString([]byte(auth))
	return http.Header{
		"Authorization": {encoded},
	}
}
// BasicAuthHeader creates a header that contains just the "Authorization"
// entry.  The implementation was originally taked from net/http but this is
// needed externally from the http request object in order to use this with
// our websockets. See 2 (end of page 4) http://www.ietf.org/rfc/rfc2617.txt
// "To receive authorization, the client sends the userid and password,
// separated by a single colon (":") character, within a base64 encoded string
// in the credentials."
BasicAuthHeader creates a header that contains just the "Authorization"
entry.  The implementation was originally taked from net/http but this is
needed externally from the http request object in order to use this with
our websockets.
// BasicAuthHeader creates a header that contains just the " Authorization " // entry . The implementation was originally taked from net / http but this is // needed externally from the http request object in order to use this with // our websockets . See 2 ( end of page 4 ) http : // www . ietf . org / rfc / rfc2617 . txt // " To receive authorization the client sends the userid and password // separated by a single colon ( " : " ) character within a base64 encoded string // in the credentials . "
func BasicAuthHeader(username, password string) http.Header {
	auth := username + ":" + password
	encoded := "Basic " + base64.StdEncoding.EncodeToString([]byte(auth))
	return http.Header{
		"Authorization": {encoded},
	}
}
func BasicAuthHeader ( username , password string ) http . Header { auth := username + " " + password encoded := " " + base64 . StdEncoding . EncodeToString ( [ ] byte ( auth ) ) return http . Header { " " : { encoded } , } }
BasicAuthHeader creates a header that contains just the "Authorization"
entry.
BasicAuthHeader creates a header that contains just the " Authorization " entry .