mirror of
https://github.com/yuezk/GlobalProtect-openconnect.git
synced 2026-11-18 22:16:18 -05:00
31 lines
1.2 KiB
Rust
31 lines
1.2 KiB
Rust
mod credential;
|
|
mod error;
|
|
mod handshake;
|
|
mod message;
|
|
mod noise;
|
|
|
|
pub use credential::SessionCredential;
|
|
pub use error::{CloseReason, HandshakeRejection, ServiceErrorCode, TransportError};
|
|
pub use handshake::{ClientPrelude, ServerPrelude};
|
|
pub use message::{ClientMessage, ServerMessage, ServiceRejection, ServiceResult};
|
|
pub use noise::{NoiseInitiator, NoiseResponder, NoiseTransport};
|
|
|
|
pub const MAX_CREDENTIAL_FRAME: usize = 512;
|
|
/// First request read before a Windows service captures its pipe client's token.
|
|
pub const WINDOWS_ADMISSION_REQUEST: [u8; 4] = *b"GPC1";
|
|
pub const MAX_PRELUDE: usize = 256;
|
|
pub const MAX_PRODUCT_VERSION: usize = 64;
|
|
pub const HIP_PROTOCOL_VERSION: u16 = 1;
|
|
pub const MAX_PLAINTEXT: usize = 60 * 1024;
|
|
pub const MAX_WS_MESSAGE: usize = u16::MAX as usize;
|
|
pub const MAX_SERVICE_MESSAGE: usize = 256;
|
|
|
|
/// Private desktop control messages; never carry credentials.
|
|
pub const DESKTOP_GUI_EXITED: u8 = 0;
|
|
pub const DESKTOP_RENDERING_RETRY: u8 = 1;
|
|
pub const DESKTOP_SWITCH_BEGIN: u8 = 2;
|
|
pub const DESKTOP_SWITCH_COMMIT: u8 = 3;
|
|
pub const DESKTOP_SWITCH_CANCEL: u8 = 4;
|
|
/// Query whether the service package can install GUI runtime dependencies; replies with 0 or 1.
|
|
pub const DESKTOP_GUI_INSTALLER: u8 = 5;
|