• Java 知识点

     · Grape

    可变参数

    变长参数是 Java 的一个语法糖,本质上还是基于数组的实现:

    void Foo(String... args);
    void Foo(String[] args);
    
    // Method signature
    ([Ljava/lang/String;)V // public void foo(String[] args)
    

    注意事 …

  • Github Usage

     · 1 min read  · Grape

    如何修改第一条的作者信息

    git commit --amend --author="developer <[email protected]>" --no-edit
    

    如何修改第一条注释信息

    git commit --amend
    

    子模块

    递归更新子模块:

    git submodule add <remote url …
  • 7z 解压文件名乱码

     · Grape

    问题描述

    在Windows 7中文版系统上使用7z压缩一些文件后,然后在Windows 10 Pro英文版系统上解压,发现凡是文件名中包含中文,最后都是乱码。

    原因

    使用7z压缩文件时,对文件名的编码是采用Windows 系统默 …

  • hacking android app with frida

     · Grape

    环境安装

    • frida-server
    • frida-tools
    pip3 install frida
    pip3 install frida-tools
    

    基础用法

    frida-ps -U
    frida-trace -U -i "recvfrom" com.android.chrome
    

    Javascript example 1

    Java.enumerateLoadedClasses(
      {
      "onMatch": function(className){ 
            console.log(className) 
        },
      "onComplete":function(){}
      }
    )
    

    Javascript example 2:chrome.js

    Java.perform(function () {
        var Activity = Java.use …
  • Android traceview 原理分析

     · 3 min read  · Grape

    使用方法

    目标进程需要打开调试开关,android:debuggable=true

    adb shell am profile start com.tencent.mm /data/local/tmp/1.trace
    adb shell am profile stop com.tencent.mm
    adb pull /data/local/tmp/1.trace
    ~/adt-2014/sdk/tools …
  1. 1
  2. 2
  3. 3
  4. 4