Same host or different? How can you tell "over the wire"?
Kevin Day
kevin at your.org
Thu Mar 22 02:37:16 UTC 2018
> On Mar 21, 2018, at 4:47 PM, Ronald F. Guilmette <rfg at tristatelogic.com> wrote:
>
> But your question certainly raises an interesting possibility, and an
> interesting question... one that I myself am not at all equiped or
> qualified to answer (because I am almost totally ignorant about even
> the bare mechanics of the SSH protocol): How could one tickle an open
> SSH port and obtain from it not just its greeting banner (which may be,
> and often is, rather generic and non-specific) but also so as to get
> the host's host-specific public key?
Does the ssh-keyscan tool do what you want?
# ssh-keyscan github.com
# github.com:22 SSH-2.0-libssh_0.7.0
github.com ssh-rsa AAAAB3NzaC1yc2EAAAABIwAAAQEAq2A7hRGmdnm9tUDbO9IDSwBK6TbQa+PXYPCPy6rbTrTtw7PHkccKrpp0yVhp5HdEIcKr6pLlVDBfOLX9QUsyCOV0wzfjIJNlGEYsdlLJizHhbn2mUjvSAHQqZETYP81eFzLQNnPHt4EVVUh7VfDESU84KezmD5QlWpXLmvU31/yMf+Se8xhHTvKSCZIFImWwoG6mbUoWf9nzpIoaSjB+weqqUUmpaaasXVal72J+UX2B+2RPW3RcT0eOzQgqlJL3RKrTJvdsjE3JEAvGq3lGHSZXy28G3skua2SmVi/w4yCE6gbODqnTWlg7+wC604ydGXA8VJiS5ap43JXiUFFAaQ==
Unless you've copied the host ssh keys manually, this will be unique to the system.
More information about the freebsd-net
mailing list