Skip to main content

bitwarden_importers/importers/keeper/proto/
push.rs

1// This file is @generated by prost-build.
2#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
3pub struct UserRegistrationRequest {
4    #[prost(bytes = "vec", tag = "1")]
5    pub message_session_uid: ::prost::alloc::vec::Vec<u8>,
6    #[prost(int32, tag = "2")]
7    pub user_id: i32,
8    #[prost(int32, tag = "3")]
9    pub enterprise_id: i32,
10}
11#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
12pub struct KaToPushServerRequest {
13    #[prost(enumeration = "MessageType", tag = "1")]
14    pub message_type: i32,
15    #[prost(string, tag = "2")]
16    pub message: ::prost::alloc::string::String,
17    #[prost(bytes = "vec", tag = "3")]
18    pub message_session_uid: ::prost::alloc::vec::Vec<u8>,
19    #[prost(bytes = "vec", repeated, tag = "4")]
20    pub encrypted_device_token: ::prost::alloc::vec::Vec<::prost::alloc::vec::Vec<u8>>,
21    #[prost(int32, repeated, tag = "5")]
22    pub user_id: ::prost::alloc::vec::Vec<i32>,
23    #[prost(int32, repeated, tag = "6")]
24    pub enterprise_id: ::prost::alloc::vec::Vec<i32>,
25}
26#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
27pub struct WssConnectionRequest {
28    #[prost(bytes = "vec", tag = "1")]
29    pub message_session_uid: ::prost::alloc::vec::Vec<u8>,
30    #[prost(bytes = "vec", tag = "2")]
31    pub encrypted_device_token: ::prost::alloc::vec::Vec<u8>,
32    #[prost(int64, tag = "3")]
33    pub device_time_stamp: i64,
34}
35#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
36pub struct WssClientResponse {
37    #[prost(enumeration = "MessageType", tag = "1")]
38    pub message_type: i32,
39    #[prost(string, tag = "2")]
40    pub message: ::prost::alloc::string::String,
41}
42#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
43pub struct PushServerDeviceRegistrationRequest {
44    #[prost(bytes = "vec", tag = "1")]
45    pub encrypted_device_token: ::prost::alloc::vec::Vec<u8>,
46    #[prost(string, tag = "2")]
47    pub push_token: ::prost::alloc::string::String,
48    #[prost(string, tag = "3")]
49    pub mobile_push_platform: ::prost::alloc::string::String,
50    #[prost(bytes = "vec", tag = "4")]
51    pub transmission_key: ::prost::alloc::vec::Vec<u8>,
52}
53#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
54pub struct SnsMessage {
55    #[prost(enumeration = "MessageType", tag = "1")]
56    pub message_type: i32,
57    #[prost(bytes = "vec", tag = "2")]
58    pub message: ::prost::alloc::vec::Vec<u8>,
59}
60#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
61#[repr(i32)]
62pub enum MessageType {
63    Unknown = 0,
64    Dna = 1,
65    Sso = 2,
66    Chat = 3,
67    User = 4,
68    Enterprise = 5,
69    Keeper = 6,
70    Session = 7,
71    Device = 8,
72    Totp = 9,
73}
74impl MessageType {
75    /// String value of the enum field names used in the ProtoBuf definition.
76    ///
77    /// The values are not transformed in any way and thus are considered stable
78    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
79    pub fn as_str_name(&self) -> &'static str {
80        match self {
81            Self::Unknown => "UNKNOWN",
82            Self::Dna => "DNA",
83            Self::Sso => "SSO",
84            Self::Chat => "CHAT",
85            Self::User => "USER",
86            Self::Enterprise => "ENTERPRISE",
87            Self::Keeper => "KEEPER",
88            Self::Session => "SESSION",
89            Self::Device => "DEVICE",
90            Self::Totp => "TOTP",
91        }
92    }
93    /// Creates an enum from field names used in the ProtoBuf definition.
94    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
95        match value {
96            "UNKNOWN" => Some(Self::Unknown),
97            "DNA" => Some(Self::Dna),
98            "SSO" => Some(Self::Sso),
99            "CHAT" => Some(Self::Chat),
100            "USER" => Some(Self::User),
101            "ENTERPRISE" => Some(Self::Enterprise),
102            "KEEPER" => Some(Self::Keeper),
103            "SESSION" => Some(Self::Session),
104            "DEVICE" => Some(Self::Device),
105            "TOTP" => Some(Self::Totp),
106            _ => None,
107        }
108    }
109}