(partially) Fix IMAP LOGIN
(partially) Fix IMAP LOGIN

Previously, the user name and password were being transmitted as IMAP (RFC
3501) quoted strings.

The problem is that quoted strings are only permitted to carry 7-bit
(ASCII) data, whereas user names and passwords entered in K-9 Mail may not
be ASCII, so K-9 was violating the RFC by sending them as quoted strings.

The solution is to transmit the credentials as IMAP literal strings, which
are permitted for user names and passwords, and which permit the
transmission of 8-bit data.

This is only a partial attempt for fixing the LOGIN command for users with
non-ASCII credentials.  The problem is that IMAP permits 8-bit data for
user names and passwords (if transmitted as literals), but the RFC says
nothing about the character encoding for 8-bit data.  This commit encodes
them as UTF-8.

The RFC author's comments on the subject:
http://mailman2.u.washington.edu/pipermail/imap-protocol/2008-February/000822.html

Ideally, users should avoid the LOGIN command and use the SASL PLAIN
mechanism (within TLS) which explicitly permits UTF-8. (K-9 Mail always
chooses PLAIN over LOGIN, when PLAIN is available.)

KitAway/k-9,herpiko/k-9,jca02266/k-9,vasyl-khomko/k-9,konfer/k-9,sanderbaas/k-9,dgger/k-9,gaionim/k-9,sonork/k-9,gnebsy/k-9,sonork/k-9,philipwhiuk/q-mail,cliniome/pki,439teamwork/k-9,rollbrettler/k-9,thuanpq/k-9,jca02266/k-9,mawiegand/k-9,dpereira411/k-9,jberkel/k-9,suzp1984/k-9,herpiko/k-9,dgger/k-9,mawiegand/k-9,KitAway/k-9,sanderbaas/k-9,vatsalsura/k-9,k9mail/k-9,nilsbraden/k-9,philipwhiuk/q-mail,moparisthebest/k-9,deepworks/k-9,gaionim/k-9,leixinstar/k-9,WenduanMou1/k-9,tsunli/k-9,vatsalsura/k-9,Eagles2F/k-9,sebkur/k-9,roscrazy/k-9,cliniome/pki,deepworks/k-9,philipwhiuk/k-9,cooperpellaton/k-9,sonork/k-9,jca02266/k-9,cketti/k-9,indus1/k-9,CodingRmy/k-9,cliniome/pki,G00fY2/k-9_material_design,gilbertw1/k-9,WenduanMou1/k-9,k9mail/k-9,moparisthebest/k-9,herpiko/k-9,nilsbraden/k-9,rollbrettler/k-9,sebkur/k-9,tsunli/k-9,ndew623/k-9,leixinstar/k-9,crr0004/k-9,thuanpq/k-9,rollbrettler/k-9,Valodim/k-9,439teamwork/k-9,bashrc/k-9,github201407/k-9,philipwhiuk/q-mail,deepworks/k-9,torte71/k-9,farmboy0/k-9,XiveZ/k-9,icedman21/k-9,sanderbaas/k-9,bashrc/k-9,vt0r/k-9,indus1/k-9,dhootha/k-9,philipwhiuk/k-9,ndew623/k-9,msdgwzhy6/k-9,bashrc/k-9,dgger/k-9,dhootha/k-9,huhu/k-9,439teamwork/k-9,torte71/k-9,rishabhbitsg/k-9,Eagles2F/k-9,gnebsy/k-9,cketti/k-9,konfer/k-9,vt0r/k-9,WenduanMou1/k-9,sedrubal/k-9,roscrazy/k-9,cooperpellaton/k-9,cketti/k-9,XiveZ/k-9,leixinstar/k-9,sebkur/k-9,farmboy0/k-9,tsunli/k-9,denim2x/k-9,gnebsy/k-9,github201407/k-9,ndew623/k-9,XiveZ/k-9,moparisthebest/k-9,k9mail/k-9,KitAway/k-9,denim2x/k-9,icedman21/k-9,vasyl-khomko/k-9,torte71/k-9,crr0004/k-9,GuillaumeSmaha/k-9,rishabhbitsg/k-9,huhu/k-9,gaionim/k-9,GuillaumeSmaha/k-9,gilbertw1/k-9,tonytamsf/k-9,nilsbraden/k-9,G00fY2/k-9_material_design,suzp1984/k-9,vasyl-khomko/k-9,denim2x/k-9,konfer/k-9,tonytamsf/k-9,dpereira411/k-9,suzp1984/k-9,mawiegand/k-9,icedman21/k-9,gilbertw1/k-9,farmboy0/k-9,CodingRmy/k-9,github201407/k-9,jberkel/k-9,dpereira411/k-9,msdgwzhy6/k-9,msdgwzhy6/k-9,GuillaumeSmaha/k-9,crr0004/k-9,thuanpq/k-9,Eagles2F/k-9,sedrubal/k-9,dhootha/k-9,cketti/k-9,huhu/k-9,cooperpellaton/k-9,tonytamsf/k-9