fix: check ip ban by prefix during login

This commit is contained in:
trisua 2025-05-21 23:52:29 -04:00
parent d7e800fcb4
commit 829eef7f5d
3 changed files with 12 additions and 4 deletions

View file

@ -1,6 +1,6 @@
use std::net::SocketAddr;
/// How many bytes should be chopped off the end of an IPV6 address to get its prefix.
/// How many bytes should be taken as the prefix (from the begining of the address).
pub(crate) const IPV6_PREFIX_BYTES: usize = 8;
/// The protocol of a [`RemoteAddr`].