# 使用 Homebrew, apk, chocolatey, apt, dnf, MacPorts, Nix, pacman, zypper, scoop, winget 安装 mkcert

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

## 安装

```sh
sudo av install brew:mkcert
```

## 代理安全回答

mkcert creates local certificate authorities and development certificates.

- **凭据访问:** Touches local trust stores and private key material.
- **远程变更:** Primarily mutates local trust state, not remote systems.
- **发布/制品风险:** Can create certificates that influence development service trust.
- **推荐控制:** Gate CA installation and private-key handling.
- **代理使用指南:** Allow certificate inspection; require approval before installing trust roots or writing private keys.

其他安装命令:

### macOS

- Homebrew (100%):

```sh
brew install mkcert
```

  证据: local Homebrew formula metadata

- MacPorts (94%):

```sh
sudo port install mkcert
```

  证据: MacPorts ports tree: security/mkcert/Portfile from https://api.github.com/repos/macports/macports-ports/git/trees/master?recursive=1

### Linux

- apk (92%):

```sh
sudo apk add mkcert
```

  证据: Alpine Linux edge package indexes: mkcert from https://dl-cdn.alpinelinux.org/alpine/edge/testing/x86_64/APKINDEX.tar.gz

- Debian apt (92%):

```sh
sudo apt install mkcert
```

  证据: Debian stable package indexes: mkcert from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz

- dnf (92%):

```sh
sudo dnf install mkcert
```

  证据: Fedora Rawhide package metadata: mkcert from https://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/Everything/x86_64/os/repodata/07190dc5ae9f35ae73866675fed6d95fe6e8d9fe22c9d7cdf85862cb2ed24a4c-primary.xml.zst

- Nix (92%):

```sh
nix profile install nixpkgs#mkcert
```

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

- pacman (92%):

```sh
sudo pacman -S mkcert
```

  证据: Arch Linux sync databases: mkcert from https://geo.mirror.pkgbuild.com/extra/os/x86_64/extra.db.tar.gz

- zypper (92%):

```sh
sudo zypper install mkcert
```

  证据: openSUSE Tumbleweed package metadata: mkcert from https://download.opensuse.org/tumbleweed/repo/oss/repodata/50b07339cb64c8ed4091bdbabddadc1ff5737b090e478818a195b40d8a3292861a879139b4a3987c31109699fde9fbf4a716367ddf4eef77da75f96e3193d6ed-primary.xml.zst

### Windows

- Chocolatey (92%):

```sh
choco install mkcert
```

  证据: Chocolatey community package catalog: mkcert from http://community.chocolatey.org/api/v2/Packages?$filter=IsLatestVersion&$select=Id&$top=1000&$skiptoken='11','microsoft-windows-terminal'

- Scoop (92%):

```sh
scoop install extras/mkcert
```

  证据: Scoop official bucket manifest trees: bucket/mkcert.json from https://api.github.com/repos/ScoopInstaller/Extras/git/trees/master?recursive=1

- winget (92%):

```sh
winget install --id FiloSottile.mkcert -e
```

  证据: Windows Package Manager source index: FiloSottile.mkcert from https://cdn.winget.microsoft.com/cache/source.msix

## 软件包事实

- **软件包键:** brew:mkcert
- **软件包管理器:** Homebrew
- **版本:** 1.4.4
- **来源摘要:** Simple tool to make locally trusted development certificates
- **主页:** <https://github.com/FiloSottile/mkcert>
- **仓库:** <https://github.com/FiloSottile/mkcert>
- **最后更新:** 2026-07-29T17:04:55+02:00
- **已生成:** 2026-08-03T19:37:03+00:00

## 可执行文件

- mkcert (别名)

## 安装行为

- Bottle: 不可用

## 版本和新鲜度

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

mkcert is Filippo Valsorda's small Go tool for locally trusted development certificates. It appeared in the 2018 developer conversation around localhost HTTPS and was explained by Valsorda in a January 2019 post: deployment certificates had become easier through ACME and Let's Encrypt, but development still fell back to HTTP because localhost and private development names cannot use ordinary public CA validation.

### 项目历史

The tool's core idea is deliberately narrow. Instead of asking each developer to memorize OpenSSL invocations or manage browser trust stores by hand, mkcert creates a local certificate authority, installs it into the system and Firefox/NSS trust stores where supported, and issues certificates for local hostnames, IP addresses, and wildcards. The upstream README also warns that the generated root CA private key can intercept secure requests from the machine, which is why mkcert is framed as a local development tool rather than production CA infrastructure.

