imap: added basic SASL XOAUTH2 support
authorKyle L. Huff <kyle.huff@curetheitch.com>
Sun, 25 Aug 2013 17:17:35 +0000 (13:17 -0400)
committerSteve Holme <steve_holme@hotmail.com>
Mon, 26 Aug 2013 09:16:32 +0000 (10:16 +0100)
commit34122800b898596f3657f89621dd6762f227653f
treefebbc0929d5326570895c809539f8d2a5e150296
parent7f41eab39524ee73ead3af815234b98dfa7904dc
imap: added basic SASL XOAUTH2 support

Added the ability to use an XOAUTH2 bearer token [RFC6750] with IMAP for
authentication using RFC6749 "OAuth 2.0 Authorization Framework".

The bearer token is expected to be valid for the user specified in
conn->user. If CURLOPT_XOAUTH2_BEARER is defined and the connection has
an advertised auth mechanism of "XOAUTH2", the user and access token are
formatted as a base64 encoded string and sent to the server as
"A001 AUTHENTICATE XOAUTH2 <bearer token>".
lib/imap.c
lib/imap.h