Documentation ¶
Index ¶
- Constants
- type AuthStruct
- func (a *AuthStruct) Auth() (cookies string, err error)
- func (a *AuthStruct) AuthDevice() (cookies string, err error)
- func (a *AuthStruct) AuthEmail(code string) (cookies string, err error)
- func (a *AuthStruct) GetLoginType() string
- func (a *AuthStruct) SetContext(ctx []byte) (err error)
- func (a *AuthStruct) SetCookie(cookies string) (err error)
Constants ¶
View Source
const ( TYPE_PASSWD = "passwd" TYPE_EMAIL = "email" TYPE_DEVICE = "device" )
View Source
const (
USER_AGENT = "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36 Edg/120.0.0.0"
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AuthStruct ¶
type AuthStruct struct { Account string Password string LoginType string Id string Lcid string Uaid string FlowToken string Ppft string Cobrandid string UrlGetCredentialType string CredentialType getCredentialTypeResp UrlPostMsa string // Passwd Login Part 1 UrlPost string // Passwd Login Part 1 UrlSessionState string // Device Login Part 1 // Get Cookie ActionUrl string PassportData struct { NAPExp string PPRID string NAP string ANON string ANONExp string T string } // contains filtered or unexported fields }
func NewAuth ¶
func NewAuth(account, password, loginType string) *AuthStruct
func (*AuthStruct) Auth ¶
func (a *AuthStruct) Auth() (cookies string, err error)
func (*AuthStruct) AuthDevice ¶
func (a *AuthStruct) AuthDevice() (cookies string, err error)
func (*AuthStruct) AuthEmail ¶
func (a *AuthStruct) AuthEmail(code string) (cookies string, err error)
func (*AuthStruct) GetLoginType ¶
func (a *AuthStruct) GetLoginType() string
func (*AuthStruct) SetContext ¶ added in v1.1.0
func (a *AuthStruct) SetContext(ctx []byte) (err error)
func (*AuthStruct) SetCookie ¶ added in v1.1.0
func (a *AuthStruct) SetCookie(cookies string) (err error)
Source Files ¶
Click to show internal directories.
Click to hide internal directories.