# 使用 Homebrew, Nix 安装 boringtun

查看 boringtun 的安装路径、可执行文件、元数据以及面向 AI 代理工作流的安全说明。

## 安装

```sh
sudo av install brew:boringtun
```

其他安装命令:

### macOS

- Homebrew (100%):

```sh
brew install boringtun
```

  证据: local Homebrew formula metadata

### Linux

- Nix (92%):

```sh
nix profile install nixpkgs#boringtun
```

  证据: nixpkgs package indexes: pkgs/by-name/bo/boringtun/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1

## 软件包事实

- **软件包键:** brew:boringtun
- **软件包管理器:** Homebrew
- **版本:** 0.7.1
- **来源摘要:** Userspace WireGuard implementation in Rust
- **主页:** <https://github.com/cloudflare/boringtun>
- **仓库:** <https://github.com/cloudflare/boringtun>
- **已生成:** 2026-08-03T19:37:03+00:00

## 可执行文件

- boringtun-cli (别名)

## 安装行为

- Bottle: 不可用

## 版本和新鲜度

- 页面生成时间: 2026-08-03
- 管理器版本: 0.7.1
## 项目历史与用法

BoringTun is Cloudflare's Rust userspace implementation of the WireGuard protocol, distributed as both a library and the boringtun-cli command-line tool.

### 项目历史

Cloudflare announced BoringTun publicly on March 27, 2019 after evaluating existing WireGuard implementations and choosing Rust for a portable, memory-safe, high-performance userspace implementation. The repository itself was created in October 2018, matching the blog's account that the project had been under development before the source release.

The README describes two deliverables: boringtun-cli for Linux and macOS userspace tunnels, and the boringtun library for client applications that supply their own platform-specific tunnel and network stacks.

### 采用历史

BoringTun's adoption story is unusually concrete for a low-level networking library: Cloudflare's README says it is deployed on millions of iOS and Android consumer devices and thousands of Cloudflare Linux servers.

Cloudflare's WARP posts tie BoringTun to the 1.1.1.1/WARP client stack, making it part of a large production VPN deployment rather than only a reference implementation.

### 使用方式

As a CLI, boringtun-cli starts a userspace WireGuard tunnel for an interface and can be used with wg and wg-quick through WG_QUICK_USERSPACE_IMPLEMENTATION. As a library, it exposes the WireGuard protocol machinery for clients that implement their own transport and tunnel integration.

Because it is userspace and permissively licensed, BoringTun is useful where the Linux kernel WireGuard module is unavailable or where client apps need portable WireGuard behavior across mobile and desktop platforms.

### 为什么软件包爱好者会关心

BoringTun matters to package nerds because it is a Rust networking primitive with a real production pedigree, a split library/CLI shape, and a clear relationship to the broader WireGuard ecosystem.

It also illustrates the packaging distinction between protocol implementation, command-line frontend, and OS integration: installing boringtun-cli gives a binary, but useful operation still depends on TUN devices, WireGuard tooling, and platform networking permissions.

### 时间线

- 2018-10: Official GitHub repository metadata shows the repository created.
- 2019-03: Cloudflare announced and open sourced BoringTun.
- 2021: Cloudflare described WARP for Linux using BoringTun as its WireGuard implementation.
- 2022: GitHub release metadata shows v0.4.0 in the public release feed.
- 2026: Repository metadata shows continued activity.

### Related projects

- WireGuard is the VPN protocol BoringTun implements.
- wireguard-go is the userspace implementation Cloudflare compared against when explaining why BoringTun was created.
- Cloudflare WARP is the large-scale client product that uses BoringTun.

### 来源

- <https://api.github.com/repos/cloudflare/boringtun>
- <https://api.github.com/repos/cloudflare/boringtun/releases?per_page=100>
- <https://blog.cloudflare.com/announcing-warp-for-linux-and-proxy-mode/>
- <https://blog.cloudflare.com/boringtun-userspace-wireguard-rust/>
- <https://github.com/cloudflare/boringtun>


## 安全说明

narrow executable package without higher-risk signals.

- **Geiger 风险:** 绿色 / 低
- narrow executable package without higher-risk signals

## 其他软件包管理器记录

- Nix - boringtun: normalized package name match | nixpkgs package indexes: pkgs/by-name/bo/boringtun/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1


## Combined YAML source

View the package source record on GitHub. [combined/boringtun.yml](https://github.com/mxcl/pkgdb/blob/main/combined/boringtun.yml)


## 来源

- pkg.so package database
- Geiger risk classifier
- curated package history
- pkgdb category and tag curation
- external package-manager database matches
- cross-ecosystem install command graph
