bunker: re-render the qr code when the bunker secret rotates, it was left on screen encoding the burnt secret.

This commit is contained in:
Yasuhiro Matsumoto
2026-08-18 13:47:00 +09:00
parent 510c0039cc
commit 73a6a6699c

View File

@@ -429,7 +429,14 @@ var bunker = &cli.Command{
}
setBunkerInfo := func() {
info, _ := bunkerInfo()
info, bunkerURI := bunkerInfo()
if c.Bool("qrcode") {
// the secret embedded in the bunker uri may have rotated,
// so the qr code on screen has to be rendered again
qr := strings.Builder{}
qrterminal.Generate(bunkerURI, qrterminal.L, &qr)
terminal.Log("QR Code for bunker URI:\n%s\n", qr.String())
}
terminal.SetFooter(info)
}