This commit is contained in:
liujiahua123123 2019-08-17 21:51:03 +08:00
parent 091037ec49
commit 13b436152b
3 changed files with 5 additions and 5 deletions

View File

@ -37,7 +37,7 @@ class Client0836_622Packet(private val qq: Int, private val password: String, pr
this.writeQQ(qq)
this.writeHex("00 06")//tag
this.writeHex("00 78")//length
this.writeTLV0006(qq, password)
this.writeTLV0006(qq, password,)
//fix
this.writeHex(Protocol._0836_622_fix2)
this.writeHex("00 1A")//tag

View File

@ -36,11 +36,12 @@ class Server0825Packet(private val type: Type, inputStream: DataInputStream) : S
serverIP = data.readIP()
}
0X00 -> {
data.skip(67)
data.skip(5)
token = data.readNBytes(56)
data.skip(28)
loginTime = data.readInt()
loginIP = data.readIP()
token = data.readNBytes(56)
tgtgtKey = getRandomKey(16)
}

View File

@ -50,8 +50,7 @@ fun DataInputStream.readUntil(byte: Byte): ByteArray {
fun DataInputStream.readIP(): String {
var buff = ""
for (i in 0..3) {//todo: check t// hat
val b = readByte()
buff += (b.toInt() + (128)).toString()
buff += (readByte().toInt()).toString()
if(i !=3)buff+="."
}
return buff