{"record":{"id":"25bd7eb24e183a15","repo":"Pumpkin-MC/Pumpkin","slug":"failed-to-read-forward-version-25bd7e","errorCode":null,"errorMessage":"Failed to read forward version","messagePattern":"Failed to read forward version","errorType":"error_code","errorClass":"VineError","httpStatus":null,"severity":"error","filePath":"crates/pumpkin/src/net/proxy/vine.rs","lineNumber":36,"sourceCode":"use crate::net::{GameProfile, java::pending::PendingConnection};\n\npub const VINE_PLAYER_INFO_CHANNEL: &str = \"vine:player_info\";\npub const VINE_FORWARDING_VERSION: i32 = 1;\npub const MAX_TIMESTAMP_DRIFT_SECS: i64 = 30;\n\n#[derive(Error, Debug)]\npub enum VineError {\n    #[error(\"No response data received\")]\n    NoData,\n    #[error(\"Vine response data too short (minimum 89 bytes)\")]\n    DataTooShort,\n    #[error(\"No public key or secret configured for Vine proxy\")]\n    MissingKeyConfig,\n    #[error(\"Invalid Ed25519 public key\")]\n    InvalidPublicKey,\n    #[error(\"Failed to verify Ed25519 signature\")]\n    InvalidSignature,\n    #[error(\"Failed to read forward version\")]\n    FailedReadForwardVersion,\n    #[error(\"Unsupported forwarding version {0}. Expected {1}\")]\n    UnsupportedForwardVersion(i32, i32),\n    #[error(\"Vine timestamp expired or desynchronized: skew of {0}s exceeds limit of {1}s\")]\n    TimestampExpired(i64, i64),\n    #[error(\"Vine challenge nonce mismatch\")]\n    ChallengeMismatch,\n    #[error(\"Missing expected challenge from pending connection\")]\n    MissingChallenge,\n    #[error(\"Failed to read address\")]\n    FailedReadAddress,\n    #[error(\"Failed to parse address\")]\n    FailedParseAddress,\n    #[error(\"Failed to read game profile name\")]\n    FailedReadProfileName,\n    #[error(\"Failed to read game profile UUID\")]\n    FailedReadProfileUUID,\n    #[error(\"Failed to read game profile properties\")]","sourceCodeStart":18,"sourceCodeEnd":54,"githubUrl":"https://github.com/Pumpkin-MC/Pumpkin/blob/8d4639e25a57c15e47448ec327c780d41bbf2356/crates/pumpkin/src/net/proxy/vine.rs#L18-L54","documentation":"VineError::FailedReadForwardVersion is returned when the VarInt forwarding version cannot be decoded from the Vine response payload after signature verification (vine.rs:170-172). The payload passed the length and signature checks but its structure is not parseable as expected, so the server aborts instead of guessing the format.","triggerScenarios":"payload.get_var_int() errors in receive_vine_plugin_response because the bytes immediately after the 64-byte signature are not a valid VarInt — e.g. truncated data or a completely different payload layout from an incompatible proxy implementation.","commonSituations":"A proxy claims to support the vine:player_info channel but writes a different payload layout; a corrupted or truncated packet slipped past the minimum-length check; a custom/misconfigured proxy plugin responds with wrong data.","solutions":["Update the proxy to a version implementing the same Vine forwarding protocol as the server","Verify the proxy's forwarding plugin/channel name matches vine:player_info and the expected payload format","Inspect proxy logs to confirm it is sending the signed Vine payload, not some other data on that channel"],"exampleFix":null,"handlingStrategy":"validation","validationCode":"// after the 64-byte signature, the payload must start with a decodable VarInt\nfn starts_with_var_int(payload: &[u8]) -> bool {\n    !payload.is_empty() && payload[0] != 0x80 // simple fast-reject; full decode happens in parser\n}","typeGuard":null,"tryCatchPattern":"match receive_vine_plugin_response(port, &config, response, challenge) {\n    Err(VineError::FailedReadForwardVersion) => {\n        tracing::warn!(\"Vine payload not parseable; proxy protocol incompatible\");\n        disconnect(DisconnectReason::InvalidForwarding);\n    }\n    result => result?,\n}","preventionTips":["Use matching, official releases of the proxy and server for the Vine protocol","Test the forwarding handshake after any proxy upgrade in a staging environment","Keep proxy forwarding plugins updated to the canonical vine:player_info layout","Log raw payload dumps at debug level to diagnose layout mismatches quickly"],"tags":["network","packet-parsing","protocol-mismatch","minecraft"],"backgroundTag":"unexpected-response-shape","analyzedSha":"8d4639e25a57c15e47448ec327c780d41bbf2356","analyzedAt":"2026-09-09T15:32:22.916Z","contentChangedAt":"2026-09-09T15:32:22.916Z","schemaVersion":2},"datasetVersion":"2026-09-16T04:17:20.429Z"}