chanserv: require channel-operator status to register
Registering a channel now needs the caller to actually hold operator status in it, so you can't register a channel you don't control. The network view tracks per-channel ops from FJOIN prefixes and FMODE +o/-o.
This commit is contained in:
parent
0681c7a3b2
commit
921088bfca
5 changed files with 88 additions and 23 deletions
|
|
@ -15,10 +15,13 @@ pub enum NetEvent {
|
|||
// A channel was created or bursted (InspIRCd FJOIN). Subsequent single joins
|
||||
// arrive as IJOIN and are not surfaced.
|
||||
ChannelCreate { channel: String },
|
||||
// A user joined a channel (an FJOIN member or an IJOIN), for auto-op.
|
||||
Join { uid: String, channel: String },
|
||||
// A user joined a channel (an FJOIN member or an IJOIN), for auto-op. `op` is
|
||||
// whether they hold channel-operator status at that point (an FJOIN prefix).
|
||||
Join { uid: String, channel: String, op: bool },
|
||||
// A user left a channel (PART) or was removed (KICK), for membership tracking.
|
||||
Part { uid: String, channel: String },
|
||||
// A user's channel-operator status changed (FMODE +o/-o), for live op tracking.
|
||||
ChannelOp { channel: String, uid: String, op: bool },
|
||||
// A channel's modes changed (FMODE), for enforcing mode locks. Our own
|
||||
// changes are filtered out by the protocol layer.
|
||||
ChannelModeChange { channel: String, modes: String },
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue