建立Outline VPN Server 教學

Hello World
8 min readApr 8, 2021

--

Outline VPN 係建立於一個Shadowsocks的翻牆程式 再由Google 的 Jigsaw 開發出來的開源系統。

台灣的Outline建立教學https://free.com.tw/google-outline/

Outline 的主要目的是簡單建立出自已的VPN,令人人都可以做出自已的VPN 伺服器。

本文會根據免費的Orcale VPS 來起Outline VPN。不點都不複習!

Outline 主頁https://getoutline.org/

先在電腦上下載你作業系統的Outline Manager,這是用來控制你的Outline VPN 的唯一個方法
https://getoutline.org/get-started/#step-1

先選你的作業系統然後download, 然後執行。
開啟Outline Manager 後,到Advnaced Click Setup
把上面的(1)全部command 抄下, 一陣貼上伺服器上。
用SSH 連接到VPS 伺服器

先更新伺服器內的軟件

sudo — sh -c ‘apt-get update; apt-get upgrade -y; apt-get dist-upgrade -y; apt-get autoremove -y; apt-get autoclean -y’

安裝 Docker

sudo curl -sS https://get.docker.com/ | sh
安裝完成的畫面

啟動 Docker

sudo systemctl start docker && sudo systemctl enable docker

驗查 docker是否運作成功

sudo systemctl status docker
見到 active 就是成功

先打上 sudo 再把剛才在outline manager 上的code 貼上,即是

sudo bash -c “$(wget -qO- https://raw.githubusercontent.com/Jigsaw-Code/outline-server/master/src/server_manager/install_scripts/install_server.sh)"

一般情況下用預設的設定會容易比猜到,你可以更改一些設定例如伺服器名稱,port number 等。(只適用於進階用戶使用)

sudo bash -c “$(wget -qO- https://raw.githubusercontent.com/Jigsaw-Code/outline-server/master/src/server_manager/install_scripts/install_server.sh)” install_server.sh — hostname=伺服器名稱 — keys-port=VPN端口 — api-port=控制端口
安裝完成後的畫面
把圖中綠色部分的apiUrl 全部複製
剛複製的貼在outline manager 上(2)的空白位置上
記下Management Port 和 Access Key Port Number

回到SSH 打入防火牆設定command

請根據自己安裝過程修改自己的端口數字

請根據自己安裝過程的端口數字 (小心輸入)
sudo iptables -I INPUT -p tcp -m tcp — dport "Management Port" -j ACCEPT
sudo iptables -I INPUT -p tcp -m tcp — dport "Access Key Port" -j ACCEPT
sudo iptables -I INPUT -p udp -m udp — dport "Access Key Port" -j ACCEPT
sudo netfilter-persistent save
sudo netfilter-persistent reload

回到Oracle VPS 網頁
https://www.oracle.com/tw/cloud/free/

入返自己的VPS, Click 入subnet
Click 入自己的Security Lists
Add Ingress Rules

Source CIDR ->0.0.0.0/0
IP Protocol-> TCP
DESTINATION PORT RANGE 入返頭先的Management Port(唔好入錯)
然後按 "+ Another Ingress Rule"

Source CIDR ->0.0.0.0/0
IP Protocol ->TCP
DESTINATION PORT RANGE 入返頭先的Access Key Port(唔好入錯)
然後按 “+ Another Ingress Rule”

Source CIDR ->0.0.0.0/0
IP Protocol ->UDP
DESTINATION PORT RANGE 入返頭先的Access Key Port(唔好入錯)
然後按 “ADD Ingress Rule

Outline VPN Server Side 設定完成, 咁就可以自己Generate Key 比自己連接!

返回outline manager

新增金鑰
隨便入Key 的名稱
按 Share
按Copy Invitation , 然後發送到你要用的裝置上

在你要用的裝置, 先安裝Outline VPN Apps, 點擊以下的URL 選擇你的裝置下載
https://getoutline.org/get-started/#step-3

下載完後Outline後,打開Invitation

在你要用的裝置只要按下https://s3.amazonaws.com/….的URL在瀏覽器打開
按下 connect this Device
按Copy
打開Outline VPN後,偵察到你剛Copy 條Key後, 佢就會自動貼上!這時候只要按Add Server 就可以了!
這時候按connect
你的VPN 已經成功連線

你可以打開https://www.whatismyip.com/ 查詢自已的IP 位置

你的Outline VPN已經成功設定! 簡單方便!!

後記:Outline VPN係一個可以被開防火牆偵測而設的VPN,因為佢無咗VPN handshake 的特徵並加入混淆數據! Outline VPN也在不定變化中。係2020年時一些國家的防火牆提升了偵察攔截功能,Outline VPN也提升了混淆數據被開偵測。假如需要去一啲網絡被封鎖的地方是比較合適。(除了北韓)

Sign up to discover human stories that deepen your understanding of the world.

Free

Distraction-free reading. No ads.

Organize your knowledge with lists and highlights.

Tell your story. Find your audience.

Membership

Read member-only stories

Support writers you read most

Earn money for your writing

Listen to audio narrations

Read offline with the Medium app

--

--

Hello World
Hello World

No responses yet

Write a response