Skip to content

Instantly share code, notes, and snippets.

View SimonTheCoder's full-sized avatar

Simon Shi SimonTheCoder

  • Liaoning, China
View GitHub Profile
@SimonTheCoder
SimonTheCoder / radare2_commands.txt
Created January 17, 2019 08:58
radare2 commands
#assemble and output a 32 bit machine code
rasm2 -a arm -b 64 "mrs x1,currentel"|perl -ne 'print "0x$_"'|rax2 =16 -e
@SimonTheCoder
SimonTheCoder / rise_to_ruins.CT
Last active November 30, 2019 15:26
Rise to Ruins Inf. influence/super villagers/heal villagers Trainer
<?xml version="1.0" encoding="utf-8"?>
<CheatTable CheatEngineTableVersion="28">
<Forms>
<mainForm_1 Class="TCEForm" Encoding="Ascii85">jg!%C):Zf/lXP9$wIC*63/)L33$B2cA_aM5*}I7c-Bz@]18$I.oHnM39oY[Tx#0!4.GMYUA$Sv#G/BC!B)8FDV+mf:_2Us[G_lOsv]okDo-iKng[zK@]1E_I2V,[4;bs^vCcZ4a*k[YGN*5eyMLg-3=i!_zBS^$DeLNrnkYs2O6Dp9y6A_EOv[L{:GV1tXGY?#)4hT?G@lHm?C3i^ffC)[GDL[]/82W5;Mjb4s9n8((kjKFcFN9V{czbvRK[!3YxWBa:+VxZ!U#*0:X@Iy4QbxjRHYY@-?#vY$!e*W9+2g@IvRS{+MO%CAp5yr$9cNC*){I!lVCiE[l,AvK:ZMg85Ce6:I%;E6scXkv:^[v#TDk65rF$n=oyz;5[TC#D!cbxvi;1C@49Hpq@kW@,y?*dxgg]6.;ODckv*V6ON9[%ddg9?+$s}Xdo7b/@]7C}[SsY_Xd6@(Oy*r8Im@-yh,Xr[FUNyS[#GRVew4asb6g^}S=kHbWaq#GpCqptcO^+pZomfgn8@bsP^+D9zo(Xoi:0;26jN(S%?D.[aY%fxq4.9D#ZK}O*HHNPJeHq*!0KOM5qwz71]kSu2Upqb#XdF^FeMPgx3WazI2vY;)F{M.X=FEZD]m){6^qErW[?aB@@gbMxvuT*RHyD6d7+H,w4XKE-PUU*5w?)2FTcdhZjB1fb/tf}o;DF}pDyV{kk^dat@ZEk</mainForm_1>
</Forms>
<CheatEntries/>
<UserdefinedSymbols>
<SymbolEntry>
<Name>bla</Name>
<Address>00B10000</Address>
@SimonTheCoder
SimonTheCoder / decode.py
Created November 13, 2019 04:31
deocde some string
#!/usr/bin/env python
target_string = "ZW PFL NREK KF CVRIE DFIV RSFLK TIPGKFXIRGYP Z IVTFDDVBU RE FECZEV TFLIJV ZEJKILTKVU SP GIFWVJJFI URE SFEVY WIFD JKREWFIU LEZMVIJZKP ALJK JVRITY TIPGKFXIRGYP RK TFLIJVIR.FIX"
my_dict = {
"A":"j",
"B":"n",
"C":"l",
"D":"m",
"E":"n",
"F":"o",
"G":"p",
@SimonTheCoder
SimonTheCoder / add_open_wt_here_to_right_click_wt.reg
Last active February 28, 2020 05:10
Add "open windows terminal here" into Right-click menu. REPALCE "<YOUR WINDOW USER NAME>" with your username !
Windows Registry Editor Version 5.00
[HKEY_CLASSES_ROOT\Directory\Background\shell\wt]
@="Open Windows Terminal here"
[HKEY_CLASSES_ROOT\Directory\Background\shell\wt\command]
@="C:\\Users\\<YOUR WINDOW USER NAME>\\AppData\\Local\\Microsoft\\WindowsApps\\wt.exe new-tab -d \"%V\""
Windows Registry Editor Version 5.00
[HKEY_CLASSES_ROOT\Directory\Background\shell\nvim]
@="Open NeoVim Terminal here"
[HKEY_CLASSES_ROOT\Directory\Background\shell\nvim\command]
@="I:\\dev\\tools\\nvim_windows\\nvim-win64\\Neovim\\bin\\nvim-qt.exe term://\"%V\"//cmd"
@SimonTheCoder
SimonTheCoder / init.vim
Last active March 2, 2020 14:57
put to C:\Users\<USERNAME>\AppData\Local\nvim
tnoremap <expr> <C-R> '<C-\><C-N>"'.nr2char(getchar()).'pi'
tnoremap <expr> <C-o> '<C-\><C-N>"'.trim(input('CMD:')).'i'
tnoremap <M-`> <C-\><C-N>
nnoremap <M-`> <ESC>
vnoremap <C-c> "+y
set mouse=a
@SimonTheCoder
SimonTheCoder / mifarecrack.c
Created March 26, 2020 04:53
Find key from proxmark3 sniff data. found here: http://www.proxmark.org/files/Various%20Software/MIFARE%20Classic/mifarecrack/ . Compile : 1 clone https://github.com/nfc-tools/mfcuk; 2 gcc -O3 -o mifarecrack crapto1.c crypto1.c mifarecrack.c
// ported from Test-file: test2.c for crapto1-v2.2
// ver 2: fixed key ordering in output
// ver 3: allow direct cut & paste from sniffer log
#include "crapto1.h"
#include <stdio.h>
#include <string.h>
// Proxmark3 sniffer log
@SimonTheCoder
SimonTheCoder / lets_chroot.sh
Created April 29, 2020 05:27
switch to chroot system
#!/bin/bash
#echo "Remount current udisk to remove 'nodev' option."
#sudo mount -t ext4 -o remount,rw,relatime,uhelper=udisks2 /dev/sda1 `pwd`/..
if [ -e ./chroot_root/dev/tty0 ]
then
echo "Nodes already binded. Skip."
else
echo "mount bind proc dev sys"
@SimonTheCoder
SimonTheCoder / gzip_mod.py
Last active May 28, 2020 02:14
Ignore gzip CRC and length checking.
"""Functions that read and write gzipped files.
The user of the file doesn't have to worry about the compression,
but random access is not allowed."""
# based on Andrew Kuchling's minigzip.py distributed with the zlib module
import struct, sys, time, os
import zlib
import io
@SimonTheCoder
SimonTheCoder / frida_webview.js
Created June 1, 2020 03:00
Using frida to inspect an Android WebView
{
console.log("SIMON TEST Begin!");
console.log("Java.available:" + Java.available);
console.log("SIMON TEST End!");
if(Java.available){
Java.perform(function(){