GitRead 中文社区
首页趋势排行榜原创文章严选周刊
更多资源
新手训练营
精选专题热门话题GitHub 文档资源精选实战指南

rage

A simple, secure and modern file encryption tool (and Rust library) with small explicit keys, no config options, and UNIX-style composability.

  • 语言Rust
  • 默认分支main
  • 大小4.1 MB
  • 更新8月21日
  • Issues74
在 GitHub 打开
avatarstr4d

项目介绍

str4d/rage 是一个托管在 GitHub 上的开源项目,主要使用 Rust 编写,采用 Apache License 2.0 许可证,目前获得 3.7k 个 Star、166 次 Fork。

仓库全名
str4d/rage

README 摘要

rage: Rust implementation of age rage is a simple, modern, and secure file encryption tool, using the age format. It features small explicit keys, no config options, and UNIX-style composability. The format specification is at age-encryption.org/v1. age was designed by @Benjojo and @FiloSottile. The reference interoperable Go implementation is available at filippo.io/age. Hardware PIV tokens such as YubiKeys are…

完整内容见 GitHub 原始 README 或本页 。

常见问题

rage 用什么语言开发?

主要使用 Rust 编写,采用 Apache License 2.0 许可证,目前有 3.7k 个 Star。

rage 可以免费商用吗?

仓库采用 Apache License 2.0 许可证,可免费使用与修改,商业使用请遵守许可证条款(例如保留版权声明与许可声明)。

如何获取 rage 的源码?

可以直接克隆仓库:git clone https://github.com/str4d/rage.git,默认分支为 main;安装与运行步骤见仓库 README。

rage 最近还在维护吗?

仓库最近一次更新为 8月21日,当前有 74 个未关闭 Issue;Star 数为 3.7k,可作为社区活跃度的参考。

本页面展示项目元数据与原始 README,GitRead 中文社区 编辑团队负责选题收录。

相关仓库

ultraworkers/claw-code avatar
claw-codeultraworkers
1 天前
194.8k
107.4k
1

一个由智能体管理的博物馆展品,使用 Rust 与 Gajae-Code / LazyCodex 构建——在无人工干预的情况下开发与维护。

Rust
26.8 MB
0
详情
clash-verge-rev/clash-verge-rev avatar
clash-verge-revclash-verge-rev
4 小时前
157.7k
11.3k
577

基于 Tauri 的现代 GUI 客户端,旨在在 Windows、macOS 和 Linux 上运行,提供量身定制的代理体验

clashclash-metaclash-verge+5
Rust
87.4 MB
1
详情
farion1231/cc-switch avatar
cc-switchfarion1231
7 小时前
153.5k
10.1k
964

跨平台桌面一体化助手,适用于 Claude Code、Codex、OpenCode、DeepSeek Harness 等。唯一官方网站:ccswitch.io

ai-toolsclaude-codecodex+16
Rust
113.0 MB
2
详情
openai/codex avatar
codexopenai
7 小时前
134.8k
21.4k
27.1k

在你的终端中运行的轻量级编码智能体

Rust
727.0 MB
1
详情
rustdesk/rustdesk avatar
rustdeskrustdesk
5 分钟前
129.0k
20.6k
212

一款开源远程桌面应用,专为自托管设计,可作为 TeamViewer 的替代方案。

androidanydeskdart+16
Rust
86.4 MB
0
详情
rust-lang/rust avatar
rustrust-lang
7 小时前
121.8k
16.0k
11.2k

让每个人都能构建可靠且高效的软件。

compilerlanguagerust
Rust
1020.5 MB
0
详情
tauri-apps/tauri avatar
tauritauri-apps
23 小时前
112.7k
4.2k
1.5k

用 Web 前端构建更小、更快、更安全的桌面和移动应用。

rustwebviewhigh-performance+4
Rust
110.8 MB
0
详情
denoland/deno avatar
denodenoland
1 周前
109.0k
7.1k
1.7k

一个面向 JavaScript 和 TypeScript 的现代运行时。

denojavascriptrust+1
Rust
247.7 MB
0
详情

关于

age-encryptionclicurve25519encryptionrustrust-libraryscryptsecure-by-defaultunix-philosophyyubikeyzero-configuration
  • Apache License 2.0
  • 3.7k Stars
  • 166 Forks
  • 32 Watching

简要分析

