Article View: news.software.nntp
Article #83622Re: Encoding of AUTHINFO USER/PASS arguments
From: Joshua Cranmer
Date: Thu, 04 Nov 2010 12:58
Date: Thu, 04 Nov 2010 12:58
31 lines
2605 bytes
2605 bytes
On 11/03/2010 04:37 PM, Julien ÉLIE wrote: > I therefore wonder how news clients handle 8-bit passwords. > > ** How do current news readers send them to news servers? Looking at the code for Thunderbird, the password is lossily converted to ASCII, so non-ASCII characters shouldn't work. A brief search on bugzilla indicates a single bug for this with a single duplicate and rather little interest by the outside community, so it seems that the occurrence of non-ASCII passwords is relatively rare. > Suppose my password is "été". What is sent for: > > AUTHINFO PASS été > ? > > Is it '\xE9' + 't' + '\xE9' (3 bytes) or "été" (5 bytes, > encoded in UTF-8)? Given my general background knowledge of NNTP charset handling in Thunderbird, the most appropriate thing to do is to keep handling it in the same charset as the server. So if I said that this is a server that uses GB2312, it sends the password in GB2312. If I said it was UTF-8, it uses UTF-8. Which means if the rest of your communication uses UTF-8, UTF-8 passwords are the safest way to go. -- Beware of bugs in the above code; I have only proved it correct, not tried it. -- Donald E. Knuth
Technical Details
Message-ID:
<iaualu$eqc$1@news-int2.gatech.edu>Path:
mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.nntp.20141118.mbox.gz!border1.nntp.ams3.giganews.com!border1.nntp.ams2.giganews.com!border3.nntp.ams.giganews.com!border1.nntp.ams.giganews.com!nntp.giganews.com!weretis.net!feeder4.news.weretis.net!nntp.club.cc.cmu.edu!micro-heart-of-gold.mit.edu!bloom-beacon.mit.edu!news-ext.gatech.edu!news-int.gatech.edu!not-for-mailReferences:
<iash7b$1vm$1@news.trigofacile.com>Show Full Headers
Complete Article Headers
Message-ID: <iaualu$eqc$1@news-int2.gatech.edu> Subject: Re: Encoding of AUTHINFO USER/PASS arguments Date: Thu, 04 Nov 2010 08:58:38 -0400 From: Joshua Cranmer <Pidgeot18@verizon.invalid> References: <iash7b$1vm$1@news.trigofacile.com> Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.nntp.20141118.mbox.gz!border1.nntp.ams3.giganews.com!border1.nntp.ams2.giganews.com!border3.nntp.ams.giganews.com!border1.nntp.ams.giganews.com!nntp.giganews.com!weretis.net!feeder4.news.weretis.net!nntp.club.cc.cmu.edu!micro-heart-of-gold.mit.edu!bloom-beacon.mit.edu!news-ext.gatech.edu!news-int.gatech.edu!not-for-mail Newsgroups: news.software.nntp,news.software.readers Organization: Georgia Institute of Technology Lines: 31 NNTP-Posting-Host: res-128-61-91-23.res.gatech.edu Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-15; format=flowed Content-Transfer-Encoding: 8bit X-Trace: news-int2.gatech.edu 1288875518 15180 128.61.91.23 (4 Nov 2010 X-Complaints-To: usenet@news-int2.gatech.edu NNTP-Posting-Date: Thu, 4 Nov 2010 12:58:38 +0000 (UTC) User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; Thunderbird/3.1.6pre In-Reply-To: <iash7b$1vm$1@news.trigofacile.com> X-Original-Bytes: 2459