其他
一个深网灰色直播APP的逆向研究
>>>> 脱壳
脱壳
mkdir t380.jadx
for i in {1..4};do
JAVA_OPTS="-Xmx8G" jadx -j 1 -r -d t380_${i}.jadx unpacked_classes${i}.dex
rsync -a t380_${i}.jadx t380.jadx
done
>>>> 逆向
逆向
$ adb shell dumpsys window windows | grep Focus
mCurrentFocus=Window{be2e8cd u0 com.zhuoyigou.dese/com.zhuoyigou.dese.ui.live.activity.PlayerLiveActivtiy}
mFocusedApp=AppWindowToken{73e5eb8 token=Token{bfded1b ActivityRecord{2d0fb2a u0 com.zhuoyigou.dese/.ui.live.activity.PlayerLiveActivtiy t50}}}
function jopen() {
p=`echo -n $1 | tr . /`
file=$p.java
gvim -R $file
}
jopen com.zhuoyigou.dese.ui.live.activity.PlayBackActivity
private void showTimeOutDialog() {
if (isMainActivityTop(GiftActivity.class)) {
reflashGiftActivity("1", null);
}
if (!isFinishing()) {
this.mLiveTimeOutDialog = new LiveTimeOutDialog(this, 2131493319);
this.mLiveTimeOutDialog.show();
this.mLiveTimeOutDialog.setGold(this.mPlayBackBean.getLiveRoom().getPayMoney());
this.mLiveTimeOutDialog.setTitle("replay");
this.mLiveTimeOutDialog.setCancelable(false);
this.mLiveTimeOutDialog.setBuyOnClick(new 12(this));
this.mLiveTimeOutDialog.setNoBuyOnClick(new 13(this));
}
}
const PlayBackActivity = Java.use("com.zhuoyigou.dese.ui.live.activity.PlayBackActivity");
PlayBackActivity.showTimeOutDialog.implementation = function() {
log("skip showTimeOutDialog()");
}
[+] skip showTimeOutDialog()
[+] skip finish()
[+] java.lang.Exception: printStackTrace here:
at android.app.Activity.finish(Native Method)
at com.zhuoyigou.dese.ui.live.activity.PlayBackActivity$11.handleMessage(PlayBackActivity.java:561)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:148)
at android.app.ActivityThread.main(ActivityThread.java:5539)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)
at de.robv.android.xposed.XposedBridge.main(XposedBridge.java:107)
void handleMessage(Message msg) {
switch(msg.what) {
// ...
case 1002:
this.this$0.mPointProgressBar.setVisibility(8);
PlayBackActivity.access$1400(this.this$0).onPause();
if (PlayBackActivity.access$400(this.this$0)) {
PlayBackActivity.access$1500(this.this$0);
} else {
PlayBackActivity.access$1600(this.this$0);
}
PlayBackActivity.access$600(this.this$0).sendEmptyMessageDelayed(AidConstants.EVENT_NETWORK_ERROR, 11000);
return;
case AidConstants.EVENT_NETWORK_ERROR /*1003*/:
if (PlayBackActivity.access$400(this.this$0) && PlayBackActivity.access$900(this.this$0).isShowing()) {
PlayBackActivity.access$900(this.this$0).dismiss();
}
this.this$0.finish();
return;
// ...
}
}
>>>> 云存储
云存储
private void initPlay(String videoUrl, PlayBackBean playBackBean) {
MyLogger.jLog().e("reVideoUrl:" + videoUrl);
this.mVideoUrl = videoUrl;
if (TextUtils.isEmpty(videoUrl)) {
showError(getString(R.string.video_invalid));
return;
}
if (this.mPLVideoTextureView == null) {
this.mPLVideoTextureView = (PLVideoTextureView) findViewById(2131362384);
}
AVOptions options = new AVOptions();
options.setInteger("timeout", StatusCodes.AUTH_DISABLED);
options.setInteger("fast-open", 1);
options.setInteger("mediacodec", 0);
PLVideoTextureView pLVideoTextureView = this.mPLVideoTextureView;
PLVideoTextureView pLVideoTextureView2 = this.mPLVideoTextureView;
pLVideoTextureView.setDisplayAspectRatio(2);
this.mPLVideoTextureView.setAVOptions(options);
this.mCustomController = new CustomController(this);
this.mPLVideoTextureView.setMediaController(this.mCustomController);
this.mPLVideoTextureView.setVideoPath(videoUrl);
this.mPLVideoTextureView.start();
this.mPLVideoTextureView.setOnInfoListener(new 4(this, playBackBean));
this.mPLVideoTextureView.setOnCompletionListener(new 5(this));
this.mPLVideoTextureView.setOnErrorListener(new 6(this));
}
ttp://qiniuvod.xxxxx.com/recordings/z1.xxxxx.qn1546622961492A/0_1546635114.mp4?sign=b6c6587f1794a14c250e143f28e07620&t=5c303623
ffmpeg -i http://xxx.com/vid.m3u8 -c copy vid.mp4
http://qiniu.example.com/resource.txt?e=1546686297&token=xxx
>>>> MISC
MISC
看雪ID:evilpan
https://bbs.pediy.com/user-844554.htm
推荐文章++++
* APK 协议分析