Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

登录后获取当前登录用户信息(type=1)3.9.0.28异常退出 #28

Closed
estinfo opened this issue Feb 15, 2023 · 17 comments
Closed

登录后获取当前登录用户信息(type=1)3.9.0.28异常退出 #28

estinfo opened this issue Feb 15, 2023 · 17 comments
Labels
bug Something isn't working good first issue Good for newcomers

Comments

@estinfo
Copy link

estinfo commented Feb 15, 2023

确认登录以后:

image

未确认登录可以正常获取

image

@ttttupup
Copy link
Owner

错误信息里的堆栈信息发一下

@ttttupup ttttupup added the bug Something isn't working label Feb 15, 2023
@estinfo
Copy link
Author

estinfo commented Feb 15, 2023

`Windows 10 Enterprise [Build 10.0.18363]
CPU: Intel(R) Xeon(R) CPU E3-1225 v3 @ 3.40GHz
微信 3.90.0028 2023/2/15 08:41:28

Type: EXCEPTION_ACCESS_VIOLATION
Error: Read address 0x63617243
Address: 77BF4437

CallStack:
VCRUNTIME140D + 0x00004437: (0x1342B884,0x63617243,0x00000009,0x3182FE49,0xF330A7E6)
wxhelper + 0x0001EBE3: (0x63617243,0x00000009,0x3182FE7D,0x1342B880,0xF330A7E6)
wxhelper + 0x00041D37: (0x63617243,0x00000009,0x1342F53C,0x1342F6DC,0xF330A7E6)
wxhelper + 0x00090024: (0x1342F12C,0x3182BD4D,0x1342F6B4,0x1342F6DC,0xF330A7E6)
wxhelper + 0x0000DC5E: (0x1342F70C,0x11F12478,0x1342F66C,0x3182BEC1,0xF330A7E6)
wxhelper + 0x0001528D: (0x11F12478,0x00000009,0x1342F70C,0x1342FAEC,0xF330A7E6)
wxhelper + 0x00094C7A: (0x11F12478,0x00000009,0x1342F70C,0x1342FA44,0xF330A7E6)
wxhelper + 0x0009EAFA: (0x11F12478,0x00000006,0x1342F974,0x00000000,0xF330A7E6)
wxhelper + 0x00094CAA: (0x11F12478,0x00000006,0x1342F974,0x1342FAC8,0xF330A7E6)
wxhelper + 0x000A4DED: (0x11F12478,0x0794D080,0x000000B1,0x00000001,0xF330A7E6)
wxhelper + 0x000A534B: (0x11F12478,0x1342FB74,0xCCCCCCCC,0xCCCCCCCC,0xF330A7E6)
wxhelper + 0x000950E9: (0x1342FAEC,0x000003E8,0x3182B385,0x77DC105F,0xF330A7E6)
wxhelper + 0x000155F2: (0x00004A90,0x74F56340,0x1342FBEC,0x77747B74,0xF330A7E6)
KERNEL32 + 0x00016359: (0x00004A90,0xCF899042,0x00000000,0x00000000,0xF330A7E6)
ntdll + 0x00067B74: (0xFFFFFFFF,0x77768F13,0x00000000,0x00000000,0xF330A7E6)

Regs:
EAX=00000009, EBX=00004A90, ECX=00000002, EDX=00000009
ESI=63617243, EDI=1342B884, EBP=1342B5E4, ESP=1342B5CC, EIP=77BF4437

DWORD_PTRs at CS:EIP:
1789168B 8304C783 E98304C6 8BF17501 03E183C8 068A1374 47460788 8DF77549
pid=0000356C init_tid=00002454 crashtid=0000370C

DWORD_PTRs at teb:
1342A5B4 13430000 13423000 00000000 00001E00 00000000 009BF000 00000000 0000356C 0000370C 00000000 11F01B68 0090B000 00000000 00000000 00000000 00000000
`

@ttttupup
Copy link
Owner

用的是3.9哪个版本的dll

@estinfo
Copy link
Author

estinfo commented Feb 15, 2023

3.9.0.28-V4的代码编译的debug 版本

@ttttupup
Copy link
Owner

看下name这个偏移地址0x2E2CE48,登录后看一下是不是正确的值,错误信息里这个偏移有问题

@ttttupup
Copy link
Owner

看你那个崩溃截图应该是几个数据目录的偏移有问题,把对应的偏移都看一下,先确定哪个偏移有问题。

@estinfo
Copy link
Author

estinfo commented Feb 15, 2023

谢谢,晚点我跟一下。

@estinfo
Copy link
Author

estinfo commented Feb 15, 2023

image

应该是 偏移的问题。

image

谢谢。

@ttttupup
Copy link
Owner

这里的偏移有些地方偷懒了,没仔细分析过,不同账号登录后可能不正确。

@ttttupup
Copy link
Owner

可以定位一下是哪个偏移的问题,个人微信复现不了。

@estinfo
Copy link
Author

estinfo commented Feb 15, 2023

比较奇怪的问题地址是:
真实地址77BF4437 - 基址:57B90000 = 0x2E2CD3C

image

跟了看了一下数据,偏移没有问题。

@ttttupup
Copy link
Owner

你标注的这几个偏移, +0x10是长度,+0x10的数据也正确吗? 下面三个存储目录+0x4是长度,看下也正确吗

@estinfo
Copy link
Author

estinfo commented Feb 15, 2023

找到原因了:
if (*(DWORD *)(base + WX_SELF_ACCOUNT_OFFSET) == 0 || *(DWORD *)(base + WX_SELF_ACCOUNT_OFFSET + 0x10) == 0) { out.account = string(); } else { out.account = string(*(char **)(base + WX_SELF_ACCOUNT_OFFSET), *(DWORD *)(base + WX_SELF_ACCOUNT_OFFSET + 0x10));

@ttttupup
Copy link
Owner

这个自定义账号是不是有特殊字符的存的是unicode的,我的账号看不出来

@hailiangchen
Copy link

我使用的是[3.9.0.28-V6] 登录成功后,使用接口/api/?type=1获取信息异常。

@estinfo
Copy link
Author

estinfo commented Feb 17, 2023

我使用的是[3.9.0.28-V6] 登录成功后,使用接口/api/?type=1获取信息异常。

把错误信息发出来,可以试一下,把account 获取注释掉,用debug 版本测试一下。

再用CE找到相对应的偏移量。

@ttttupup ttttupup added the good first issue Good for newcomers label Feb 18, 2023
@koko01024122
Copy link

@estinfo 您好,请问下该问题您这里解决了吗?如果是的话是如何解决的?谢谢

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

4 participants