File: null-key.c

package info (click to toggle)
putty 0.83-3
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 13,216 kB
  • sloc: ansic: 148,476; python: 8,466; perl: 1,830; makefile: 128; sh: 117
file content (22 lines) | stat: -rw-r--r-- 519 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
#include "misc.h"
#include "ssh.h"

unsigned nullkey_supported_flags(const ssh_keyalg *self)
{
    return 0;
}

const char *nullkey_alternate_ssh_id(const ssh_keyalg *self, unsigned flags)
{
    /* There are no alternate ids */
    return self->ssh_id;
}

ssh_key *nullkey_base_key(ssh_key *key)
{
    /* When a key is not certified, it is its own base */
    return key;
}

bool nullkey_variable_size_no(const ssh_keyalg *self) { return false; }
bool nullkey_variable_size_yes(const ssh_keyalg *self) { return true; }