auth

package
v0.0.0-...-1c51142 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 21, 2023 License: AGPL-3.0 Imports: 23 Imported by: 0

Documentation

Index

Constants

View Source
const (
	WLOGIN_A5

	WLOGIN_RESERVED
	WLOGIN_STWEB
	WLOGIN_A2
	WLOGIN_ST

	WLOGIN_LSKEY

	WLOGIN_SKEY
	WLOGIN_SIG64
	WLOGIN_OPENKEY
	WLOGIN_TOKEN

	WLOGIN_VKEY
	WLOGIN_D2
	WLOGIN_SID
	WLOGIN_PSKEY
	WLOGIN_AQSIG
	WLOGIN_LHSIG
	WLOGIN_PAYTOKEN
	WLOGIN_PF
	WLOGIN_DA2
	WLOGIN_QRPUSH
	WLOGIN_PT4Token
)

see oicq/wlogin_sdk/request/WtloginHelper.java class SigType

Variables

View Source
var (
	AppVersions = map[ProtocolType]*AppVersion{
		AndroidPhone: {
			ApkId:           "com.tencent.mobileqq",
			AppId:           537164840,
			SubAppId:        537164840,
			AppKey:          "0S200MNJT807V3GE",
			SortVersionName: "8.9.63.11390",
			BuildTime:       1685069178,
			ApkSign:         []byte{0xA6, 0xB7, 0x45, 0xBF, 0x24, 0xA2, 0xC2, 0x77, 0x52, 0x77, 0x16, 0xF6, 0xF3, 0x6E, 0xB6, 0x8D},
			SdkVersion:      "6.0.0.2546",
			SSOVersion:      20,
			MiscBitmap:      150470524,
			SubSigmap:       0x10400,
			MainSigMap: WLOGIN_A5 | WLOGIN_RESERVED | WLOGIN_STWEB | WLOGIN_A2 | WLOGIN_ST |
				WLOGIN_LSKEY | WLOGIN_SKEY | WLOGIN_SIG64 | 1<<16 | WLOGIN_VKEY | WLOGIN_D2 |
				WLOGIN_SID | WLOGIN_PSKEY | WLOGIN_AQSIG | WLOGIN_LHSIG | WLOGIN_PAYTOKEN,
			QUA:      "V1_AND_SQ_8.9.63_4194_YYB_D",
			Protocol: AndroidPhone,
		},
		AndroidPad: {
			ApkId:           "com.tencent.mobileqq",
			AppId:           537164888,
			SubAppId:        537164888,
			AppKey:          "0S200MNJT807V3GE",
			SortVersionName: "8.9.63.11390",
			BuildTime:       1685069178,
			ApkSign:         []byte{0xA6, 0xB7, 0x45, 0xBF, 0x24, 0xA2, 0xC2, 0x77, 0x52, 0x77, 0x16, 0xF6, 0xF3, 0x6E, 0xB6, 0x8D},
			SdkVersion:      "6.0.0.2546",
			SSOVersion:      20,
			MiscBitmap:      150470524,
			SubSigmap:       0x10400,
			MainSigMap: WLOGIN_A5 | WLOGIN_RESERVED | WLOGIN_STWEB | WLOGIN_A2 | WLOGIN_ST |
				WLOGIN_LSKEY | WLOGIN_SKEY | WLOGIN_SIG64 | 1<<16 | WLOGIN_VKEY | WLOGIN_D2 |
				WLOGIN_SID | WLOGIN_PSKEY | WLOGIN_AQSIG | WLOGIN_LHSIG | WLOGIN_PAYTOKEN,
			QUA:      "V1_AND_SQ_8.9.63_4194_YYB_D",
			Protocol: AndroidPad,
		},
		AndroidWatch: {
			ApkId:           "com.tencent.qqlite",
			AppId:           537065138,
			SubAppId:        537065138,
			SortVersionName: "2.0.8",
			BuildTime:       1559564731,
			ApkSign:         []byte{0xA6, 0xB7, 0x45, 0xBF, 0x24, 0xA2, 0xC2, 0x77, 0x52, 0x77, 0x16, 0xF6, 0xF3, 0x6E, 0xB6, 0x8D},
			SdkVersion:      "6.0.0.2365",
			SSOVersion:      5,
			MiscBitmap:      16252796,
			SubSigmap:       0x10400,
			MainSigMap: WLOGIN_A5 | WLOGIN_RESERVED | WLOGIN_STWEB | WLOGIN_A2 | WLOGIN_ST |
				WLOGIN_LSKEY | WLOGIN_SKEY | WLOGIN_SIG64 | 1<<16 | WLOGIN_VKEY | WLOGIN_D2 |
				WLOGIN_SID | WLOGIN_PSKEY | WLOGIN_AQSIG | WLOGIN_LHSIG | WLOGIN_PAYTOKEN,
			Protocol: AndroidWatch,
		},
		IPad: {
			ApkId:           "com.tencent.minihd.qq",
			AppId:           537151363,
			SubAppId:        537151363,
			SortVersionName: "8.9.33.614",
			BuildTime:       1595836208,
			ApkSign:         []byte{170, 57, 120, 244, 31, 217, 111, 249, 145, 74, 102, 158, 24, 100, 116, 199},
			SdkVersion:      "6.0.0.2433",
			SSOVersion:      19,
			MiscBitmap:      150470524,
			SubSigmap:       66560,
			MainSigMap:      WLOGIN_STWEB | WLOGIN_A2 | WLOGIN_ST | WLOGIN_SKEY | WLOGIN_VKEY | WLOGIN_D2 | WLOGIN_SID | WLOGIN_PSKEY,
			Protocol:        IPad,
		},
		MacOS: {
			ApkId:           "com.tencent.minihd.qq",
			AppId:           537128930,
			SubAppId:        537128930,
			SortVersionName: "5.8.9",
			BuildTime:       1595836208,
			ApkSign:         []byte{170, 57, 120, 244, 31, 217, 111, 249, 145, 74, 102, 158, 24, 100, 116, 199},
			SdkVersion:      "6.0.0.2433",
			SSOVersion:      12,
			MiscBitmap:      150470524,
			SubSigmap:       66560,
			MainSigMap:      WLOGIN_STWEB | WLOGIN_A2 | WLOGIN_ST | WLOGIN_SKEY | WLOGIN_VKEY | WLOGIN_D2 | WLOGIN_SID | WLOGIN_PSKEY,
			Protocol:        MacOS,
		},
		QiDian: {
			ApkId:           "com.tencent.qidian",
			AppId:           537141082,
			SubAppId:        537036590,
			SortVersionName: "5.0.0",
			BuildTime:       1630062176,
			ApkSign:         []byte{160, 30, 236, 171, 133, 233, 227, 186, 43, 15, 106, 21, 140, 133, 92, 41},
			SdkVersion:      "6.0.0.2484",
			SSOVersion:      18,
			MiscBitmap:      184024956,
			SubSigmap:       66560,
			MainSigMap:      WLOGIN_STWEB | WLOGIN_A2 | WLOGIN_ST | WLOGIN_SKEY | WLOGIN_D2 | WLOGIN_PSKEY | WLOGIN_DA2,
			Protocol:        QiDian,
		},
	}
)

