[getdns-users] GetDNSapi for Erlang

Rick van Rein rick at openfortress.nl
Sun Jul 2 19:46:58 UTC 2017


Hey Willem,

>> Is anyone aware of work that has been done to make GetDNSapi work with
>> Erlang?  DuckDuckGo seems to have misplaced the answers to this one :)
>
> I don't know for sure, but I vaguely remember that Linus Nordberg (on
> the CC) was interested in getdns bindings for Erlang for his CT for
> DNSSEC work and I believe he looked into this at some point.

Thanks.  It is very strange to hit a language these days with barely
any support for DNS and DNSSEC!  But that's what GetDNS is all about
of course.

But I have come to realise that my question was too hasty...
the extensive dictionaries generated by GetDNS are very close to a
scripted or dynamic language, and Erlang being function and dynamic
in nature I thought the match would work.

In the end however, I realised that the Unbound API is much closer
to Erlang in style, because it is easier to use with pattern matching
on an output record with bogus/secure/... flags.  The extra work
needed for parsing the RDATA is easy because Erlang even does
pattern matching in binaries:

case SrvRDATA of
   << _:48, $. >> -> ...unavailable...;
   << Priority:16, Weight:16, Port:16, Target >> ) -> ...act...
end

In comparison, I believe pattern matching GetDNS's dictionaries
would be more difficult.  I saw a link with the message-passing
between minute processes (Go adopted the same style) on account
of event-driven GetDNS, but that is not unique about GetDNS, of
course.

Hope I'm not disappointing you with this :)

Thanks,
 -Rick



More information about the Users mailing list