phacility/phabricator · warning · PhutilArgumentUsageException
You must enter an LDAP password.
Error message
You must enter an LDAP password.
What it means
The second interactive check in bin/auth ldap: after the username, the workflow prompts for the LDAP password with terminal echo disabled (stty -echo ... stty echo). An empty password aborts with PhutilArgumentUsageException before the adapter attempts to bind.
Source
Thrown at src/applications/auth/management/PhabricatorAuthManagementLDAPWorkflow.php:49
pht('The LDAP extension is not enabled.'));
exit(1);
}
$adapter = $provider->getAdapter();
$console->writeOut("%s\n", pht('Enter LDAP Credentials'));
$username = phutil_console_prompt(pht('LDAP Username: '));
if (!strlen($username)) {
throw new PhutilArgumentUsageException(
pht('You must enter an LDAP username.'));
}
phutil_passthru('stty -echo');
$password = phutil_console_prompt(pht('LDAP Password: '));
phutil_passthru('stty echo');
if (!strlen($password)) {
throw new PhutilArgumentUsageException(
pht('You must enter an LDAP password.'));
}
$adapter->setLoginUsername($username);
$adapter->setLoginPassword(new PhutilOpaqueEnvelope($password));
$console->writeOut("\n");
$console->writeOut("%s\n", pht('Connecting to LDAP...'));
$account_ids = $adapter->getAccountIdentifiers();
if ($account_ids) {
$value_list = mpull($account_ids, 'getIdentifierRaw');
$value_list = implode(', ', $value_list);
$console->writeOut("%s\n", pht('Found LDAP Account: %s', $value_list));
} else {
$console->writeOut("%s\n", pht('Unable to find LDAP account!'));
}View on GitHub (pinned to 5720a38cfe)
Solutions
- Re-run and type the password blind (no characters will appear — that is expected), then press Enter.
- Ensure the run happens in a real terminal so stty echo suppression works.
- If the password is genuinely empty on the LDAP side, use a dedicated test account with a password.
Defensive patterns
Strategy: validation
Prevention
- Expect blind input: echo is disabled during the password prompt, so typed characters do not display.
- Run in a real TTY so stty -echo works and stdin is attached.
- Use a dedicated test account with a known password.
When it happens
Trigger: Pressing Enter at the 'LDAP Password:' prompt; typing nothing because the disabled echo makes it look like input is not registering; stdin closed in non-interactive runs.
Common situations: Users confused by the blind password prompt; scripted invocations without a TTY; password managers not pasting into the hidden prompt.
Related errors
- You must enter an LDAP username.
- Request parameter "%s" is not formatted properly. Expected a
- Request parameter "%s" is not formatted properly. Expected a
- Invalid Request (CSRF)
- This server is configured as "%s", but you are using the dom
AI-assisted analysis of phacility/phabricator@5720a38cfe (2026-08-21).
Data as JSON: /api/errors/fd8ef0d98e40f4cf.
Report an issue: GitHub.