This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
# coding=utf-8 | |
import sys | |
import re | |
bdinfo = {} | |
images = [] | |
def init(): |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.stephen.demo; | |
import android.Manifest; | |
import android.annotation.TargetApi; | |
import android.app.KeyguardManager; | |
import android.content.Context; | |
import android.content.pm.PackageManager; | |
import android.hardware.fingerprint.FingerprintManager; | |
import android.os.Build; | |
import android.os.CancellationSignal; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
private static boolean isWindows() { | |
return System.getProperties().getProperty("os.name").contains("Windows"); | |
} | |
public static String exec(String command, long timeout) { | |
Process ps; | |
try { | |
if(isWindows()) { | |
ps = Runtime.getRuntime().exec("cmd.exe /C " + command); | |
} else { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
# -*- coding: utf-8 -*- | |
import os | |
import hashlib | |
import sys | |
import math | |
import json | |
import urllib2 | |
import urllib |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# my customized aliases | |
alias yyupdate="sudo apt-get update && sudo apt-get dist-upgrade -y" | |
# alipay build bundle | |
alias kcart='python build_bundle.py /data/workspace/alipay/android_phone_biosecurity/kcart -DproguardSkip=true' | |
alias bl='python build.py -Dskipcheck=true -DproguardSkip=true -Dandroid.dex.guard=false' | |
notes=/data/Dropbox/stackedit/work/`date +%Y`/`date +%b` | |
note=$notes/`date +%d`.md |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
#-*- coding:utf-8 -*- | |
import socket | |
import fcntl | |
import struct | |
import json | |
import httplib, urllib | |
params = dict( |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0"?> | |
<root> | |
<item> | |
<name>F19 to F19</name> | |
<appendix>(F19 to Hyper (ctrl+shift+cmd+opt) + F19 Only, send escape)</appendix> | |
<identifier>private.f192f19_escape</identifier> | |
<autogen> | |
--KeyOverlaidModifier-- | |
KeyCode::F19, | |
KeyCode::COMMAND_L, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Json::value val; | |
val = val["1"]; | |
if (val.isNull() || !val.isObject()) { | |
return false; | |
} | |
val = val["2"]; | |
if (val.isNull() || !val.isObject()) { | |
return false; | |
} | |
val = val["3"]; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#define _CRT_SECURE_NO_WARNINGS | |
#define _SCL_SECURE_NO_WARNINGS | |
#include <websocketpp/config/asio_no_tls.hpp> | |
#include <websocketpp/server.hpp> | |
#include <boost/shared_array.hpp> | |
#include <iostream> | |
typedef websocketpp::server<websocketpp::config::asio> server; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* This utility generates a self-signed X.509 certificate with an embedded | |
* DNSSEC chain. | |
* | |
* Usage: ./gencert <PEM private key> <DNSSEC chain file> > cert.pem | |
*/ | |
#include <stdio.h> | |
#include <openssl/asn1.h> | |
#include <openssl/bio.h> |
NewerOlder