CURL.SetOptionTLSAuthType
-------------------------

Sets the TLS authentication type.

| Component | Version | macOS | Windows | Linux | Server | iOS SDK |
|---|---|---|---|---|---|---|
| [CURL](component_CURL.md) | [3.5](newinversion35.md) | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes |

MBS( "CURL.SetOptionTLSAuthType"; curl; Type { ; Encoding } ) 

**MBS**( **"CURL.SetOptionTLSAuthType";** /\* Sets the TLS authentication type. \*/  
**$curl**; /\* The CURL session handle. \*/   
**$Type**; /\* the TLS authentication type.e.g. "SRP" \*/   
**$Encoding**) /\* Optional; The text encoding for text parameter.   
Default is UTF-8.e.g. "UTF8" \*/ 

### Parameters

| Parameter | Description | Example | Flags |
|---|---|---|---|
| curl | The CURL session handle. | $curl |  |
| Type | the TLS authentication type. | "SRP" |  |
| Encoding | The text encoding for text parameter.    Default is UTF-8.   Possible encoding names: ANSI, ISO-8859-1, Latin1, Mac, Native, UTF-8, DOS, Hex, Base64 or Windows. More listed in the [FAQ](https://www.monkeybreadsoftware.com/filemaker/faq.shtml). | "UTF8" | Optional |

### Result

Returns OK or error.

### Description

Sets the TLS authentication type.  
Please also set username and password.  
You can set this to "SRP" to use Secure Remote Password authentication.  
See also [TLSAUTH\_TYPE](https://curl.haxx.se/libcurl/c/CURLOPT_TLSAUTH_TYPE.html) option in CURL manual.

### See also

- [CURL.SetOptionProxyTLSAuthType](CURLSetOptionProxyTLSAuthType.md)
- [CURL.SetOptionSASLAuthZID](CURLSetOptionSASLAuthZID.md)
- [CURL.SetOptionSSHAuthTypes](CURLSetOptionSSHAuthTypes.md)
- [CURL.SetOptionSSLCertType](CURLSetOptionSSLCertType.md)
- [CURL.SetOptionSSLKeyType](CURLSetOptionSSLKeyType.md)
- [CURL.SetOptionTLSAuthPassword](CURLSetOptionTLSAuthPassword.md)
- [CURL.SetOptionTLSAuthUsername](CURLSetOptionTLSAuthUsername.md)

Created 18th August 2014 , last changed 5th July 2015

  
[CURL.SetOptionTLSAuthPassword](CURLSetOptionTLSAuthPassword.md) - [CURL.SetOptionTLSAuthUsername](CURLSetOptionTLSAuthUsername.md)

[HTML Version](CURLSetOptionTLSAuthType.shtml)