From 3c9127625f965a13d47b427a0db389d0cd257028 Mon Sep 17 00:00:00 2001 From: James Berry Date: Sun, 14 Apr 2024 09:41:05 +0100 Subject: [PATCH 1/2] Capability proposal --- rotom.proto | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/rotom.proto b/rotom.proto index db1eb8f..4987d54 100644 --- a/rotom.proto +++ b/rotom.proto @@ -62,6 +62,7 @@ message MitmResponse { AuthStatus status = 2; bool supports_compression = 3; string useragent = 4; + uint64 mitm_capability = 5; // Bitwise field built up of Mitm Capability flags } message RpcResponse { @@ -131,3 +132,7 @@ enum RpcStatus { RPC_STATUS_LOGIN_ERROR_BAIL = 20; RPC_STATUS_MITM_DISALLOWED_REQUEST = 99; } + +enum MitmCapability { + MITM_CAPABILITY_REQUEST_LONG_SESSIONS = 1; +} \ No newline at end of file From 8a44c7e4cce47d2c5bafff4e3df053fbfe7de45e Mon Sep 17 00:00:00 2001 From: James Berry Date: Tue, 16 Apr 2024 10:10:34 +0100 Subject: [PATCH 2/2] Change new capability to bool; add some comments --- rotom.proto | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) diff --git a/rotom.proto b/rotom.proto index 4987d54..94a8bf8 100644 --- a/rotom.proto +++ b/rotom.proto @@ -23,14 +23,14 @@ message MitmRequest { LoginSource source = 2; bytes token_proto = 3; string worker_id = 4; - bool enable_compression = 5; + bool enable_compression = 5; // Controller can support compressed responses } message RpcRequest { message SingleRpcRequest { int32 method = 1; bytes payload = 2; - bool is_compressed = 3; + bool is_compressed = 3; // This request is compressed } repeated SingleRpcRequest request = 1; @@ -60,16 +60,16 @@ message MitmResponse { message LoginResponse { string worker_id = 1; AuthStatus status = 2; - bool supports_compression = 3; + bool supports_compression = 3; // Agent can support compressed requests string useragent = 4; - uint64 mitm_capability = 5; // Bitwise field built up of Mitm Capability flags + bool request_long_sessions = 5; // Agent prefers longer sessions over fast reconnects } message RpcResponse { message SingleRpcResponse { int32 method = 1; bytes payload = 2; - bool is_compressed = 3; + bool is_compressed = 3; // This payload response is compressed } RpcStatus rpc_status = 1; @@ -132,7 +132,3 @@ enum RpcStatus { RPC_STATUS_LOGIN_ERROR_BAIL = 20; RPC_STATUS_MITM_DISALLOWED_REQUEST = 99; } - -enum MitmCapability { - MITM_CAPABILITY_REQUEST_LONG_SESSIONS = 1; -} \ No newline at end of file