diff options
author | Florian Weimer <fweimer@redhat.com> | 2020-02-07 18:48:04 +0100 |
---|---|---|
committer | Florian Weimer <fweimer@redhat.com> | 2020-02-07 18:48:04 +0100 |
commit | d4e209d35564eecdc006ab9f5b10bc8494c6f1f9 (patch) | |
tree | 306e97edbabf692ede994582347d53b622571411 /resolv | |
parent | 814309f0c226fc1f2c4eb6a042d74df6f496db23 (diff) | |
download | glibc-d4e209d35564eecdc006ab9f5b10bc8494c6f1f9.tar.gz glibc-d4e209d35564eecdc006ab9f5b10bc8494c6f1f9.tar.xz glibc-d4e209d35564eecdc006ab9f5b10bc8494c6f1f9.zip |
resolv: Fix CNAME chaining in resolv/tst-resolv-ai_idn-common.c
The second CNAME record optionally generated by the response function used the question name, not the redirected name from the first CNAME. This breaks the chain and results in failures of these IDNA tests if CNAME owner names are checked as expected (which the current implementation does not do).
Diffstat (limited to 'resolv')
-rw-r--r-- | resolv/tst-resolv-ai_idn-common.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/resolv/tst-resolv-ai_idn-common.c b/resolv/tst-resolv-ai_idn-common.c index 9e8ed7611c..97eb617cfa 100644 --- a/resolv/tst-resolv-ai_idn-common.c +++ b/resolv/tst-resolv-ai_idn-common.c @@ -219,8 +219,9 @@ response (const struct resolv_response_context *ctx, } if (with_idn_cname) { + const char *previous_name = next_name; next_name = ANDERES_NAEMCHEN_IDNA ".example"; - resolv_response_open_record (b, qname, C_IN, T_CNAME, 0); + resolv_response_open_record (b, previous_name, C_IN, T_CNAME, 0); resolv_response_add_name (b, next_name); resolv_response_close_record (b); } |