client info is added
This commit is contained in:
parent
d65e294c42
commit
a572e8f45d
|
@ -2,17 +2,27 @@ use crate::protobuf::rpc;
|
|||
|
||||
const SUBJECT: &str = "bet.beteran.c2se.backend.identity";
|
||||
|
||||
pub const SUBJECT_CAPTCHA: &str = const_format::concatcp!(SUBJECT, ".Captcha");
|
||||
/// subject = bet.beteran.c2se.backend.identity.Captcha
|
||||
#[derive(Clone, PartialEq, ::prost::Message)]
|
||||
pub struct CaptchaRequest {}
|
||||
#[derive(Clone, PartialEq, ::prost::Message)]
|
||||
pub struct CaptchaResponse {
|
||||
#[prost(message, optional, tag = "1")]
|
||||
pub error: ::core::option::Option<rpc::Error>,
|
||||
#[prost(string, optional, tag = "2")]
|
||||
pub image: ::core::option::Option<::prost::alloc::string::String>,
|
||||
}
|
||||
|
||||
pub const SUBJECT_SIGNIN: &str = const_format::concatcp!(SUBJECT, ".Signin");
|
||||
/// subject = bet.beteran.c2se.backend.identity.Signin
|
||||
#[derive(Clone, PartialEq, ::prost::Message)]
|
||||
pub struct SigninRequest {
|
||||
#[prost(string, tag = "1")]
|
||||
pub site_url: ::prost::alloc::string::String,
|
||||
#[prost(string, tag = "2")]
|
||||
pub username: ::prost::alloc::string::String,
|
||||
#[prost(string, tag = "3")]
|
||||
#[prost(string, tag = "2")]
|
||||
pub password: ::prost::alloc::string::String,
|
||||
#[prost(string, tag = "4")]
|
||||
#[prost(string, tag = "3")]
|
||||
pub security_code: ::prost::alloc::string::String,
|
||||
}
|
||||
#[derive(Clone, PartialEq, ::prost::Message)]
|
||||
|
|
1
src/c2se/core/mod.rs
Normal file
1
src/c2se/core/mod.rs
Normal file
|
@ -0,0 +1 @@
|
|||
pub mod network;
|
3
src/c2se/core/network.rs
Normal file
3
src/c2se/core/network.rs
Normal file
|
@ -0,0 +1,3 @@
|
|||
const HEADER: &str = "bet.beteran.c2se.core.network";
|
||||
|
||||
pub const HEADER_CLIENT: &str = const_format::concatcp!(HEADER, ".Client");
|
|
@ -2,17 +2,27 @@ use crate::protobuf::rpc;
|
|||
|
||||
const SUBJECT: &str = "bet.beteran.c2se.frontend.identity";
|
||||
|
||||
pub const SUBJECT_CAPTCHA: &str = const_format::concatcp!(SUBJECT, ".Captcha");
|
||||
/// subject = bet.beteran.c2se.frontend.identity.Captcha
|
||||
#[derive(Clone, PartialEq, ::prost::Message)]
|
||||
pub struct CaptchaRequest {}
|
||||
#[derive(Clone, PartialEq, ::prost::Message)]
|
||||
pub struct CaptchaResponse {
|
||||
#[prost(message, optional, tag = "1")]
|
||||
pub error: ::core::option::Option<rpc::Error>,
|
||||
#[prost(string, optional, tag = "2")]
|
||||
pub image: ::core::option::Option<::prost::alloc::string::String>,
|
||||
}
|
||||
|
||||
pub const SUBJECT_SIGNIN: &str = const_format::concatcp!(SUBJECT, ".Signin");
|
||||
/// subject = bet.beteran.c2se.frontend.identity.Signin
|
||||
#[derive(Clone, PartialEq, ::prost::Message)]
|
||||
pub struct SigninRequest {
|
||||
#[prost(string, tag = "1")]
|
||||
pub site_url: ::prost::alloc::string::String,
|
||||
#[prost(string, tag = "2")]
|
||||
pub username: ::prost::alloc::string::String,
|
||||
#[prost(string, tag = "3")]
|
||||
#[prost(string, tag = "2")]
|
||||
pub password: ::prost::alloc::string::String,
|
||||
#[prost(string, tag = "4")]
|
||||
#[prost(string, tag = "3")]
|
||||
pub security_code: ::prost::alloc::string::String,
|
||||
}
|
||||
#[derive(Clone, PartialEq, ::prost::Message)]
|
||||
|
|
|
@ -1,8 +1,10 @@
|
|||
//!
|
||||
//!
|
||||
|
||||
///
|
||||
///
|
||||
pub mod backend;
|
||||
///
|
||||
///
|
||||
pub mod core;
|
||||
///
|
||||
pub mod frontend;
|
||||
|
|
1
src/models/core/mod.rs
Normal file
1
src/models/core/mod.rs
Normal file
|
@ -0,0 +1 @@
|
|||
pub mod network;
|
9
src/models/core/network.rs
Normal file
9
src/models/core/network.rs
Normal file
|
@ -0,0 +1,9 @@
|
|||
#[derive(Clone, PartialEq, ::prost::Message)]
|
||||
pub struct Client {
|
||||
#[prost(string, optional, tag = "1")]
|
||||
pub site_url: ::core::option::Option<::prost::alloc::string::String>,
|
||||
#[prost(uint64, tag = "2")]
|
||||
pub client_id: u64,
|
||||
#[prost(string, tag = "3")]
|
||||
pub client_ip: ::prost::alloc::string::String,
|
||||
}
|
|
@ -1 +1,2 @@
|
|||
pub mod core;
|
||||
pub mod member;
|
||||
|
|
|
@ -1,13 +1,28 @@
|
|||
use crate::models::core;
|
||||
use crate::protobuf::rpc;
|
||||
|
||||
const SUBJECT: &str = "bet.beteran.ss.member.identity";
|
||||
|
||||
/// subject = bet.beteran.ss.member.identity.Captcha
|
||||
#[derive(Clone, PartialEq, ::prost::Message)]
|
||||
pub struct CaptchaRequest {
|
||||
#[prost(message, optional, tag = "1")]
|
||||
pub client: ::core::option::Option<core::network::Client>,
|
||||
}
|
||||
#[derive(Clone, PartialEq, ::prost::Message)]
|
||||
pub struct CaptchaResponse {
|
||||
#[prost(message, optional, tag = "1")]
|
||||
pub error: ::core::option::Option<rpc::Error>,
|
||||
#[prost(string, optional, tag = "2")]
|
||||
pub image: ::core::option::Option<::prost::alloc::string::String>,
|
||||
}
|
||||
|
||||
pub const SUBJECT_SIGNIN: &str = const_format::concatcp!(SUBJECT, ".Signin");
|
||||
/// subject = bet.beteran.ss.member.identity.Signin
|
||||
#[derive(Clone, PartialEq, ::prost::Message)]
|
||||
pub struct SigninRequest {
|
||||
#[prost(string, tag = "1")]
|
||||
pub site_url: ::prost::alloc::string::String,
|
||||
#[prost(message, optional, tag = "1")]
|
||||
pub client: ::core::option::Option<core::network::Client>,
|
||||
#[prost(string, tag = "2")]
|
||||
pub username: ::prost::alloc::string::String,
|
||||
#[prost(string, tag = "3")]
|
||||
|
|
Loading…
Reference in New Issue
Block a user