$ mksdcard [SDCARD_SIZE]M [SDCARD_NAME]
create emulator
$ android create avd --target [TARGET_VER] --name [TARGET_NAME] --sdcard [SDCARD_NAME]
list emulator
$ android list avd
start emulator
$ emulator -avd [TARGET_NAME] -sdcard /path/to/sdcard
install apk via Internet
$ adb export ADBHOST=[MY_ANDROID_IP]
$ /path/to/sdk/tools/adb kill-server
$ adb install [MY_APP.apk]
tcpdump
$ adb shell tcpdump -i any -p -s 0 -w /sdcard/capture.pcap
"-i any": listen on any network interface
"-p": disable promiscuous mode (doesn't work anyway)
"-s 0": capture the entire packet
"-w": write packets to a file (rather than printing to stdout)
沒有留言:
張貼留言