15

FreeBSD & pfSense 上的 WireGuard 問題

 3 years ago
source link: https://blog.gslin.org/archives/2021/03/29/10092/freebsd-pfsense-%e4%b8%8a%e7%9a%84-wireguard-%e5%95%8f%e9%a1%8c/
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.

FreeBSD & pfSense 上的 WireGuard 問題

FreeBSDpfSense 上的 WireGuard 實做問題前幾天被 Ars 的人整理出來:「Buffer overruns, license violations, and bad code: FreeBSD 13’s close call」,文章有點長度,但整個劇情有種在看八點檔的感覺... 在 Hacker News 上的「Buffer overruns, license violations, and bad code: FreeBSD 13’s close call (arstechnica.com)」與後續的「In-kernel WireGuard is on its way to FreeBSD and the pfSense router (arstechnica.com)」都值得翻翻。

目前 FreeBSD 與 pfSense 都已經把現有的 WireGuard 實做拿掉,主要原因是實做本身的品質很差 (以及安全性問題),而且沒有將 WireGuard 的功能實做完整。

文章裡面有提到兩個組織面上的問題 (還有攻擊個人的部份,這邊就不提了),第一個是 FreeBSD 的 review process,看起來比較像是系統面的問題,目前還是缺乏人力。

另外一個是 Netgate 本身 (pfSense 後面的公司),本來沒有太多背景知識,但這次事件發生後跑去翻了一下資料,發現原來之前就有一些「記錄」了,像是註冊競爭對手的產品 OPNsense 沒有註冊的網域 opnsense.com,然後導去 pfSense 家的事情,最後使得 Deciso (OPNsense 後面的公司) 到 WIPO 上搶回來:「WIPO Domain Name Decision: D2017-1828」。

可以花些時間來看看替代方案...

Related

這次 PIXNET 前後台的一些整理

趁著在家養傷 (腳痛) 寫程式的時候,順便把這陣子 PIXNET 在重新改寫的部份紀錄下來,從底層與 OS 比較有關的、PHP 的,以及 Web UI 的部份。 FreeBSD 的 NFS client 的效能並不好,在這次 PIXNET 前後台大改版前,我這幾天重新跑數據看目前舊系統的架構,可以看出來 PHP code 放到 NFS 上面所吃的 system CPU resource 比 userland CPU resource 還多:(這是其中一台 blog 主機的 CPU usage,用 Munin 畫出來的圖,中間斷掉那段是我在改 Munin 的設定...) 從圖上可以看出這台跑 blog 的主機有 4 Logical CPUs,但卻有很多 idle time。這是因為 NFS 量更大時會不穩定,所以我們無法使用更高。這次改版把所有的 code…

August 14, 2008

In "Blog"

使用 PHP Framework 的效能問題

PHP Framework 裡會大量使用 require_once(),由於需要判斷是否載入過檔案,require_once() 會使用 realpath() 取得檔案實際路徑資訊當作判斷條件,而這點會有效能上的問題。 其他人其實也遇過,參考:PHP Performance tip: require versus require_once,其中 comment 的部份也說明了目前 Google 到的方法是沒有用的。 FreeBSD libc 裡的 realpath(3) 會使用 lstat(2),而 FreeBSD 的 lstat(2) 因為用到 VFS_LOCK_GIANT(9),所以在 FreeBSD 上很多隻 PHP 同時用 realpath() 的時候效能並不好。 在 Linux 的 libc 據說沒這個問題 (我沒有實際去 trace libc code,聽別人轉述的),不過實際灌了一台 Debian 跑 PHP 發現解決了 lstat() 的問題後,require_once() 造成的效能問題還是很嚴重。…

August 29, 2008

In "Computer"

用 pfSense 接 AWS Direct Connect (Public VIF) 的方式

公司在菲律賓的辦公室因為常常會需要連到 AWS 傳輸影音資料 (新加坡,ap-southeast-1),但發現偶而會很不順,傳輸的時候會很卡,所以後來決定租了一條專線用 AWS Direct Connect 接進去。 不過因為跑在 AWS 上面的服務是掛在 public network 上,而不是 private ip 的網段,所以就不能用 IPsec site-to-site 打通收工,而需要搞 BGP routing,然後就卡關卡的亂七八糟 XD 首先是文書作業的部份,因為 AWS 對於 public network peering 需要證明你要交換的 IP address 是你自己的 (或是有被授權),這部份在 web console 上建立完 Public VIF 後會進入審核階段,接下來就要開 support ticket 提供 LOA-CFA 文件後才能繼續設定,我們這邊是從 ISP 申請 AWS Direct Connect…

October 27, 2020

In "AWS"

a611ee8db44c8d03a20edf0bf5a71d80?s=49&d=identicon&r=gAuthor Gea-Suan LinPosted on March 29, 2021March 29, 2021Categories Computer, FreeBSD, Murmuring, Network, OS, Security, Software, VPNTags deciso, freebsd, netgate, opnsense, pfsense, security, vpn, wireguard

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Comment

Name *

Email *

Website

Notify me of follow-up comments by email.

Notify me of new posts by email.

Post navigation


About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK