proxy-header.d 1.3 KB

1234567891011121314151617181920212223242526272829303132
  1. c: Copyright (C) Daniel Stenberg, <daniel@haxx.se>, et al.
  2. SPDX-License-Identifier: curl
  3. Long: proxy-header
  4. Arg: <header/@file>
  5. Help: Pass custom header(s) to proxy
  6. Protocols: HTTP
  7. Added: 7.37.0
  8. Category: proxy
  9. Example: --proxy-header "X-First-Name: Joe" -x http://proxy $URL
  10. Example: --proxy-header "User-Agent: surprise" -x http://proxy $URL
  11. Example: --proxy-header "Host:" -x http://proxy $URL
  12. See-also: proxy
  13. Multi: append
  14. ---
  15. Extra header to include in the request when sending HTTP to a proxy. You may
  16. specify any number of extra headers. This is the equivalent option to --header
  17. but is for proxy communication only like in CONNECT requests when you want a
  18. separate header sent to the proxy to what is sent to the actual remote host.
  19. curl makes sure that each header you add/replace is sent with the proper
  20. end-of-line marker, you should thus **not** add that as a part of the header
  21. content: do not add newlines or carriage returns, they only mess things up for
  22. you.
  23. Headers specified with this option are not included in requests that curl
  24. knows are not be sent to a proxy.
  25. This option can take an argument in @filename style, which then adds a header
  26. for each line in the input file (added in 7.55.0). Using @- makes curl read
  27. the headers from stdin.
  28. This option can be used multiple times to add/replace/remove multiple headers.