Skip to main content

steam_protos/messages/
credentials.rs

1//! Credentials protobuf messages
2
3use prost::Message;
4
5use crate::messages::base::CMsgIPAddress;
6
7/// Get Steam Guard details request
8#[derive(Clone, PartialEq, Message)]
9pub struct CCredentialsGetSteamGuardDetailsRequest {
10    #[prost(string, optional, tag = "2")]
11    pub webcookie: Option<String>,
12    #[prost(fixed32, optional, tag = "3")]
13    pub timestamp_minimum_wanted: Option<u32>,
14    #[prost(int32, optional, tag = "4")]
15    pub deprecated_ipaddress: Option<i32>,
16    #[prost(message, optional, tag = "5")]
17    pub ip_address: Option<CMsgIPAddress>,
18}
19
20/// Get Steam Guard details response
21#[derive(Clone, PartialEq, Message)]
22pub struct CCredentialsGetSteamGuardDetailsResponse {
23    #[prost(bool, optional, tag = "1")]
24    pub is_steamguard_enabled: Option<bool>,
25    #[prost(fixed32, optional, tag = "2")]
26    pub timestamp_steamguard_enabled: Option<u32>,
27    #[prost(string, optional, tag = "4")]
28    pub deprecated_machine_name_userchosen: Option<String>,
29    #[prost(fixed32, optional, tag = "5")]
30    pub deprecated_timestamp_machine_steamguard_enabled: Option<u32>,
31    #[prost(bool, optional, tag = "6")]
32    pub deprecated_authentication_exists_from_geoloc_before_mintime: Option<bool>,
33    #[prost(uint64, optional, tag = "7")]
34    pub deprecated_machine_id: Option<u64>,
35    #[prost(message, repeated, tag = "8")]
36    pub session_data: Vec<CredentialsSessionData>,
37    #[prost(bool, optional, tag = "9")]
38    pub is_twofactor_enabled: Option<bool>,
39    #[prost(fixed32, optional, tag = "10")]
40    pub timestamp_twofactor_enabled: Option<u32>,
41    #[prost(bool, optional, tag = "11")]
42    pub is_phone_verified: Option<bool>,
43}
44
45/// Session data for Steam Guard details
46#[derive(Clone, PartialEq, Message)]
47pub struct CredentialsSessionData {
48    #[prost(uint64, optional, tag = "1")]
49    pub machine_id: Option<u64>,
50    #[prost(string, optional, tag = "2")]
51    pub machine_name_userchosen: Option<String>,
52    #[prost(fixed32, optional, tag = "3")]
53    pub timestamp_machine_steamguard_enabled: Option<u32>,
54    #[prost(bool, optional, tag = "4")]
55    pub authentication_exists_from_geoloc_before_mintime: Option<bool>,
56    #[prost(bool, optional, tag = "6")]
57    pub authentication_exists_from_same_ip_before_mintime: Option<bool>,
58    #[prost(uint32, optional, tag = "7")]
59    pub public_ipv4: Option<u32>,
60    #[prost(string, optional, tag = "8")]
61    pub public_ip_address: Option<String>,
62}
63
64/// Get last credential change time request
65#[derive(Clone, PartialEq, Message)]
66pub struct CCredentialsLastCredentialChangeTimeRequest {
67    #[prost(bool, optional, tag = "1")]
68    pub user_changes_only: Option<bool>,
69}
70
71/// Get last credential change time response
72#[derive(Clone, PartialEq, Message)]
73pub struct CCredentialsLastCredentialChangeTimeResponse {
74    #[prost(fixed32, optional, tag = "1")]
75    pub timestamp_last_password_change: Option<u32>,
76    #[prost(fixed32, optional, tag = "2")]
77    pub timestamp_last_email_change: Option<u32>,
78    #[prost(fixed32, optional, tag = "3")]
79    pub timestamp_last_password_reset: Option<u32>,
80}
81
82/// Get account auth secret request
83#[derive(Clone, PartialEq, Message)]
84pub struct CCredentialsGetAccountAuthSecretRequest {}
85
86/// Get account auth secret response
87#[derive(Clone, PartialEq, Message)]
88pub struct CCredentialsGetAccountAuthSecretResponse {
89    #[prost(int32, optional, tag = "1")]
90    pub secret_id: Option<i32>,
91    #[prost(bytes = "vec", optional, tag = "2")]
92    pub secret: Option<Vec<u8>>,
93}