cookie encryption
in aFleX
I am working on an aflex to encrypt the value of a cookie when sending it to the client, and decrypting it when sending it to the server. Is there a way to improve the b64encode security. IOW, how do I get better encryption of the cookie. Here is what I have so far:
when HTTP_RESPONSE {
set decrypted [HTTP::cookie "cookiename"]
if { not ($decrypted equals "") } {
set encrypted [b64encode $decrypted]
HTTP::cookie remove "cookiename"
HTTP::cookie insert name "cookiename" value $encrypted
}
}
when HTTP_REQUEST {
set encrypted [HTTP::cookie "cookiename"]
if { not ($encrypted equals "") } {
set decrypted [b64decode $encrypted]
HTTP::cookie remove "cookiename"
HTTP::cookie insert name "cookiename" value $decrypted
}
}
0