def proxy.connect.header

bend-kit-http@0.38.2.0 · http.bend:3467

import bend-kit-http@0.38.2.0/http.bend as Http
import Base

3467def proxy.connect.header(+authority: String, authorization: String) -> String:
3468  match authorization:
3469    case SNil{}:
3470      "CONNECT " ++ authority ++ " HTTP/1.1\r\nHost: " ++ authority ++ "\r\n\r\n"
3471    case other:
3472      "CONNECT " ++ authority ++ " HTTP/1.1\r\nHost: " ++ authority
3473        ++ "\r\nProxy-Authorization: " ++ authorization ++ "\r\n\r\n"

Uses (2)

Used by (1)