V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
推荐学习书目
Learn Python the Hard Way
Python Sites
PyPI - Python Package Index
http://diveintopython.org/toc/index.html
Pocoo
值得关注的项目
PyPy
Celery
Jinja2
Read the Docs
gevent
pyenv
virtualenv
Stackless Python
Beautiful Soup
结巴中文分词
Green Unicorn
Sentry
Shovel
Pyflakes
pytest
Python 编程
pep8 Checker
Styles
PEP 8
Google Python Style Guide
Code Style from The Hitchhiker's Guide
uzfg57666
V2EX  ›  Python

企业微信外部群 PC 版 hook 源码 api 接口 sdk

  •  1
     
  •   uzfg57666 · 2022-10-24 16:10:26 +08:00 · 1698 次点击
    这是一个创建于 549 天前的主题,其中的信息可能已经有所发展或是发生改变。

    通过 hookPC 企微内存调用函数,实现各种方便的功能,支持各种开发语言调用,现已实现的功能: 发各种消息, 接收各种消息,外部群内部群管理,手机号加好友,名片加好友,标签管理,开放平台 openid 和用户 id 互相转换打通官方人员管理 等等功能,无限更新中…

    部分 c++代码示例:

    //读取内存数据

    void readWechatData() { //拿到模块基址 DWORD wechatWin = getWechatWinAdd();

    //装数据的容器
    CHAR wxid[0x100] = {0};
    sprintf_s(wxid, "%s", wechatWin + 0x1131BEC);
    WetDigItemText(hwndDlg, WXID, wxid);
    
    //微信账号
    CHAR username[0x100] = { 0 };
    sprintf_s(username, "%s", wechatWin + 0x111B90);
    WetDigItemText(hwndDlg, USERNAME, username);
    //企微头像
    CHAR headPic[0x100] = { 0 };
    DWORD pPic = wechatWin + 0x1131F2c;
    printf_s(headPic, "%s", wechatWin + 0x1131F2C);
    

    }

    //写内存 WOID writeData(HWND handDlg) { //拿到模块基址 DWORD wechatWin = getWechatWinAdd(); DQORD wxid = wechatWin + 0x1131BEC; //拿到要修改的字符串 char wxid Text[0x100] = { 0 }; GetDlgItemText(handDlg, WXID, wxidText, sizeof(wxidText)); //修改内存 WriteProcessMemory(GetCurrentProcess(), (LPVOID)wxid, wxidText, sizeof(wxidText), NULL); }

    void SaveImg(DWORD qrcode) { //获取图片长度 DWORD dwPicLen = qrcode + 0x4; size_t cpyLen = (size_t)((LPVOID)dwPicLen); //拷贝图片的数据 char PicData[0xFFF] = { 0 }; memcpy(PicData, ((LPVOID)qrcode), cpyLen);

    char szTempPath[MAX_PATH] = { 0 };
    char szPicturePath[MAX_PATH] = { 0 };
    GetTempPathA(MAX_PATH, szTempPath);
    
    sprintf_s(szPicturePath, "%s%s", szTempPath, "qrcode.png");
    //将文件写到 Temp 目录下
    HANDLE hFile = CreateFileA(szPicturePath, GENERIC_ALL, 0, NULL, CREATE_ALWAYS, FILE_ATTRIBUTE_NORMAL, NULL);
    if (hFile == NULL)
    {
    	MessageBoxA(NULL, "创建图片文件失败", "错误", 0);
    	return;
    }
    
    DWORD dwRead = 0;
    if (WriteFile(hFile, PicData, cpyLen, &dwRead, NULL) == 0)
    {
    	MessageBoxA(NULL, "写入图片文件失败", "错误", 0);
    	return;
    }
    CloseHandle(hFile);
    
    //完成之后卸载 HOOK
    UnHookQrCode(QrCodeOffset);
    

    }

    欢迎技术交流:

    HWND Qq[]=“2645542961”; wchar_t tempbuff[0x1030];

    1 条回复    2022-10-25 10:20:16 +08:00
    Ashore
        1
    Ashore  
       2022-10-25 10:20:16 +08:00
    会不会有法律风险?
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   我们的愿景   ·   实用小工具   ·   2781 人在线   最高记录 6543   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 26ms · UTC 15:40 · PVG 23:40 · LAX 08:40 · JFK 11:40
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.