Skip to content

Instantly share code, notes, and snippets.

View nevermoe's full-sized avatar

nevermoe

View GitHub Profile
@nevermoe
nevermoe / vimrc
Last active November 9, 2023 03:21
set nocompatible " 关闭 vi 兼容模式
syntax on " 自动语法高亮
colorscheme desert " 设定配色方案
set number " 显示行号
" set cursorline " 突出显示当前行
set ruler " 打开状态栏标尺
set shiftwidth=2 " 设定 << 和 >> 命令移动时的宽度为 2
set softtabstop=2 " 使得按退格键时可以一次删掉 2 个空格
set tabstop=2 " 设定 tab 长度为 2
set expandtab
#
# OpenSSL example configuration file.
# This is mostly being used for generation of certificate requests.
#
# This definition stops the following lines choking if HOME isn't
# defined.
HOME = .
RANDFILE = $ENV::HOME/.rnd
import gdb
import traceback
class StopAtRead(gdb.Command):
def __init__(self):
super(StopAtRead, self).__init__('stop_at_read', gdb.COMMAND_NONE)
def invoke(self, target_fd, from_tty):
gdb.execute('set pagination off')
gdb.execute('handle all nostop pass noprint')
define xxd
dump binary memory dump.bin $arg0 ((void*)$arg0)+$arg1
shell xxd dump.bin
shell rm dump.bin
end
source ~/Documents/git_codes/gdb_utilities/gdb_utilities.py
#!/usr/bin/python
## echo "command script import ~/Documents/git_codes/lldb_utilities/lldb_utilities.py" >> ~/.lldbinit
import lldb
import commands
import optparse
import shlex
### a script
from idaapi import *
idaapi.step_over()
GetDebuggerEvent(WFNE_SUSP, -1)
rv = idaapi.regval_t()
idaapi.get_reg_val('EIP',rv)
ea = rv.ival
print "0x%x" % ea
import idautils
import idaapi
import idc
LIGHT_BLUE = 0xFFFF00
GREEN = 0x00FF00
WHITE = 0xFFFFFF
for funcea in idautils.Functions():
xor_in_func = 0
@nevermoe
nevermoe / install_busybox.sh
Last active October 16, 2018 09:53 — forked from alsanchez/install_busybox.sh
Install busybox on the x86 Android emulator
#!/bin/bash
wget "https://busybox.net/downloads/binaries/1.26.2-i686/busybox" -O /tmp/busybox
adb push /tmp/busybox /data/data/busybox
adb shell "mount -o remount,rw /system && mv /data/data/busybox /system/bin/busybox && chmod 755 /system/bin/busybox && /system/bin/busybox --install /system/bin"
dump_seg = "debug001"
dump_file = "C:\dump_mem"
seg_start = 0
seg_end = 0
seg_length = 0
seg = idc.FirstSeg()
while seg != idc.BADADDR:
segName = idc.SegName(seg)
if segName == dump_seg:
@nevermoe
nevermoe / floatsign.sh
Last active June 29, 2018 12:10 — forked from Weptun/floatsign.sh
Now fix when no entitlements are present.
# !/bin/bash
# Copyright (c) 2011 Float Mobile Learning
# http://www.floatlearning.com/
# Extension Copyright (c) 2013 Weptun Gmbh
# http://www.weptun.de
#
# Extended by Ronan O Ciosoig January 2012
#
# Extended by Patrick Blitz, April 2013