GithubHelp home page GithubHelp logo

qqmessageoutput's Introduction

qqmessageoutput

安卓QQ聊天记录导出/安卓QQ数据库解密

update

20240212:给程序加了一个判定语句,防止消息为空时产生bug。

Usage

# 初始化
q = QQoutput(dbfile, key)
# 获得所有好友的个人资料
q.getAllMyFriends()
# 导出聊天记录
q.output(yourfriendqq, mode)

Tips

获取db文件手机最好要root。但是当初经过我不屑的探索,没有root也不是没有办法。

在QQ官方更新了聊天记录备份功能之后,可以先将数据备份到电脑,然后再把数据导入到一个root过的设备(比如模拟器),再提取db文件。

获取db文件的方法请移步我写的文章:安卓QQ聊天记录导出、备份完全攻略

data\data\com.tencent.mobileqq\databases\你的QQ.db

另外我还发现,如果聊天记录过多,会将较早的聊天记录存入以下数据库

data\data\com.tencent.mobileqq\databases\slowtable_你的QQ.db

yourkey是解密的密钥,一般是手机序列号,拨号键盘下输入*#06#

部分新版qq的解密密钥则可能位于以下文件中

data\data\com.tencent.mobileqq\files\kc

手机QQ的db文件加密方式是异或加密,如果找不到自己的key可以反向破解

刚刚发现,QQ竟然支持手机聊天记录备份了!!!

QQmsg

Update

[2019-10-02]新增了QQ群的消息记录导出,mode=1是好友,2是群

[2020-04-22]增加导出所有好友个人资料功能,优化代码(以前写的代码冗余太多,太烂了

[2020-07-01]增加可能的其他解密key,感谢@howyay提供

[2020-07-20]修复昵称中存在emoji的解密问题,感谢@ctem049修复

[2023-06-10]修复聊天记录中存在空消息时解密的问题,感谢@MuyuChen修复

ToDo

  • 自行解密key功能
  • 导出的聊天记录用不同颜色区分是“你”说的,还是“我”说的
  • 导出的聊天记录用QQ-昵称-备注这样的形式,增加辨识度

qqmessageoutput's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

qqmessageoutput's Issues

TIM也可以用

tx另一款聊天软件tim也是同样的加解密方法,解密的密钥放在com.tencent.tim\files\kc里

好友数据导出乱码

现象:
image

复现:
使用手机序列号作key,然后跑代码,打开frienddata就是这样

Thanks for your codes

Hello, Roadwide. Thanks for your codes. I tested your codes. It works on my phone, but does not decrypt on an android pad that has a IMEI. I noticed the QQ app's name is "com.tencent.hd.qq" other than "com.tencent.mobileqq". So I guess the pad's QQ "com.tencent.hd.qq" does not use IMEI as the encryption key. Because some pad may not has a IMEI. Now I can not login the QQ, just pulled the pad's QQ data(rooted). Do you have any idea about the key in this situation? Thanks.

qqnt问题

貌似qqnt修改了存放记录的db文件,请问大佬得到了databases文件夹和kc文件里的key后应该如何导出呢

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.