Skip to content

Commit b83d3cf

Browse files
committed
update usage in error messages
1 parent e400285 commit b83d3cf

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

proxy/proxy.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -254,8 +254,8 @@ Request: %s %s
254254
Host: %s
255255
256256
To allow this request, restart boundary with:
257-
--allow "%s" # Allow all methods to this host
258-
--allow "%s %s" # Allow only %s requests to this host
257+
--allow "domain=%s" # Allow all methods to this host
258+
--allow "method=%s domain=%s" # Allow only %s requests to this host
259259
260260
For more help: https://github.com/coder/boundary
261261
`,
@@ -639,7 +639,7 @@ func (p *Server) constructFullURL(req *http.Request, hostname string) string {
639639

640640
// writeBlockedResponseStreaming writes a blocked response directly to the TLS connection
641641
func (p *Server) writeBlockedResponseStreaming(tlsConn *tls.Conn, req *http.Request) {
642-
response := fmt.Sprintf("HTTP/1.1 403 Forbidden\r\nContent-Type: text/plain\r\nConnection: close\r\n\r\n🚫 Request Blocked by Boundary\n\nRequest: %s %s\nHost: %s\n\nTo allow this request, restart boundary with:\n --allow \"%s\"\n",
642+
response := fmt.Sprintf("HTTP/1.1 403 Forbidden\r\nContent-Type: text/plain\r\nConnection: close\r\n\r\n🚫 Request Blocked by Boundary\n\nRequest: %s %s\nHost: %s\n\nTo allow this request, restart boundary with:\n --allow \"domain=%s\"\n",
643643
req.Method, req.URL.Path, req.Host, req.Host)
644644
_, _ = tlsConn.Write([]byte(response))
645645
}

0 commit comments

Comments
 (0)