[BACK]Return to dns.c CVS log [TXT][DIR] Up to [local] / src / usr.bin / ssh

Diff for /src/usr.bin/ssh/dns.c between version 1.42 and 1.43

version 1.42, 2022/02/01 23:32:51 version 1.43, 2023/02/10 04:56:30
Line 299 
Line 299 
  * Export the fingerprint of a key as a DNS resource record   * Export the fingerprint of a key as a DNS resource record
  */   */
 int  int
 export_dns_rr(const char *hostname, struct sshkey *key, FILE *f, int generic)  export_dns_rr(const char *hostname, struct sshkey *key, FILE *f, int generic,
       int alg)
 {  {
         u_int8_t rdata_pubkey_algorithm = 0;          u_int8_t rdata_pubkey_algorithm = 0;
         u_int8_t rdata_digest_type = SSHFP_HASH_RESERVED;          u_int8_t rdata_digest_type = SSHFP_HASH_RESERVED;
Line 309 
Line 310 
         int success = 0;          int success = 0;
   
         for (dtype = SSHFP_HASH_SHA1; dtype < SSHFP_HASH_MAX; dtype++) {          for (dtype = SSHFP_HASH_SHA1; dtype < SSHFP_HASH_MAX; dtype++) {
                   if (alg != -1 && dtype != alg)
                           continue;
                 rdata_digest_type = dtype;                  rdata_digest_type = dtype;
                 if (dns_read_key(&rdata_pubkey_algorithm, &rdata_digest_type,                  if (dns_read_key(&rdata_pubkey_algorithm, &rdata_digest_type,
                     &rdata_digest, &rdata_digest_len, key)) {                      &rdata_digest, &rdata_digest_len, key)) {

Legend:
Removed from v.1.42  
changed lines
  Added in v.1.43