Differential D25040 Diff 97 src/applications/almanac/management/AlmanacManagementTrustKeyWorkflow.php
Changeset View
Changeset View
Standalone View
Standalone View
src/applications/almanac/management/AlmanacManagementTrustKeyWorkflow.php
Show First 20 Lines • Show All 55 Lines • ▼ Show 20 Lines | $handle = id(new PhabricatorHandleQuery()) | ||||
->executeOne(); | ->executeOne(); | ||||
$console->writeOut( | $console->writeOut( | ||||
"**<bg:red> %s </bg>**\n\n%s\n\n%s\n\n%s", | "**<bg:red> %s </bg>**\n\n%s\n\n%s\n\n%s", | ||||
pht('IMPORTANT!'), | pht('IMPORTANT!'), | ||||
phutil_console_wrap( | phutil_console_wrap( | ||||
pht( | pht( | ||||
'Trusting a public key gives anyone holding the corresponding '. | 'Trusting a public key gives anyone holding the corresponding '. | ||||
'private key complete, unrestricted access to all data in '. | 'private key complete, unrestricted access to all data. The '. | ||||
'Phabricator. The private key will be able to sign requests that '. | 'private key will be able to sign requests that bypass policy and '. | ||||
'skip policy and security checks.')), | 'security checks.')), | ||||
phutil_console_wrap( | phutil_console_wrap( | ||||
pht( | pht( | ||||
'This is an advanced feature which should normally be used only '. | 'This is an advanced feature which should normally be used only '. | ||||
'when building a Phabricator cluster. This feature is very '. | 'when building a cluster. This feature is very dangerous if '. | ||||
'dangerous if misused.')), | 'misused.')), | ||||
pht('This key is associated with device "%s".', $handle->getName())); | pht('This key is associated with device "%s".', $handle->getName())); | ||||
$prompt = pht( | $prompt = pht( | ||||
'Really trust this key?'); | 'Really trust this key?'); | ||||
if (!phutil_console_confirm($prompt)) { | if (!phutil_console_confirm($prompt)) { | ||||
throw new PhutilArgumentUsageException( | throw new PhutilArgumentUsageException( | ||||
pht('User aborted workflow.')); | pht('User aborted workflow.')); | ||||
} | } | ||||
Show All 13 Lines |
Content licensed under Creative Commons Attribution-ShareAlike 4.0 (CC-BY-SA) unless otherwise noted; code licensed under Apache 2.0 or other open source licenses. · CC BY-SA 4.0 · Apache 2.0