public string ToString(bool corchetes) { string format = null; if (corchetes) { format = "{0}=\"{1}\""; } else { format = "{0}={1}"; } return(string.Format(CultureInfo.InvariantCulture, format, OAuthEncoder.UrlEncode(Clave), OAuthEncoder.UrlEncode(Valor))); }
private string GenerarFirma() { string signatureBaseString = string.Format( CultureInfo.InvariantCulture, "{2}&{0}&{1}", OAuthEncoder.UrlEncode(RequestUriWithoutQuery.Normalizar()), OAuthEncoder.UrlEncode(GetSignParameters()), Verb); string key = string.Format( CultureInfo.InvariantCulture, "{0}&{1}", OAuthEncoder.UrlEncode(ConsumerSecret.Valor), OAuthEncoder.UrlEncode(TokenSecret.Valor)); return(OAuthEncoder.GenerarHash(signatureBaseString, key)); }