diff options
Diffstat (limited to 'docs/cmdline-opts/proto-redir.md')
-rw-r--r-- | docs/cmdline-opts/proto-redir.md | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/docs/cmdline-opts/proto-redir.md b/docs/cmdline-opts/proto-redir.md new file mode 100644 index 000000000..f0a307a17 --- /dev/null +++ b/docs/cmdline-opts/proto-redir.md @@ -0,0 +1,28 @@ +--- +c: Copyright (C) Daniel Stenberg, <daniel@haxx.se>, et al. +SPDX-License-Identifier: curl +Long: proto-redir +Arg: <protocols> +Help: Enable/disable PROTOCOLS on redirect +Added: 7.20.2 +Category: connection curl +Multi: single +See-also: + - proto +Example: + - --proto-redir =http,https $URL +--- + +# `--proto-redir` + +Tells curl to limit what protocols it may use on redirect. Protocols denied by +--proto are not overridden by this option. See --proto for how protocols are +represented. + +Example, allow only HTTP and HTTPS on redirect: + + curl --proto-redir -all,http,https http://example.com + +By default curl only allows HTTP, HTTPS, FTP and FTPS on redirects (added in +7.65.2). Specifying *all* or *+all* enables all protocols on redirects, which +is not good for security. |