MCPcopy Create free account
hub / github.com/LagrangeDev/LagrangeGo / buildLoginPacket

Method buildLoginPacket

client/oicq.go:78–92  ·  view source on GitHub ↗
(uin uint32, cmd string, body []byte)

Source from the content-addressed store, hash-verified

76}
77
78func (c *QQClient) buildLoginPacket(uin uint32, cmd string, body []byte) []byte {
79 var _cmd uint16
80 if cmd == "wtlogin.login" {
81 _cmd = 2064
82 } else {
83 _cmd = 2066
84 }
85
86 return c.oicq.Marshal(&oicq.Message{
87 Uin: uin,
88 Command: _cmd,
89 EncryptionMethod: oicq.EM_ECDH,
90 Body: body,
91 })
92}
93
94func (c *QQClient) decodeLoginResponse(buf []byte, sig *auth.SigInfo) (LoginResponse, error) {
95 reader := binary.NewReader(buf)

Callers 2

buildCode2dPacketMethod · 0.95
QRCodeLoginMethod · 0.95

Calls 1

MarshalMethod · 0.45

Tested by

no test coverage detected