热度分
4079
价值分
2278
活跃状态
活跃
GitHub

语言占比

Fluent
Rust

Release

  • rage v0.12.17月14日
  • rage v0.11.47月14日
  • rage v0.12.07月13日
  • rage v0.11.37月13日
  • rage v0.11.24月22日

贡献者

str4dstr4ddependabot[bot]dependabot[bot]dueseedueseeBoostCookieBoostCookiedconnollydconnollynickzananickzanainterratointerratogibbz00gibbz00MacilMacilFiloSottileFiloSottilekanrukanruwoodruffwwoodruffw

The age logo, an wireframe of St. Peters dome in Rome, with the text: age, file encryption

rage: Rust implementation of age

rage is a simple, modern, and secure file encryption tool, using the age format. It features small explicit keys, no config options, and UNIX-style composability.

The format specification is at age-encryption.org/v1. age was designed by @Benjojo and @FiloSottile.

The reference interoperable Go implementation is available at filippo.io/age.

Hardware PIV tokens such as YubiKeys are supported through the age-plugin-yubikey plugin.

For more plugins, implementations, tools, and integrations, check out the awesome age list.

Installation

Environment CLI command
Cargo (Rust 1.85+) cargo install rage
Homebrew (macOS or Linux) brew install rage
MacPorts port install rage
Alpine Linux (edge) apk add rage
Arch Linux pacman -S rage-encryption
Debian Debian packages
NixOS Add to config: environment.systemPackages = [ pkgs.rage ];
Or run nix-env -i rage
openSUSE Tumbleweed zypper install rage-encryption
Ubuntu 22.04+ Debian packages
FreeBSD pkg install rage-encryption
Scoop (Windows) scoop bucket add main
scoop install main/rage

On Windows, Linux, and macOS, you can use the pre-built binaries.

Help from new packagers is very welcome. Please use the package name rage; the fallback package name rage-encryption should be used only when there are unavoidable name conflicts in package systems that use global namespaces. Do not rename any binaries; instead use your package system’s conflicting package mechanism to prevent installation of both packages at once.

Usage

Usage: rage [--encrypt] (-r RECIPIENT | -R PATH)... [-i IDENTITY] [-a] [-o OUTPUT] [INPUT]
       rage [--encrypt] --passphrase [-a] [-o OUTPUT] [INPUT]
       rage --decrypt [-i IDENTITY] [-o OUTPUT] [INPUT]

Arguments:
  [INPUT]  Path to a file to read from.

Options:
  -h, --help                    Print this help message and exit.
  -V, --version                 Print version info and exit.
  -e, --encrypt                 Encrypt the input (the default).
  -d, --decrypt                 Decrypt the input.
  -p, --passphrase              Encrypt with a passphrase instead of recipients.
      --max-work-factor <WF>    Maximum work factor to allow for passphrase decryption.
  -a, --armor                   Encrypt to a PEM encoded format.
  -r, --recipient <RECIPIENT>   Encrypt to the specified RECIPIENT. May be repeated.
  -R, --recipients-file <PATH>  Encrypt to the recipients listed at PATH. May be repeated.
  -i, --identity <IDENTITY>     Use the identity file at IDENTITY. May be repeated.
  -j <PLUGIN-NAME>              Use age-plugin-PLUGIN-NAME in its default mode as an identity.
  -o, --output <OUTPUT>         Write the result to the file at path OUTPUT.

INPUT defaults to standard input, and OUTPUT defaults to standard output.
If OUTPUT exists, it will be overwritten.

RECIPIENT can be:
- An age public key, as generated by rage-keygen ("age1...").
- An SSH public key ("ssh-ed25519 AAAA...", "ssh-rsa AAAA...").

PATH is a path to a file containing age recipients, one per line
(ignoring "#" prefixed comments and empty lines). "-" may be used to
read recipients from standard input.

IDENTITY is a path to a file with age identities, one per line
(ignoring "#" prefixed comments and empty lines), or to an SSH key file.
Passphrase-encrypted age identity files can be used as identity files.
Multiple identities may be provided, and any unused ones will be ignored.
"-" may be used to read identities from standard input.

Multiple recipients

Files can be encrypted to multiple recipients by repeating -r/--recipient. Every recipient will be able to decrypt the file.

