curl/docs/cmdline-opts/proto.md
Daniel Stenberg e7219c2bdc
cmdline-opts: language cleanups
Use imperative mood consistently for the first sentence describing an
option.

"Set this" instead "tell curl to set" or "this sets..."

Plus some extra cleanups and rephrasing.

Closes #13106
2024-03-12 15:42:33 +01:00

1.4 KiB

c SPDX-License-Identifier Long Arg Help Added Category Multi See-also Example
Copyright (C) Daniel Stenberg, <daniel@haxx.se>, et al. curl proto <protocols> Enable/disable PROTOCOLS 7.20.2 connection curl single
proto-redir
proto-default
--proto =http,https,sftp $URL

--proto

Limit what protocols to allow for transfers. Protocols are evaluated left to right, are comma separated, and are each a protocol name or 'all', optionally prefixed by zero or more modifiers. Available modifiers are:

+

Permit this protocol in addition to protocols already permitted (this is the default if no modifier is used).

-

Deny this protocol, removing it from the list of protocols already permitted.

=

Permit only this protocol (ignoring the list already permitted), though subject to later modification by subsequent entries in the comma separated list.

For example: --proto -ftps uses the default protocols, but disables ftps

--proto -all,https,+http only enables http and https

--proto =http,https also only enables http and https

Unknown and disabled protocols produce a warning. This allows scripts to safely rely on being able to disable potentially dangerous protocols, without relying upon support for that protocol being built into curl to avoid an error.

This option can be used multiple times, in which case the effect is the same as concatenating the protocols into one instance of the option.