diff --git a/docs/modelists/extbans.csv b/docs/modelists/extbans.csv
index 1185df0..eb6c760 100644
--- a/docs/modelists/extbans.csv
+++ b/docs/modelists/extbans.csv
@@ -1,33 +1,35 @@
-Extban / IRCd,charybdis,InspIRCd,UnrealIRCd
-ban_account,$a:,R:,~a:
-ban_account_legacy,,,~R:
-ban_all_opers,$o,,
-ban_all_registered,$a,,
-ban_all_ssl,$z,,
-ban_banshare,$j:,,
-ban_blockcaps,,B:,
-ban_blockcolor,,c:,
-ban_certfp,,z:,~S:
-ban_extgecos,$x:,,
-ban_inchannel,$c:,j:,~c:
-ban_invites,,A:,
-ban_noctcp,,C:,
-ban_nojoins,,,~j:
-ban_nokicks,,Q:,
-ban_nonick,,N:,~n:
-ban_nonotice,,T:,
-ban_not_account,$~a:,,
-ban_not_banshare,$~j:,,
-ban_not_extgecos,$~x:,,
-ban_not_inchannel,$~c:,,
-ban_not_opers,$~o,,
-ban_not_realname,$~r:,,
-ban_not_server,$~s:,,
-ban_not_ssl,$~z,,
-ban_opertype,,O:,~O:
-ban_partmsgs,,p:,
-ban_realname,$r:,r:,~r:
-ban_server,$s:,s:,
-ban_stripcolor,,S:,
-ban_unregistered_matching,,U:,
-quiet,+q (cmode),m:,~q:
+Extban / IRCd,charybdis,InspIRCd,UnrealIRCd,Nefarious
+ban_account,$a:,R:,~a:,~a:
+ban_account_legacy,,,~R:,
+ban_all_opers,$o,,,
+ban_all_registered,$a,,,
+ban_all_ssl,$z,,,
+ban_banshare,$j:,,,~j:
+ban_blockcaps,,B:,,
+ban_blockcolor,,c:,,
+ban_certfp,,z:,~S:,
+ban_extgecos,$x:,,,
+ban_inchannel,$c:,j:,~c:,~c:
+ban_invites,,A:,,
+ban_mark,,,,~m:
+ban_noctcp,,C:,,
+ban_nojoins,,,~j:,
+ban_nokicks,,Q:,,
+ban_nonick,,N:,~n:,~n:
+ban_nonotice,,T:,,
+ban_not_account,$~a:,,,
+ban_not_banshare,$~j:,,,
+ban_not_extgecos,$~x:,,,
+ban_not_inchannel,$~c:,,,
+ban_not_opers,$~o,,,
+ban_not_realname,$~r:,,,
+ban_not_server,$~s:,,,
+ban_not_ssl,$~z,,,
+ban_opertype,,O:,~O:,
+ban_partmsgs,,p:,,
+ban_realname,$r:,r:,~r:,~r:
+ban_server,$s:,s:,,
+ban_stripcolor,,S:,,
+ban_unregistered_mark,,,,~M:
+ban_unregistered_matching,,U:,,
+quiet,+q (cmode),m:,~q:,~q:
diff --git a/docs/modelists/extbans.html b/docs/modelists/extbans.html
index 6d85ad2..5fa4c71 100644
--- a/docs/modelists/extbans.html
+++ b/docs/modelists/extbans.html
@@ -76,103 +76,110 @@ td:first-child, th[scope="row"] {
charybdis |
InspIRCd |
UnrealIRCd |
+Nefarious |
ban_account |
-$a:data | R:data | ~a:data |
+$a:data | R:data | ~a:data | ~a:data |
ban_account_legacy |
-n/a | n/a | ~R:data |
+n/a | n/a | ~R:data | n/a |
ban_all_opers |
-$o | n/a | n/a |
+$o | n/a | n/a | n/a |
ban_all_registered |
-$a | n/a | n/a |
+$a | n/a | n/a | n/a |
ban_all_ssl |
-$z | n/a | n/a |
+$z | n/a | n/a | n/a |
ban_banshare |
-$j:data | n/a | n/a |
+$j:data | n/a | n/a | ~j:data |
ban_blockcaps |
-n/a | B:data | n/a |
+n/a | B:data | n/a | n/a |
ban_blockcolor |
-n/a | c:data | n/a |
+n/a | c:data | n/a | n/a |
ban_certfp |
-n/a | z:data | ~S:data |
+n/a | z:data | ~S:data | n/a |
ban_extgecos |
-$x:data | n/a | n/a |
+$x:data | n/a | n/a | n/a |
ban_inchannel |
-$c:data | j:data | ~c:data |
+$c:data | j:data | ~c:data | ~c:data |
ban_invites |
-n/a | A:data | n/a |
+n/a | A:data | n/a | n/a |
+
+ban_mark |
+n/a | n/a | n/a | ~m:data |
ban_noctcp |
-n/a | C:data | n/a |
+n/a | C:data | n/a | n/a |
ban_nojoins |
-n/a | n/a | ~j:data |
+n/a | n/a | ~j:data | n/a |
ban_nokicks |
-n/a | Q:data | n/a |
+n/a | Q:data | n/a | n/a |
ban_nonick |
-n/a | N:data | ~n:data |
+n/a | N:data | ~n:data | ~n:data |
ban_nonotice |
-n/a | T:data | n/a |
+n/a | T:data | n/a | n/a |
ban_not_account |
-$~a:data | n/a | n/a |
+$~a:data | n/a | n/a | n/a |
ban_not_banshare |
-$~j:data | n/a | n/a |
+$~j:data | n/a | n/a | n/a |
ban_not_extgecos |
-$~x:data | n/a | n/a |
+$~x:data | n/a | n/a | n/a |
ban_not_inchannel |
-$~c:data | n/a | n/a |
+$~c:data | n/a | n/a | n/a |
ban_not_opers |
-$~o | n/a | n/a |
+$~o | n/a | n/a | n/a |
ban_not_realname |
-$~r:data | n/a | n/a |
+$~r:data | n/a | n/a | n/a |
ban_not_server |
-$~s:data | n/a | n/a |
+$~s:data | n/a | n/a | n/a |
ban_not_ssl |
-$~z | n/a | n/a |
+$~z | n/a | n/a | n/a |
ban_opertype |
-n/a | O:data | ~O:data |
+n/a | O:data | ~O:data | n/a |
ban_partmsgs |
-n/a | p:data | n/a |
+n/a | p:data | n/a | n/a |
ban_realname |
-$r:data | r:data | ~r:data |
+$r:data | r:data | ~r:data | ~r:data |
ban_server |
-$s:data | s:data | n/a |
+$s:data | s:data | n/a | n/a |
ban_stripcolor |
-n/a | S:data | n/a |
+n/a | S:data | n/a | n/a |
+
+ban_unregistered_mark |
+n/a | n/a | n/a | ~M:data |
ban_unregistered_matching |
-n/a | U:data | n/a |
+n/a | U:data | n/a | n/a |
quiet |
-+q (cmode) | m:data | ~q:data |
++q (cmode) | m:data | ~q:data | ~q:data |
diff --git a/protocols/p10.py b/protocols/p10.py
index 4af3421..e1ffb52 100644
--- a/protocols/p10.py
+++ b/protocols/p10.py
@@ -796,6 +796,20 @@ class P10Protocol(IRCS2SProtocol):
'registered': 'r', 'cloak_sethost': 'h', 'cloak_fakehost': 'f',
'cloak_hashedhost': 'C', 'cloak_hashedip': 'c', 'locop': 'O',
'*A': '', '*B': '', '*C': 'fCcrh', '*D': 'oOiwskgxnqBdDHIRWaXLz'})
+ # Nefarious supports extbans as documented at
+ # https://github.com/evilnet/nefarious2/blob/master/doc/extendedbans.txt
+ self.extbans_matching.update({
+ 'ban_account': '~a:',
+ 'ban_inchannel': '~c:',
+ 'ban_realname': '~r:',
+ 'ban_mark': '~m:',
+ 'ban_unregistered_mark': '~M:',
+ 'ban_banshare': '~j:'
+ })
+ self.extbans_acting.update({
+ 'quiet': '~q:',
+ 'ban_nonick': '~n:'
+ })
elif p10_ircd == 'snircd':
# snircd has +u instead of +Q for hidequits, and fewer chanel modes.
cmodes = {'oplevel_apass': 'A', 'oplevel_upass': 'U', 'delayjoin': 'D', 'regonly': 'r',