@recaptime-dev's working patches + fork for Phorge, a community fork of Phabricator. (Upstream dev and stable branches are at upstream/main and upstream/stable respectively.) hq.recaptime.dev/wiki/Phorge
phorge phabricator
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Auth SSH Details: show Public Key (not just Type)

Summary:
At the moment the "SSH Key Details" page lists only two minimal information:

- Key Type (Example: 'ssh-rsa')
- Created (Example: 'Wed, Dec 13, 5:13 PM')

After this change it shows also the original Public Key. It becomes something like:

- Public Key (Example: 'ssh-rsa AAAB3....... mariana@localhost')
- Created (Example: 'Wed, Dec 13, 5:13 PM')

This is just a minimal UX change.
Note that you can already see the Public Key by clicking "Edit".
So, nothing new is shown.

Context:

Premising that Phorge encourages to Revoke your decommissioned / deprecated
/ compromised SSH keys with a very lovely "Revoke" Workflow...

Root problem:

If you Revoke one of your keys, and if you then want to double-check that
SSH Public Key again (if you want to see its original body), you then discover
that you cannot see it anymore. In fact, the only way is the Edit button, but
Editing is disabled for any Revoked Key. In this kind of situation, it's not
nice to have to involve your favorite database administrator, to inspect the
'phabricator_auth.auth_sshkey' database table, to just be able to see your SSH
Public Key again.

After this change, you can easily self-audit your Revoked SSH Public Keys,
and your beloved DBA has extra free time. Win-win situation.

Closes T15692

Test Plan:
- visit your SSH Keys, open one, and check the new Details with your big eyes
- do the dame while juggling two ping pong balls (is anybody reading this?)
- do the same on a Revoked key

Reviewers: O1 Blessed Committers, aklapper

Reviewed By: O1 Blessed Committers, aklapper

Subscribers: aklapper, tobiaswiese, Matthew, Cigaryno

Maniphest Tasks: T15692

Differential Revision: https://we.phorge.it/D25495

authored by

Valerio Bozzolan and committed by
Valerio Bozzolan
549a26d0 8e09dbfe

+1 -1
+1 -1
src/applications/auth/controller/PhabricatorAuthSSHKeyViewController.php
··· 110 110 $properties = id(new PHUIPropertyListView()) 111 111 ->setUser($viewer); 112 112 113 - $properties->addProperty(pht('SSH Key Type'), $ssh_key->getKeyType()); 113 + $properties->addProperty(pht('Public Key'), $ssh_key->getEntireKey()); 114 114 $properties->addProperty( 115 115 pht('Created'), 116 116 phabricator_datetime($ssh_key->getDateCreated(), $viewer));