Uploaded image for project: 'COmanage'
  1. COmanage
  2. CO-1598

Don't allow entry of invalid ssh keys

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Open
    • Priority: Minor
    • Resolution: Unresolved
    • Affects Version/s: COmanage Registry 3.0.0 (Fancy New Dress)
    • Fix Version/s: COmanage Registry Future
    • Component/s: Registry
    • Labels:
      None

      Description

      When adding an ssh key, one is inclined to simply paste an openssh-style public key file of the form 

      ssh-rsa abcdef1234...fedcba0987654321 somekey_id

      into the text field.  The UI accepts this, but when the key is actually provisioned (to ldap, for example), the key will be 

      ssh-rsa ssh-rsa abcdef1234...fedcba0987654321 somekey_id comment

      I guess in a way this makes sense, as COmanage simply adds the key type and comment the user has provided, but for a user it is a bit unfriendly.

      I guess there are several ways around this:

      1. make clearer in the UI what the user should enter, exactly
      2. reject user input that doesn't adhere to the format COmanage is expecting (the common case can be caught based on a simple regex, I guess)
      3. automatically detect the openssl key foramt, and populate/override the key type and comment fields.

      From a UI point of view, option 3 would be preferable, I guess.  It could be implemented by a small piece of js, and combined with a server side check for option 2.

       

        Smart Checklist

          Attachments

            Issue Links

              Activity

                People

                Assignee:
                benn.oshrin@at.internet2.edu Benn Oshrin
                Reporter:
                baszoetekouw Bas Zoetekouw (Inactive)
                Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                  Dates

                  Created:
                  Updated: