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

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

## 安装

```sh
sudo av install brew:libsecret
```

其他安装命令:

### macOS

- Homebrew (100%):

```sh
brew install libsecret
```

  证据: local Homebrew formula metadata

- MacPorts (94%):

```sh
sudo port install libsecret
```

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

### Linux

- apk (92%):

```sh
sudo apk add libsecret
```

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

- dnf (92%):

```sh
sudo dnf install libsecret
```

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

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

- pacman (92%):

```sh
sudo pacman -S libsecret
```

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

- Debian apt (92%):

```sh
sudo apt install gir1.2-secret-1
```

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

- zypper (92%):

```sh
sudo zypper install libsecret-1-0
```

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

## 软件包事实

- **软件包键:** brew:libsecret
- **软件包管理器:** Homebrew
- **版本:** 0.21.7
- **来源摘要:** Library for storing/retrieving passwords and other secrets
- **主页:** <https://wiki.gnome.org/Projects/Libsecret>
- **已生成:** 2026-08-03T19:37:03+00:00

## 可执行文件

- secret-tool (别名)

## 安装行为

- Bottle: 不可用

## 版本和新鲜度

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

libsecret is GNOME's GObject-based client library for the freedesktop.org Secret Service D-Bus API. It is the package behind many Linux desktop applications that need to store passwords, tokens, and other secrets without binding directly to a particular keyring implementation.

### 项目历史

The freedesktop.org Secret Service specification was authored by GNOME Keyring and KWallet developers and describes collections, items, sessions, prompts, and D-Bus interfaces for desktop secret storage. libsecret implements the client side of that model for GNOME-style C, GObject Introspection, JavaScript, Python, and Vala users.

The GNOME API documentation identifies libsecret as a Secret Service D-Bus client library authored by Stef Walter, Daiki Ueno, and Niels De Graef. GitLab tag history shows the project publishing 0.1 in March 2012 and reaching the 0.20 and 0.21 series in the 2020s.

### 采用历史

libsecret's adoption is tied to the move from application-specific password files toward desktop keyring services reachable over D-Bus. It gives GNOME applications, command-line helpers such as secret-tool, and language bindings a shared library interface over the Secret Service API.

### 使用方式

Applications define schemas and attributes, then store, look up, and delete secrets through the Secret Service. The official usage documentation shows pkg-config integration for C, imports through GObject Introspection for JavaScript and Python, and Vala package usage.

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

libsecret is a small but sensitive dependency: it bridges package-managed applications to session keyrings without each package carrying its own password-storage backend. It is also a common build dependency for tools that only need secret storage on desktop Linux.

### 时间线

- 2008-2011: The Secret Service API copyright period covers the specification authorship window.
- 2012: libsecret 0.1 was tagged in March.
- 2020: libsecret 0.20.0 was tagged in January.
- 2023: libsecret 0.21.0 was tagged in August.
- 2025: libsecret 0.21.7 was tagged in March.

### Related projects

- Related projects include GNOME Keyring, KWallet, D-Bus, GObject Introspection, freedesktop.org Secret Service, and secret-tool.

### 来源

- <https://gitlab.gnome.org/GNOME/libsecret>
- <https://gnome.pages.gitlab.gnome.org/libsecret>
- <https://gnome.pages.gitlab.gnome.org/libsecret/libsecret-using.html>
- <https://specifications.freedesktop.org/secret-service-spec/latest/>


## 安全说明

library-like package without higher-risk signals.

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

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

