Pumpkin-MC/Pumpkin · error · EncryptionError
verify token does not match
Error message
verify token does not match
What it means
EncryptionError variant fired when the verify token returned by the client does not match the one the server sent in the encryption request, proving the response was not produced by the legitimate client.
Solutions
- Abort the handshake and disconnect
- Compare tokens with constant-time equality
- Log the mismatch at debug level
Defensive patterns
Strategy: validation
When it happens
Trigger: Thrown at crates/pumpkin/src/net/mod.rs:432 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of Pumpkin-MC/Pumpkin@8d4639e25a (2026-09-09).
Data as JSON: /api/errors/e3847a024b35611e.
Report an issue: GitHub.
Appendix: source
Thrown at crates/pumpkin/src/net/mod.rs:432
)),
None => text,
});
}
None
}
#[derive(Error, Debug)]
pub enum EncryptionError {
#[error("failed to decrypt shared secret")]
FailedDecrypt,
#[error("shared secret has the wrong length")]
SharedWrongLength,
#[error("encryption is already enabled")]
AlreadyEncrypted,
#[error("no encryption request is pending")]
NoPendingVerifyToken,
#[error("verify token does not match")]
VerifyTokenMismatch,
}
fn is_valid_player_name(name: &str) -> bool {
if name.len() > 16 {
return false;
}
!name.chars().any(|c| c.is_control() || c == ' ')
}
#[derive(Clone, Copy, Debug)]
pub enum DisconnectReason {
Unknown = 0,
CantConnectNoInternet = 1,
NoPermissions = 2,
UnrecoverableError = 3,
ThirdPartyBlocked = 4,
ThirdPartyNoInternet = 5,View on GitHub (pinned to 8d4639e25a)