1
0
mirror of https://github.com/netbox-community/netbox.git synced 2024-05-10 07:54:54 +00:00

Merge branch 'develop' into 568-csv-import-cf

This commit is contained in:
hSaria
2020-01-21 21:30:38 +00:00
committed by GitHub
24 changed files with 853 additions and 128 deletions

View File

@ -16,6 +16,8 @@ def validate_rsa_key(key, is_secret=True):
"""
Validate the format and type of an RSA key.
"""
if key.startswith('ssh-rsa '):
raise forms.ValidationError("OpenSSH line format is not supported. Please ensure that your public is in PEM (base64) format.")
try:
key = RSA.importKey(key)
except ValueError: