diff --git a/lib/tools/prepare_node_join.py b/lib/tools/prepare_node_join.py
index b1270f53cc3b0d8bc38b4d83b95e4727ed2ccfdf..09710378827469fc64d054e30c95fbb653344238 100644
--- a/lib/tools/prepare_node_join.py
+++ b/lib/tools/prepare_node_join.py
@@ -58,11 +58,6 @@ _DATA_CHECK = ht.TStrictDict(False, True, {
   constants.SSHS_SSH_ROOT_KEY: _SSH_KEY_LIST,
   })
 
-_SSHK_TO_SSHAK = {
-  constants.SSHK_RSA: constants.SSHAK_RSA,
-  constants.SSHK_DSA: constants.SSHAK_DSS,
-  }
-
 _SSH_DAEMON_KEYFILES = {
   constants.SSHK_RSA:
     (pathutils.SSH_HOST_RSA_PUB, pathutils.SSH_HOST_RSA_PRIV),
@@ -70,9 +65,6 @@ _SSH_DAEMON_KEYFILES = {
     (pathutils.SSH_HOST_DSA_PUB, pathutils.SSH_HOST_DSA_PRIV),
   }
 
-assert frozenset(_SSHK_TO_SSHAK.keys()) == constants.SSHK_ALL
-assert frozenset(_SSHK_TO_SSHAK.values()) == constants.SSHAK_ALL
-
 
 class JoinError(errors.GenericError):
   """Local class for reporting errors.
@@ -312,9 +304,8 @@ def UpdateSshRoot(data, dry_run, _homedir_fn=None):
   if dry_run:
     logging.info("This is a dry run, not modifying %s", auth_keys_file)
   else:
-    for (kind, public_key, _) in keys:
-      line = "%s %s" % (_SSHK_TO_SSHAK[kind], public_key)
-      utils.AddAuthorizedKey(auth_keys_file, line)
+    for (_, _, public_key) in keys:
+      utils.AddAuthorizedKey(auth_keys_file, public_key)
 
 
 def LoadData(raw):
diff --git a/test/ganeti.tools.prepare_node_join_unittest.py b/test/ganeti.tools.prepare_node_join_unittest.py
index b629f77284e0b4921f2846b40fdcd27db14fede9..bbc3634416951b84b5cd729134f64d7e88291e82 100755
--- a/test/ganeti.tools.prepare_node_join_unittest.py
+++ b/test/ganeti.tools.prepare_node_join_unittest.py
@@ -287,7 +287,7 @@ class TestUpdateSshRoot(unittest.TestCase):
   def testUpdate(self):
     data = {
       constants.SSHS_SSH_ROOT_KEY: [
-        (constants.SSHK_DSA, "pubdsa", "privatedsa"),
+        (constants.SSHK_DSA, "ssh-dss pubdsa", "privatedsa"),
         ]
       }
 
@@ -299,7 +299,7 @@ class TestUpdateSshRoot(unittest.TestCase):
     self.assertEqual(utils.ReadFile(utils.PathJoin(self.sshdir, "id_dsa")),
                      "privatedsa")
     self.assertEqual(utils.ReadFile(utils.PathJoin(self.sshdir, "id_dsa.pub")),
-                     "pubdsa")
+                     "ssh-dss pubdsa")
     self.assertEqual(utils.ReadFile(utils.PathJoin(self.sshdir,
                                                    "authorized_keys")),
                      "ssh-dss pubdsa\n")