From ffc8a7edc773442a9f12d3ede93718845409968f Mon Sep 17 00:00:00 2001 From: epriestley <git@epriestley.com> Date: Mon, 17 Nov 2014 19:54:17 -0800 Subject: [PATCH] Minor, correct spelling of PKCS8 key format Summary: I faked this out locally because of the OSX stuff and goofed the key format spelling. Auditors: btrahan --- src/applications/auth/sshkey/PhabricatorAuthSSHPublicKey.php | 4 ++-- .../conduit/controller/PhabricatorConduitAPIController.php | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/applications/auth/sshkey/PhabricatorAuthSSHPublicKey.php b/src/applications/auth/sshkey/PhabricatorAuthSSHPublicKey.php index d32a1f84e7..8d14a14c6e 100644 --- a/src/applications/auth/sshkey/PhabricatorAuthSSHPublicKey.php +++ b/src/applications/auth/sshkey/PhabricatorAuthSSHPublicKey.php @@ -107,14 +107,14 @@ final class PhabricatorAuthSSHPublicKey extends Phobject { return $key; } - public function toPCKS8() { + public function toPKCS8() { // TODO: Put a cache in front of this. $tmp = new TempFile(); Filesystem::writeFile($tmp, $this->getEntireKey()); list($pem_key) = execx( - 'ssh-keygen -e -m pcks8 -f %s', + 'ssh-keygen -e -m PKCS8 -f %s', $tmp); unset($tmp); diff --git a/src/applications/conduit/controller/PhabricatorConduitAPIController.php b/src/applications/conduit/controller/PhabricatorConduitAPIController.php index 9738237b82..ec040690a4 100644 --- a/src/applications/conduit/controller/PhabricatorConduitAPIController.php +++ b/src/applications/conduit/controller/PhabricatorConduitAPIController.php @@ -224,7 +224,7 @@ final class PhabricatorConduitAPIController $raw_key = idx($metadata, 'auth.key'); $public_key = PhabricatorAuthSSHPublicKey::newFromRawKey($raw_key); - $ssl_public_key = $public_key->toPCKS8(); + $ssl_public_key = $public_key->toPKCS8(); // First, verify the signature. try {