Mobile app version of vmapp.org
Login or Join
Nimeshi995

: How to use apache mod-rewrite to remove trailing semi-colon on cookie? We have the following cookie set by a product: Set-Cookie: SSOCookie=T7ngsCmzC2FEq5p2a7o%3D; path=/; domain=.demo.com; We would

@Nimeshi995

Posted in: #Apache #Cookie #ModRewrite

We have the following cookie set by a product:

Set-Cookie: SSOCookie=T7ngsCmzC2FEq5p2a7o%3D; path=/; domain=.demo.com;


We would like to use Apache to remove the trailing ; which doesn't match the Cookie specification. Can we use mod_rewrite? How?

We are using Apache/2.0.47.

10.01% popularity Vote Up Vote Down


Login to follow query

More posts by @Nimeshi995

1 Comments

Sorted by latest first Latest Oldest Best

 

@Ogunnowo487

As you are referring to a Set-Cookie header, this must be in reference to a response being sent by the product to which you refer.

Assuming you cannot fix the product nor can the vendor, you will need to modify the response headers as required. You can't achieve this with mod_rewrite; it is for manipulating request URLs only.

mod_headers is described as as being for the "[c]ustomization of HTTP request and response headers". Examine the documentation for the 'edit' action.

10% popularity Vote Up Vote Down


Back to top | Use Dark Theme