Components | All | New | MacOS | Windows | Linux | iOS | ||||
Examples | Mac & Win | Server | Client | Guides | Statistic | FMM | Blog | Deprecated | Old |
CURL.SetOptionRedirProtocols
Limit which protocols are used for redirection.
Component | Version | macOS | Windows | Linux | Server | iOS SDK |
CURL | 2.5 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes |
Deprecated
This function was deprecated. Use CURL.SetOptionRedirProtocolsString instead.
MBS( "CURL.SetOptionRedirProtocols"; curl; Value ) More
Parameters
Parameter | Description | Example |
---|---|---|
curl | The CURL session handle. | $curl |
Value | The bitmask defining which protocols to use. | 1 |
Result
Returns "OK" on success.
Description
Limit which protocols are used for redirection.Pass a number that holds a bitmask of protocol values (see below). If used, this bitmask limits what protocols libcurl may use in a transfer that it follows to in a redirect when CURL.SetOptionFollowLocation is enabled. This allows you to limit specific transfers to only be allowed to use a subset of protocols in redirections. By default libcurl will allow all protocols except for FILE and SCP.
HTTP | 1 |
FTP | 4 |
FTPS | 8 |
SCP | 16 |
SFTP | 32 |
TELNET | 64 |
LDAP | 128 |
LDAPS | 256 |
DICT | 512 |
FILE | 1024 |
TFTP | 2048 |
IMAP | 4096 |
IMAPS | 8192 |
POP3 | 16384 |
POP3S | 32768 |
SMTP | 65536 |
SMTPS | 131072 |
RTSP | 262144 |
ALL | -1 |
See also
- CURL.SetOptionDefaultProtocol
- CURL.SetOptionFollowLocation
- CURL.SetOptionHAProxyProtocol
- CURL.SetOptionProtocols
- CURL.SetOptionRedirProtocolsString
Release notes
- Version 13.0
- Deprecated CURL.SetOptionRedirProtocols in favor of CURL.SetOptionRedirProtocolsString function.
Blog Entries
Created 18th August 2014, last changed 21st December 2022