From: dwsteele (@dwsteele) <noreply+dwsteele@github.com>
To: pgbackrest/pgbackrest <noreply+pgbackrest-pgbackrest@github.com>
Subject: Re: [pgbackrest/pgbackrest] PR #2898: Add stanza-rekey command to change the repository passphrase.
Date: Fri, 06 Nov 2026 16:27:02 +0000
Message-ID: <gh-pgbackrest-pgbackrest-2898-c6689816611@github.com> (raw)
In-Reply-To: <gh-pgbackrest-pgbackrest-2898@github.com>
References: <gh-pgbackrest-pgbackrest-2898@github.com>
> Wouldn't it make more sense to preserve the passphrase used to decrypt an info file when saving it, and leave the actual rekeying to stanza-rekey?
Well, yes, that would make a lot more sense! You are correct that the rekey should not happen as a side effect and I completely missed that.
Here's a better implementation at 6d189c9776f. This preserves the prior key on save and only rekey updates it. I'll have another look at it on Monday but I think this is the way to go.