null-key.c 519 B

1234567891011121314151617181920212223
  1. #include "misc.h"
  2. #include "ssh.h"
  3. unsigned nullkey_supported_flags(const ssh_keyalg *self)
  4. {
  5. return 0;
  6. }
  7. const char *nullkey_alternate_ssh_id(const ssh_keyalg *self, unsigned flags)
  8. {
  9. /* There are no alternate ids */
  10. return self->ssh_id;
  11. }
  12. ssh_key *nullkey_base_key(ssh_key *key)
  13. {
  14. /* When a key is not certified, it is its own base */
  15. return key;
  16. }
  17. bool nullkey_variable_size_no(const ssh_keyalg *self) { return false; }
  18. bool nullkey_variable_size_yes(const ssh_keyalg *self) { return true; }