Sign in to follow this  
Max_Payne

MSN Messenger Library?

Recommended Posts

I'm looking for a library that implements the MSN messenger protocol and is written in C/C++ (preferably C++). It would be nice if it supported MSN display images. I know there is DotMSN, but that is for .NET only, and portability matters to me. I also know of libmsn, but the development seems halted and they support very minimal features (excluding display images). I've also thought of taking apart an open source MSN client... But I couldn't find one with the features I wanted written entirely in C++. Any help would be appreciated...

Share this post


Link to post
Share on other sites
I think there's a branch of gaim called libgaim which basically gives you all the IM protocol support of gaim minus all the UI etc so you can build it into your own applications.

Share this post


Link to post
Share on other sites
Quote:
Original post by Monder
I think there's a branch of gaim called libgaim which basically gives you all the IM protocol support of gaim minus all the UI etc so you can build it into your own applications.


That would be quite interesting, but do you have any idea where it can be found? I can only seem to find talks about "when GAIM will be done" dating from 2003 (hopefully it is done?)

Share this post


Link to post
Share on other sites
Quote:
Original post by Monder
I think there's a branch of gaim called libgaim which basically gives you all the IM protocol support of gaim minus all the UI etc so you can build it into your own applications.


You might also be able to do something similar with Miranda-IM, another open source IM client. They use plugin DLL's to connect to various networks so in theory, if you use the plugin DLL's the same way, you might be able to support the various IM networks.

Share this post


Link to post
Share on other sites
I recently wrote an MSN bot to automate the last bits of my social life. The library I used is for C# though, but hell, if your fluent in C++ you can pickup C# in a day ( C -> C# takes a week, in my experience ).

DotMSN - .NET Messenger Library

The documentation is horrible; its for the programmers, not the end user. Go to www.planet-source-code.com download the dos-console code that demonstrates how to use this library, and learn from that.

Share this post


Link to post
Share on other sites
This is pretty much the only source I used: http://www.hypothetic.org/docs/msn/index.php

My client can connect and do basic MSN stuff, but it doesn't support images or anything. The reason is, that part of the MSN protocol is when you recieve a challenge message, the server expects you to MD5 hash some value with another value. The problem is that one of the values is unknown (nobody seems to know how these values were reached), and the only known listed ones are for older protocol versions. I don't know how other clients do display images and the like.

Also, the newer protocols haven't been taken apart completely yet.

There's a version of my code uploaded Here (VC 6 workspace) which includes OpenSSL stuff for the HTTPS authentication. It's been ages since I looked at it though, and the code is a bit odd. As I said, it doesn't implement a lot of stuff, but it should be a reasonablr starting pooint.

Let me know if there's any issues with it. The protocol is ugly as hell, just look at CMSN::AttemptLogin in MSN.cpp...

Share this post


Link to post
Share on other sites
Quote:
Original post by Evil Steve
This is pretty much the only source I used: http://www.hypothetic.org/docs/msn/index.php

My client can connect and do basic MSN stuff, but it doesn't support images or anything. The reason is, that part of the MSN protocol is when you recieve a challenge message, the server expects you to MD5 hash some value with another value. The problem is that one of the values is unknown (nobody seems to know how these values were reached), and the only known listed ones are for older protocol versions. I don't know how other clients do display images and the like.

Also, the newer protocols haven't been taken apart completely yet.

There's a version of my code uploaded Here (VC 6 workspace) which includes OpenSSL stuff for the HTTPS authentication. It's been ages since I looked at it though, and the code is a bit odd. As I said, it doesn't implement a lot of stuff, but it should be a reasonablr starting pooint.

Let me know if there's any issues with it. The protocol is ugly as hell, just look at CMSN::AttemptLogin in MSN.cpp...


I might just end up writing some kind of plugin *in* Miranda-IM or *in* gaim so that my software can use the IM software as it is. Surely someone has figured out display images since Trillian does it...

Share this post


Link to post
Share on other sites
Quote:
That would be quite interesting, but do you have any idea where it can be found?


Unfortunately no, I've seen it mentioned in various places but I've never found somewhere which actually has the straight library for D/L. Adium purports to use it, so you may find the library by poking around in the source (I took a brief look through the SVN tree and found a few references to it but nothing that actually looked like the libgaim source), it may be sitting around in the gaim CVS as well.

Share this post


Link to post
Share on other sites
I would also be interested in documentation on how to write plugins for IM software, assuming that can allow me to do what I want (use the IM software to allow my own software to communicate over MSN, and possibly other networks).

Share this post


Link to post
Share on other sites
Well, gaim meets my expectations, and I'd like to code a gaim plugin. However, I'm wondering where I could go about finding instructions on how to do this. Compiling the whole gaim source to have it statically compiled is unappealing to me since there are so many dependencies (I would have to install at least 5 packages on my windows machine, and reinstall cygwin just to hope to get it to compile).

I'm hoping to compile my plugin as a clean, lean DLL without having to even use cygwin, if possible. Does anyone know how to go about doing that?

I don't know what the hell is up with the gaim documentation, but it seems to be all disjoint and I can't find anything in it.

Share this post


Link to post
Share on other sites
I guess this mostly answers my question, although it's still shadowy what dependencies need to be cared for and how the makefile needs to be changed:

http://gaim.sourceforge.net/faq.php#q94

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this