diff options
author | 2000-03-23 22:15:33 +0000 | |
---|---|---|
committer | 2000-03-23 22:15:33 +0000 | |
commit | 18bb4946ae772b4abf42d227a057259776f798fb (patch) | |
tree | 2f8551c2b872d24e8684af64eb361a5c2b7bef1b /usr.bin/ssh/hostfile.h | |
parent | oops, return values are int (diff) | |
download | wireguard-openbsd-18bb4946ae772b4abf42d227a057259776f798fb.tar.xz wireguard-openbsd-18bb4946ae772b4abf42d227a057259776f798fb.zip |
initial support for DSA keys. ok deraadt@, niels@
Diffstat (limited to 'usr.bin/ssh/hostfile.h')
-rw-r--r-- | usr.bin/ssh/hostfile.h | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/usr.bin/ssh/hostfile.h b/usr.bin/ssh/hostfile.h new file mode 100644 index 00000000000..64fe185da9f --- /dev/null +++ b/usr.bin/ssh/hostfile.h @@ -0,0 +1,22 @@ +#ifndef HOSTFILE_H +#define HOSTFILE_H + +/* + * Checks whether the given host is already in the list of our known hosts. + * Returns HOST_OK if the host is known and has the specified key, HOST_NEW + * if the host is not known, and HOST_CHANGED if the host is known but used + * to have a different host key. The host must be in all lowercase. + */ +typedef enum { + HOST_OK, HOST_NEW, HOST_CHANGED +} HostStatus; +HostStatus +check_host_in_hostfile(const char *filename, const char *host, Key *key, Key *found); + +/* + * Appends an entry to the host file. Returns false if the entry could not + * be appended. + */ +int add_host_to_hostfile(const char *filename, const char *host, Key *key); + +#endif |