Skip to content

Update SSH key expired warning messages

What does this MR do?

This MR updates the SSH key profile and admin views to be more descriptive with the icon tooltips depending on whether SSH key expiration enforcement is enabled.

It also adds an additional description to the expiry date form field on the SSH key creation form in the user's profile.

Screenshots (strongly suggested)

Form description

Enforced Not enforced CE
image image image

Tooltip

Scenario Outcome
Valid and not expired image
Valid and expired and enforced image
Valid and expired and not enforced image
Valid and expired on CE image
Not valid and not expired image
Not valid and expired and enforced image
Not valid and expired and not enforced image
Not valid and expired on CE image

Does this MR meet the acceptance criteria?

Conformity

Availability and Testing

  1. Make sure you are using an GitLab Ultimate or greater license
  2. Go to [HOST]/admin/application_settings/general#js-account-settings and enable/disable the Enforce SSH key expiration setting
  3. Go to [HOST]/-/profile/keys and make sure the description and tooltip render as expected

For forcing an invalid key, you can do this after key creation by changing which SSH key types are allowed on the instance. If you forbid your SSH keys type, it will invalidate the key!

  1. Go to [HOST]/admin/application_settings/generaljs-visibility-settings and enable/disable your SSH keys type
  2. Go to [HOST]/-/profile/keys and make sure the tooltip renders as expected

image

Security

If this MR contains changes to processing or storing of credentials or tokens, authorization and authentication methods and other items described in the security review guidelines:

  • [-] Label as security and @ mention @gitlab-com/gl-security/appsec
  • [-] The MR includes necessary changes to maintain consistency between UI, API, email, or other methods
  • [-] Security reports checked/validated by a reviewer from the AppSec team

Related to #247515 (closed)

Edited by Jiaan Louw

Merge request reports