Skip to content

Instantly share code, notes, and snippets.

🏠
Working from home

Recolic recolic

🏠
Working from home
Block or report user

Report or block recolic

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View fuck-wine-mime.sh
#!/bin/bash
# Prevent the fucking wine to add mime file association.
# Implements https://askubuntu.com/questions/323437/how-to-prevent-wine-from-adding-file-associations
set -o xtrace
rm -f ~/.local/share/mime/packages/x-wine*
rm -f ~/.local/share/applications/wine-extension*
rm -f ~/.local/share/icons/hicolor/*/*/application-x-wine-extension*
rm -f ~/.local/share/mime/application/x-wine-extension*
@recolic
recolic / README.md
Last active Sep 2, 2019
适合华科校园卡的MIFARE卡复制教程
View README.md

MIFARE GUIDE FOR HUST

整理了可行的MIFARE卡复制方法/工具。使用ACR122U A9工具。复制卡只含有UID,因此只能进图书馆/宿舍楼,不能消费。

Linux

安装libnfc. sudo pacman -S libnfc。下面的教程在ArchLinux (Linux 5.1.4)测试好用。

如果命令失败了,提示找不到NFC设备之类的话,你可以sudo或者重新插拔一下就好了。

@recolic
recolic / README.md
Last active Nov 3, 2019
android qq 聊天记录导出
View README.md

android qq聊天记录导出大致流程

tested on android 6 tencent qq

  1. 设法将/data/data/com.tencent.*/databases目录拷贝出来,我假设你了解如何做到这一点。

  2. 运行以下命令。我假设你了解如何安装/使用sqlite,我假设你了解linux基本知识。

$ sqlite3 872222222-IndexQQMsg.db
@recolic
recolic / rlib.min.hpp
Created May 14, 2019
C++11 minified rlib. usually used while writing ALG solutions.
View rlib.min.hpp
/*
*
* string.hpp: string process utility.
* Recolic Keghart <root@recolic.net>
* MIT License
*
* Minified version: works on C++11.
*
*/
@recolic
recolic / hackQQ.sh
Created Mar 21, 2019 — forked from kookxiang/hackQQ.sh
一键得到一个精简版的手机QQ(Android)
View hackQQ.sh
#!/system/bin/sh
# 使用方法:
# adb shell "curl -Ssl https://gist.githubusercontent.com/kookxiang/1104e898f270c9a7a0784f70979ec532/raw/hackQQ.sh | su"
# 使用方法 (手动):
# 0.确保你手机 Root 了
# 1.下载这个脚本到某个地方
# 2.下载 Android SDK(需要其中的 adb)
# 3.在命令行运行 adb devices,确保能看到你的手机
@recolic
recolic / fuckboc.user.js
Last active Mar 7, 2019
[tampermonkey] SB中国银行网银购汇不用等30秒看sb购汇申请书。一键安装:https://openuserjs.org/users/recolic/scripts
View fuckboc.user.js
// ==UserScript==
// @name FUCK BankOfChina By USD from CNY 30 seconds wait.
// @namespace https://recolic.net/
// @version 0.1
// @description If you buy other concurrency on www.boc.cn, you have to wait 30 seconds to read a document. I fucked it.
// @author Recolic Keghart <root@recolic.net>
// @match https://ebsnew.boc.cn/boc15/welcome.html*
// @grant none
// ==/UserScript==
@recolic
recolic / py3in2.py
Created Feb 10, 2019
Run python3 in a python2 code.
View py3in2.py
import tempfile, subprocess
def py3in2(func_text, arg):
# escape char in arg should be escaped twice.
payload = ['#/usr/bin/env python3', 'def _func(arg):']
for line in func_text.split('\n'):
payload.append(' ' + line)
payload.append('with open("/dev/fd/1", "w") as f:\n f.write(_func(\''+arg+'\'))\n')
payload = '\n'.join(payload)
@recolic
recolic / forked_udpfwd.cc
Created Dec 14, 2018
naive udp forwarder with naive encryption. copied from an unknown guy. the code style is extremely horrible but it's good enough to fuck GFW.
View forked_udpfwd.cc
#include<stdio.h>
#include<string.h>
#include<sys/socket.h>
#include<arpa/inet.h>
#include<stdlib.h>
#include<getopt.h>
#include <unistd.h>
#include<errno.h>
#include <fcntl.h>
@recolic
recolic / README.md
Created Oct 20, 2018
Download public shared google drive large file with wget. by vladalive
View README.md

I've used @beliys code and made a bash command.

Setup: Add this code to your ~/.bash_aliases file.

function gdrive_download () {
  CONFIRM=$(wget --quiet --save-cookies /tmp/cookies.txt --keep-session-cookies --no-check-certificate "https://docs.google.com/uc?export=download&id=$1" -O- | sed -rn 's/.*confirm=([0-9A-Za-z_]+).*/\1\n/p')
  wget --load-cookies /tmp/cookies.txt "https://docs.google.com/uc?export=download&confirm=$CONFIRM&id=$1" -O $2
  rm -rf /tmp/cookies.txt
}
You can’t perform that action at this time.