Skip to content

Instantly share code, notes, and snippets.

View zhaozhao's full-sized avatar

zhaozhao zhaozhao

  • XiDian University
  • XiAn,China
View GitHub Profile
readelf -x .init_array mmpayuserappsvr |sed '1,2d'|sed '/^\s*$/d'|awk '{print $2}{print $3}{print $4}{print $5}'|sed 's/.\{2\}/& /g'|awk '{ for (i=NF; i>1; i--) printf("%s",$i); print $1; }'|xargs addr2line -e mmpayuserappsvr
readelf -x .ctors patchbuild |sed '1,2d'|sed '/^\s*$/d'|awk '{print $2}{print $3}{print $4}{print $5}'|sed 's/.\{2\}/& /g'|awk '{ for (i=NF; i>1; i--) printf("%s",$i); print $1; }'|tac|xargs addr2line -e patchbuild
#!/bin/bash
#
### default variables
tracing=/sys/kernel/debug/tracing
flock=/var/tmp/.ftrace-lock; wroteflock=0
opt_duration=0; duration=; opt_name=0; name=; opt_time=0; opt_reexec=0
opt_argc=0; argc=8; max_argc=16; ftext=
trap ':' INT QUIT TERM PIPE HUP # sends execution to end tracing section
@zhaozhao
zhaozhao / karabiner.py
Last active October 8, 2018 05:06
karabiner launcher
# -*- coding: utf-8 -*-
import json
import os
def dual_keys():
def dual_key(key_code, to, to_if_alone):
description = "{key_code} to {to} if pressed with other keys, to {to_if_alone} if pressed alone".format(
key_code=key_code,
to=to,
to_if_alone=to_if_alone
)