mirror of
https://github.com/jlu5/PyLink.git
synced 2024-11-24 03:29:28 +01:00
parent
75798b5fba
commit
ae87def11f
@ -7,7 +7,6 @@ ban,+b,+b,+b,+b,+b,+b
|
||||
banexception,+e (m_banexception),+e,+e,+e,+e,+e
|
||||
blockcaps,+B (m_blockcaps),,+G (extensions/chm_nocaps.c),,,
|
||||
blockcolor,+c (m_blockcolor),,,+c,+c,+c
|
||||
c_noforwards,,+Q,+Q,,,
|
||||
delayjoin,,,,,,+D
|
||||
exemptchanops,+X (m_exemptchanops),,,,,
|
||||
filter,+g (m_filter),,,,,
|
||||
@ -32,6 +31,7 @@ nickflood,+F (m_nickflood),,,,,
|
||||
noamsg,,,,,,+T
|
||||
noctcp,+C (m_noctcp),+C,+C,+C,+C,+C
|
||||
noextmsg,+n,+n,+n,+n,+n,+n
|
||||
noforwards,,+Q,+Q,,,
|
||||
noinvite,,,,,,
|
||||
nokick,+Q (m_nokicks),,+E,+Q,,
|
||||
noknock,+K (m_knock),+p,,+K,+p,
|
||||
|
|
@ -674,9 +674,9 @@ whitelisted_cmodes = {'admin', 'allowinvite', 'autoop', 'ban', 'banexception',
|
||||
'regmoderated', 'secret', 'sslonly', 'adminonly',
|
||||
'stripcolor', 'topiclock', 'voice', 'flood',
|
||||
'flood_unreal', 'joinflood', 'freetarget',
|
||||
'c_noforwards', 'noinvite'}
|
||||
'noforwards', 'noinvite'}
|
||||
whitelisted_umodes = {'bot', 'hidechans', 'hideoper', 'invisible', 'oper',
|
||||
'regdeaf', 'u_stripcolor', 'u_noctcp', 'wallops',
|
||||
'regdeaf', 'stripcolor', 'noctcp', 'wallops',
|
||||
'hideidle'}
|
||||
def relayModes(irc, remoteirc, sender, channel, modes=None):
|
||||
"""
|
||||
|
@ -387,6 +387,9 @@ class InspIRCdProtocol(TS6BaseProtocol):
|
||||
for modepair in args[-1].split():
|
||||
name, char = modepair.split('=')
|
||||
|
||||
# Strip c_ prefixes to be consistent with other protocols.
|
||||
name = name.lstrip('c_')
|
||||
|
||||
if name == 'reginvite': # Reginvite? That's a dumb name.
|
||||
name = 'regonly'
|
||||
|
||||
@ -396,10 +399,6 @@ class InspIRCdProtocol(TS6BaseProtocol):
|
||||
# but I personally prefer the latter.
|
||||
name = 'owner'
|
||||
|
||||
if name == 'c_registered':
|
||||
# Be consistent with other protocols
|
||||
name = 'registered'
|
||||
|
||||
# We don't care about mode prefixes; just the mode char.
|
||||
self.irc.cmodes[name] = char[-1]
|
||||
|
||||
@ -413,6 +412,8 @@ class InspIRCdProtocol(TS6BaseProtocol):
|
||||
# Ditto above.
|
||||
for modepair in args[-1].split():
|
||||
name, char = modepair.split('=')
|
||||
# Strip u_ prefixes to be consistent with other protocols.
|
||||
name = name.lstrip('u_')
|
||||
self.irc.umodes[name] = char
|
||||
|
||||
elif args[0] == 'CAPABILITIES':
|
||||
|
@ -684,7 +684,7 @@ class P10Protocol(Protocol):
|
||||
'snomask': 's', 'servprotect': 'k', 'sno_debug': 'g', 'cloak': 'x',
|
||||
'hidechans': 'n', 'deaf_commonchan': 'q', 'bot': 'B', 'deaf': 'D',
|
||||
'hideoper': 'H', 'hideidle': 'I', 'regdeaf': 'R', 'showwhois': 'W',
|
||||
'admin': 'a', 'override': 'X', 'u_noforward': 'L', 'ssl': 'z',
|
||||
'admin': 'a', 'override': 'X', 'noforward': 'L', 'ssl': 'z',
|
||||
'registered': 'r', 'cloak_sethost': 'h', 'cloak_fakehost': 'f',
|
||||
'cloak_hashedhost': 'C', 'cloak_hashedip': 'c',
|
||||
'*A': '', '*B': '', '*C': 'fCcrh', '*D': 'oOiwskgxnqBDHIRWaXLz'}
|
||||
|
@ -263,7 +263,7 @@ class TS6Protocol(TS6BaseProtocol):
|
||||
# charybdis-specific modes:
|
||||
'quiet': 'q', 'redirect': 'f', 'freetarget': 'F',
|
||||
'joinflood': 'j', 'largebanlist': 'L', 'permanent': 'P',
|
||||
'c_noforwards': 'Q', 'stripcolor': 'c', 'allowinvite':
|
||||
'noforwards': 'Q', 'stripcolor': 'c', 'allowinvite':
|
||||
'g', 'opmoderated': 'z', 'noctcp': 'C',
|
||||
# charybdis-specific modes provided by EXTENSIONS
|
||||
'operonly': 'O', 'adminonly': 'A', 'sslonly': 'S',
|
||||
@ -284,9 +284,9 @@ class TS6Protocol(TS6BaseProtocol):
|
||||
self.irc.cmodes = chary_cmodes
|
||||
|
||||
# Define supported user modes
|
||||
chary_umodes = {'deaf': 'D', 'servprotect': 'S', 'u_admin': 'a',
|
||||
chary_umodes = {'deaf': 'D', 'servprotect': 'S', 'admin': 'a',
|
||||
'invisible': 'i', 'oper': 'o', 'wallops': 'w',
|
||||
'snomask': 's', 'u_noforward': 'Q', 'regdeaf': 'R',
|
||||
'snomask': 's', 'noforward': 'Q', 'regdeaf': 'R',
|
||||
'callerid': 'g', 'operwall': 'z', 'locops': 'l',
|
||||
'cloak': 'x',
|
||||
# Now, map all the ABCD type modes:
|
||||
@ -304,7 +304,7 @@ class TS6Protocol(TS6BaseProtocol):
|
||||
self.irc.cmodes.update(elemental_cmodes)
|
||||
self.irc.cmodes['*D'] += ''.join(elemental_cmodes.values())
|
||||
|
||||
elemental_umodes = {'u_noctcp': 'C', 'deaf': 'D', 'bot': 'B', 'u_noinvite': 'V',
|
||||
elemental_umodes = {'noctcp': 'C', 'deaf': 'D', 'bot': 'B', 'noinvite': 'V',
|
||||
'hidechans': 'I'}
|
||||
self.irc.umodes.update(elemental_umodes)
|
||||
self.irc.umodes['*D'] += ''.join(elemental_umodes.values())
|
||||
|
@ -313,7 +313,7 @@ class UnrealProtocol(TS6BaseProtocol):
|
||||
'bot': 'B', 'cloak': 'x', 'ssl': 'z',
|
||||
'filter': 'G', 'hideoper': 'H', 'hideidle': 'I',
|
||||
'regdeaf': 'R', 'servprotect': 'S',
|
||||
'u_noctcp': 'T', 'showwhois': 'W',
|
||||
'noctcp': 'T', 'showwhois': 'W',
|
||||
'*A': '', '*B': '', '*C': '', '*D': 'dipqrstwBxzGHIRSTW'})
|
||||
|
||||
f = self.irc.send
|
||||
|
Loading…
Reference in New Issue
Block a user