3

Is there currently an IRC Server (not Services) written in .NET?

One of my coworkers had never used IRC before, or heard of it, which surprised me because he is familiar with Jabber and other messaging protocols.

Wanted to show him how simple the protocol is using .NET (he knows VB.NET, Flash, and 3D Design, so .NET is probably only way I could show him).

Can only find code for Clients in my search, no servers.

Anyone know of one, that sticks relatively close to the standard? No fancy stuff like nickserv etc is needed.

Note: Referring to the server itself, like UnrealIRCD etc; not services.

Brett Allen
  • 5,297
  • 5
  • 32
  • 62
  • 3
    Note: IRC Services are *usually* implemented alongside an IRCD, not as part of one. (i.e. u-lined bots) – Aren Dec 15 '10 at 22:15
  • I'm referring to the Server not services, daemon I suppose would be more recognizable to people familiar with IRC servers. – Brett Allen Dec 15 '10 at 22:17
  • http://codeplex.com is a great place to search for C#/.NET stuff -- lots of projects, lots of trash, but a few gems. But in this case no servers... hmm :-/ –  Dec 15 '10 at 22:19
  • @Aequitarium: I was referring mainly to this point in your post: *"Anyone know of one, that sticks relatively close to the standard? No fancy stuff like nickserv etc is needed."* – Aren Dec 15 '10 at 22:20
  • @pst Only finding Clients unfortunately, I know there is no reason to write an IRCD in .NET but still, I imagined -someone- would have done it for fun by now lol. – Brett Allen Dec 15 '10 at 22:22
  • @Aren Yep, realized that after I posted my reply, good point. – Brett Allen Dec 15 '10 at 22:22
  • http://sourceforge.net/projects/sharpwircd/#download I found this one. ^_^ –  Mar 17 '12 at 05:43

1 Answers1

0

A quick search found me this one (quite old) ...

http://sourceforge.net/projects/csharpircserv/


This section of the code listens for incoming connnections

    public cSocket(string Server, int Port)
    {
        if(sock != null && sock.Connected)
        {
            sock.Shutdown(SocketShutdown.Both);
            System.Threading.Thread.Sleep(10);
            sock.Close();
        }
        sock = new Socket(AddressFamily.InterNetwork, SocketType.Stream, ProtocolType.Tcp);    
        IPEndPoint ep = new IPEndPoint(IPAddress.Parse(Server), Port);
        AsyncCallback onconnect = new AsyncCallback(OnConnect);
        sock.BeginConnect(ep, onconnect, sock);
    }

This section of Main.cs responses to Ping

    switch(sp[0].ToLower())
                        {
                            case "ping":
                                s.Send("PONG :"+co[1]);
                                break;
JTew
  • 3,149
  • 3
  • 31
  • 39
  • Think you were typing that as I clarified the question lol. Meant a server/daemon, not the services. – Brett Allen Dec 15 '10 at 22:19
  • I think this does do that unless I misunderstand ... I have updated my answer. – JTew Dec 15 '10 at 22:36
  • That's the method used for the service (NickServ HostServ etc) to connect to the IRC Server, and the PONG response is something Clients give when Pinged. Wish it were what I was looking for, unfortunately it's not :( – Brett Allen Dec 16 '10 at 20:08