Disable agent forwarding when no agent is set

pull/285/head
Kelvin Schoofs 3 years ago
parent f62bfa669d
commit e013489677

@ -165,6 +165,10 @@ export async function calculateActualConfig(config: FileSystemConfig): Promise<F
// Issue with the ssh2 dependency apparently not liking false
delete config.passphrase;
}
if (config.agentForward && !config.agent) {
logging.debug(`\tNo agent while having agentForward, disabling agent forwarding`);
config.agentForward = false;
}
if (!config.privateKey && !config.agent && !config.password) {
logging.debug(`\tNo privateKey, agent or password. Gonna prompt for password`);
config.password = true as any;

Loading…
Cancel
Save