2

I launched the node express on my localhost:3000..

**curl -H 'samlresponse:12323' -v http://localhost:3000 , returns data correctly.

but if I tried following...

curl -H 'samlresponse:{here is the entire samlresponse, it's very long..almost 20k..}' -v http://localhost:3000

The server always return "Empty reply from server", is there a way to passby or fix this issue?

Yinjun Zhang
  • 275
  • 1
  • 3
  • 8

1 Answers1

3

Source Code of node at github says:

/* Maximium header size allowed. If the macro is not defined
 * before including this header then the default is used. To
 * change the maximum header size, define the macro in the build
 * environment (e.g. -DHTTP_MAX_HEADER_SIZE=<value>). To remove
 * the effective limit on the size of the header, define the macro
 * to a very large number (e.g. -DHTTP_MAX_HEADER_SIZE=0x7fffffff)
 */
#ifndef HTTP_MAX_HEADER_SIZE
# define HTTP_MAX_HEADER_SIZE (80*1024)
#endif

So, you probably need to rebuild node from source to surpass the limit of 80*1024. But, personally I think that, it is large enough for a header, and you should re-evaulate whether your statergy is correct.

Iceman
  • 6,035
  • 2
  • 23
  • 34