Skip to content

Nuface Blog

隨意隨手記 Casual Notes

Menu
  • Home
  • About
  • Services
  • Blog
  • Contact
  • Privacy Policy
  • Login
Menu

Category: Cybersecurity

About Cybersecurity

Fixing “no matching host key type found” When SSH from Ubuntu 24.04 to CentOS 6

Posted on 2025-11-192025-11-19 by Rico

When trying to SSH from Ubuntu 24.04 to a legacy CentOS 6 server, you may encounter the following error: This happens because: In short:👉 The new Ubuntu SSH client refuses the old CentOS 6 SSH server’s key algorithms. This article summarizes several practical and safe ways to connect. ✅ Method 1: Temporarily enable ssh-rsa (recommended)…

Read more

Ubuntu 24.04 SSH 到 CentOS 6 出現「no matching host key type found」的解決方法

Posted on 2025-11-192025-11-19 by Rico

在 Ubuntu 24.04 終端機使用 SSH 連線到 CentOS 6 時,你可能會遇到以下錯誤訊息: 這個問題主要是因為: 換句話說:👉「新」的 Ubuntu 24.04 不願意用「舊」的 CentOS 6 的金鑰方式。 本文將整理幾種實務上可用、又兼顧安全的連線方法。 ✅ 方法一:一次性允許 ssh-rsa(推薦) 若 CentOS 6 支援 ssh-rsa,可用下列指令強制接受: ✔️ 不修改系統設定✔️ 單次使用比較安全 ✅ 方法二:CentOS 6 只支援 ssh-dss (DSA) 時 若出現錯誤仍無法連上,可能對方只支援 ssh-dss: ⚠️ ssh-dss 已極度不安全,不推薦,只在必要時臨時使用。 ✅ 方法三:在 ~/.ssh/config 中永久加入例外 若需要常常連線此台 CentOS 6,可針對單一 host 放寬設定: 新增: 之後使用: ✔️ 只針對特定主機生效✔️ 不影響整體安全性…

Read more

Fixing Fail2Ban Postfix Filter Errors on CentOS 7

Posted on 2025-11-062025-11-06 by Rico

1. Background When managing mail servers, Fail2Ban is used to block malicious IPs and brute-force attempts.On CentOS 7 (Fail2Ban v0.11.2 / Python 2.7), running: triggered the following error: 2. Root Cause Fail2Ban filters often reference shared variables like: These are defined in /etc/fail2ban/filter.d/common.conf.However, on older versions (e.g., CentOS 7’s 0.11.x), the IPv4/IPv6 variables are missing,causing…

Read more

在 CentOS 7 修正 Fail2Ban Postfix 過濾器錯誤並建立有效防護

Posted on 2025-11-062025-11-06 by Rico

一、問題背景 在管理郵件伺服器時,Fail2Ban 常用於封鎖惡意連線或暴力破解行為。Rico 在 CentOS 7(Fail2Ban v0.11.2 / Python 2.7)環境下執行以下指令測試 Postfix 過濾器: 卻出現錯誤訊息: 二、問題原因 Fail2Ban 的過濾器(filter)會引用一些共用變數,如: 這些變數定義在 /etc/fail2ban/filter.d/common.conf。但在某些舊版(如 0.11.x for CentOS 7)中,__prefix_ipv4 和 __prefix_ipv6 並未被定義,導致過濾器解析失敗。 三、修正方法 ✅ 方法一:改用 <HOST>(推薦) Fail2Ban 內建 <HOST> 巨集,自動辨識 IPv4 與 IPv6。修改 /etc/fail2ban/filter.d/postfix-pipelining.conf: 測試: 若輸出顯示: 即代表成功命中。 ✅ 方法二:手動補上變數(若不想改 regex) 在 filter 開頭自行定義: 四、延伸:建立 Postfix 過濾器防護 建立 jail 設定 /etc/fail2ban/jail.d/postfix-pipelining.local: 重新載入: 五、進階:擴充另一個過濾器…

Read more

Building a Secure OpenVPN Server on OPNsense — Step-by-Step Practical Guide

Posted on 2025-11-062025-11-11 by Rico

Author: Rico WuEnvironment: OPNsense 25.xUse case: Remote work, branch office connectivity, employee VPN 1️⃣ Why OPNsense + OpenVPN? OpenVPN is an open-source, SSL-based VPN protocol that’s secure, cross-platform, and reliable.OPNsense provides a built-in GUI for managing OpenVPN — allowing administrators to quickly deploy: This makes OPNsense a strong, cost-free VPN gateway for modern hybrid work….

Read more

在 OPNsense 上建立與設定 OpenVPN:完整實務指南

Posted on 2025-11-062025-11-20 by Rico

作者: Rico Wu環境: OPNsense 25.x應用場景: 遠端辦公、跨地分公司連線、行動員工 VPN 一、為什麼選擇 OPNsense + OpenVPN? OpenVPN 是一款開源、安全且穩定的 VPN 解決方案,而 OPNsense 內建完整的 OpenVPN 管理介面,可快速建立: 與傳統 VPN 相比,OpenVPN 使用 TLS/SSL 驗證機制,可確保連線安全並支援跨平台(Windows / macOS / Linux / iOS / Android)。 二、建立 OpenVPN 伺服器(Server) 🔹 步驟 1:建立憑證授權中心(CA) 1️⃣ 前往 System → Trust → Authorities → +Add2️⃣ 設定如下: → 儲存 ✅ 🔹 步驟 2:建立伺服器憑證…

Read more

Deep Packet Power: Enabling Layer-7 Traffic Control on OPNsense

Posted on 2025-11-062025-11-06 by Rico

