Differential D21765 Diff 51884 src/applications/auth/controller/PhabricatorAuthSSHKeyGenerateController.php
Changeset View
Changeset View
Standalone View
Standalone View
src/applications/auth/controller/PhabricatorAuthSSHKeyGenerateController.php
Show First 20 Lines • Show All 99 Lines • ▼ Show 20 Lines | try { | ||||
return $this->newDialog() | return $this->newDialog() | ||||
->setTitle(pht('Generate New Keypair')) | ->setTitle(pht('Generate New Keypair')) | ||||
->addHiddenInput('objectPHID', $key->getObject()->getPHID()) | ->addHiddenInput('objectPHID', $key->getObject()->getPHID()) | ||||
->appendParagraph( | ->appendParagraph( | ||||
pht( | pht( | ||||
'This workflow will generate a new SSH keypair, add the public '. | 'This workflow will generate a new SSH keypair, add the public '. | ||||
'key, and let you download the private key.')) | 'key, and let you download the private key.')) | ||||
->appendParagraph( | ->appendParagraph( | ||||
pht('Phabricator will not retain a copy of the private key.')) | pht('The private key will not be retained.')) | ||||
->addSubmitButton(pht('Generate New Keypair')) | ->addSubmitButton(pht('Generate New Keypair')) | ||||
->addCancelButton($cancel_uri); | ->addCancelButton($cancel_uri); | ||||
} catch (Exception $ex) { | } catch (Exception $ex) { | ||||
return $this->newDialog() | return $this->newDialog() | ||||
->setTitle(pht('Unable to Generate Keys')) | ->setTitle(pht('Unable to Generate Keys')) | ||||
->appendParagraph($ex->getMessage()) | ->appendParagraph($ex->getMessage()) | ||||
->addCancelButton($cancel_uri); | ->addCancelButton($cancel_uri); | ||||
} | } | ||||
} | } | ||||
} | } |