diff --git a/src/bin/d2/d2_lexer.ll b/src/bin/d2/d2_lexer.ll index d3d1c4caee..14c3411aca 100644 --- a/src/bin/d2/d2_lexer.ll +++ b/src/bin/d2/d2_lexer.ll @@ -329,6 +329,8 @@ ControlCharacterFill [^"\\]|\\["\\/bfnrtu] switch(driver.ctx_) { case isc::d2::D2ParserContext::DDNS_DOMAIN: case isc::d2::D2ParserContext::DDNS_DOMAINS: + case isc::d2::D2ParserContext::DNS_SERVER: + case isc::d2::D2ParserContext::DNS_SERVERS: return isc::d2::D2Parser::make_KEY_NAME(driver.loc_); default: return isc::d2::D2Parser::make_STRING("key-name", driver.loc_); diff --git a/src/bin/d2/d2_parser.yy b/src/bin/d2/d2_parser.yy index 796ff239d6..f6bc82cfaa 100644 --- a/src/bin/d2/d2_parser.yy +++ b/src/bin/d2/d2_parser.yy @@ -456,7 +456,7 @@ ddns_domain_params: ddns_domain_param ; ddns_domain_param: ddns_domain_name - | ddns_domain_key_name + | ddns_key_name | dns_servers | user_context | comment @@ -477,7 +477,7 @@ ddns_domain_name: NAME { ctx.leave(); }; -ddns_domain_key_name: KEY_NAME { +ddns_key_name: KEY_NAME { ctx.unique("key-name", ctx.loc2pos(@1)); ctx.enter(ctx.NO_KEYWORD); } COLON STRING { @@ -534,6 +534,7 @@ dns_server_params: dns_server_param dns_server_param: dns_server_hostname | dns_server_ip_address | dns_server_port + | ddns_key_name | user_context | comment | unknown_map_entry