anchor.diff:      CookieData=generate_session_data(UserName,ExpirationTime,SessionExtraData,FSessionKey,ServerKey),
       mochiweb_cookies:cookie("id",CookieData,[{max_age,20000},{local_time,calendar:universal_time_to_local_time(calendar:universal_time())}]).
   
  -
   %% @spec cookie_check_session(RawData,ExpirationTime,FSessionKey : function(A), ServerKey)->{false,[UserName,Expiration,Data]} | 
   %%                                                                                          {false,[]}                         |
   %%                                                                                          {true,[UserName,Expiration,Data]}
  
positive.code: 	    end
      end;
  check_session_cookie(A,_,_,_,_) ->
      io:format("what the hell ~p~n",[A]),
      {false,[]}.
  
  %% @doc This does not encrypt the whole cookie
  cookie_decode (Encoded) ->
      erlang:binary_to_term (hexstr_to_bin(Encoded)).
  cookie_encode (Term) ->
      bin_to_hexstr(erlang:term_to_binary (Term, [compressed,{minor_version,1}])).
  
  %% cookie_encrypt_data(Data,Key)-> binary()
  %%                                Data = Key = iolist() | binary
  
negative.code: cookie_gen_hmac(UserName,ExpirationTime,Data,SessionKey,Key)->
      crypto:sha_mac(Key,[UserName,ExpirationTime,Data,SessionKey]).
  
  %% @doc Using 
  cookie_decode (Encoded) ->
      erlang:binary_to_term(hexstr_to_bin(Encoded)).
  cookie_encode (Term) ->
      bin_to_hexstr(erlang:term_to_binary (Term, [compressed,{minor_version,1}])).
  
  bin_to_hexstr(Bin) ->
    lists:flatten([io_lib:format("~2.16.0B", [X]) ||
  