Documentation ¶
Index ¶
- type Check
- type CheckData
- type ComboTokenReq
- type ComboTokenReqLoginTokenData
- type ComboTokenRsp
- type ComboTokenRspLoginData
- type Gate
- type Geetest
- type GranterApiGetConfig
- type GranterApiGetConfigData
- type Login
- type LoginAccount
- type LoginAccountRequestJson
- type LoginData
- type LoginTokenRequest
- type NodeService
- type QrAppIcons
- type QrEnabledApps
- type RiskyApiCheck
- type Server
- func (s *Server) ComboGranterApiGetConfigHandler(c *gin.Context)
- func (s *Server) ErrorDispatch(c *gin.Context)
- func (s *Server) ErrorGate(c *gin.Context)
- func (s *Server) ExchangeCdkey(c *gin.Context)
- func (s *Server) GetAgreementInfos(c *gin.Context)
- func (s *Server) GetExperimentListHandler(c *gin.Context)
- func (s *Server) GlobalRotationEvent()
- func (s *Server) HandleDefault(c *gin.Context)
- func (s *Server) InitRouter()
- func (s *Server) LoginRequestHandler(c *gin.Context)
- func (s *Server) QueryDispatchHandler(c *gin.Context)
- func (s *Server) QueryGatewayHandler(c *gin.Context)
- func (s *Server) QueryGatewayHandlerCapture(c *gin.Context)
- func (s *Server) QueryGatewayHandlerCaptureCn(c *gin.Context)
- func (s *Server) RiskyApiCheckHandler(c *gin.Context)
- func (s *Server) SdkDataUploadHandler(c *gin.Context)
- func (s *Server) Shutdown(context.Context) error
- func (s *Server) Start() error
- func (s *Server) V2LoginRequestHandler(c *gin.Context)
- func (s *Server) VerifyRequestHandler(c *gin.Context)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ComboTokenReq ¶
type ComboTokenRsp ¶
type ComboTokenRsp struct { Retcode int `json:"retcode"` Message string `json:"message"` Data *ComboTokenRspLoginData `json:"data"` }
type ComboTokenRspLoginData ¶
type GranterApiGetConfig ¶
type GranterApiGetConfig struct { Data *GranterApiGetConfigData `json:"data"` Message string `json:"message"` Retcode any `json:"retcode"` }
type GranterApiGetConfigData ¶
type GranterApiGetConfigData struct { Protocol bool `json:"protocol"` QrEnabled bool `json:"qr_enabled"` LogLevel string `json:"log_level"` AnnounceURL string `json:"announce_url"` PushAliasType int `json:"push_alias_type"` DisableYsdkGuard bool `json:"disable_ysdk_guard"` EnableAnnouncePicPopup bool `json:"enable_announce_pic_popup"` AppName string `json:"app_name"` QrEnabledApps QrEnabledApps `json:"qr_enabled_apps"` QrAppIcons QrAppIcons `json:"qr_app_icons"` QrCloudDisplayName string `json:"qr_cloud_display_name"` EnableUserCenter bool `json:"enable_user_center"` }
type LoginAccount ¶
type LoginAccount struct { UID string `json:"uid"` Name string `json:"name"` Email string `json:"email"` Mobile string `json:"mobile"` IsEmailVerify string `json:"is_email_verify"` Realname string `json:"realname"` IdentityCard string `json:"identity_card"` Token string `json:"token"` SafeMobile string `json:"safe_mobile"` FacebookName string `json:"facebook_name"` GoogleName string `json:"google_name"` TwitterName string `json:"twitter_name"` GameCenterName string `json:"game_center_name"` AppleName string `json:"apple_name"` SonyName string `json:"sony_name"` TapName string `json:"tap_name"` Country string `json:"country"` ReactivateTicket string `json:"reactivate_ticket"` AreaCode string `json:"area_code"` DeviceGrantTicket string `json:"device_grant_ticket"` SteamName string `json:"steam_name"` UnmaskedEmail string `json:"unmasked_email"` UnmaskedEmailType int `json:"unmasked_email_type"` }
type LoginAccountRequestJson ¶
type LoginData ¶
type LoginData struct { Account *LoginAccount `json:"account"` DeviceGrantRequired bool `json:"device_grant_required"` SafeMoblieRequired bool `json:"safe_moblie_required"` RealpersonRequired bool `json:"realperson_required"` ReactivateRequired bool `json:"reactivate_required"` RealnameOperation string `json:"realname_operation"` }
type LoginTokenRequest ¶
type NodeService ¶ added in v1.2.1
type NodeService struct {
// contains filtered or unexported fields
}
func (*NodeService) GetAllServiceGateRsp ¶ added in v1.2.1
func (n *NodeService) GetAllServiceGateRsp(serviceMsg pb.Message)
ping包回应
func (*NodeService) ServiceConnectionReq ¶ added in v1.2.1
func (n *NodeService) ServiceConnectionReq()
向node注册
func (*NodeService) ServiceConnectionRsp ¶ added in v1.2.1
func (n *NodeService) ServiceConnectionRsp(serviceMsg pb.Message)
向node注册回包
type QrAppIcons ¶
type QrEnabledApps ¶
type RiskyApiCheck ¶
type Server ¶
type Server struct { AppId uint32 Port string InnerAddr string OuterAddr string IsAutoCreate bool Config *config.Config Store *dispatch.Store Router *gin.Engine AutoCreate sync.Mutex Ec2b *random.Ec2b DispatchList []config.Dispatch Ticker *time.Ticker Stop chan struct{} IsPe bool KcpIp string KcpPort uint32 // contains filtered or unexported fields }
func (*Server) ComboGranterApiGetConfigHandler ¶
func (*Server) ErrorDispatch ¶ added in v1.3.0
func (*Server) ExchangeCdkey ¶ added in v1.4.0
func (*Server) GetAgreementInfos ¶
func (*Server) GetExperimentListHandler ¶
func (*Server) GlobalRotationEvent ¶ added in v1.2.1
func (s *Server) GlobalRotationEvent()
func (*Server) HandleDefault ¶
func (*Server) InitRouter ¶
func (s *Server) InitRouter()
func (*Server) LoginRequestHandler ¶
登录流程 1.从数据库获取此用户名,有返回,无则下一步 2.若关闭了自动注册返回次用户不存在,否则进入下一步 3.此步是开启了自动注册,将用户名写入数据库,并且获取到key作为accountUid返回
func (*Server) QueryDispatchHandler ¶
func (*Server) QueryGatewayHandler ¶
func (*Server) QueryGatewayHandlerCapture ¶
其逻辑不适用于大流量使用,请仅在dev中/人数较少时使用
func (*Server) QueryGatewayHandlerCaptureCn ¶ added in v1.2.2
func (*Server) RiskyApiCheckHandler ¶
func (*Server) SdkDataUploadHandler ¶
func (*Server) V2LoginRequestHandler ¶
流程: 1.检查token是否正确 2.若正确则生成token返回 3.若错误或不存在则返回错误
func (*Server) VerifyRequestHandler ¶
Click to show internal directories.
Click to hide internal directories.