2

I need to understand what the PubkeyAuthentication=false actually is doing in the following command:

ssh -X -o PubkeyAuthentication=false notadmin@<DedicatedHost>

Is it turning off the PubkeyAuthentication? This is in a test procedure for to test Access Control and I am trying to understand what the is doing to by pass the PubkeyAuthentication.

2
  • Hi and welcome to Superuser! It is expected that you do some research first before posting a question. Have you, for example, read the manual of the ssh command? If the explanation of the option PubkeyAuthentication was not clear for you, can you edit your question to indicate what exactly was not clear? Feb 6, 2019 at 16:53
  • It is not a command, with -o you specify options used for this specific invocation overwriting the Config file or defaults
    – eckes
    Feb 8, 2019 at 21:07

2 Answers 2

1

You are on the client machine, connecting to aSSH server. When you specify -o PubkeyAuthentication=false you are telling the server you DO NOT support ssh-key auth for that session.

SSH servers are most commonly setup to be accessed with a ssh-key or via password authentication. (Other methods are available)

If you want to use ssh -X -o PubkeyAuthentication=false notadmin@<DedicatedHost> on the client session, that server will need to support Password authentication. If the server does NOT support password authentication and you specify -o PubkeyAuthentication=false The server will fallback to any other authentication method available.

If the server has Password Auth disabled an PubkeyAuth enabled, you will not be able to connect using your SSH arguments.

0

When you pass PubkeyAuthentication it enables or disables the general SSH public key authentication for that use and on that host. As explained on the documentation for ssh_config options states:

Specifies whether to try public key authentication. The argument to this keyword must be yes (the default) or no.

But in the command you provide, it seems that false is set:

ssh -X -o PubkeyAuthentication=false notadmin@<DedicatedHost>

Which might work, but am unsure. Would assume it should be no instead. But in your question you ask:

This is in a test procedure for to test Access Control and I am trying to understand what the is doing to by pass the PubkeyAuthentication.

Most likely if this is in a test procedure—and someone developed those tests—then they wanted to force the SSH connection to not used SSH keys for authentication but rather use some other method; most likely a plain old password being typed in.

As for why that would be desired? Who knows. Without the context of the larger test context, nobody here can say. But I said what I said and based on what I know that line should not work since false is a literally false option.

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.