javagrizzly

Is there a way to remove a header in Grizzly server?


Currently Grizzly server sends a header to client side, which we don't want to send.

Header which we want to hide is:

WWW-Authenticate: Basic

I see org.glassfish.grizzly.http.server.Response class has option to set the value of this header to different one, but we want to hide this header itself.

Is there any other way to remove the header?

Thanks In Advance, Soman


Solution

  • Try: org.glassfish.grizzly.http.server.Response.getResponse().getHeaders().removeHeader()