Ltm v10.2 Remove HttpOnly from cookie
Hi All,
i need a help about removing "HttpOnly" from a cookie.
I got this cookie below and i would like to remove HttpOnly from it.
Set-Cookie: JSESSIONID=PppHQh1V51nRpcH0QJJNsldV0sjLcFKzndTd2PhGMKNp20nHprzd!1975339553; path=/; HttpOnly
i tried with stream profile with no success.
Here is the code of streamprofile
profile stream stream_http_only {
defaults from stream
source "HttpOnly"
target none
}
i tried also with irule below but no success again.
when HTTP_RESPONSE {
Check if there are any Set-Cookie headers
if {[HTTP::header exists "Set-Cookie"]}{
Loop through each Set-Cookie header remove the HttpOnly option
foreach a_set_cookie_value [HTTP::header values "Set-Cookie"] {
log local0. "[IP::client_addr]:[TCP::client_port]: Current Set-Cookie value: [HTTP::header value $a_set_cookie_value], \
updated value [string map -nocase {HttpOnly ""} [HTTP::header value $a_set_cookie_value]]"
HTTP::header replace Set-Cookie [string map -nocase {HttpOnly ""} [HTTP::header value $a_set_cookie_value]]
}
}
}
Log from this irule is
Oct 4 12:07:10 local/tmm info tmm[4931]: Rule irule_rem_http_only : 10.130.102.92:44306: Current Set-Cookie value: , updated value
Oct 4 12:07:10 local/tmm info tmm[4931]: Rule irule_rem_http_only : 10.130.102.92:44306: Current Set-Cookie value: , updated value
Please help me.