X-Git-Url: https://git.arvados.org/arvados.git/blobdiff_plain/e4b54c3b5d99c99553e319ead28c3aa8dcd6eecc..b80db2511622b7600fa7a03e7db4c5c82cf61d39:/src/validators/is-rsa-key.tsx

diff --git a/src/validators/is-rsa-key.tsx b/src/validators/is-rsa-key.tsx
index 7620a801d4..d41b092906 100644
--- a/src/validators/is-rsa-key.tsx
+++ b/src/validators/is-rsa-key.tsx
@@ -6,5 +6,5 @@
 const ERROR_MESSAGE = 'Public key is invalid';
 
 export const isRsaKey = (value: any) => {
-    return value.match(/ssh-rsa AAAA[0-9A-Za-z+/]+[=]{0,3} ([^@]+@[^@]+)/i) ? undefined : ERROR_MESSAGE;
+    return value.match(/ssh-rsa AAAA[0-9A-Za-z+/]+[=]{0,3}(( [^@]+@[^@]+)|$)/i) ? undefined : ERROR_MESSAGE;
 };
