# 使用 Homebrew, dnf, MacPorts, Nix, apt, pacman, zypper 安装 libyubikey

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

## 安装

```sh
sudo av install brew:libyubikey
```

其他安装命令:

### macOS

- Homebrew (100%):

```sh
brew install libyubikey
```

  证据: local Homebrew formula metadata

- MacPorts (94%):

```sh
sudo port install libyubikey
```

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

### Linux

- dnf (92%):

```sh
sudo dnf install libyubikey
```

  证据: Fedora Rawhide package metadata: libyubikey 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#libyubikey
```

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

- Debian apt (92%):

```sh
sudo apt install libyubikey-dev
```

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

- pacman (92%):

```sh
sudo pacman -S yubico-c
```

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

- zypper (92%):

```sh
sudo zypper install libyubikey-devel
```

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

## 软件包事实

- **软件包键:** brew:libyubikey
- **软件包管理器:** Homebrew
- **版本:** 1.13
- **来源摘要:** C library for manipulating Yubico one-time passwords
- **主页:** <https://yubico.github.io/yubico-c/>
- **已生成:** 2026-08-03T19:37:03+00:00

## 可执行文件

- modhex (别名)
- ykgenerate (别名)
- ykparse (别名)

## 安装行为

- Bottle: 不可用

## 版本和新鲜度

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

libyubikey is the C library inside Yubico yubico-c for low-level YubiKey one-time-password work: modhex conversion, OTP parsing, and OTP generation around the original Yubico authentication model.

### 项目历史

Yubico was founded in Stockholm in 2007 and launched YubiKey 1.0 in 2008 as a driverless one-touch OTP authenticator that identifies as a keyboard. yubico-c followed as the low-level C software development kit for the YubiKey authentication device.

The yubico-c repository describes the command-line tools that expose the library concepts: modhex converts between modhex, hex, and binary forms; ykparse decrypts and parses one OTP with the corresponding AES key; ykgenerate constructs and encrypts one OTP from key and internal token data.

### 采用历史

libyubikey belongs to the pre-FIDO YubiKey software stack, when OTP validation and provisioning were central to deploying hardware authentication. As Yubico and Google moved U2F into the FIDO Alliance in 2013 and browsers and services adopted FIDO U2F from 2014 onward, libyubikey remained relevant for legacy OTP integrations and tooling rather than newer WebAuthn flows.

Yubico announced end-of-life for yubico-c on February 19, 2025, with end-of-life scheduled for February 19, 2026. That makes the package historically important as part of the original YubiKey OTP era, even where newer Yubico libraries cover PIV, FIDO, OATH, or platform-specific use cases.

### 使用方式

Packagers expose libyubikey as a small C library plus tools for modhex and YubiKey OTP token work. It is most useful for test vectors, provisioning scripts, compatibility tooling, and software that needs to parse or generate Yubico OTP values without pulling in higher-level device-management stacks.

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

For package nerds, libyubikey is a tiny security package with a lot of context packed into it: custom alphabets, AES-backed OTP fields, hardware-token history, man pages, Autotools, and a clear line from early two-factor authentication to later FIDO/WebAuthn ecosystems.

### 时间线

- 2007: Yubico was founded in Stockholm and developed a YubiKey 1.0 prototype.
- 2008: YubiKey 1.0 was launched.
- 2010: Yubico added OATH one-time-password support to the YubiKey product line.
- 2013: Yubico and Google contributed U2F technical specifications to the FIDO Alliance.
- 2025-02-19: Yubico announced end-of-life for yubico-c.
- 2026-02-19: Yubico scheduled yubico-c to reach end-of-life.

### Related projects

- yubico-c is the upstream source package for libyubikey. Related Yubico projects include higher-level YubiKey management and protocol libraries, while U2F, FIDO2, and WebAuthn represent the standards track that superseded many OTP-first deployments.

### 来源

- <https://developers.yubico.com/yubico-c/>
- <https://github.com/Yubico/yubico-c>
- <https://www.yubico.com/why-yubico/yubico-innovation-history/>


## 安全说明

library-like package without higher-risk signals.

- **Geiger 风险:** 绿色 / 低
- library-like package without higher-risk signals

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

- Debian apt - libyubikey-dev - 1.13-6: normalized package name match | Debian stable package indexes: libyubikey-dev from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | Yubikey OTP library development files | https://developers.yubico.com/yubico-c/
- Debian apt - libyubikey0 - 1.13-6: normalized package name match | Debian stable package indexes: libyubikey0 from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | Yubikey OTP handling library runtime | https://developers.yubico.com/yubico-c/
- Nix - libyubikey: normalized package name match | nixpkgs package indexes: pkgs/by-name/li/libyubikey/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1
- Ubuntu apt - libyubikey-dev - 1.13-6: normalized package name match | Ubuntu 24.04 LTS package indexes: libyubikey-dev from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | Yubikey OTP library development files | https://developers.yubico.com/yubico-c/
- Ubuntu apt - libyubikey0 - 1.13-6: normalized package name match | Ubuntu 24.04 LTS package indexes: libyubikey0 from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | Yubikey OTP handling library runtime | https://developers.yubico.com/yubico-c/
- dnf - libyubikey - 1.13-28.fc45: normalized package name match | Fedora Rawhide package metadata: libyubikey from https://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/Everything/x86_64/os/repodata/07190dc5ae9f35ae73866675fed6d95fe6e8d9fe22c9d7cdf85862cb2ed24a4c-primary.xml.zst | C library for decrypting and parsing Yubikey One-time passwords | http://opensource.yubico.com/yubico-c
- dnf - libyubikey-devel - 1.13-28.fc45: normalized package name match | Fedora Rawhide package metadata: libyubikey-devel from https://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/Everything/x86_64/os/repodata/07190dc5ae9f35ae73866675fed6d95fe6e8d9fe22c9d7cdf85862cb2ed24a4c-primary.xml.zst | Development files for libyubikey | http://opensource.yubico.com/yubico-c
- pacman - yubico-c - 1.13-8: normalized package name match | Arch Linux sync databases: yubico-c from https://geo.mirror.pkgbuild.com/extra/os/x86_64/extra.db.tar.gz | Yubico YubiKey C library | https://github.com/Yubico/yubico-c
- zypper - libyubikey-devel - 1.13-3.31: normalized package name match | openSUSE Tumbleweed package metadata: libyubikey-devel from https://download.opensuse.org/tumbleweed/repo/oss/repodata/50b07339cb64c8ed4091bdbabddadc1ff5737b090e478818a195b40d8a3292861a879139b4a3987c31109699fde9fbf4a716367ddf4eef77da75f96e3193d6ed-primary.xml.zst | Yubico's USB key low-level C library | https://developers.yubico.com/
- zypper - libyubikey-tools - 1.13-3.31: normalized package name match | openSUSE Tumbleweed package metadata: libyubikey-tools from https://download.opensuse.org/tumbleweed/repo/oss/repodata/50b07339cb64c8ed4091bdbabddadc1ff5737b090e478818a195b40d8a3292861a879139b4a3987c31109699fde9fbf4a716367ddf4eef77da75f96e3193d6ed-primary.xml.zst | Tools to support Yubico's USB key low-level C library | https://developers.yubico.com/
- zypper - libyubikey0 - 1.13-3.31: normalized package name match | openSUSE Tumbleweed package metadata: libyubikey0 from https://download.opensuse.org/tumbleweed/repo/oss/repodata/50b07339cb64c8ed4091bdbabddadc1ff5737b090e478818a195b40d8a3292861a879139b4a3987c31109699fde9fbf4a716367ddf4eef77da75f96e3193d6ed-primary.xml.zst | Yubico's USB key low-level C library | https://developers.yubico.com/
- MacPorts - libyubikey: normalized package name match | MacPorts ports tree: security/libyubikey/Portfile from https://api.github.com/repos/macports/macports-ports/git/trees/master?recursive=1


## Combined YAML source

View the package source record on GitHub. [combined/libyubikey.yml](https://github.com/mxcl/pkgdb/blob/main/combined/libyubikey.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
