Re: [systemd-devel] Howto find sshfp records?

2018-07-29 Thread Mantas Mikulėnas
On Sun, Jul 29, 2018 at 3:40 PM Stef Bon  wrote:

> Hi,
>
> I cannot find a header file where DNS_TYPE_SSHFP is defined,
> only in the source tree of systemd.
> There should be a header file in /usr/include. Where can I find it?
>

systemd doesn't seem to have a public header; however, glibc's
 appears to have `T_SSHFP` and `ns_t_sshfp` for the same
purpose.

You can also just add the definition directly in your code. The type number
is 44, as defined by https://tools.ietf.org/html/rfc4255 (section 5).

-- 
Mantas Mikulėnas
___
systemd-devel mailing list
systemd-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/systemd-devel


Re: [systemd-devel] Howto find sshfp records?

2018-07-29 Thread Stef Bon
Hi,

I cannot find a header file where DNS_TYPE_SSHFP is defined,
only in the source tree of systemd.
There should be a header file in /usr/include. Where can I find it?

Stef
___
systemd-devel mailing list
systemd-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/systemd-devel


Re: [systemd-devel] Howto find sshfp records?

2018-07-22 Thread Stef Bon
Op zo 22 jul. 2018 om 21:49 schreef Mantas Mikulėnas :

> How can I make it to find sshfp records?
>>
>
> From the same page, "Use ResolveRecord() in order to resolve arbitrary
> resource records. The call will return the binary RRset data. This calls is
> useful to acquire resource records for which no high-level calls such as
> ResolveHostname(), ResolveAddress() and ResolveService() exist. In
> particular RRs such as MX, SSHFP, TLSA, CERT, OPENPGPKEY or IPSECKEY may be
> requested via this API."
>

Yes I know there is a second example there, but can you give an example how
to use this ?

Thanks in advance
Stef

>
>
___
systemd-devel mailing list
systemd-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/systemd-devel


Re: [systemd-devel] Howto find sshfp records?

2018-07-22 Thread Mantas Mikulėnas
On Sun, Jul 22, 2018 at 10:29 PM Stef Bon  wrote:

> Hi,
>
> I'm writing a ssh client, and I want it to be able to do a dns lookup of
> sshfp records.
> The ipv4 address is known, as wel as the hostname.
> I've found the code about resolving:
>
> https://www.freedesktop.org/wiki/Software/systemd/writing-resolver-clients/
>
> How can I make it to find sshfp records?
>

>From the same page, "Use ResolveRecord() in order to resolve arbitrary
resource records. The call will return the binary RRset data. This calls is
useful to acquire resource records for which no high-level calls such as
ResolveHostname(), ResolveAddress() and ResolveService() exist. In
particular RRs such as MX, SSHFP, TLSA, CERT, OPENPGPKEY or IPSECKEY may be
requested via this API."

-- 
Mantas Mikulėnas
___
systemd-devel mailing list
systemd-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/systemd-devel


[systemd-devel] Howto find sshfp records?

2018-07-22 Thread Stef Bon
Hi,

I'm writing a ssh client, and I want it to be able to do a dns lookup of
sshfp records.
The ipv4 address is known, as wel as the hostname.
I've found the code about resolving:

https://www.freedesktop.org/wiki/Software/systemd/writing-resolver-clients/

How can I make it to find sshfp records?

Stef
___
systemd-devel mailing list
systemd-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/systemd-devel