$ rage -o example.png.age -r age1uvscypafkkxt6u2gkguxet62cenfmnpc0smzzlyun0lzszfatawq4kvf2u \
    -r age1ex4ty8ppg02555at009uwu5vlk5686k3f23e7mac9z093uvzfp8sxr5jum example.png
Recipient files

Multiple recipients can also be listed one per line in one or more files passed with the -R/--recipients-file flag.

$ cat recipients.txt
# Alice
age1ql3z7hjy54pw3hyww5ayyfg7zqgvc7w3j2elw8zmrj2kg5sfn9aqmcac8p
# Bob
age1lggyhqrw2nlhcxprm67z43rta597azn8gknawjehu9d9dl0jq3yqqvfafg
$ rage -R recipients.txt example.jpg > example.jpg.age

If the argument to -R (or -i) is -, the file is read from standard input.

Passphrases

Files can be encrypted with a passphrase by using -p/--passphrase. By default rage will automatically generate a secure passphrase.

$ rage -p -o example.png.age example.png
Type passphrase (leave empty to autogenerate a secure one): [hidden]
Using an autogenerated passphrase:
    kiwi-general-undo-bubble-dwarf-dizzy-fame-side-sunset-sibling
$ rage -d example.png.age >example.png
Type passphrase: [hidden]

If a binary named pinentry is available in $PATH, it will be used to ask the user for a passphrase. The PINENTRY_PROGRAM environment variable can be used to set the binary name or path to use. If a pinentry binary is not available, or PINENTRY_PROGRAM is set to the empty string, rage will fall back to the CLI instead.

Passphrase-protected identity files

If an identity file passed to -i/--identity is a passphrase-encrypted age file, it will be automatically decrypted.

$ rage -p -o key.age <(rage-keygen)
Public key: age1pymw5hyr39qyuc950tget63aq8vfd52dclj8x7xhm08g6ad86dkserumnz
Type passphrase (leave empty to autogenerate a secure one): [hidden]
Using an autogenerated passphrase:
    flash-bean-celery-network-curious-flower-salt-amateur-fence-giant
$ rage -r age1pymw5hyr39qyuc950tget63aq8vfd52dclj8x7xhm08g6ad86dkserumnz secrets.txt > secrets.txt.age
$ rage -d -i key.age secrets.txt.age > secrets.txt
Type passphrase: [hidden]

Passphrase-protected identity files are not necessary for most use cases, where access to the encrypted identity file implies access to the whole system. However, they can be useful if the identity file is stored remotely.

SSH keys

As a convenience feature, rage also supports encrypting to ssh-rsa and ssh-ed25519 SSH public keys, and decrypting with the respective private key file. (ssh-agent is not supported.)

$ rage -R ~/.ssh/id_ed25519.pub example.png > example.png.age
$ rage -d -i ~/.ssh/id_ed25519 example.png.age > example.png

Note that SSH key support employs more complex cryptography, and embeds a public key tag in the encrypted file, making it possible to track files that are encrypted to a specific public key.

Feature flags

When building with Cargo, you can configure rage using --no-default-features and --features comma,separated,flags to enable or disable the following feature flags:

  • mount enables the rage-mount tool, which can mount age-encrypted TAR or ZIP archives as read-only. It is currently only usable on Unix systems (as it relies on libfuse), and has an MSRV of 1.88.

  • ssh (enabled by default) enables support for reusing existing SSH key files for age encryption.

  • unstable enables in-development functionality. Anything behind this feature flag has no stability or interoperability guarantees.

Rust Library

Applications wishing to use rage as a library should use the age crate, which rage is built on top of.

License

Licensed under either of

  • Apache License, Version 2.0, (LICENSE-APACHE or http://www.apache.org/licenses/LICENSE-2.0)
  • MIT license (LICENSE-MIT or http://opensource.org/licenses/MIT)

at your option.

Contribution

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.

评论

登录 后发表评论
暂无评论
GitRead 中文社区
深度解读 · 趋势洞察 · 价值精选

关于

关于我们联系我们编辑准则收录标准赞赏人员

发现

技术趋势新手训练营资源精选实战指南精选专题热门话题GitHub 文档

条款

隐私政策服务条款网站地图
26.9万收录项目
6.3万中文话题
155精选专题
发现技术价值,连接开源智慧
© 2026 GitRead · GitHub 中文社区 本站与 GitHub, Inc. 无隶属关系;GitHub 是 GitHub, Inc. 的商标。