kv-proto: add PreloginResponse for GET /v1/auth/prelogin
A new device needs account_id and the KDF params to derive AUTH_INPUT before it can build KE1, so they cannot come only from login/start. Co-Authored-By: Claude Opus 5.5 <[email protected]>
This commit is contained in:
@@ -134,6 +134,14 @@ pub struct SetupRequest {
|
||||
pub device: DeviceEnroll,
|
||||
}
|
||||
|
||||
/// `GET /v1/auth/prelogin`: the public inputs a new device needs to derive `AUTH_INPUT`
|
||||
/// before it can build `ke1` (docs/02 "Key derivation"). Unauthenticated, rate limited.
|
||||
#[derive(Debug, Clone, Serialize, Deserialize)]
|
||||
pub struct PreloginResponse {
|
||||
pub account_id: Uuid,
|
||||
pub kdf: KdfParams,
|
||||
}
|
||||
|
||||
/// `POST /v1/auth/login/start`.
|
||||
#[derive(Debug, Clone, Serialize, Deserialize)]
|
||||
pub struct LoginStart {
|
||||
|
||||
Reference in New Issue
Block a user