1
0
mirror of https://github.com/moparisthebest/curl synced 2024-12-21 23:58:49 -05:00

sasl-ir: Added CURLOPT_SASL_IR to enable/disable the SASL initial response

This commit is contained in:
Steve Holme 2013-04-27 09:39:21 +01:00
parent 6420672879
commit a846fbbe2a
3 changed files with 13 additions and 2 deletions

View File

@ -1527,9 +1527,12 @@ typedef enum {
/* Enable/disable specific SSL features with a bitmask, see CURLSSLOPT_* */ /* Enable/disable specific SSL features with a bitmask, see CURLSSLOPT_* */
CINIT(SSL_OPTIONS, LONG, 216), CINIT(SSL_OPTIONS, LONG, 216),
/* set the SMTP auth originator */ /* Set the SMTP auth originator */
CINIT(MAIL_AUTH, OBJECTPOINT, 217), CINIT(MAIL_AUTH, OBJECTPOINT, 217),
/* Enable/disable SASL initial response */
CINIT(SASL_IR, LONG, 218),
CURLOPT_LASTENTRY /* the last unused */ CURLOPT_LASTENTRY /* the last unused */
} CURLoption; } CURLoption;

View File

@ -2246,20 +2246,27 @@ CURLcode Curl_setopt(struct SessionHandle *data, CURLoption option,
break; break;
case CURLOPT_MAIL_FROM: case CURLOPT_MAIL_FROM:
/* Set the SMTP mail originator */
result = setstropt(&data->set.str[STRING_MAIL_FROM], result = setstropt(&data->set.str[STRING_MAIL_FROM],
va_arg(param, char *)); va_arg(param, char *));
break; break;
case CURLOPT_MAIL_AUTH: case CURLOPT_MAIL_AUTH:
/* Set the SMTP auth originator */
result = setstropt(&data->set.str[STRING_MAIL_AUTH], result = setstropt(&data->set.str[STRING_MAIL_AUTH],
va_arg(param, char *)); va_arg(param, char *));
break; break;
case CURLOPT_MAIL_RCPT: case CURLOPT_MAIL_RCPT:
/* get a list of mail recipients */ /* Set the list of mail recipients */
data->set.mail_rcpt = va_arg(param, struct curl_slist *); data->set.mail_rcpt = va_arg(param, struct curl_slist *);
break; break;
case CURLOPT_SASL_IR:
/* Enable/disable SASL initial response */
data->set.sasl_ir = (0 != va_arg(param, long)) ? TRUE : FALSE;
break;
case CURLOPT_RTSP_REQUEST: case CURLOPT_RTSP_REQUEST:
{ {
/* /*

View File

@ -1563,6 +1563,7 @@ struct UserDefined {
long socks5_gssapi_nec; /* flag to support nec socks5 server */ long socks5_gssapi_nec; /* flag to support nec socks5 server */
#endif #endif
struct curl_slist *mail_rcpt; /* linked list of mail recipients */ struct curl_slist *mail_rcpt; /* linked list of mail recipients */
bool sasl_ir; /* Enable/disable SASL initial response */
/* Common RTSP header options */ /* Common RTSP header options */
Curl_RtspReq rtspreq; /* RTSP request type */ Curl_RtspReq rtspreq; /* RTSP request type */
long rtspversion; /* like httpversion, for RTSP */ long rtspversion; /* like httpversion, for RTSP */