or
or
By clicking below, you agree to our terms of service.
New to HackMD? Sign up
Syntax | Example | Reference | |
---|---|---|---|
# Header | Header | 基本排版 | |
- Unordered List |
|
||
1. Ordered List |
|
||
- [ ] Todo List |
|
||
> Blockquote | Blockquote |
||
**Bold font** | Bold font | ||
*Italics font* | Italics font | ||
~~Strikethrough~~ | |||
19^th^ | 19th | ||
H~2~O | H2O | ||
++Inserted text++ | Inserted text | ||
==Marked text== | Marked text | ||
[link text](https:// "title") | Link | ||
 | Image | ||
`Code` | Code |
在筆記中貼入程式碼 | |
```javascript var i = 0; ``` |
|
||
:smile: | ![]() |
Emoji list | |
{%youtube youtube_id %} | Externals | ||
$L^aT_eX$ | LaTeX | ||
:::info This is a alert area. ::: |
This is a alert area. |
On a scale of 0-10, how likely is it that you would recommend HackMD to your friends, family or business associates?
Please give us some advice and help us improve HackMD.
Do you want to remove this version name and description?
Syncing
xxxxxxxxxx
架設tpot 手記
安裝T-pot可依據個人需求進行,一種是分散式,一種是單機版。
下列方式為分散式安裝步驟:
下載輕量化的debian安裝檔。
1.1 安裝步驟依個人喜好進行安裝。(網路上一堆debian安裝步驟,請自行google一下囉)
Download Debian Netinstall Image > amd64版本 http://ftp.debian.org/debian/dists/bullseye/main/installer-amd64/current/images/netboot/mini.iso
安裝完debian後,下達下列指令,進行t-pot安裝。
git clone https://github.com/telekom-security/tpotce
cd tpotce/iso/installer/
./install.sh –type=user
2.1 若安裝完後,發現git指令未安裝,請執行sudo apt install git-all
開始進行t-pot安裝,因為我們要架設分散式架構,要先準備兩台主機;並請先其中一台選擇安裝HIVE角色。 (HIVE角色主要安裝Elastic stack and T-Pot tools)

https://github.com/telekom-security/tpotce#distributed-deployment
安裝另一台debian & 安裝HIVE-Sensor角色。(HIVE-sensor角色主要是各式hoenypot角色)
兩台主機安裝完後,可於兩台主機執行dps.sh來確認服務是啟動沒問題。

將安裝之帳號(ex. james), 加入sudo群組。(非常重要!!)
sudo adduser james(account) sudo
於HIVE(tpot02)主機(此例192.168.254.110),輸入

su -
deploy.sh
輸入指令後,將依據步驟進行設定。但IP要指向HIVE主機(此例 192.168.254.120)。
待sensor與HIVE主機建立連線後,系統畫面會要求reboot重開,重開後就完成設定。
Sensor重開過程中,可以登入至HIVE,輸入

cat /etc/group >> 看到tpotlogs & tpot02(電腦名稱)建立。
cat /etc/passwd >> 看到tpot02 帳號被建立,且無法透過shell登入。

若想測試sensor是否真的有傳送資料至HIVE,參考官方文件說明

找尋測試honeypot(此例- CitrixHoneypot)
依據citrixhoneypot登入頁面測試- 測試不斷輸入帳密…並按下[Log on]…

過一段時間,開啟T-pot dashboard,選擇[CitrixHoneypot]。

開啟Citrixhoneypot deshboard後,畫面拉到下方可以看到Source IP (此例:192.168.254.118),經比對確認是模擬的攻擊主機。

YES, 架設T-POT 分散式(HIVE & HIVE sensor)架構完成。
提醒,若真要應用於正式環境,須謹慎評估及確認T-pot的安全設定與擺放的位置與預期目標。
下列方式是安裝T-Pot standalone方式 (這部份實作&測試是OK的,但資源要很兇..記憶體10G以上才順):
1. 選擇STANDARD (standalone)安裝
1.1 設定固定IP
1.1.1 如何找VM實體網卡名稱-參照https://github.com/telekom-security/tpotce/issues/325
1.2 安裝完後若遇到[Raise network interfaces]錯誤訊息,請參照https://ithelp.ithome.com.tw/articles/10296777進行設定。
1.3 安裝完tpot後,kibana 頁面無法正常顯示(error message- 502)
1.3.1 目前發現可能很大原因是需要讓docker下載與建立完成,可嘗試讓他擺放並運作一段時間,看是否kibana服務會自動起來並運作穩定。
https://github.com/telekom-security/tpotce/issues/205
2 預設保存於kibana的log是放置30天。
2.1.1 若需要修改保存更久時間,請先修改logrotate.conf檔,路徑如下:/opt/tpot/etc/logrotate/logrotate.conf.
2.1.2 若要清除Log資料,請執行clean.sh
3 故障排除:
3.1 檢查您的容器是否正常運行:dps.sh
3.2 查看你的系統資源是否耗盡:htop,glances