O'Reilly logo

Linux in a Nutshell, 6th Edition by Robert Love, Stephen Figgins, Ellen Siever, Arnold Robbins

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Name

ssh-keyscan

Synopsis

ssh-keyscan [options]

Gather public and private host keys from a number of hosts. Can be used in scripts.

Options

−4

Use IPv4 addresses only.

−6

Use IPv6 addresses only.

-f file

Read hostnames or addrlist namelist pairs from file. If - is specified instead of a filename, read hosts or addrlist namelist pairs from standard input.

-H

Hash hostnames and addresses in the output.

-p port

Specify the port to connect to on the remote host.

-t type

Specify the type of key to get from the scanned hosts. Possible values are rsa1 for SSH1 (default), or rsa or dsa for SSH2. Specify multiple values in a comma-separated list.

-T timeout

Specify the timeout for attempting a connection, in seconds. Default is 5 seconds.

-v

Verbose mode.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required