Functions

func CalcPow

func CalcPow(data []byte) []byte

Types

type AppVersion

type AppVersion struct {
	ApkSign         []byte
	ApkId           string
	SortVersionName string
	SdkVersion      string
	AppId           uint32
	SubAppId        uint32
	AppKey          string
	BuildTime       uint32
	SSOVersion      uint32
	MiscBitmap      uint32
	SubSigmap       uint32
	MainSigMap      uint32
	QUA             string
	Protocol        ProtocolType
}

func (*AppVersion) String

func (v *AppVersion) String() string

func (*AppVersion) UpdateFromJson

func (v *AppVersion) UpdateFromJson(d []byte) error

type Device

type Device struct {
	Display      []byte
	Product      []byte
	Device       []byte
	Board        []byte
	Brand        []byte
	Model        []byte
	Bootloader   []byte
	FingerPrint  []byte
	BootId       []byte
	ProcVersion  []byte
	BaseBand     []byte
	SimInfo      []byte
	OSType       []byte
	MacAddress   []byte
	IpAddress    []byte
	WifiBSSID    []byte
	WifiSSID     []byte
	IMSIMd5      []byte
	IMEI         string
	AndroidId    []byte
	APN          []byte
	VendorName   []byte
	VendorOSName []byte
	Guid         []byte
	TgtgtKey     []byte
	QImei16      string
	QImei36      string
	Protocol     ProtocolType
	Version      *OSVersion
}

func (*Device) GenDeviceInfoData

func (info *Device) GenDeviceInfoData() []byte

func (*Device) GenNewGuid

func (info *Device) GenNewGuid()

func (*Device) GenNewTgtgtKey

func (info *Device) GenNewTgtgtKey()

func (*Device) ReadJson

func (info *Device) ReadJson(d []byte) error

func (*Device) RequestQImei

func (info *Device) RequestQImei()

func (*Device) ToJson

func (info *Device) ToJson() []byte

type OSVersion

type OSVersion struct {
	Incremental []byte
	Release     []byte
	CodeName    []byte
	SDK         uint32
}

type ProtocolType

type ProtocolType int
const (
	Unset        ProtocolType = iota
	AndroidPhone              // Android Phone
	AndroidWatch              // Android Watch
	MacOS                     // MacOS
	QiDian                    // 企点
	IPad                      // iPad
	AndroidPad                // Android Pad
)

func (ProtocolType) String

func (i ProtocolType) String() string

func (ProtocolType) Version

func (i ProtocolType) Version() *AppVersion

type SigInfo

type SigInfo struct {
	LoginBitmap uint64
	TGT         []byte
	TGTKey      []byte

	SrmToken        []byte // study room manager | 0x16a
	T133            []byte
	EncryptedA1     []byte
	UserStKey       []byte
	UserStWebSig    []byte
	SKey            []byte
	SKeyExpiredTime int64
	D2              []byte
	D2Key           []byte
	DeviceToken     []byte

	PsKeyMap    map[string][]byte
	Pt4TokenMap map[string][]byte

	// Others
	OutPacketSessionID []byte
	Dpwd               []byte

	// tlv cache
	T104     []byte
	T174     []byte
	G        []byte
	T402     []byte
	RandSeed []byte // t403
	T547     []byte

	// sync info
	SyncCookie       []byte
	PubAccountCookie []byte
	Ksid             []byte
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL