public void SetSignature(string httpMethod, Uri url, NameValueCollection parameters) { this["oauth_signature"] = OAuthUtility.GetSignature(httpMethod, url, this.ConsumerSecret, this.TokenSecret, parameters, this).ToString(); }
/// <summary> /// Sets signature. /// </summary> /// <param name="httpMethod">The HTTP method: <b>GET</b> or <b>POST</b>. Default is <b>POST</b>.</param> /// <param name="url">The request URI.</param> /// <param name="tokenSecret">The token secret.</param> /// <param name="parameters">The query parameters.</param> /// <param name="applicationSecret">The application secret key obtained from the provider website.</param> public void SetSignature(string httpMethod, Uri url, string applicationSecret, string tokenSecret, NameValueCollection parameters) { this["oauth_signature"] = OAuthUtility.GetSignature(httpMethod, url, applicationSecret, tokenSecret, parameters, this); }
public OAuthSignature GetSignature(string httpMethod, Uri url, string tokenSecret, NameValueCollection parameters) { return(OAuthUtility.GetSignature(httpMethod, url, this.ApplicationSecret, tokenSecret, parameters, this.Authorization)); }
/// <summary> /// Gets signature for the current request. /// </summary> /// <param name="httpMethod">The HTTP method: <b>GET</b> or <b>POST</b>. Default is <b>POST</b>.</param> /// <param name="url">The request URI.</param> /// <param name="tokenSecret">The token secret.</param> /// <param name="parameters">The query parameters.</param> /// <param name="applicationSecret">The application secret key obtained from the provider website.</param> /// <param name="authorization">The authorization parameters.</param> public static OAuthSignature GetSignature(string httpMethod, string url, string applicationSecret, string tokenSecret, NameValueCollection parameters, OAuthAuthorization authorization) { return(OAuthUtility.GetSignature(httpMethod, new Uri(url), applicationSecret, tokenSecret, parameters, authorization)); }