Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Possible to get query owner without trailing dot? #49

Open
maxenglander opened this issue Sep 23, 2019 · 0 comments
Open

Possible to get query owner without trailing dot? #49

maxenglander opened this issue Sep 23, 2019 · 0 comments

Comments

@maxenglander
Copy link

When extracting the owner from an ldns packet, it seems a trailing dot is always appended. Is it possible to get the owner without trailing dot?

Possibly relevant:

ldns/examples/ldns-mx.c

Lines 46 to 50 in 2131ed5

/* ldns_dname_new_frm_str makes absolute dnames always!
* So deabsolutify domain.
* TODO: Create ldns_dname_new_frm_str_relative? Yuck!
*/
ldns_rdf_set_size(domain, ldns_rdf_size(domain) - 1);

query

$ dig @127.0.0.1 google.com

server

fprintf(stdout, "owner: %s\n", ldns_rdf2str(ldns_rr_owner(...)));

stdout

owner: google.com.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant