diff options
author | Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> | 2014-08-03 16:44:49 -0400 |
---|---|---|
committer | Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> | 2014-08-03 22:02:32 -0400 |
commit | ff3d6560bead6879a2fed1bf99bfe8273b3723f1 (patch) | |
tree | 4d69e1598f16bc613e6fd7d9febe0665184abcd2 /src/resolve/resolved-dns-packet.h | |
parent | 8db0d2f5c37e7e8f5bfce016cfdad7947a3ea939 (diff) |
resolved: add identifiers for dnssec algorithms
Diffstat (limited to 'src/resolve/resolved-dns-packet.h')
-rw-r--r-- | src/resolve/resolved-dns-packet.h | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/src/resolve/resolved-dns-packet.h b/src/resolve/resolved-dns-packet.h index 4e3001911e..f3b0f0c9eb 100644 --- a/src/resolve/resolved-dns-packet.h +++ b/src/resolve/resolved-dns-packet.h @@ -200,3 +200,19 @@ static inline uint16_t dnskey_to_flags(const DnsResourceRecord *rr) { return (rr->dnskey.zone_key_flag * DNSKEY_FLAG_ZONE_KEY | rr->dnskey.sep_flag * DNSKEY_FLAG_SEP); } + +/* http://tools.ietf.org/html/rfc4034#appendix-A.1 */ +enum { + DNSSEC_ALGORITHM_RSAMD5 = 1, + DNSSEC_ALGORITHM_DH, + DNSSEC_ALGORITHM_DSA, + DNSSEC_ALGORITHM_ECC, + DNSSEC_ALGORITHM_RSASHA1, + DNSSEC_ALGORITHM_INDIRECT = 252, + DNSSEC_ALGORITHM_PRIVATEDNS, + DNSSEC_ALGORITHM_PRIVATEOID, + _DNSSEC_ALGORITHM_MAX_DEFINED +}; + +const char* dnssec_algorithm_to_string(int i) _const_; +int dnssec_algorithm_from_string(const char *s) _pure_; |