Skip to content

Instantly share code, notes, and snippets.

View tienthanh2509's full-sized avatar

Phạm Tiến Thành tienthanh2509

View GitHub Profile
#!/bin/bash
# Make sure run this script with root privileges
cd /tmp
export DEBIAN_FRONTEND=noninteractive
export LANG=en_US.UTF-8
export TERM xterm
echo -e "\e[44mKiểm tra cập nhật kho...\e[0m"
apt-get update
apt-get install -y nano zip unzip curl wget
@tienthanh2509
tienthanh2509 / _ide_helper.php
Created August 21, 2016 06:31 — forked from barryvdh/_ide_helper.php
Laravel IDE Helper for Netbeans / PhpStorm / Sublime Text 2 CodeIntel, generated using https://github.com/barryvdh/laravel-ide-helper
<?php
/**
* A helper file for Laravel 5, to provide autocomplete information to your IDE
* Generated for Laravel 5.1.40 (LTS) on 2016-07-18.
*
* @author Barry vd. Heuvel <barryvdh@gmail.com>
* @see https://github.com/barryvdh/laravel-ide-helper
*/
namespace {
@tienthanh2509
tienthanh2509 / local_manifest.xml
Last active February 15, 2017 13:28
LineageOS CM14.1 local_manifest.xml
<?xml version="1.0" encoding="UTF-8"?>
<manifest>
<!-- Xóa các kho luu trữ không cần đến -->
<remove-project name="device/generic/arm64" />
<remove-project name="device/generic/mini-emulator-arm64" />
<remove-project name="device/generic/mini-emulator-armv7-a-neon" />
<remove-project name="device/generic/mini-emulator-x86" />
<remove-project name="device/generic/mini-emulator-x86_64" />
<remove-project name="device/generic/qemu" />
<remove-project name="device/generic/x86" />
@tienthanh2509
tienthanh2509 / gapps-config.txt
Created January 27, 2017 03:45
Open GApps for Oneplus X
# ATTENTION! This script is specific for OnePlus X's OxygenOS.
# You are using this script on your own risk!
# Requires Open GApps stock package or higher! Download it from here: http://opengapps.org/?arch=arm&api=6.0&variant=stock or http://opengapps.org/?arch=arm&api=7.1&variant=stock
# Read more about gapps-config file here: https://github.com/opengapps/opengapps/wiki/Advanced-Features-and-Options
# Last edit: Fri Jan 27 10:29:59 DST 2017
# Force DPI Setting
forcedpi480
# Force Clean Install Setting
forceclean
@tienthanh2509
tienthanh2509 / local_manifest.xml
Created February 23, 2017 16:45
OOS local_manifest.xml
<?xml version="1.0" encoding="UTF-8"?>
<manifest>
<remove-project name="platform/prebuilts/android-emulator" />
<remove-project name="platform/prebuilts/clang/darwin-x86/host/3.6" />
<remove-project name="device/generic/arm64" />
<remove-project name="device/generic/mini-emulator-arm64" />
<remove-project name="device/generic/mini-emulator-armv7-a-neon" />
<remove-project name="device/generic/mini-emulator-mips" />
<remove-project name="device/generic/mini-emulator-x86" />
<remove-project name="device/generic/mini-emulator-x86_64" />
@tienthanh2509
tienthanh2509 / nimbus.sh
Last active March 28, 2017 13:15
Nimbus install script
#!/bin/bash
# Author: Phạm Tiến Thành
# Copyright (c) 2017 PT Studio, All rights reserved.
# Zero to Cloud Guide
# http://www.nimbusproject.org/docs/current/admin/z2c/service-dependencies.html
sudo sed -i 's/http:\/\/archive.ubuntu.com/http:\/\/opensource.xtdv.net/g' /etc/apt/sources.list
sudo sed -i 's/http:\/\/vn.archive.ubuntu.com/http:\/\/opensource.xtdv.net/g' /etc/apt/sources.list
sudo apt update
sudo apt install -y git nano curl wget unzip zip aria2
@tienthanh2509
tienthanh2509 / hack.sh
Created April 8, 2017 03:11
Hack WPA2 password
#/bin/bash
# Author: Phạm Tiến Thành (@tienthanh2509)
# Usage: ./hack.sh <command>
# mon: Prepare wifi monitor mode
# capture: Capture wifi packets
# crack: Crack wifi password from capture packets and try to parse password from password list
# Thông tin wifi cần hack
AP_MAC="64:D9:54:BC:C5:9E"
@tienthanh2509
tienthanh2509 / virtualbox-iteee.sh
Last active April 9, 2017 09:57
Ubuntu VirtualBox Service for virtual machine
#!/bin/sh
# kFreeBSD do not accept scripts as interpreters, using #!/bin/sh and sourcing.
if [ true != "$INIT_D_SCRIPT_SOURCED" ] ; then
set "$0" "$@"; INIT_D_SCRIPT_SOURCED=true . /lib/init/init-d-script
fi
### BEGIN INIT INFO
# Provides: VirtualBox Run Machine
# Required-Start: $remote_fs $syslog
# Required-Stop: $remote_fs $syslog
# Default-Start: 2 3 4 5
@tienthanh2509
tienthanh2509 / local_manifest.xml
Created April 25, 2017 14:02
LineageOS CM13 for Onyplus X with sultanxda mod
<?xml version="1.0" encoding="UTF-8"?>
<manifest>
<!-- local_manifest.xml for CM13 with sultanxda mod -->
<!--Patcher (run "./patcher/patcher.sh" before each compilation)-->
<!--Use Bacon's patcher script-->
<project path="patcher" name="sultanxda/patcher" revision="stable/cm-13.0-bacon" />
<!--Repositories to replace-->
<remove-project name="LineageOS/android_hardware_qcom_audio" />
<remove-project name="LineageOS/android_hardware_qcom_camera" />
@tienthanh2509
tienthanh2509 / openwrt-image-builder.sh
Last active December 30, 2017 14:02
OpenWrt Image Builder for TP-Link TLWR941
docker run -d -it --name openwrt -w /opt/openwrt -v /opt/openwrt:/opt/openwrt tienthanh2509/ubuntu
apt-get install -y subversion build-essential libncurses5-dev zlib1g-dev gawk git ccache gettext libssl-dev xsltproc wget
wget https://downloads.openwrt.org/snapshots/trunk/ar71xx/generic/OpenWrt-ImageBuilder-ar71xx-generic.Linux-x86_64.tar.bz2
tar -jxvf OpenWrt-ImageBuilder-ar71xx-generic.Linux-x86_64.tar.bz2
cd OpenWrt-ImageBuilder-ar71xx-generic.Linux-x86_64
make image PROFILE=TLWR941 PACKAGES="luci -ppp -ppp-mod-pppoe -ip6tables -odhcp6c -kmod-ipv6 -kmod-ip6tables -luci-proto-ipv6 -luci-proto-ppp" -j7
make image PROFILE=TLWR741 PACKAGES="luci hostapd -wpad-mini -ppp -ppp-mod-pppoe -ip6tables -odhcp6c -kmod-ipv6 -kmod-ip6tables -luci-proto-ipv6 -luci-proto-ppp" -j7