Permalink
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
475 lines (320 sloc) 13.2 KB

my-pc-env

The develop environment of my pc 😄

1.Windows

1.Editor && Terminal

Editor

VS code: https://code.visualstudio.com

Here is my VS code!

THINKPAD-X250_Skye_20170903_223009

Terminal

cmder

2. Programming Languages

C

Compile C/Cpp files inside WSL.

Python

The environment of Python on Windows is complex, I use Python2 and Python3 at the same time. So, I download the packages from python.org, and install them in different directory. Then I mv d:/python3/python.exe d:/python3/python3.exe, Just like this:

THINKPAD-X250_Skye_20170903_222719

Then, add it into your System Path:

PATH

Demo:

C:\Users\liu1l
$ python
Python 2.7.13 (v2.7.13:a06454b1afa1, Dec 17 2016, 20:53:40) [MSC v.1500 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>>
^C
C:\Users\liu1l
$ python3
Python 3.5.2 (v3.5.2:4def2a2901a5, Jun 25 2016, 22:18:55) [MSC v.1900 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>>
Python Packages

Some python packages may not available on Windows, such as numpy or pycrypto. We can find most of them in this site: http://www.lfd.uci.edu/~gohlke/pythonlibs/. And, you can install the pycrypto package using the binary wheels: https://github.com/sfbahr/PyCrypto-Wheels.

Golang

Simply download the installer and install it on your pc.

https://golang.org/

Java

  1. install JDK

  2. install JRE(REMEBER install them in different path)

  3. setting the path like this:

    path1

    path2

3.Tools & Software

Software

Typora

Upload my own csshttps://github.com/liu1l/my-pc-env/own.css. Also, you should install the Noto Sans SC and Monaco fonts in your pc.

Vmware Workstation Pro

KEY: GG3JH-8DG8K-489TZ-9QMEE-XYRFF

VMWare 14: GA18K-DRXE3-488TZ-J4ZNX-PZAXA https://download3.vmware.com/software/wkst/file/VMware-workstation-full-14.0.0-6661328.exe

Shadowsocks

You Know it.

https://github.com/shadowsocks/shadowsocks-windows/

Chrome
Xshell
7z
Git
Proxifier
Typora
Slack & Bearychat & Wechat & TIM

Slack: xdsec-slack

Bearychat: xdsec-bearychat

TIM: office.qq.com

Wechat: https://wx.qq.com/

MISC

These software can be download in their official websites. And the JEB(Cracked) \ Stegsolve can be found in here. And you can get the 吾爱破解工具包2.0 here:链接: https://pan.baidu.com/s/1kVssd19 密码: rek2.

Wireshark

If you can't find any interface in wireshark, close it and run it as administer permission.

ARCHPR

LICENSE KEY: ARCHPRP-GSVMT-66892-GKVMB-52992 orARCHPRP-KSNYZ-65395-WFZFG-56252

JEB
Stegsolve

Binary

IDA Pro

Download the 7.0 edition here: https://down.52pojie.cn/Tools/Disassemblers/IDA_Pro_v6.8_and_Hex-Rays_Decompiler_(ARM,x64,x86)_Green.rar

WinDbg

Download the preview edition in Windows Store.

WEB

BurpSuite_pro

The crack edition.

4.Desktop beautify

Wallpapers

Unsplash.com

Fonts

  • Monaco
  • Noto Sans SC
  • Operator
  • Iosevka

5.Browers

I choose Chrome. And here is some backup of some config files.

Stylish

6.Others

Picture bed

https://sm.ms

And here is a upload python script.

2.Linux

Ubuntu & Kali

Source list of Ubuntu

  1. XDU sourcelist:
#deb http://archive.ubuntu.com/ubuntu/ xenial main restricted universe multiverse
#deb http://archive.ubuntu.com/ubuntu/ xenial-updates main restricted universe multiverse
#deb http://security.ubuntu.com/ubuntu/ xenial-security main restricted universe multiverse
#deb http://mirrors.xdlinux.info/ubuntu/ trusty main restricted universe multiverse
#deb http://mirrors.xdlinux.info/ubuntu/ trusty-security main restricted universe multiverse
#deb http://mirrors.xdlinux.info/ubuntu/ trusty-updates main restricted universe multiverse
# deb http://mirrors.xdlinux.info/ubuntu/ trusty-proposed main restricted universe multiverse
#deb http://mirrors.xdlinux.info/ubuntu/ trusty-backports main restricted universe multiverse
#deb-src http://mirrors.xdlinux.info/ubuntu/ trusty main restricted universe multiverse
#deb-src http://mirrors.xdlinux.info/ubuntu/ trusty-security main restricted universe multiverse
#deb-src http://mirrors.xdlinux.info/ubuntu/ trusty-updates main restricted universe multiverse
# deb-src http://mirrors.xdlinux.info/ubuntu/ trusty-proposed main restricted universe multiverse
#deb-src http://mirrors.xdlinux.info/ubuntu/ trusty-backports main restricted universe multiverse
deb http://mirrors.xdlinux.info/ubuntu/ xenial main restricted universe multiverse
deb http://mirrors.xdlinux.info/ubuntu/ xenial-security main restricted universe multiverse
deb http://mirrors.xdlinux.info/ubuntu/ xenial-updates main restricted universe multiverse
deb http://mirrors.xdlinux.info/ubuntu/ xenial-proposed main restricted universe multiverse
deb http://mirrors.xdlinux.info/ubuntu/ xenial-backports main restricted universe multiverse
deb-src http://mirrors.xdlinux.info/ubuntu/ xenial main restricted universe multiverse
deb-src http://mirrors.xdlinux.info/ubuntu/ xenial-security main restricted universe multiverse
deb-src http://mirrors.xdlinux.info/ubuntu/ xenial-updates main restricted universe multiverse
deb-src http://mirrors.xdlinux.info/ubuntu/ xenial-proposed main restricted universe multiverse
deb-src http://mirrors.xdlinux.info/ubuntu/ xenial-backports main restricted universe multiverse
  1. For other areas, use:

    # deb cdrom:[Ubuntu 16.04 LTS _Xenial Xerus_ - Release amd64 (20160420.1)]/ xenial main restricted
    deb-src http://archive.ubuntu.com/ubuntu xenial main restricted #Added by software-properties
    deb http://mirrors.aliyun.com/ubuntu/ xenial main restricted
    deb-src http://mirrors.aliyun.com/ubuntu/ xenial main restricted multiverse universe #Added by software-properties
    deb http://mirrors.aliyun.com/ubuntu/ xenial-updates main restricted
    deb-src http://mirrors.aliyun.com/ubuntu/ xenial-updates main restricted multiverse universe #Added by software-properties
    deb http://mirrors.aliyun.com/ubuntu/ xenial universe
    deb http://mirrors.aliyun.com/ubuntu/ xenial-updates universe
    deb http://mirrors.aliyun.com/ubuntu/ xenial multiverse
    deb http://mirrors.aliyun.com/ubuntu/ xenial-updates multiverse
    deb http://mirrors.aliyun.com/ubuntu/ xenial-backports main restricted universe multiverse
    deb-src http://mirrors.aliyun.com/ubuntu/ xenial-backports main restricted universe multiverse #Added by software-properties
    deb http://archive.canonical.com/ubuntu xenial partner
    deb-src http://archive.canonical.com/ubuntu xenial partner
    deb http://mirrors.aliyun.com/ubuntu/ xenial-security main restricted
    deb-src http://mirrors.aliyun.com/ubuntu/ xenial-security main restricted multiverse universe #Added by software-properties
    deb http://mirrors.aliyun.com/ubuntu/ xenial-security universe
    deb http://mirrors.aliyun.com/ubuntu/ xenial-security multiverse

oh-my-git

See this link: https://github.com/arialdomartini/oh-my-git

oh-my-zsh

Before install oh-my-zsh, you should install git & zsh. Simply type in sudo apt update && sudo apt upgrade && sudo apt install zsh git.Then install oh-my-zsh use the command line above:

sh -c "$(curl -fsSL https://raw.githubusercontent.com/robbyrussell/oh-my-zsh/master/tools/install.sh)"

Fish-shell

Install
sudo apt install fish
Package-manage

Use Fisherman.

  • Install:

      curl -Lo ~/.config/fish/functions/fisher.fish --create-dirs git.io/fisherman

Radare2

  git clone https://github.com/radare/radare2.git 
  cd sys/
  ./install.sh

Install Z3

apt install virtualenv
mkdir z3_env
cd z3_env
git clone https://github.com/Z3Prover/z3
virtualenv venv
source venv/bin/activate
cd z3
python scripts/mk_make.py --python
cd build
make 
make install

Check if Z3 is avaliable:

(venv) ➜ python -c 'import z3; print(z3.get_version_string())'
4.6.1

Install pwn environment

There is a install script written by @b1gtang. See https://github.com/skyel1u/my-pc-env/blob/master/src/install_pwn_env.sh.

Some pwntools errors:

If there is any mistake such as MemoryError, you can run sudo pip --no-cache-dir install pwntools.

Install llvm-obfuscator

$ git clone -b llvm-4.0 https://github.com/obfuscator-llvm/obfuscator.git
$ mkdir build
$ cd build
$ cmake -G "Unix Makefiles" -DCMAKE_BUILD_TYPE=Release -DLLVM_INCLUDE_TESTS=OFF ../obfuscator
$ make 

It takes a long time to build clang and llvm-obfuscator. When the compilation is finished, you can find the binaries in build/bin.

To use llvm-obfuscator:

 ~ ./obs/build/bin/clang work_tmp/example.c -o test -mllvm -fla # use control flow flatting

Pypi Source

  1. cd ~

  2. mkdir .pip

  3. vim pip.conf

  4. Copy this into the pip.conf file:

    [global]
    index-url=http://mirrors.aliyun.com/pypi/simple/
    
    [install]
    trusted-host=mirrors.aliyun.com
    

Shadowsocks

  • Install Shadowsocks-go:
wget --no-check-certificate -O shadowsocks-go.sh https://raw.githubusercontent.com/teddysun/shadowsocks_install/master/shadowsocks-go.sh
chmod +x shadowsocks-go.sh
./shadowsocks-go.sh 2>&1 | tee shadowsocks-go.log
  • Update the Kernel, use BBR
wget --no-check-certificate https://github.com/teddysun/across/raw/master/bbr.sh
chmod +x bbr.sh
./bbr.sh

The config file located in this path:/etc/shadowsocks/config.json. If you run this command:lsmod | grep bbr, and you can see this:

~ lsmod | grep bbr
tcp_bbr                20480  43

Congratulations, bbr works!

L2TP/IPSec

  • Check the VPS whether support the TUN module:

    shadowsocks cat /dev/net/tun
    cat: /dev/net/tun: File descriptor in bad state
  • Check the VPS whether support the PPP module:

    shadowsocks cat /dev/ppp
    cat: /dev/ppp: No such device or address

If you see the return and the same as above, then that everything is normal. And go next:

~ wget --no-check-certificate https://raw.githubusercontent.com/teddysun/across/master/l2tp.sh
~ chmod +x l2tp.sh
~ ./l2tp.sh

If there is anything caused an error, please see the /root/l2tp.logto check.

l2tp -a (Add a user)
l2tp -d (Delete a user)
l2tp -l (List all users)
l2tp -m (Modify a user password)

Open-cv

First, you should install the dependent package:

$ sudo apt-get install build-essential
$ sudo apt-get install cmake git libgtk2.0-dev pkg-config libavcodec-dev libavformat-dev libswscale-dev
$ sudo apt-get install python-dev python-numpy libtbb2 libtbb-dev libjpeg-dev libpng-dev libtiff-dev libjasper-dev libdc1394-22-dev 
$ sudo apt-get install libavcodec-dev libavformat-dev libswscale-dev libv4l-dev liblapacke-dev
$ sudo apt-get install libatlas-base-dev gfortran 
$ sudo apt-get install ffmpeg

Download the open-cv source code and install it:

$ wget https://github.com/opencv/opencv/archive/3.3.0.zip
$ unzip 3.3.0.zip
$ cd opencv-3.3.0
$ mkdir build
$ cd build
$ cmake ../ -DWITH_GTK_2_X=ON -DCMAKE_INSTALL_PREFIX=/usr/local
$ make -j4
$ sudo make install

3.Windows Subsystem Linux

Install zsh

  • Run this sudo apt-get install zsh
  • Open your bash profile nano ~/.bashrc
  • Add this to set it to use ZSH as default:
if [ -t 1 ]; then
exec zsh
fi

Get your terminal looking pretty pt.2

  • Install oh-my-zsh with

    sh -c "$(curl -fsSL https://raw.githubusercontent.com/robbyrussell/oh-my-zsh/master/tools/install.sh)"
    • Read docs here on how to add more plugins and change themes (I went with their out of the box 'robbyrussell').

Fix the ls and cd colours

  • Out of the box when you ls or cd + Tab you get some nasty background colours on the directories. To fix this, crack open your ~/.zshrc file and add this to the end:
#Change ls colours
LS_COLORS="ow=01;36;40" && export LS_COLORS

#make cd use the ls colours
zstyle ':completion:*' list-colors "${(@s.:.)LS_COLORS}"
autoload -Uz compinit
compinit

Fix zsh premissons

  1. Filst:
% cd /usr/local/share/zsh
% sudo chmod -R 755 ./site-functions
% sudo chown -R root:root ./site-functions
  1. Then:
cd /home/${usr}/.oh-my-zsh/custom/
sudo chmod -R 755 ./plugins