Richard Jones committed 0ef5572

allow ecdsa-sha2-nistp* ssh key types; fixes #10

  • Participants
  • Parent commits 3e6cd6b

Comments (0)

Files changed (1)

             if line.strip():
                 raise FormError, "Invalid key format: multiple lines"
         key = key[0].strip()
-        if not key.startswith('ssh-dss') and not key.startswith('ssh-rsa'):
+        if not any(pfx for pfx in 'ssh-dss ssh-rsa ecdsa-sha2-nistp'
+                if key.startswith(pfx)):
             raise FormError, "Invalid key format: does not start with ssh-dss or ssh-rsa", key)