http://www.perlmonks.org?node_id=11132732


in reply to Re: Saving HTTP::Cookies into Netscape format using bless/re-bless
in thread Saving HTTP::Cookies into Netscape format using bless/re-bless

Your approach looks to me to be the safest way for the particular case of cookie-transformation.