[jdev] sasl plain again
Norman Rasmussen
norman at rasmussen.co.za
Thu Apr 13 05:02:52 CDT 2006
On 4/13/06, Adrian Adrian <flashbk2003 at yahoo.com> wrote:
> Hello list,
>
> Sorry to bring an old issue again but I'm still not clear with SASL PLAIN
> authentication mechanism.
> My XMPP server is the brand new Wildfire 1.6. The new server update takes
> care of that bug that didn't allow empty auth packet.
>
> My communication is this :
> C [start stream]
> S [advertises auth mechanism]
> C [select mechanism]
> <auth
> xmlns='urn:ietf:params:xml:ns:xmpp-sasl'mechanism='PLAIN'/>
> S [blank challenge]
> <challenge
> xmlns="urn:ietf:params:xml:ns:xmpp-sasl">=</challenge>
> C "initial response"
> This "initial response" is giving me a hard time.
> This is the place where I'm supposed to send user name and password base64
> encoded to the server ?
yes,
either as part of the auth:
<auth xmlns='urn:ietf:params:xml:ns:xmpp-sasl'mechanism='PLAIN'>stuffin
here</auth>
or later as the reponse:
<repsonse xmlns='urn:ietf:params:xml:ns:xmpp-sasl'mechanism='PLAIN'>stuffin
here</response>
> And another stupid question :
> Is there a way to send credentials in an other form than null character
> delimited ?
No, unfortunatly not.
> The language I write the code with (flash actionscript 2.0) is
> truncating strings at the first '\0' encountered. And as I figure
> base64(str1+"\0"+str2) isn't the same with base64(str1)+'='+base64(str2)
Correct, they're different.
I assume you're using the meychi encoder (I found your comments on
their blog)? Maybe try and post a comment on their forums about
trying to encode nulls.
--
- Norman Rasmussen
- Email: norman at rasmussen.co.za
- Home page: http://norman.rasmussen.co.za/
More information about the JDev
mailing list