mirror of
https://github.com/isc-projects/bind9.git
synced 2026-05-26 19:34:04 -04:00
Fix a bug in dns_tkey_processquery()
The 'keyname' variable could be used in the add_rdata_to_list()
call without being initialized. Make sure that 'keyname' is non-NULL
for all the cases that do not jump to the 'cleanup:' label.
(cherry picked from commit 172f5496ba)
This commit is contained in:
parent
527ec95456
commit
163db61ebd
1 changed files with 6 additions and 1 deletions
|
|
@ -420,7 +420,8 @@ dns_tkey_processquery(dns_message_t *msg, dns_tkeyctx_t *tctx,
|
|||
/*
|
||||
* A delete operation uses the fully specified qname.
|
||||
*/
|
||||
CHECK(process_deletetkey(signer, qname, &tkeyin, &tkeyout,
|
||||
keyname = qname;
|
||||
CHECK(process_deletetkey(signer, keyname, &tkeyin, &tkeyout,
|
||||
ring));
|
||||
break;
|
||||
case DNS_TKEYMODE_GSSAPI:
|
||||
|
|
@ -463,6 +464,10 @@ dns_tkey_processquery(dns_message_t *msg, dns_tkeyctx_t *tctx,
|
|||
result = DNS_R_NOTIMP;
|
||||
goto cleanup;
|
||||
default:
|
||||
/*
|
||||
* For unrecognized modes also use the fully specified qname.
|
||||
*/
|
||||
keyname = qname;
|
||||
tkeyout.error = dns_tsigerror_badmode;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue