Page MenuHomePhabricator

D16864.diff
No OneTemporary

D16864.diff

diff --git a/src/applications/passphrase/conduit/PassphraseQueryConduitAPIMethod.php b/src/applications/passphrase/conduit/PassphraseQueryConduitAPIMethod.php
--- a/src/applications/passphrase/conduit/PassphraseQueryConduitAPIMethod.php
+++ b/src/applications/passphrase/conduit/PassphraseQueryConduitAPIMethod.php
@@ -82,7 +82,7 @@
switch ($credential->getCredentialType()) {
case PassphraseSSHPrivateKeyFileCredentialType::CREDENTIAL_TYPE:
- if ($secret) {
+ if ($secret !== null) {
$material['file'] = $secret;
}
if ($public_key) {
@@ -91,7 +91,7 @@
break;
case PassphraseSSHGeneratedKeyCredentialType::CREDENTIAL_TYPE:
case PassphraseSSHPrivateKeyTextCredentialType::CREDENTIAL_TYPE:
- if ($secret) {
+ if ($secret !== null) {
$material['privateKey'] = $secret;
}
if ($public_key) {
@@ -99,10 +99,15 @@
}
break;
case PassphrasePasswordCredentialType::CREDENTIAL_TYPE:
- if ($secret) {
+ if ($secret !== null) {
$material['password'] = $secret;
}
break;
+ case PassphraseTokenCredentialType::CREDENTIAL_TYPE:
+ if ($secret !== null) {
+ $material['token'] = $secret;
+ }
+ break;
}
if (!$allow_api) {

File Metadata

Mime Type
text/plain
Expires
Fri, Oct 25, 2:35 AM (3 w, 3 d ago)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
6747678
Default Alt Text
D16864.diff (1 KB)

Event Timeline