From 58ef9fcb8da0c5cc782f6e1f09a91d03bdf629fa Mon Sep 17 00:00:00 2001 From: Filippo Valsorda Date: Sat, 29 Aug 2026 18:59:30 +0200 Subject: [PATCH] cmd/age-keygen: correct public key output documentation Reported by Joe Doyle of Trail of Bits. --- cmd/age-keygen/keygen.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cmd/age-keygen/keygen.go b/cmd/age-keygen/keygen.go index 91098e5..682a757 100644 --- a/cmd/age-keygen/keygen.go +++ b/cmd/age-keygen/keygen.go @@ -31,8 +31,8 @@ age-keygen generates a new native X25519 or, with the -pq flag, post-quantum hybrid ML-KEM-768 + X25519 key pair, and outputs it to standard output or to the OUTPUT file. -If an OUTPUT file is specified, the public key is printed to standard error. -If OUTPUT already exists, it is not overwritten. +When generating a key, if the output is not going to a terminal, the public key +is printed to standard error. If OUTPUT already exists, it is not overwritten. In -y mode, age-keygen reads an identity file from INPUT or from standard input and writes the corresponding recipient(s) to OUTPUT or to standard