Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Need help with IRC client

Posted on 1998-12-15
5
Medium Priority
?
211 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

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

A lot of questions regard threads in Delphi.   One of the more specific questions is how to show progress of the thread.   Updating a progressbar from inside a thread is a mistake. A solution to this would be to send a synchronized message to the…
Creating an auto free TStringList The TStringList is a basic and frequently used object in Delphi. On many occasions, you may want to create a temporary list, process some items in the list and be done with the list. In such cases, you have to…
In this video you will find out how to export Office 365 mailboxes using the built in eDiscovery tool. Bear in mind that although this method might be useful in some cases, using PST files as Office 365 backup is troublesome in a long run (more on t…
We’ve all felt that sense of false security before—locking down external access to a database or component and feeling like we’ve done all we need to do to secure company data. But that feeling is fleeting. Attacks these days can happen in many w…
Suggested Courses

618 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