?
Solved

Need help with IRC client

Posted on 1998-12-15
5
Medium Priority
?
210 Views
Last Modified: 2010-04-04
Hey Everyone ... I'm trying to learn how to use the tclientsocket in delphi4 to write an irc client.. I've done a bit of research on client server communications, but I'm having this problem

I can connect to the server without a problem, I get the server text
NOTICE AUTH :*** Looking up your hostname...

NOTICE AUTH :*** Checking Ident
NOTICE AUTH :*** Found your hostname

NOTICE AUTH :*** No Ident response

at this time you send you NICK, and USER info .. when I do this I get no response from the server .. after about 10 seconds, it ping times me out ... I'm useing socket.sendtext('blahblah'); to send it info.. as far as i can find I'm sending the right text.. but the server will not rspond.. can someone help me out, let me know what I'm doign wrong... I would greatly appriciate it .. thanks alot

- Danny
0
Comment
Question by:ender42
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
5 Comments
 
LVL 4

Expert Comment

by:davidmwilliams
ID: 1351229
 I think what you are doing is actually fine; the problem is that the irc server you are connecting to is trying to validate your login by calling an ident server on your system.  It's not actually asking your irc client to provide an identity (via NICK or USER).
  What you should perhaps do is look up the RFC on the ident protocol - or find a PC version of identd - and go from there.
0
 

Accepted Solution

by:
tjm4809 earned 200 total points
ID: 1351230
Mr. Williams is correct in that it is looking for an identd reply, not your NICK/USER information.  But, that is not what is ping timing you out.

In addition to wanting identd information, most IRC servers send you a PING message as soon as you connect, and every 60 seconds or so thereafter.  For most verions of ircd, you cannot begin to login until you respond to the first PING.  If you are watching what's coming into the TClientSocket, you'll see the PING message.  To respond to it, simply send back the same message the server sent you, replacing PING with PONG.

Next, you'll need to work on setting up an identd server, which is very simple to do.  You can find information on that in the RFC's.
0
 

Author Comment

by:ender42
ID: 1351231
Ok, I set up an identd server, and the irc server detects it.. everything looks fine.. it will not recognize the info i send it..

procedure TForm1.socketConnect(Sender: TObject; Socket: TCustomWinSocket);
begin
servertext.lines.add('Connected');
Socket.sendtext('NICK somenick');
Socket.sendtext('USER ender ansible irc.ais.net :Ender Wiggin');
end;

I've been useing that irc server to test... but I've tried many others...

Can someone please tell me if theres somethign wrong with that.. this is just so frustrating.. i don't undertand why it's not communicating correctly.. thanks

- Danny
0
 
LVL 4

Expert Comment

by:davidmwilliams
ID: 1351232
 Have you checked the RFC for the irc protocol?
  What messages are you getting back from the server?  Any errors?
0
 

Author Comment

by:ender42
ID: 1351233
Ok, an update on this little saga... it was something very simple actually... when I was sending the string I was not sendign a cr-lf with it.. which is obviously required for it to register on the server ... so.. now it works fine, I'm logged in, and I'm working on all the other lovely parseing I must do... thanks again for the help guys...

- Danny
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction I have seen many questions in this Delphi topic area where queries in threads are needed or suggested. I know bumped into a similar need. This article will address some of the concepts when dealing with a multithreaded delphi database…
In my programming career I have only very rarely run into situations where operator overloading would be of any use in my work.  Normally those situations involved math with either overly large numbers (hundreds of thousands of digits or accuracy re…
NetCrunch network monitor is a highly extensive platform for network monitoring and alert generation. In this video you'll see a live demo of NetCrunch with most notable features explained in a walk-through manner. You'll also get to know the philos…
Do you want to know how to make a graph with Microsoft Access? First, create a query with the data for the chart. Then make a blank form and add a chart control. This video also shows how to change what data is displayed on the graph as well as form…
Suggested Courses
Course of the Month11 days, 6 hours left to enroll

752 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question