Page 1 of 4 1234 LastLast
Results 1 to 40 of 124

Thread: Badger Messenger, an MSN clone that uses the MSN Network.

  1. #1

    Thread Starter
    Super Moderator Wokawidget's Avatar
    Join Date
    Nov 2001
    Location
    Headingly Occupation: Classified
    Posts
    9,633

    Badger Messenger, an MSN clone that uses the MSN Network.

    IMPORTANT: (updated 25 Feb 2010) In the last few months Microsoft have stopped the MSN network using the MSNP9 protocol. This means the following project does NOT work since it replies on this protocol. See posts 118 to 120 in this thread as to why this doesn't work in more depth. I will be looking at writing a newer .NET version using the latest protocol later this year.

    Ok, here it is.
    Still rough, but it's good enough to put up here now.

    This is the source code to a version of MSN messenger I have written.

    The original source code I got this from was posted here a week or so ago by alkatran. The link for this thread is here:

    http://www.vbforums.com/showthread.php?t=323108

    Cheers, for posting your code, not many do, more should


    Badger Messenger so far doesn't actually do much.

    You can log into your MSN account, see your contacts, change your status, add and delete groups. You can sort contacts numerous ways too. That's it.
    There's a lot more coded into the DLL, I just haven't added the functionality in the UI yet.

    Conversations don't work yet. I had them working but refractured the code and haven't got round to putting it in. The old code is just remarked out.


    SOme of the features include:
    • Set initial status before login
    • Add Group
    • Delete Group
    • Rename Group
    • Set Contacts Nickname (different to their displayname. The nick name is a name you can give them and see them by)
    • Set your displayname
    • Set your status
    • Remembers last login and settings
    • List contacts by email, nickname or displayname
    • See which of your contacts DO NOT have you on their contacts list


    The MSNMessenger code is in a DLL, so you can refernece this in any of your apps and easily write your own UI for it.
    You can even link it to your corporate DB and only allow certain emails to be registered as contacts, ie for a site engineer, the MSN network is great to chat to your mates but it's really for contacting ya boss back at the office.


    Think that's it so far.

    The site I got the MSN protocols from was quite handy:

    http://www.hypothetic.org/docs/msn/n...le_session.php


    Comments are most welcome.

    Future revisions will be posted here frequently over the next week.

    Just unzip the file, and then run Test.vpg

    This code ain't for the faint hearted


    A newer Version can be foound 2 posts down...the attachment on this post is the old version, but is left here for historical reasons


    Even newer post!
    Updated 20th Sept 2005: See post #34

    Woof
    Attached Files Attached Files

  2. #2

  3. #3
    PowerPoster Pc_Madness's Avatar
    Join Date
    Dec 2001
    Location
    Melbourne, Australia
    Posts
    2,765

    Re: Badger Messenger, an MSN clone that uses the MSN Network.

    Bad Woka bad!

    SetDisplayName hammers the msn server till it disconnects you.

    And you still haven't fixed the line in vbMSNMessenger.modMSPassport:GetPassPort()

    mobjHttp.SetRequestHeader "Authorization", "Passport1.4 OrgVerb=GET,OrgURL=http%3A%2F%2Fmessenger%2Emsn%2Ecom,sign-in=" & pstrEmail & ",pwd=" & pstrPassword & "," & pstrProtocol

    to allow the use of nonstandard characters.
    Don't Rate my posts.

  4. #4

    Thread Starter
    Super Moderator Wokawidget's Avatar
    Join Date
    Nov 2001
    Location
    Headingly Occupation: Classified
    Posts
    9,633

    Re: Badger Messenger, an MSN clone that uses the MSN Network.

    OK, here's the new version.

    It has a few more features added.

    Most of the above features have now bneen fully implemented in the UI.
    Auto login feature, plus initial login status.

    Change displayname and status.

    Contacts in RED do NOT have you on their contact list

    Easily see who's on your banned and allowed list.

    You can now initiate a chat, or receive a chat.

    The code is a little buggy in some places, it's still only an alpha release, but it's comming along.

    Need more testers and feedback.

    Woof
    Attached Files Attached Files

  5. #5
    New Member
    Join Date
    Mar 2005
    Posts
    13

    Re: Badger Messenger, an MSN clone that uses the MSN Network.

    VERY NICE! lolz, a good thing to add to this would be the ability to send files to your contacts, so if you have friends using msn 6 or 7 and u sign on usng this, you are still able to send and receive files from your contacts, please can you help me with this, i need help sending files accross msn 6, i want to set up a file server at home where when a message is received, it check it and if it is something then it will send that file to that person, how to send files over msn please

  6. #6
    New Member
    Join Date
    Mar 2005
    Posts
    8

    Re: Badger Messenger, an MSN clone that uses the MSN Network.

    i cant get it to an exe from some reason

  7. #7
    New Member
    Join Date
    Mar 2005
    Posts
    8

    Re: Badger Messenger, an MSN clone that uses the MSN Network.

    sorry for double post but..

    Woka i did what you sayd but it says:
    Code:
    The Project 'DemoUi' can not be build because it references project '*my path*\vbMSNMessenger.vbp' That Has Not Been Build


    i dont understand why it doesnt work =\ im a vb newb kidda..

  8. #8

    Thread Starter
    Super Moderator Wokawidget's Avatar
    Join Date
    Nov 2001
    Location
    Headingly Occupation: Classified
    Posts
    9,633

    Re: Badger Messenger, an MSN clone that uses the MSN Network.

    Yes. You have to change the reference that it points to.
    Toools...References....Now select vbMSNMessenger, but the DLL version. Remove the current vbMSNMessenger ref as this looks at the project.

    Woka

  9. #9
    New Member
    Join Date
    Mar 2005
    Posts
    8

    Re: Badger Messenger, an MSN clone that uses the MSN Network.

    i still cant get it...
    so what your saying is that i have to remove the vbmsnmessenger reference?

    Gunner
    Last edited by gunner; Mar 15th, 2005 at 09:24 AM.

  10. #10
    New Member
    Join Date
    Mar 2005
    Posts
    8

    Re: Badger Messenger, an MSN clone that uses the MSN Network.

    Hi,
    when i send it to other persons it requiers dll's well woka said all ref things , so thats what i did. but he still cant run it

    also im trying to change the status pictures but it doesnt work =\

  11. #11
    PowerPoster Pc_Madness's Avatar
    Join Date
    Dec 2001
    Location
    Melbourne, Australia
    Posts
    2,765

    Re: Badger Messenger, an MSN clone that uses the MSN Network.

    You need to remove all the references, compile each of the projects in the project group and then add the references again.

    If you want to give it to someone else then you'll need to get them to register the dll files, which can be done using an installer or, from Run the regsvr32 command, but I can't remember the syntax... I think its just 'regsvr32 Pathtodllgoeshere'....

    And my understanding was that "display pictures" weren't support at the moment, its using the protocol before display pictures? And even then, he hasn't included support for it.

  12. #12
    New Member
    Join Date
    Mar 2005
    Posts
    8

    Re: Badger Messenger, an MSN clone that uses the MSN Network.

    yes i know but what are the dll files i need to send to them?

    and i mean status pictures: like away and busy and stuff like that.

  13. #13
    Fanatic Member
    Join Date
    Mar 2002
    Location
    AUSTRALIA
    Posts
    603

    Re: Badger Messenger, an MSN clone that uses the MSN Network.

    Hi Wokawidget,
    As you know(from my postings), I like to keep things simple.
    Thus I usually avoid VBG's and DLLs etc, so an idiot like me can compile and distribute very easily.

    I recently was looking at a project which required a DLL. The author pointed out that we should not register his DLL. Instead we just ensure it is in the same path as the exe. Or if we like, we can place it in the Windows\System32 folder.
    That sounded 'like a piece of cake' to me.

    This question may expose my lack of knowledge regarding DLLs, but could yours be made like that ?
    Or are there apples and oranges with DLLs (different types, with different requirements) >
    Rob C

  14. #14

    Thread Starter
    Super Moderator Wokawidget's Avatar
    Join Date
    Nov 2001
    Location
    Headingly Occupation: Classified
    Posts
    9,633

    Re: Badger Messenger, an MSN clone that uses the MSN Network.

    The DLLs in my project definately require registering.

    AxtiveX Usercontrols, OCX files, can be placed in the apps folder, or System32, and they will get registered automatically. Not sure about different DLLs though.
    Mine DO require installing.

    I have heard you mention keeping it simple before

    But what is even simpler is learning Inno setup and using that to install the app.
    ALL vb apps require DLLs. Even a simple EXE requires 3 DLLs for the VB runtimes. Most PCs have these installed from other apps, and so your app works. But this will not always be the case.

    What people fail to realise is that using an installer is JUST as important as any other process involved in your app. I have nevr quite understood why people are scared of them

    Woka

  15. #15
    PowerPoster Pc_Madness's Avatar
    Join Date
    Dec 2001
    Location
    Melbourne, Australia
    Posts
    2,765

    Re: Badger Messenger, an MSN clone that uses the MSN Network.

    Generally a case a of hosting size restrictions and being on dial up is usually the reason for wanting to avoid Installers... espiceally when the program is a 50k exe and a 20k dll.


    Remind me to show you my blocking code, it works but when you log back in again it nolonger recieves the contacts display Name.

  16. #16
    Hyperactive Member Arachnid13's Avatar
    Join Date
    Jan 2003
    Location
    England
    Posts
    327

    Question Re: Badger Messenger, an MSN clone that uses the MSN Network.

    hey, nice code, do you think you could make something that runs alongside msn7 and changes ur name at certain time interval... for example.. you could have your name, with a smiley bouncing left and right through ur name:

    Arachnid13
    Arachnid13
    Arachnid13
    Arachnid13
    Arachnid13
    Arachnid13
    Arachnid13
    Arachnid13
    Arachnid13
    Arachnid13
    Arachnid13

    i've been wanting to do this for ages and been trying to find code to do it but i havent been able to
    Do you wake up in the morning feeling sleepy and grumpy? Then you must be Snow White

  17. #17
    PowerPoster Pc_Madness's Avatar
    Join Date
    Dec 2001
    Location
    Melbourne, Australia
    Posts
    2,765

    Re: Badger Messenger, an MSN clone that uses the MSN Network.

    You can only change your name so many times and then the server will block the command for a while.

  18. #18
    Hyperactive Member Arachnid13's Avatar
    Join Date
    Jan 2003
    Location
    England
    Posts
    327

    Re: Badger Messenger, an MSN clone that uses the MSN Network.

    hmm, well i may just have to design my own chat network then!
    Do you wake up in the morning feeling sleepy and grumpy? Then you must be Snow White

  19. #19
    Addicted Member
    Join Date
    Feb 2005
    Posts
    163

    Re: Badger Messenger, an MSN clone that uses the MSN Network.

    it is very good i ihave to say, is there a way of making it get info from my site regesterants. so only people who are in my site can chat.

  20. #20

    Thread Starter
    Super Moderator Wokawidget's Avatar
    Join Date
    Nov 2001
    Location
    Headingly Occupation: Classified
    Posts
    9,633

    Re: Badger Messenger, an MSN clone that uses the MSN Network.

    Yup.
    This is what I wrote it for....as a demo to my boss that we can use the MSN network for our engineers, but you can check your own local DB for permissions as well as having an MSN account.
    In the frmMain you have the following function:
    VB Code:
    1. Public Sub SignIn(ByVal pblnAutoLogin As Boolean)
    2. Dim strEmail    As String
    3. Dim strPassword As String
    4. Dim enmStatus   As vbBadgerMessenger.vbBadgerStatusConstants
    5. Dim blnLogin    As Boolean
    6.     If pblnAutoLogin Then
    7.         strEmail = GetSysSetting(SECTION_LOGIN, SETTING_LOGIN_EMAIL)
    8.         strPassword = DecryptData(GetSysSetting(SECTION_LOGIN, SETTING_LOGIN_PASSWORD))
    9.         enmStatus = ctlLoginStatus.Status
    10.     End If
    11.     If Len(strEmail) > 0 And Len(strPassword) > 0 Then
    12.         blnLogin = True
    13.     Else
    14.         If GetLoginDetails(strEmail, strPassword, enmStatus) Then
    15.             ctlLoginStatus.Status = enmStatus
    16.             blnLogin = True
    17.         End If
    18.     End If
    19.     If blnLogin Then
    20.         If pblnAutoLogin Then
    21.             SetSysSetting SECTION_LOGIN, SETTING_LOGIN_STATUS, ctlLoginStatus.Status
    22.         End If
    23.         Screen.MousePointer = vbHourglass
    24.         mnuSignIn.Enabled = False
    25.         cmdSignIn.Enabled = False
    26.         mobjMSN.SignIn strEmail, strPassword, enmStatus
    27.     End If
    28. End Sub
    The line of code that logs you in is:
    VB Code:
    1. mobjMSN.SignIn strEmail, strPassword, enmStatus
    So, what you want is something like.
    VB Code:
    1. 'rest of code from function
    2. If CustomLogin() Then
    3.    mobjMSN.SignIn strEmail, strPassword, enmStatus
    4. End If
    5. 'rest of fucntion code
    6.  
    7. Private Function CustomLogin() As Boolean
    8.    'code to validate engineers login against your DB
    9. End Function
    You may want to open another username password form so they can enter their site details, but I wud just validate the email address to be fair, something like:
    VB Code:
    1. Private Function CustomLogin(ByVal pstrEmail As String) As Boolean
    2.    'code to validate engineers login against your DB
    3. End Function
    What code here completely depends on your system, or how your uses are going to validate against your DB.
    If the DB in on a local LAN, which is what it is in my case, then I can just use ADO to connect to the SQL DB, or access, and validate the email address.
    If you are doing this via the web, ie the DB is on your web server, then there are a number of ways to do this. I would go for a WebService written in .NET, but this does require you to learn webservices and have a copy of .NET.
    You could also use ADO again, and by specifying the IP of the server you may be able to connect to your remote DB. Klienma, an admin here, does this all the time so you may want to ask him about this.
    The other method would be to use a INet control on the form. You then write a web page that handles an Email param. Then using JS and VBscript or PHP, whatever, you can take that param and validate it. Then all you need to do is write a response to the page of True, or False. Your Msnger client will then just look at the text of the web page to see if it's been valdiated or not.

    Hope that points you in the right direction. If you have any questions then give me a shout.

    Woka

  21. #21
    Addicted Member
    Join Date
    Feb 2005
    Posts
    163

    Re: Badger Messenger, an MSN clone that uses the MSN Network.

    OK i don't know how i can connect to sql db using vb how can i do it? i will be using a remote server will it be possible?

  22. #22
    I'm about to be a PowerPoster! kleinma's Avatar
    Join Date
    Nov 2001
    Location
    NJ - USA (Near NYC)
    Posts
    23,383

    Re: Badger Messenger, an MSN clone that uses the MSN Network.

    connecting to a SQL Server using ADO is pretty simple, and just as simple connecting to a remote one as a local one.

    this function will return an open connection to a SQL Server... replace the DBNAMEHERE,PASSWORDHERE, etc with your own values.
    VB Code:
    1. Public Function OpenCN() As ADODB.Connection
    2.  
    3. On Error GoTo EH:
    4.  
    5.     Set OpenCN = New ADODB.Connection
    6.    
    7.     '*********************************************
    8.     'SQL SERVER CONNECTION
    9.     OpenCN.ConnectionString = "Provider=SQLOLEDB;Persist Security Info=false;User ID=USERIDHERE;pwd=PASSWORDHERE;Initial Catalog=DBNAMEHERE;Server=SERVERNAMEHERE;Database=DBNAMEHERE;Locale Identifier=1033;Connect Timeout=10;Use Procedure for Prepare=1;Auto Translate=True;Packet Size=4096"
    10.     '*********************************************
    11.    
    12.     OpenCN.Open
    13.    
    14.     Exit Function
    15.  
    16. EH:
    17.     MsgBox "Error connecting to SQL Server.", vbCritical
    18.     Set OpenCN = Nothing
    19. End Function

  23. #23

  24. #24
    I'm about to be a PowerPoster! kleinma's Avatar
    Join Date
    Nov 2001
    Location
    NJ - USA (Near NYC)
    Posts
    23,383

    Re: Badger Messenger, an MSN clone that uses the MSN Network.

    sorry, IP would be the server name...

    something like this
    "Provider=SQLOLEDB;Persist Security Info=false;User ID=kleinma;pwd=kleinmaspassword;Initial Catalog=kleinmasdb;Server=42.36.101.5;Database=kleinmasdb;Locale Identifier=1033;Connect Timeout=10;Use Procedure for Prepare=1;Auto Translate=True;Packet Size=4096"
    standard port for SQL Server (2000) is 1433, the connection will use that by default. If the port is different you specify it like this

    IP,PORT
    like this
    "Provider=SQLOLEDB;Persist Security Info=false;User ID=kleinma;pwd=kleinmaspassword;Initial Catalog=kleinmasdb;Server=42.36.101.5,2433;Database=kleinmasdb;Locale Identifier=1033;Connect Timeout=10;Use Procedure for Prepare=1;Auto Translate=True;Packet Size=4096"

  25. #25
    Addicted Member
    Join Date
    Feb 2005
    Posts
    163

    Re: Badger Messenger, an MSN clone that uses the MSN Network.

    can this be used to connect to mysql?

  26. #26
    I'm about to be a PowerPoster! kleinma's Avatar
    Join Date
    Nov 2001
    Location
    NJ - USA (Near NYC)
    Posts
    23,383

    Re: Badger Messenger, an MSN clone that uses the MSN Network.

    you could connect to mysql, but the connection string provided is for SQL Server only. Each type of DB server has its own set of information needed to connect.

    check out this site: http://www.connectionstrings.com/

    you can find connection string configurations to virtually any DB you can imagine

  27. #27
    Addicted Member
    Join Date
    Feb 2005
    Posts
    163

    Re: Badger Messenger, an MSN clone that uses the MSN Network.

    the link only does vb.net wile i am using vb6?

  28. #28
    I'm about to be a PowerPoster! kleinma's Avatar
    Join Date
    Nov 2001
    Location
    NJ - USA (Near NYC)
    Posts
    23,383

    Re: Badger Messenger, an MSN clone that uses the MSN Network.

    a connection string is a connection string so even if its says its .net, thats because its showing you a connection using .net objects, but the actual string sent to the database is still the same

    for example under MySQL ole db connection info, it shows
    Provider=MySQLProv;Data Source=mydb;User Id=UserName;Password=asdasd;"

    this would still be the same in VB6

  29. #29
    New Member
    Join Date
    Aug 2005
    Posts
    1

    Re: Badger Messenger, an MSN clone that uses the MSN Network.

    hi woof, how can i help you with this vb clone to the msn network ?


    Quote Originally Posted by Wokawidget
    OK, here's the new version.

    It has a few more features added.

    Most of the above features have now bneen fully implemented in the UI.
    Auto login feature, plus initial login status.

    Change displayname and status.

    Contacts in RED do NOT have you on their contact list

    Easily see who's on your banned and allowed list.

    You can now initiate a chat, or receive a chat.

    The code is a little buggy in some places, it's still only an alpha release, but it's comming along.

    Need more testers and feedback.

    Woof

  30. #30

  31. #31
    Fanatic Member uniquegodwin's Avatar
    Join Date
    Jul 2005
    Location
    Chennai,India
    Posts
    694

    Re: Badger Messenger, an MSN clone that uses the MSN Network.

    Can you give me some advice on how I can make a similar kind of thing for yahoo messenger using vb.net? If you have any plans of making it,I would Love to help doesnt matter even if its for msn..but,using .net.
    Godwin

    Help someone else with what someone helped you!

  32. #32

    Thread Starter
    Super Moderator Wokawidget's Avatar
    Join Date
    Nov 2001
    Location
    Headingly Occupation: Classified
    Posts
    9,633

    Re: Badger Messenger, an MSN clone that uses the MSN Network.

    I have no idea what type of advice to give.
    The main structure and implementation of a yahoo messenger would be very similar, just a different protocol.
    I am currently writting badgermessenger.Net although it's quite a way off yet. Still playing with it.

    If you find any info on the yahoo protocol then that would be great,

    Woof

  33. #33
    Fanatic Member uniquegodwin's Avatar
    Join Date
    Jul 2005
    Location
    Chennai,India
    Posts
    694

    Re: Badger Messenger, an MSN clone that uses the MSN Network.

    Oh sure,Ill be checking it out and ill ask you if I have doubts
    Godwin

    Help someone else with what someone helped you!

  34. #34

    Thread Starter
    Super Moderator Wokawidget's Avatar
    Join Date
    Nov 2001
    Location
    Headingly Occupation: Classified
    Posts
    9,633

    Re: Badger Messenger, an MSN clone that uses the MSN Network.

    OK. The new version is here.

    I've had it for ages, and not posted it. Sorry

    Have been writting BadgerMessenger .NET and have switched to the new MSNP12 protocol, which MSN Messenger 7.5 uses.

    I noticed some old bugs to do with payloads that my old app had, so I have just fixed them, and decided to post the newer version here.

    Badger Messenger.NET will be forthcoming, but I don't know when.

    If anyone has any MSNP12 code they would like to share then that would be great.

    Woka
    Attached Files Attached Files

  35. #35

    Thread Starter
    Super Moderator Wokawidget's Avatar
    Join Date
    Nov 2001
    Location
    Headingly Occupation: Classified
    Posts
    9,633

    Re: Badger Messenger, an MSN clone that uses the MSN Network.

    Here are the screen shots of said new version:

    Attached Images Attached Images    

  36. #36
    Super Moderator RobDog888's Avatar
    Join Date
    Apr 2001
    Location
    LA, Calif. Raiders #1 AKA:Gangsta Yoda™
    Posts
    60,713

    Re: Badger Messenger, an MSN clone that uses the MSN Network.

    You should update the first post to let members know that the updated version is in post #34 now.

    I bet your going to get allot of spam now too with your email in the SS's

    Hey, where am I?
    VB/Office Guru™ (AKA: Gangsta Yoda™ )
    I dont answer coding questions via PM. Please post a thread in the appropriate forum.

    Microsoft MVP 2006-2011
    Office Development FAQ (C#, VB.NET, VB 6, VBA)
    Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
    If a post has helped you then Please Rate it!
    • Reps & Rating Posts • VS.NET on Vista • Multiple .NET Framework Versions • Office Primary Interop Assemblies • VB/Office Guru™ Word SpellChecker™.NET • VB/Office Guru™ Word SpellChecker™ VB6 • VB.NET Attributes Ex. • Outlook Global Address List • API Viewer utility • .NET API Viewer Utility •
    System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6

  37. #37
    Hyperactive Member ..:RUDI:..'s Avatar
    Join Date
    Aug 2005
    Location
    Yorkshire, England! c0d: Da Vinci
    Posts
    344

    Re: Badger Messenger, an MSN clone that uses the MSN Network.

    Quote Originally Posted by Wokawidget
    OK. The new version is here.

    I've had it for ages, and not posted it. Sorry

    Have been writting BadgerMessenger .NET and have switched to the new MSNP12 protocol, which MSN Messenger 7.5 uses.

    I noticed some old bugs to do with payloads that my old app had, so I have just fixed them, and decided to post the newer version here.

    Badger Messenger.NET will be forthcoming, but I don't know when.

    If anyone has any MSNP12 code they would like to share then that would be great.

    Woka
    Is this project still going???

    And MSNP13 is now in use, with MSNM 8 (Which I of course, do have )



    My Personal Home | MageBB Home | Elders Online
    Yes, Noteme is my father.

  38. #38

  39. #39
    Hyperactive Member ..:RUDI:..'s Avatar
    Join Date
    Aug 2005
    Location
    Yorkshire, England! c0d: Da Vinci
    Posts
    344

    Re: Badger Messenger, an MSN clone that uses the MSN Network.

    Don't know for sure, but MSN Messenger 8 uses it



    My Personal Home | MageBB Home | Elders Online
    Yes, Noteme is my father.

  40. #40

    Thread Starter
    Super Moderator Wokawidget's Avatar
    Join Date
    Nov 2001
    Location
    Headingly Occupation: Classified
    Posts
    9,633

    Re: Badger Messenger, an MSN clone that uses the MSN Network.

    Can you download a demo of this?
    Is MSN 8 the one that includes Yahoo IM?
    That protocol will be all over the shop.

    Woka

Page 1 of 4 1234 LastLast

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width