- Debian apt - gir1.2-secret-1 - 0.21.7-1: normalized package name match | Debian stable package indexes: gir1.2-secret-1 from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | Secret store (GObject-Introspection) | https://wiki.gnome.org/Projects/Libsecret
- Debian apt - libsecret-1-0 - 0.21.7-1: normalized package name match | Debian stable package indexes: libsecret-1-0 from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | Secret store | https://wiki.gnome.org/Projects/Libsecret
- Debian apt - libsecret-1-dev - 0.21.7-1: normalized package name match | Debian stable package indexes: libsecret-1-dev from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | Secret store (development files) | https://wiki.gnome.org/Projects/Libsecret
- Debian apt - libsecret-common - 0.21.7-1: normalized package name match | Debian stable package indexes: libsecret-common from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | Secret store (common files) | https://wiki.gnome.org/Projects/Libsecret
- Debian apt - libsecret-tools - 0.21.7-1: normalized package name match | Debian stable package indexes: libsecret-tools from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | tool for storing and retrieving GObject passwords | https://wiki.gnome.org/Projects/Libsecret
- Nix - libsecret: normalized package name match | nixpkgs package indexes: pkgs/by-name/li/libsecret/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1
- Ubuntu apt - gir1.2-secret-1 - 0.21.4-1build3: normalized package name match | Ubuntu 24.04 LTS package indexes: gir1.2-secret-1 from https://archive.ubuntu.com/ubuntu/dists/noble/main/binary-amd64/Packages.gz | Secret store (GObject-Introspection) | https://wiki.gnome.org/Projects/Libsecret
- Ubuntu apt - libsecret-1-0 - 0.21.4-1build3: normalized package name match | Ubuntu 24.04 LTS package indexes: libsecret-1-0 from https://archive.ubuntu.com/ubuntu/dists/noble/main/binary-amd64/Packages.gz | Secret store | https://wiki.gnome.org/Projects/Libsecret
- Ubuntu apt - libsecret-1-dev - 0.21.4-1build3: normalized package name match | Ubuntu 24.04 LTS package indexes: libsecret-1-dev from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | Secret store (development files) | https://wiki.gnome.org/Projects/Libsecret
- Ubuntu apt - libsecret-common - 0.21.4-1build3: normalized package name match | Ubuntu 24.04 LTS package indexes: libsecret-common from https://archive.ubuntu.com/ubuntu/dists/noble/main/binary-amd64/Packages.gz | Secret store (common files) | https://wiki.gnome.org/Projects/Libsecret
- Ubuntu apt - libsecret-tools - 0.21.4-1build3: normalized package name match | Ubuntu 24.04 LTS package indexes: libsecret-tools from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | tool for storing and retrieving GObject passwords | https://wiki.gnome.org/Projects/Libsecret
- apk - libsecret - 0.21.7-r0: normalized package name match | Alpine Linux edge package indexes: libsecret from https://dl-cdn.alpinelinux.org/alpine/edge/main/x86_64/APKINDEX.tar.gz | Library for storing and retrieving passwords and other secrets | https://gnome.pages.gitlab.gnome.org/libsecret
- apk - libsecret-dev - 0.21.7-r0: normalized package name match | Alpine Linux edge package indexes: libsecret-dev from https://dl-cdn.alpinelinux.org/alpine/edge/main/x86_64/APKINDEX.tar.gz | Library for storing and retrieving passwords and other secrets (development files) | https://gnome.pages.gitlab.gnome.org/libsecret
- apk - libsecret-doc - 0.21.7-r0: normalized package name match | Alpine Linux edge package indexes: libsecret-doc from https://dl-cdn.alpinelinux.org/alpine/edge/main/x86_64/APKINDEX.tar.gz | Library for storing and retrieving passwords and other secrets (documentation) | https://gnome.pages.gitlab.gnome.org/libsecret
- apk - libsecret-lang - 0.21.7-r0: normalized package name match | Alpine Linux edge package indexes: libsecret-lang from https://dl-cdn.alpinelinux.org/alpine/edge/main/x86_64/APKINDEX.tar.gz | Languages for package libsecret | https://gnome.pages.gitlab.gnome.org/libsecret
- apk - libsecret-static - 0.21.7-r0: normalized package name match | Alpine Linux edge package indexes: libsecret-static from https://dl-cdn.alpinelinux.org/alpine/edge/main/x86_64/APKINDEX.tar.gz | Library for storing and retrieving passwords and other secrets (static library) | https://gnome.pages.gitlab.gnome.org/libsecret


## Combined YAML source

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