Netflix / denominator

Portably control DNS clouds using java or bash
Apache License 2.0
580 stars 110 forks source link

Spaces in rdata cause only first word to be used #371

Closed quinncomendant closed 9 years ago

quinncomendant commented 9 years ago

Hi Guys,

I've encountered what may be a pretty serious bug.

I tried to add a TXT record, v=spf1 include:example.com -all but the result was only the first word (v=spf1) was added to the record. Here's a test:

[q@localhost ~] denominator -q -p mock record -z denominator.io. add -n denominator.io. -t TXT -d "ONE TWO THREE"
;; in zone denominator.io. adding to rrset denominator.io. TXT values: [{txtdata=ONE}]
;; ok

Notice the txtdata=ONE in the status output.

Is this a problem with java parsing multi-word arguments?

Denominator 4.5.0 Java version: 1.8.0_45

codefromthecrypt commented 9 years ago

"Is this a problem with java parsing multi-word arguments" heh pretty sure I can create this bug in any language :P

quinncomendant commented 9 years ago

Ha. But hey I was just throwing in a red herring so you could claim innocence. If in doubt, blame java ;P

codefromthecrypt commented 9 years ago

Fixed via f16d173f64004751c5df99d38673e2af9af1ed0b

codefromthecrypt commented 9 years ago

released as 4.7.1 https://github.com/Homebrew/homebrew/pull/44116

itsjohannawren commented 8 years ago

I hate to dredge up closed issues, but Denominator supports SPF records (type 99) which will definitely contain spaces. This should probably include those as well.