Home Forums Support Telnet communication with NetworkCommsDotNet?

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #3980
    Anonymous
    Inactive

    Hello,

    I’m trying to set up a server using NetworkingCommsDotNet where I can accept Telnet clients, but I can’t understand how to do it properly. I’m using the following code:

    public static void Init()
            {
                NetworkComms.AppendGlobalConnectionEstablishHandler(ConnectionEstablished, true);
                NetworkComms.AppendGlobalIncomingPacketHandler<string>("Message", ReceivedData);      
            }
    
            public static void StartListening()
            {
                Connection.StartListening(ConnectionType.TCP, new System.Net.IPEndPoint(System.Net.IPAddress.Parse(serverIP), serverPort));
            }
    
            private static void ConnectionEstablished(Connection _connection)
            {       
                Logger.LogMessage("Connection established with " + _connection.ConnectionInfo.RemoteEndPoint.ToString());
            }

    What am I doing wrong?

    #3992
    Anonymous
    Inactive

    Heya Robert,

    Looks like you are on the right path, you should be aware NetworkComms.Net implements a custom application layer protocol to support a large number of features. This may interfere with the telnet protocol. NetworkComms.Net does offer Unmanaged Connections, which is included in one of the examples

    Kind regards,
    Marc

    #4002
    Anonymous
    Inactive

    Hi Marc,

    After a bit more testing I started to assume there was some handshaking going on under the hood. I wasn’t aware that unmanaged connections were available however – good to know!

    Thanks

Viewing 3 posts - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.