« Back to APIs

Error after Authenticating

Combination View Flat View Tree View
Threads [ Previous | Next ]
toggle
I am getting this error after authenticating to my presence server:
 
ERROR!! <error><mechanism-too-weak xmlns="urn:ietf:params:xml:ns:xmpp-sasl"/></error>
 
What do i need to fix this?
 
I am trying to embed the jabber client into a web app. My Mac Jabber client will authenticate and works fine. But,I can't get any of the sample code to wotk. Any tips would be appreciated.
-tom

Hi Tom,

You haven't actually authenticated yet, that error means that the SASL authentication mechanisms offered by the client are considered "too weak" by the server, therefore there is no authentication type that the client and server can agree on.

That said I'm having the same problem, and I don't have an answer yet, but I'll post here when I get one.

Albert

Hi Tom,

Ok, I figured out how to get past it. The error is misleading as it's the client code throwing the error.

add this

jabberwerx._config.unsecureAllowed = true;

and you should see the authentication go through. I've done this with both "democlient.js" and "sampleclient.html".

As a warning I'm seeing some other disconnects come through, but at least this will get you further.

Albert

Hi Albert,
  I also got past that error with your suggestion but then i get this error:
 
ERROR!! <error><not-authorized xmlns="urn:ietf:params:xml:ns:xmpp-sasl"/></error>
 
  Not sure how to get past this. I can log in to the server with the same credentilas on my Mac Jabber client. I wish there was a public server I could test with.
-tom
 
Hi Tom,

Ok, I figured out how to get past it. The error is misleading as it's the client code throwing the error.

add this

jabberwerx._config.unsecureAllowed = true;

and you should see the authentication go through. I've done this with both "democlient.js" and "sampleclient.html".

As a warning I'm seeing some other disconnects come through, but at least this will get you further.

Albert

Hi Tom,

I've got some ideas but first I'd like to know what domain you're using and which url you're using for the BOSH interface?

Albert

I am using the IP address of the server for the domain and I have an SSL apache proxy to the Bosh interface on the same server at port 7335. I set it up according to the instructions here: http://developer.cisco.com/jabber/doc/api/deploymentGuide.html.

Ok, so what I've done to get things to work is the following.

BOSH URL should be "https://im.ciscowebex.com/isj1" not https://im.ciscowebex.com/http-bind. I've seen numerous intermittent problems using the "http-bind" url.

Also I'd guess you're getting the "not authorized" because you're using the IP address for the domain. Basically the domain needs to be the name of the Connect/Jabber service that you have a user account with. For example my credentials are

albert.gallego@west-eval.com

so when using the sampleclient.html I use the following parameters

var demo_config = {
httpBindingURL: "/httpbinding",
domain: "west-eval.com",
maxGraphAge: 5,
unsecureAllowed: true,
atSymbolAllowed: false,
logPersistence: false
};

and in Apache's httpd.conf I have

ProxyPass /httpbinding https://im.ciscowebex.com/isj1 keepalive=On disablereuse=Off

I also get this error in the sample client:

closed: <stream:error xmlns:stream="http://etherx.jabber.org/streams"><undefined-condition xmlns="urn:ietf:params:xml:ns:xmpp-streams"/></stream:error>

I am also using an on premise CUPS and not Cisco Webex.

Unfortunately I don't have a CUPS server to test against. My suggestion would be to get some traces of exactly what XMPP is going between the client and the server. If you post those I'll see if I can spot anything.

Also have you looked at any error logs from the CUPS side?

Hi Tom,

Can you show us your values for demo_config parameters that you use to connect to CUP server ?
BTW, It would be great if you can send the source-code of your sample to cup-caxl@cisco.com.

Also, Plz send us the logs from jwa_console ( plz check SampleClient implementation[doc/examples/sampleclient.html] for attaching this to your client )

thanks
Shankar

RE: Error after Authenticating
Answer
6/21/12 1:53 AM as a reply to Shankar Ganesh Jayagopi.
I am stuck on this as well.

Can get the sample client to work.

When I go here

http://10.122.23.101/caxl/doc/examples/sampleclient.html

I get a blank page and no info in the console or anything to go on.


When I go here :

http://10.122.23.101/caxl/doc/examples/jutt/index.html
I get

entity added entity<jabberwerx.LocalUser>[[bsunderl@alphawest.com.au]:[]]: bsunderl
entity added entity<jabberwerx.Server>[[alphawest.com.au]:[]]: alphawest.com.au
client status Disconnected ===> Attempting to connect
entity Entity cache batch update started
entity Entity cache batch update completed in 4ms with 0 events.
client ERROR!! <error><mechanism-too-weak xmlns="urn:ietf:params:xml:ns:xmpp-sasl"/></error>
client status Attempting to connect ===> Disconnected


