mirror of
https://gitlab.isc.org/isc-projects/bind9
synced 2025-09-03 16:15:27 +00:00
3953. [bug] Don't escape semi-colon in TXT fields. [RT #37159]
This commit is contained in:
2
CHANGES
2
CHANGES
@@ -1,3 +1,5 @@
|
|||||||
|
3953. [bug] Don't escape semi-colon in TXT fields. [RT #37159]
|
||||||
|
|
||||||
3952. [bug] dns_name_fullcompare failed to set *nlabelsp when the
|
3952. [bug] dns_name_fullcompare failed to set *nlabelsp when the
|
||||||
two name pointers were the same. [RT #37176]
|
two name pointers were the same. [RT #37176]
|
||||||
|
|
||||||
|
@@ -121,6 +121,9 @@ txt09 TXT foo\010bar
|
|||||||
txt10 TXT foo\ bar
|
txt10 TXT foo\ bar
|
||||||
txt11 TXT "\"foo\""
|
txt11 TXT "\"foo\""
|
||||||
txt12 TXT \"foo\"
|
txt12 TXT \"foo\"
|
||||||
|
txt13 TXT "foo;"
|
||||||
|
txt14 TXT "foo\;"
|
||||||
|
txt15 TXT "bar\\;"
|
||||||
|
|
||||||
; type 17
|
; type 17
|
||||||
rp01 RP mbox-dname txt-dname
|
rp01 RP mbox-dname txt-dname
|
||||||
|
@@ -90,6 +90,9 @@ txt09.example. 3600 IN TXT "foo\010bar"
|
|||||||
txt10.example. 3600 IN TXT "foo bar"
|
txt10.example. 3600 IN TXT "foo bar"
|
||||||
txt11.example. 3600 IN TXT "\"foo\""
|
txt11.example. 3600 IN TXT "\"foo\""
|
||||||
txt12.example. 3600 IN TXT "\"foo\""
|
txt12.example. 3600 IN TXT "\"foo\""
|
||||||
|
txt13.example. 3600 IN TXT "foo;"
|
||||||
|
txt14.example. 3600 IN TXT "foo;"
|
||||||
|
txt15.example. 3600 IN TXT "bar\\;"
|
||||||
uri01.example. 3600 IN URI 10 20 "https://www.isc.org/"
|
uri01.example. 3600 IN URI 10 20 "https://www.isc.org/"
|
||||||
uri02.example. 3600 IN URI 30 40 "https://www.isc.org/HolyCowThisSureIsAVeryLongURIRecordIDontEvenKnowWhatSomeoneWouldEverWantWithSuchAThingButTheSpecificationRequiresThatWesupportItSoHereWeGoTestingItLaLaLaLaLaLaLaSeriouslyThoughWhyWouldYouEvenConsiderUsingAURIThisLongItSeemsLikeASillyIdeaButEnhWhatAreYouGonnaDo/"
|
uri02.example. 3600 IN URI 30 40 "https://www.isc.org/HolyCowThisSureIsAVeryLongURIRecordIDontEvenKnowWhatSomeoneWouldEverWantWithSuchAThingButTheSpecificationRequiresThatWesupportItSoHereWeGoTestingItLaLaLaLaLaLaLaSeriouslyThoughWhyWouldYouEvenConsiderUsingAURIThisLongItSeemsLikeASillyIdeaButEnhWhatAreYouGonnaDo/"
|
||||||
uri03.example. 3600 IN URI 30 40 ""
|
uri03.example. 3600 IN URI 30 40 ""
|
||||||
|
@@ -90,6 +90,9 @@ txt09.example. 3600 IN TXT "foo\010bar"
|
|||||||
txt10.example. 3600 IN TXT "foo bar"
|
txt10.example. 3600 IN TXT "foo bar"
|
||||||
txt11.example. 3600 IN TXT "\"foo\""
|
txt11.example. 3600 IN TXT "\"foo\""
|
||||||
txt12.example. 3600 IN TXT "\"foo\""
|
txt12.example. 3600 IN TXT "\"foo\""
|
||||||
|
txt13.example. 3600 IN TXT "foo;"
|
||||||
|
txt14.example. 3600 IN TXT "foo;"
|
||||||
|
txt15.example. 3600 IN TXT "bar\\;"
|
||||||
uri01.example. 3600 IN URI 10 20 "https://www.isc.org/"
|
uri01.example. 3600 IN URI 10 20 "https://www.isc.org/"
|
||||||
uri02.example. 3600 IN URI 30 40 "https://www.isc.org/HolyCowThisSureIsAVeryLongURIRecordIDontEvenKnowWhatSomeoneWouldEverWantWithSuchAThingButTheSpecificationRequiresThatWesupportItSoHereWeGoTestingItLaLaLaLaLaLaLaSeriouslyThoughWhyWouldYouEvenConsiderUsingAURIThisLongItSeemsLikeASillyIdeaButEnhWhatAreYouGonnaDo/"
|
uri02.example. 3600 IN URI 30 40 "https://www.isc.org/HolyCowThisSureIsAVeryLongURIRecordIDontEvenKnowWhatSomeoneWouldEverWantWithSuchAThingButTheSpecificationRequiresThatWesupportItSoHereWeGoTestingItLaLaLaLaLaLaLaSeriouslyThoughWhyWouldYouEvenConsiderUsingAURIThisLongItSeemsLikeASillyIdeaButEnhWhatAreYouGonnaDo/"
|
||||||
uri03.example. 3600 IN URI 30 40 ""
|
uri03.example. 3600 IN URI 30 40 ""
|
||||||
|
@@ -1167,12 +1167,12 @@ txt_totext(isc_region_t *source, isc_boolean_t quote, isc_buffer_t *target) {
|
|||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
/*
|
/*
|
||||||
* Escape double quote, semi-colon, backslash.
|
* Escape double quote and backslash. If we are not
|
||||||
* If we are not enclosing the string in double
|
* enclosing the string in double quotes also escape
|
||||||
* quotes also escape at sign.
|
* at sign and semicolon.
|
||||||
*/
|
*/
|
||||||
if (*sp == 0x22 || *sp == 0x3b || *sp == 0x5c ||
|
if (*sp == 0x22 || *sp == 0x5c ||
|
||||||
(!quote && *sp == 0x40)) {
|
(!quote && (*sp == 0x40 || *sp == 0x3b))) {
|
||||||
if (tl < 2)
|
if (tl < 2)
|
||||||
return (ISC_R_NOSPACE);
|
return (ISC_R_NOSPACE);
|
||||||
*tp++ = '\\';
|
*tp++ = '\\';
|
||||||
|
Reference in New Issue
Block a user