### 使用方式

mkcert became a common package-manager utility because it solves a recurring web-development pain point with one command and no project-specific configuration. Homebrew, MacPorts, Linux packages, and prebuilt binaries cover the usual developer platforms, while the README leaves web-server configuration to the user after the certificate and key are generated.

### 来源

- <https://formulae.brew.sh/formula/mkcert>
- <https://github.com/FiloSottile/mkcert>
- <https://news.ycombinator.com/item?id=17748208>
- <https://words.filippo.io/mkcert-valid-https-certificates-for-localhost/>


## 安全说明

narrow executable package without higher-risk signals.

- **Geiger 风险:** 绿色 / 低
- narrow executable package without higher-risk signals
- **审批门规则:** 4


## Configuration and credential file locations

These source-backed paths show where this package keeps local settings or durable credentials. Automic Vault can use them as review targets for secret scanning, migration, and command approval.


## Credential files

- macOS: ~/Library/Application Support/mkcert/rootCA-key.pem
## 其他软件包管理器记录

- Debian apt - mkcert - 1.4.4-1+b18: normalized package name match | Debian stable package indexes: mkcert from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | Simple zero-config tool to make locally trusted certificates | https://github.com/FiloSottile/mkcert
- Nix - mkcert: normalized package name match | nixpkgs package indexes: pkgs/by-name/mk/mkcert/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1
- Ubuntu apt - mkcert - 1.4.4-1ubuntu2: normalized package name match | Ubuntu 24.04 LTS package indexes: mkcert from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | Simple zero-config tool to make locally trusted certificates | https://github.com/FiloSottile/mkcert
- apk - mkcert - 1.4.4-r30: normalized package name match | Alpine Linux edge package indexes: mkcert from https://dl-cdn.alpinelinux.org/alpine/edge/testing/x86_64/APKINDEX.tar.gz | simple zero-config tool to make locally trusted development certificates with any names you'd like | https://mkcert.dev/
- dnf - mkcert - 1.4.4-10.fc45: normalized package name match | Fedora Rawhide package metadata: mkcert from https://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/Everything/x86_64/os/repodata/07190dc5ae9f35ae73866675fed6d95fe6e8d9fe22c9d7cdf85862cb2ed24a4c-primary.xml.zst | Make and install locally trusted development certificates | https://github.com/FiloSottile/mkcert
- pacman - mkcert - 1.4.4-3: normalized package name match | Arch Linux sync databases: mkcert from https://geo.mirror.pkgbuild.com/extra/os/x86_64/extra.db.tar.gz | Simple tool for making locally-trusted development certificates | https://github.com/FiloSottile/mkcert
- zypper - mkcert - 1.4.4-1.7: normalized package name match | openSUSE Tumbleweed package metadata: mkcert from https://download.opensuse.org/tumbleweed/repo/oss/repodata/50b07339cb64c8ed4091bdbabddadc1ff5737b090e478818a195b40d8a3292861a879139b4a3987c31109699fde9fbf4a716367ddf4eef77da75f96e3193d6ed-primary.xml.zst | CLI tool for making locally-trusted development certificates | https://github.com/FiloSottile/mkcert
- MacPorts - mkcert: normalized package name match | MacPorts ports tree: security/mkcert/Portfile from https://api.github.com/repos/macports/macports-ports/git/trees/master?recursive=1
- Chocolatey - mkcert: normalized package name match | Chocolatey community package catalog: mkcert from http://community.chocolatey.org/api/v2/Packages?$filter=IsLatestVersion&$select=Id&$top=1000&$skiptoken='11','microsoft-windows-terminal'
- Scoop - extras/mkcert: normalized package name match | Scoop official bucket manifest trees: bucket/mkcert.json from https://api.github.com/repos/ScoopInstaller/Extras/git/trees/master?recursive=1
- winget - FiloSottile.mkcert: normalized package name match | Windows Package Manager source index: FiloSottile.mkcert from https://cdn.winget.microsoft.com/cache/source.msix


## Combined YAML source

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


## 来源

- pkg.so package database
- Geiger risk classifier
- approval-gate seed metadata
- curated configuration and credential file locations
- curated package history
- pkgdb category and tag curation
- external package-manager database matches
- cross-ecosystem install command graph
- curated agent safety answer