Author: Rico WuEnvironment: OPNsense 25.x + Zenarmor + SuricataUse case: Enterprise internet access control & application-layer filtering 🧱 1. What Is Layer-7 Control? Traditional firewalls operate mainly at Layer-3 and Layer-4 — controlling traffic based on IP addresses, ports, and protocols.While effective for basic routing and NAT, they can’t tell what the traffic actually is….

Read more

深度封包的力量:在 OPNsense 啟用 Layer 7(L7)應用層流量控制

Posted on 2025-11-062025-11-06 by Rico

作者: Rico Wu環境: OPNsense 25.x + Zenarmor + Suricata應用場景: 企業上網行為管理與應用層封包管控 🧱 一、什麼是 L7 流量控制? 一般防火牆主要運作在 L3(網路層)與 L4(傳輸層),也就是依據 IP、Port、通訊協定 來允許或阻擋流量。這樣能處理連線方向與基本安全,但無法辨識「應用內容」。 L7(Layer 7,應用層)防火牆 能深入檢視封包內容(DPI, Deep Packet Inspection),可根據實際應用類型進行控制,例如: 在企業網路環境中,L7 控制能大幅提升 安全性、效率與使用行為可視化。 ⚙️ 二、OPNsense 如何支援 L7? OPNsense 是基於 FreeBSD + pf 架構的防火牆,其中 pf 防火牆本身僅支援 L3/L4 控制。 但 OPNsense 可透過 插件與整合模組 實現 L7(應用層)控制,常用的三種方式如下: 模組 功能用途 L7 支援程度 備註 Zenarmor (原名…

Read more

Wazuh: The Core Concept and Working Principles of an Open-Source MDR Platform

Posted on 2025-11-042025-11-04 by Rico

In today’s rapidly evolving cybersecurity landscape, organizations face challenges that go far beyond preventing traditional malware infections. The real question has become how to detect threats early, respond quickly, and maintain continuous monitoring. Traditional antivirus and firewalls stop known threats, but they often miss subtle or unknown attacks happening inside the environment.This is where MDR…

Read more

Wazuh:開源 MDR 平台的核心概念與運作原理

Posted on 2025-11-042025-11-04 by Rico

在資安威脅不斷演變的今天,企業面臨的挑戰不再只是防止病毒入侵,而是如何即時偵測、快速反應、持續監控。傳統防毒與防火牆只能擋住「已知威脅」,但無法即時發現內部異常行為或未知攻擊。這時,MDR(Managed Detection and Response) 的概念便應運而生。 而在眾多 MDR 解決方案中,Wazuh 以開源、靈活與整合能力強等特點,成為許多企業自建 SOC(Security Operation Center)時的首選。 一、什麼是 Wazuh? Wazuh 是一套開源的 安全監控與威脅回應平台,同時具備: 換句話說,Wazuh 能幫助企業從「事後分析」轉變為「主動偵測與即時回應」。 二、整體架構概覽 Wazuh 採用 分散式架構,主要由三個核心元件組成: 整個架構可擴充至多台 Manager、分層式部署,適合跨國或多據點企業使用。 三、運作原理:從資料收集到自動回應 1️⃣ 資料收集(Data Collection) 每台主機上安裝的 Wazuh Agent 會定期蒐集各種安全相關事件,例如: 這些資料會加密傳送到 Wazuh Manager 進行集中分析。 2️⃣ 規則比對與威脅分析(Detection & Correlation) Manager 接收到事件後,會利用內建與自訂的規則集(ruleset)進行分析: 這個階段的分析可搭配: 3️⃣ 威脅關聯與分級(Correlation & Prioritization) Wazuh 會根據事件嚴重度(level 0–15)進行分級。例如: 透過事件關聯分析,能有效降低誤報率,提升告警的精確度。 4️⃣ 自動化回應(Response &…

Read more

Posts pagination

  • Previous
  • 1
  • 2

Recent Posts

  • Postfix + Let’s Encrypt + BIND9 + DANE Fully Automated TLSA Update Guide
  • Postfix + Let’s Encrypt + BIND9 + DANE TLSA 指紋自動更新完整教學
  • Deploying DANE in Postfix
  • 如何在 Postfix 中部署 DANE
  • DANE: DNSSEC-Based TLS Protection

Recent Comments

  1. Building a Complete Enterprise-Grade Mail System (Overview) - Nuface Blog on High Availability Architecture, Failover, GeoDNS, Monitoring, and Email Abuse Automation (SOAR)
  2. Building a Complete Enterprise-Grade Mail System (Overview) - Nuface Blog on MariaDB + PostfixAdmin: The Core of Virtual Domain & Mailbox Management
  3. Building a Complete Enterprise-Grade Mail System (Overview) - Nuface Blog on Daily Operations, Monitoring, and Performance Tuning for an Enterprise Mail System
  4. Building a Complete Enterprise-Grade Mail System (Overview) - Nuface Blog on Final Chapter: Complete Troubleshooting Guide & Frequently Asked Questions (FAQ)
  5. Building a Complete Enterprise-Grade Mail System (Overview) - Nuface Blog on Network Architecture, DNS Configuration, TLS Design, and Postfix/Dovecot SNI Explained

Archives

  • December 2025
  • November 2025
  • October 2025

Categories

  • AI
  • Apache
  • Cybersecurity
  • Database
  • DNS
  • Docker
  • Fail2Ban
  • FileSystem
  • Firewall
  • Linux
  • LLM
  • Mail
  • N8N
  • OpenLdap
  • OPNsense
  • PHP
  • QoS
  • Samba
  • Switch
  • Virtualization
  • VPN
  • WordPress
© 2025 Nuface Blog | Powered by Superbs Personal Blog theme