Closed philandstuff closed 10 years ago
The use of single vs. double quotes in a Ruby array actually translates to a different header?
@philandstuff by chance do you have a snippet or screenshot of the effect?
The %(...)
construct is a quoting operator; those single and double quotes are part of the resultant string:
irb(main):001:0> %(Basic realm='Restricted Area')
=> "Basic realm='Restricted Area'"
irb(main):002:0> %(Basic realm="Restricted Area")
=> "Basic realm=\"Restricted Area\""
The effect is that you get you must log in to area "'Restricted" on <server>
when going to a sensu-dashboard instance in safari -- note the leading single quote before Restricted.
Yes, it's quite a minor bug :smile:
:+1:
A basic auth realm parameter is a quoted-string RFC2617§1.2; a quoted-string takes double quotes, not single quotes RFC2616§2.2.