Sample client settings are :

var demo_config = {
domain: "alphawest.com.au",
maxGraphAge: 5,
unsecureAllowed: true,
atSymbolAllowed: false,
logPersistence: false,
serviceDiscoveryEnabled: false,
httpBindingURL: "/httpbinding",
httpBindingURL_secondary: "/httpbinding"
};


Although not sure where "sampleclient.html" gets the user id from ?

Conversely, in http://10.122.23.101/caxl/doc/examples/jutt/index.html I am not sure where it gets the server details from having set just this ( assume it just uses /httpbinding" )

// Setup username and password
this.username = "bsunderl@alphawest.com.au";
this.password = "*********";

Note , my BOSH Server is at awcupres01@alphawest.com.au, and http://myservrer_that_hosts_JABBER_SDK/httpbinding DOES give me an apparent successful connection to BOSH (I set up a forward proxy w/ SSL).

Others suggested this : unsecureAllowed: true, but I already have this ? Could the issue be taht my BOSH sevrer only talks SSL ? Do I need to import the cert from BOSH server into my SDK webservers keystore ? ??

Note, I got the softphone samples working in a flash, CAXL seems more tricky.

Ben



Sample client settings are :

var demo_config = {
domain: "alphawest.com.au",
maxGraphAge: 5,
unsecureAllowed: true,
atSymbolAllowed: false,
logPersistence: false,
serviceDiscoveryEnabled: false,
httpBindingURL: "/httpbinding",
httpBindingURL_secondary: "/httpbinding"
};

Ben,
The key setting will be the domain and the httpBindURL.
The domain needs to match with the domain name setting with your CUP server.
If you use Proxy to forward, then the httpBindingURL will be "http://Your_Proxy_Server/httpbinding"
If you directly connecting to CUP server, it should be "https://Your_CUP_Server:<code>:7335/httpbinding"</code>
Make sure the same usename can be login to your CUP server, and is assigned into the Topology.
The unsecureAllowed is a arg that allows you to connect using http.
 
Hope this would help
 
Howard

Hi ,

Can somebody help me out to find out what would be the actual server binding url that need to used for testing.

I am using the following config set

client = new jabberwerx.Client();
var connectArgs = {
domain : "cisco.com",
maxGraphAge : 5,
unsecureAllowed : true,
atSymbolAllowed : false,
logPersistence : false,
serviceDiscoveryEnabled : false,
httpBindingURL: "https://im.ciscowebex.com/isj1"
};

jabberwerx.$(document).bind("ready", function() {
//client.connect("jwtest0@example.com", "test", connectArgs);
client.connect("magandhi01","*******",connectArgs);
});





Thanks
Haji Chowdary

Hi ,

Can somebody help me out to find out what would be the actual server binding url that need to used for testing.

I am using the following config set

client = new jabberwerx.Client();
var connectArgs = {
domain : "cisco.com",
maxGraphAge : 5,
unsecureAllowed : true,
atSymbolAllowed : false,
logPersistence : false,
serviceDiscoveryEnabled : false,
httpBindingURL: "https://im.ciscowebex.com/isj1"
};

jabberwerx.$(document).bind("ready", function() {
//client.connect("jwtest0@example.com", "test", connectArgs);
client.connect("cbasha","*******",connectArgs);
});

I am getting the following Error on successful authentication for the request

<<Post Request xml:>>
<body xmlns="http://jabber.org/protocol/httpbind" sid="66naQ4tD83xUtaRJf8U1tA14901" rid="601454592">
<iq id="resource-bind" xmlns="jabber:client" type="set">
<bind xmlns="urn:ietf:params:xml:ns:xmpp-bind"></bind>
</iq>
</body>

<<Response XML>>
<html><head><title>Not Found</title></head><body>Not Found</body></html>

Can you please let me know if i am using the correct config set and appropriate URL?. I have a valid WebEx account id cbasha@cisco.com

Thanks
Haji

Haji,
Instead of httpBindingURL: "https://im.ciscowebex.com/isj1"
Please try httpBindingURL: "https://im3.ciscowebex.com/http-bind"
Also, make sure you are using the hosted SDK, not the on-prem SDK

Hope this would help
Howard

Thanks Ting-Hao Chen for quick reply, This really helped me . Now I am able to get the connection and reply.

Regards
Haji