Not logged in. · Lost password · Register
Forum: agsXMPP RSS
Avatar
Paul #1
Member since Oct 2008 · 4 posts
Group memberships: Members
Show profile · Link to this post
Subject: agsXMPP for Silverlight 2
Hi,

I'm building a Chat app in Silverlight 2, and I wanted to use the sample project from the article posted on your blog as an example. I installed an Openfire server on my computer to perform connection tests locally. I tried to run your app, using some account I created on that server.

The connection doesn't even occur, and I don't get any message on the server console, though I changed the client-to-server port to 4530 in both server settings and silverlight code, and provided all the information to make the connection via xmpp protocol.

If you have any details on how you managed to establish a connection in silverlight, please let me know. I have a lot of time to spend on this work as it is a part of a school project.

Thanks,

Paul
Avatar
Alex #2
Member since Feb 2003 · 4307 posts · Location: Germany
Group memberships: Administrators, Members
Show profile · Link to this post
hi Paul,

I run the server on my local developer machine on port 4502.
Because Silverlight allows only connections on a small port range and no cross domain requests.

Alex
Avatar
Paul #3
Member since Oct 2008 · 4 posts
Group memberships: Members
Show profile · Link to this post
Hi Alex,

As I said in the first message, I also configured both the local server and the silverlight application to communicate on port 4530, which is in the range that Silverlight supports, so I don't think this is where the problem comes from. Anyway I will try out with 4502 just to see hat it does.

For cross domain communication, silverlight 2 beta 2 now allows it but with a condition : you have to define a security policy in a file that tells the app if the connection is allowed or not (you can provide ip address range, port range, etc.)µ.


Check this blog post which explains it in details :
http://timheuer.com/blog/archive/2008/06/06/silverlight-so…
Avatar
Paul #4
Member since Oct 2008 · 4 posts
Group memberships: Members
Show profile · Link to this post
I've tried several configurations on my OpenFire server but I still cannot connect to it with your sample application. Can you give me some details about your own local config : what server you use to run the app locally, what your server configuration is, etc.

Thank you,
Avatar
Alex #5
Member since Feb 2003 · 4307 posts · Location: Germany
Group memberships: Administrators, Members
Show profile · Link to this post
Hi Paul,

I run a local ejabberd server on the domain alex-laptop which is the workstation nae of my developer machine. I attached my ejabberd config. There you can see a second connection manager for c2s on port 4502.

Did you try to sniff the network traffic on your machine to see if it creates a tcp connection and exchanges some xmpp stanzas with the server or not?

Alex
The author has attached one file to this post:
ejabberd.cfg 10.7 kBytes
You have no permission to open this file.
Avatar
Paul #6
Member since Oct 2008 · 4 posts
Group memberships: Members
Show profile · Link to this post
Thank you for the response,

in fact I tried with another approach, using a web service in my silverlight application to make the connection. But I think I will give a try with a ejabberd server, because right now I'm using Openfire and the problem might come from some compatibility issues.

I'll let you know if it worked. Thanks again.
Avatar
Alex #7
Member since Feb 2003 · 4307 posts · Location: Germany
Group memberships: Administrators, Members
Show profile · Link to this post
Paul, do you have a policy server running on your local machine like described here:
http://silverlight.net/blogs/msnow/archive/2008/06/26/full…

Today I updated to the release version of Silverlight 2.0 and it doesnt work without the policy server.
You can contact me directly and I will send you the latest Silverlight version and a Policy server project.

Regards,
Alex
Close Smaller – Larger + Reply to this post:
Verification code: VeriCode Please enter the word from the image into the text field below. (Type the letters only, lower case is okay.)
Smileys: :-) ;-) :-D :-p :blush: :cool: :rolleyes: :huh: :-/ <_< :-( :'( :#: :scared: 8-( :nuts: :-O
Special characters:
Forum: agsXMPP RSS