How prateek-banerjee/quantum-resistant_pake_protocols works
This Rust workspace implements three quantum-resistant PAKE protocols—TK-PAKE, modified OCAKE-PAKE, and KEM-AE-PAKE—and a Tokio client/server executor. The user workflow is client registration followed by login, protocol-message exchange, and session-key derivation; the server loads and updates per-client state and enforces login-attempt controls. Protocol-specific cryptography relies on shared encoding, variant dispatch, and KEM wrappers. README also documents replaceable storage, including SQLite. Executor server routing and some subsystem internals were not excerpted, so their links are left unverified rather than inferred.
Main entry points: common_details.rs Shared protocol details · server_handler.rs Server request handling · kem_ae_pake/server.rs KEM-AE protocol · ocake_pake/server.rs OCAKE protocol
Components 27
Client API
- Register and login
qr_pake_protocols/pake_protocol_executors/src/executors/b_pake_protocols/generic_client.rs
Protocol execution
- Client handlers
qr_pake_protocols/pake_protocol_executors/src/protocol_execution_logic/b_pake_protocols/multi_client_handler/client_handler.rs - KEM-AE client flow
qr_pake_protocols/pake_protocol_executors/src/protocol_execution_logic/b_pake_protocols/multi_client_handler/kem_ae_pake/client_side.rs - OCAKE client flow
qr_pake_protocols/pake_protocol_executors/src/protocol_execution_logic/b_pake_protocols/multi_client_handler/ocake_pake/client_side.rs - TK client flow
qr_pake_protocols/pake_protocol_executors/src/protocol_execution_logic/b_pake_protocols/multi_client_handler/tk_pake/client_side.rs - Server request handling
qr_pake_protocols/pake_protocol_executors/src/protocol_execution_logic/b_pake_protocols/multi_client_handler/server_handler.rs - KEM-AE server flow
qr_pake_protocols/pake_protocol_executors/src/protocol_execution_logic/b_pake_protocols/multi_client_handler/kem_ae_pake/server_side.rs - OCAKE server flow
qr_pake_protocols/pake_protocol_executors/src/protocol_execution_logic/b_pake_protocols/multi_client_handler/ocake_pake/server_side.rs - TK server flow
qr_pake_protocols/pake_protocol_executors/src/protocol_execution_logic/b_pake_protocols/multi_client_handler/tk_pake/server_side.rs
PAKE protocols
- KEM-AE protocol
qr_pake_protocols/src/core_protocol_functionalities/b_pake_protocols/kem_ae_pake/server.rs - KEM-AE client
qr_pake_protocols/src/core_protocol_functionalities/b_pake_protocols/kem_ae_pake/client.rs - OCAKE protocol
qr_pake_protocols/src/core_protocol_functionalities/b_pake_protocols/ocake_pake/server.rs - OCAKE client
qr_pake_protocols/src/core_protocol_functionalities/b_pake_protocols/ocake_pake/client.rs - TK protocol
qr_pake_protocols/src/core_protocol_functionalities/b_pake_protocols/tk_pake/server.rs - TK client
qr_pake_protocols/src/core_protocol_functionalities/b_pake_protocols/tk_pake/client.rs - Shared protocol details
qr_pake_protocols/src/core_protocol_functionalities/b_pake_protocols/kem_ae_pake/common_details.rs
Crypto support
- Encoding and decoding
qr_pake_protocols/src/encode_decode.rs - Base conversion
qr_pake_protocols/src/base_converter.rs - Common crypto functions
qr_pake_protocols/src/overall_common_functionalities.rs - Variant selection
qr_pake_protocols/src/protocol_variants.rs - ML-KEM wrapper
qr_pake_protocols/src/mlkem_variant_wrapper.rs - Frodo wrapper
qr_pake_protocols/src/frodo_variant_wrapper.rs
State storage
- Storage interface
qr_pake_protocols/pake_protocol_executors/src/protocol_execution_logic/b_pake_protocols/multi_client_handler/storage_handler.rs - In-memory storage
qr_pake_protocols/pake_protocol_executors/src/protocol_execution_logic/b_pake_protocols/multi_client_handler/storage_handler.rs - SQLite storage
test_framework_api/src/other_storage.rs
Other components
- Client
- PAKE server
Connections 27
- Client → Register and login: requests registration/login
qr_pake_protocols/pake_protocol_executors/src/executors/b_pake_protocols/generic_client.rs - Register and login → Client handlers: dispatches
qr_pake_protocols/pake_protocol_executors/src/executors/b_pake_protocols/generic_client.rs - KEM-AE client flow → KEM-AE protocol: runs protocol
- OCAKE client flow → OCAKE client: runs protocol
- TK client flow → TK client: runs protocol
- PAKE server → Server request handling: sends requests
- Server request handling → Storage interface: uses state
qr_pake_protocols/pake_protocol_executors/src/protocol_execution_logic/b_pake_protocols/multi_client_handler/server_handler.rs - Server request handling → KEM-AE server flow: routes protocol
- Server request handling → OCAKE server flow: routes protocol
- Server request handling → TK server flow: routes protocol
- KEM-AE server flow → KEM-AE protocol: runs protocol
- OCAKE server flow → OCAKE protocol: runs protocol
- TK server flow → TK protocol: runs protocol
- KEM-AE protocol → Shared protocol details: uses details
qr_pake_protocols/src/core_protocol_functionalities/b_pake_protocols/kem_ae_pake/server.rs - OCAKE protocol → Shared protocol details: uses details
qr_pake_protocols/src/core_protocol_functionalities/b_pake_protocols/ocake_pake/server.rs - TK protocol → Shared protocol details: uses details
qr_pake_protocols/src/core_protocol_functionalities/b_pake_protocols/tk_pake/server.rs - KEM-AE client → Shared protocol details: uses details
qr_pake_protocols/src/core_protocol_functionalities/b_pake_protocols/kem_ae_pake/client.rs - OCAKE client → Shared protocol details: uses details
qr_pake_protocols/src/core_protocol_functionalities/b_pake_protocols/ocake_pake/client.rs - TK client → Shared protocol details: uses details
qr_pake_protocols/src/core_protocol_functionalities/b_pake_protocols/tk_pake/client.rs - KEM-AE protocol → Common crypto functions: calls crypto
qr_pake_protocols/src/core_protocol_functionalities/b_pake_protocols/kem_ae_pake/server.rs - OCAKE protocol → Common crypto functions: calls crypto
qr_pake_protocols/src/core_protocol_functionalities/b_pake_protocols/ocake_pake/server.rs - TK protocol → Common crypto functions: calls crypto
qr_pake_protocols/src/core_protocol_functionalities/b_pake_protocols/tk_pake/server.rs - Base conversion → Encoding and decoding: uses codecs
qr_pake_protocols/src/base_converter.rs - Variant selection → ML-KEM wrapper: constructs dispatcher
qr_pake_protocols/src/protocol_variants.rs - Variant selection → Frodo wrapper: constructs dispatcher
qr_pake_protocols/src/protocol_variants.rs - Storage interface → In-memory storage: implements
qr_pake_protocols/pake_protocol_executors/src/protocol_execution_logic/b_pake_protocols/multi_client_handler/storage_handler.rs - SQLite storage → Storage interface: implements trait
test_framework_api/src/other_storage.rs