anchor.diff:          _                     -> Bin
       end.
   
  --spec decrypt_value(#radius_request{}, binary(), eradius_dict:attribute_encryption()) -> eradius_dict:attr_value().
  -decrypt_value(Req,  <<Val/binary>>, scramble)   -> scramble(Req#radius_request.secret, Req#radius_request.authenticator, Val);
  -decrypt_value(Req,  <<Val/binary>>, salt_crypt) -> salt_decrypt(Req#radius_request.secret, Req#radius_request.authenticator, Val);
  -decrypt_value(_Req, <<Val/binary>>, no)         -> Val.
  +-spec decrypt_value(#radius_request{}, #decoder_state{}, binary(),
  +		    eradius_dict:attribute_encryption()) -> eradius_dict:attr_value().
  +decrypt_value(#radius_request{secret = Secret, authenticator = Authenticator},
  +	      _, <<Val/binary>>, scramble) ->
  +    scramble(Secret, Authenticator, Val);
  +decrypt_value(#radius_request{secret = Secret},
  +	      #decoder_state{request_authenticator = RequestAuthenticator},
  +	      <<Val/binary>>, salt_crypt)
  +when is_binary(RequestAuthenticator) ->
  +    salt_decrypt(Secret, RequestAuthenticator, Val);
  +decrypt_value(_Req, _State, <<Val/binary>>, _Type) ->
  +    Val.
   
   -spec decode_vendor_specific_attribute(#radius_request{}, non_neg_integer(), binary(), non_neg_integer(), #decoder_state{}) -> #decoder_state{}.
   decode_vendor_specific_attribute(_Req, _VendorID, <<>>, _Pos, State) ->
  
positive.code: %% -- Wire Decoding
  
  -record(decoder_state, {
  	  attrs = []       :: eradius_lib:attribute_list(),
  	  hmac_pos         :: 'undefined' | non_neg_integer(),
  	  eap_msg = []     :: [binary()]
  
negative.code: 
  -spec salt_encrypt(salt(), secret(), authenticator(), binary()) -> binary().
  salt_encrypt(Salt, SharedSecret, RequestAuthenticator, PlainText) ->
      CipherText = do_salt_crypt(encrypt, Salt, SharedSecret, RequestAuthenticator, (pad_to(16, << (byte_size(PlainText)):8, PlainText/binary >>))),
      <<Salt/binary, CipherText/binary>>.
  
  -spec salt_decrypt(secret(), authenticator(), binary()) -> binary().
  salt_decrypt(SharedSecret, RequestAuthenticator, <<Salt:2/binary, CipherText/binary>>) ->
      << Length:8/integer, PlainText/binary >> = do_salt_crypt(decrypt, Salt, SharedSecret, RequestAuthenticator, CipherText),
      if
          Length < byte_size(PlainText) ->
              binary:part(PlainText, 0, Length);
  