Skip to content

Commit 2b549d5

Browse files
committed
Patch from thommey which adds support for old CGIIRC hostname spoofing.
Also add an AUTHORS file.
1 parent c1bd031 commit 2b549d5

File tree

3 files changed

+10
-0
lines changed

3 files changed

+10
-0
lines changed

AUTHORS

+4
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
The following people have contributed code to qwebirc:
2+
3+
Chris Porter <[email protected]>
4+
Thomas Sader <[email protected]>

config.py.example

+3
Original file line numberDiff line numberDiff line change
@@ -26,11 +26,14 @@ APP_TITLE = "FooNet Web IRC"
2626
DNS_TIMEOUT = 5
2727

2828
# Possible types include "webirc" (CGIIRC style webirc config block),
29+
# "cgiirc" (old CGIIRC style serverpassword),
2930
# "hmac" (quakenet specific) and None (passes ip and host in realname)
3031
WEBIRC_MODE = "webirc"
3132

3233
# webirc mode values
3334
WEBIRC_PASSWORD = "fish"
35+
# cgiirc mode values
36+
CGIIRC_STRING = "CGIIRC"
3437
# hmac mode values
3538
HMACKEY = "mrmoo"
3639
HMACTEMPORAL = 30

qwebirc/ircclient.py

+3
Original file line numberDiff line numberDiff line change
@@ -82,6 +82,9 @@ def connectionMade(self):
8282
elif config.WEBIRC_MODE == "webirc":
8383
self.write("WEBIRC %s qwebirc %s %s" % (config.WEBIRC_PASSWORD, hostname, ip))
8484
self.write("USER %s bleh %s :%s" % (ident, ip, realname))
85+
elif config.WEBIRC_MODE == "cgiirc":
86+
self.write("PASS %s_%s_%s" % (config.CGIIRC_STRING, ip, hostname))
87+
self.write("USER %s bleh %s :%s" % (ident, ip, realname))
8588
else:
8689
if ip == hostname:
8790
dispip = ip

0 commit comments

Comments
 (0)