0

Is adding an extra redudandant header to the HTTP request may cause any functionality harm?

for example:

Adding :

myheader=blablabla

Nimantha
  • 6,405
  • 6
  • 28
  • 69
dushkin
  • 1,939
  • 3
  • 37
  • 82

2 Answers2

0

An X- prefix was customary for those headers, but no longer. It shouldn't break anything as long as your headers are formatted correctly (so: myheader: blablabla, not myheader=blablabla)

Community
  • 1
  • 1
Wrikken
  • 69,272
  • 8
  • 97
  • 136
0

The HTTP 1.1 specification says (about entity headers);

Unrecognized header fields SHOULD be ignored by the recipient and MUST be forwarded by transparent proxies.

In other words - since the wording is SHOULD, not MUST - recipients are allowed to react to unknown headers, so technically your extra header could cause harm.

In practice though I have never seen a recipient do this, and with the surfacing of newer RFCs regarding custom header use seeing an adverse effect is very unlikely.

Community
  • 1
  • 1
Joachim Isaksson
  • 176,943
  • 25
  • 281
  • 294