Class KnownHostsFileKeyVerificationStrategy

    • Field Detail

      • KNOWN_HOSTS_DEFAULT

        public static final String KNOWN_HOSTS_DEFAULT
      • KNOWN_HOSTS_PROPERTY

        public static final String KNOWN_HOSTS_PROPERTY
    • Constructor Detail

      • KnownHostsFileKeyVerificationStrategy

        @DataBoundConstructor
        public KnownHostsFileKeyVerificationStrategy()
    • Method Detail

      • verify

        public boolean verify​(SlaveComputer computer,
                              HostKey hostKey,
                              TaskListener listener)
                       throws Exception
        Description copied from class: SshHostKeyVerificationStrategy
        Check if the given key is valid for the host identifier.
        Specified by:
        verify in class SshHostKeyVerificationStrategy
        Parameters:
        computer - the computer this connection is being initiated for
        hostKey - the key that was transmitted by the remote host for the current connection. This is the key that should be checked to see if we trust it by the current verifier.
        listener - the connection listener to write any output log to
        Returns:
        whether the provided HostKey is trusted and the current connection can therefore continue.
        Throws:
        Exception
      • getKnownHostsFile

        @Restricted(org.kohsuke.accmod.restrictions.NoExternalUse.class)
        public File getKnownHostsFile()