]> jfr.im git - irc.git/blob - software/!RELEASES/ircservices/achurch.org/services/lists/ircservices/2008/005655.html
RELEASE -> !RELEASE
[irc.git] / software / !RELEASES / ircservices / achurch.org / services / lists / ircservices / 2008 / 005655.html
1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
2 <HTML>
3 <HEAD>
4 <TITLE> [IRCServices] ircservices 5.1.11 RFC 1459 protocol module broken?
5 </TITLE>
6 <LINK REL="Index" HREF="index.html" >
7 <LINK REL="made" HREF="mailto:ircservices%40ircservices.za.net?Subject=%5BIRCServices%5D%20ircservices%205.1.11%20RFC%201459%20protocol%20module%0A%09broken%3F&In-Reply-To=FD68DED0-3656-4099-AACC-AF25241FE1C5%40barton.de">
8 <META NAME="robots" CONTENT="index,nofollow">
9 <META http-equiv="Content-Type" content="text/html; charset=us-ascii">
10 <LINK REL="Previous" HREF="005654.html">
11 <LINK REL="Next" HREF="005656.html">
12 </HEAD>
13 <BODY BGCOLOR="#ffffff">
14 <H1>[IRCServices] ircservices 5.1.11 RFC 1459 protocol module broken?</H1>
15 <B>Andrew Church</B>
16 <A HREF="mailto:ircservices%40ircservices.za.net?Subject=%5BIRCServices%5D%20ircservices%205.1.11%20RFC%201459%20protocol%20module%0A%09broken%3F&In-Reply-To=FD68DED0-3656-4099-AACC-AF25241FE1C5%40barton.de"
17 TITLE="[IRCServices] ircservices 5.1.11 RFC 1459 protocol module broken?">achurch at achurch.org
18 </A><BR>
19 <I>Sat Nov 8 01:59:41 PST 2008</I>
20 <P><UL>
21 <LI>Previous message: <A HREF="005654.html">[IRCServices] ircservices 5.1.11 RFC 1459 protocol module broken?
22 </A></li>
23 <LI>Next message: <A HREF="005656.html">[IRCServices] Services 5.1.13 released
24 </A></li>
25 <LI> <B>Messages sorted by:</B>
26 <a href="date.html#5655">[ date ]</a>
27 <a href="thread.html#5655">[ thread ]</a>
28 <a href="subject.html#5655">[ subject ]</a>
29 <a href="author.html#5655">[ author ]</a>
30 </LI>
31 </UL>
32 <HR>
33 <!--beginarticle-->
34 <PRE>Fixed, thanks for the report.
35
36 As for which protocol is &quot;most advanced&quot;, it's hard to say; each protocol
37 has its own different set of features. The rfc1459, ts8, dalnet, and
38 undernet-p9 protocols are all archaic at this point, but most of the other
39 protocols supported by Services are reasonably modern and suitable for use.
40
41 --Andrew Church
42 <A HREF="http://lists.ircservices.za.net/mailman/listinfo/ircservices">achurch at achurch.org</A>
43 <A HREF="http://achurch.org/">http://achurch.org/</A>
44
45 &gt;<i>Hello!
46 </I>&gt;<i>
47 </I>&gt;<i>I'm working on getting ngIRCd connected to the ircservices 5.1.11
48 </I>&gt;<i>package, at the moment I'm using the RFC 1459 protocol module and
49 </I>&gt;<i>enhanced ngIRCd to understand server and user registration according
50 </I>&gt;<i>to this older RFC.
51 </I>&gt;<i>
52 </I>&gt;<i>Thereby I encountered a problem: ircservices all the time answered
53 </I>&gt;<i>with the following error message:
54 </I>&gt;<i>
55 </I>&gt;<i>----------&gt; cut here &lt;----------
56 </I>&gt;<i>debug: Received: :a.irc.net PASS srvPWD 0210-IRC+ ngircd|dev:CHLZ PZ
57 </I>&gt;<i>debug: Received: :a.irc.net SERVER a.irc.net 1 :A Server Info Text
58 </I>&gt;<i>debug: Received: NICK test :1
59 </I>&gt;<i>debug: Received: :test USER ~alex localhost a.irc.net :Alex
60 </I>&gt;<i>debug: Received: :test MODE test :+w
61 </I>&gt;<i>debug: user: MODE +w for nonexistent nick test from test: test +w
62 </I>&gt;<i>----------&gt; cut here &lt;----------
63 </I>&gt;<i>
64 </I>&gt;<i>&quot;nonexistent nick test&quot; ... hm!?
65 </I>&gt;<i>
66 </I>&gt;<i>Digging through the source code of ircservices, I found the folowing
67 </I>&gt;<i>code in modules/protocol/rfc1459.c, line 42 ff.:
68 </I>&gt;<i>
69 </I>&gt;<i>----------&gt; cut here &lt;----------
70 </I>&gt;<i>static void m_user(char *source, int ac, char **av)
71 </I>&gt;<i>{
72 </I>&gt;<i> char *new_av[7];
73 </I>&gt;<i> if (ac != 5)
74 </I>&gt;<i> return;
75 </I>&gt;<i>----------&gt; cut here &lt;----------
76 </I>&gt;<i>
77 </I>&gt;<i>So this function checks if the USER command das 5(!) parameters. BUT:
78 </I>&gt;<i>according to RFC 1459 the USER command only has 4 parameters, see
79 </I>&gt;<i>section 4.1.3:
80 </I>&gt;<i>
81 </I>&gt;<i>----------&gt; cut here &lt;----------
82 </I>&gt;<i>4.1.3 User message
83 </I>&gt;<i>
84 </I>&gt;<i> Command: USER
85 </I>&gt;<i> Parameters: &lt;username&gt; &lt;hostname&gt; &lt;servername&gt; &lt;realname&gt;
86 </I>&gt;<i>
87 </I>&gt;<i>[...]
88 </I>&gt;<i>----------&gt; cut here &lt;----------
89 </I>&gt;<i>
90 </I>&gt;<i>So the above mentioned test in ircservices always silently failed.
91 </I>&gt;<i>
92 </I>&gt;<i>Proposed patch:
93 </I>&gt;<i>
94 </I>&gt;<i>----------&gt; cut here &lt;----------
95 </I>&gt;<i>--- rfc1459.c.ORIG 2008-08-13 21:28:33.000000000 +0200
96 </I>&gt;<i>+++ rfc1459.c 2008-08-13 21:27:51.000000000 +0200
97 </I>&gt;<i>@@ -43,8 +43,11 @@ static void m_user(char *source, int ac,
98 </I>&gt;<i>{
99 </I>&gt;<i> char *new_av[7];
100 </I>&gt;<i>
101 </I>&gt;<i>- if (ac != 5)
102 </I>&gt;<i>+ if (ac != 4) {
103 </I>&gt;<i>+ module_log_debug(1, &quot;USER message: wrong number of parameters&quot;
104 </I>&gt;<i>+ &quot; (%d) for source `%s'&quot;, ac, source ?
105 </I>&gt;<i>source : &quot;?&quot;);
106 </I>&gt;<i> return;
107 </I>&gt;<i>+ }
108 </I>&gt;<i> new_av[0] = source; /* Nickname */
109 </I>&gt;<i> new_av[1] = (char *)&quot;0&quot;; /* # of hops (was in NICK command... we
110 </I>&gt;<i>lose) */
111 </I>&gt;<i> new_av[2] = (char *)&quot;0&quot;; /* Timestamp */
112 </I>&gt;<i>----------&gt; cut here &lt;----------
113 </I>&gt;<i>
114 </I>&gt;<i>Can you tell me if I'm correct? Or do I overlook something?
115 </I>&gt;<i>
116 </I>&gt;<i>And can you tell me which protocol module is the &quot;most advanced&quot; or
117 </I>&gt;<i>&quot;best&quot;?
118 </I>&gt;<i>
119 </I>&gt;<i>Thanks a lot!
120 </I>&gt;<i>Alex
121 </I>&gt;<i>------------------------------------------------------------------
122 </I>&gt;<i>To unsubscribe or change your subscription options, visit:
123 </I>&gt;<i><A HREF="http://lists.ircservices.za.net/mailman/listinfo/ircservices">http://lists.ircservices.za.net/mailman/listinfo/ircservices</A>
124 </I></PRE>
125
126
127
128
129 <!--endarticle-->
130 <HR>
131 <P><UL>
132 <!--threads-->
133 <LI>Previous message: <A HREF="005654.html">[IRCServices] ircservices 5.1.11 RFC 1459 protocol module broken?
134 </A></li>
135 <LI>Next message: <A HREF="005656.html">[IRCServices] Services 5.1.13 released
136 </A></li>
137 <LI> <B>Messages sorted by:</B>
138 <a href="date.html#5655">[ date ]</a>
139 <a href="thread.html#5655">[ thread ]</a>
140 <a href="subject.html#5655">[ subject ]</a>
141 <a href="author.html#5655">[ author ]</a>
142 </LI>
143 </UL>
144
145 </body></html>