IRC Bot: Error - Registration Timeout

痴心易碎 提交于 2019-12-04 09:13:00

Telnet for roc.esper.net:

~$ telnet roc.esper.net 6667
Trying 198.247.173.216...
Connected to roc.esper.net.
Escape character is '^]'.
:roc.esper.net NOTICE AUTH :*** Looking up your hostname...
:roc.esper.net NOTICE AUTH :*** Found your hostname
NICK Goo
USER Goo * * :Goo
PING :268966433
PONG :268966433

NICK, USER and PONG were send by me. After that, welcome message follows:

:roc.esper.net 001 Goo :Welcome to the EsperNet Internet Relay Chat Network Goo
:roc.esper.net 002 Goo :Your host is roc.esper.net[198.247.173.216/6667], running version esphyb-1.0.1

And so on...

So, again, check for PING-PONG and if your messages are sent correctly (especially CR/LF or '\n' at end).

By the way, I get "registration timed out" if I don't send any of the messages, even if PONG is missing, but once I answered PING, there is no timeout anymore (at least not after 30 seconds).

Try sending the USER command before the NICK command. What IRC network are you trying to connect to?

"
> telnet irc.freenode.net 6667
NOTICE AUTH :*** Looking up your hostname...
NOTICE AUTH :*** Checking ident
NOTICE AUTH :*** No identd (auth) response
NOTICE AUTH :*** Couldn't look up your hostname
USER x x x x
NICK hwjrh
:kubrick.freenode.net 001 hwjrh :Welcome to the freenode IRC Network hwjrh
:kubrick.freenode.net 002 hwjrh :Your host is kubrick.freenode.net[kubrick.freenode.net/6667], running version hyperion-1.0.2b
"

Works for me; I telnet to Freenode, Undernet and Dalnet all the time...

From the tutorials I looked at (like this one), it seems that you are doing it right, except that this

USER Goo * * :Goo

is

USER Goo 0 * :Goo

in all the tutorials I saw. Also, don't forget the PING-PONG later on, but this should not be needed for registration (EDIT: It seems that this is wrong and PONG is needed right after you send NICK).

I guess you know about RFC 1459, which will also help you a lot with this.

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!