Метод | Описание | |
---|---|---|
ConcatenateRequestElements ( string method, string url, WebParameterCollection parameters ) : string |
Creates a request elements concatentation value to send with a request. This is also known as the signature base.
|
|
ConstructRequestUrl ( |
Creates a request URL suitable for making OAuth requests. Resulting URLs must exclude port 80 or port 443 when accompanied by HTTP and HTTPS, respectively. Resulting URLs must be lower case.
|
|
GetNonce ( ) : string |
Generates a random 16-byte lowercase alphanumeric string.
|
|
GetSignature ( OAuthSignatureMethod signatureMethod, OAuthSignatureTreatment signatureTreatment, string signatureBase, string consumerSecret ) : string |
Creates a signature value given a signature base and the consumer secret. This method is used when the token secret is currently unknown.
|
|
GetSignature ( OAuthSignatureMethod signatureMethod, OAuthSignatureTreatment signatureTreatment, string signatureBase, string consumerSecret, string tokenSecret ) : string |
Creates a signature value given a signature base and the consumer secret and a known token secret.
|
|
GetSignature ( OAuthSignatureMethod signatureMethod, string signatureBase, string consumerSecret ) : string |
Creates a signature value given a signature base and the consumer secret. This method is used when the token secret is currently unknown.
|
|
GetSignature ( OAuthSignatureMethod signatureMethod, string signatureBase, string consumerSecret, string tokenSecret ) : string |
Creates a signature value given a signature base and the consumer secret and a known token secret.
|
|
GetTimestamp ( ) : string |
Generates a timestamp based on the current elapsed seconds since '01/01/1970 0000 GMT"
|
|
GetTimestamp ( System.DateTime dateTime ) : string |
Generates a timestamp based on the elapsed seconds of a given time since '01/01/1970 0000 GMT"
|
|
NormalizeRequestParameters ( WebParameterCollection parameters ) : string |
Sorts a collection of key-value pairs by name, and then value if equal, concatenating them into a single string. This string should be encoded prior to, or after normalization is run.
|
|
SortParametersExcludingSignature ( WebParameterCollection parameters ) : WebParameterCollection |
Sorts a WebParameterCollection by name, and then value if equal.
|
|
UrlEncodeRelaxed ( string value ) : string |
URL encodes a string based on section 5.1 of the OAuth spec. Namely, percent encoding with [RFC3986], avoiding unreserved characters, upper-casing hexadecimal characters, and UTF-8 encoding for text value pairs.
|
|
UrlEncodeStrict ( string value ) : string |
URL encodes a string based on section 5.1 of the OAuth spec. Namely, percent encoding with [RFC3986], avoiding unreserved characters, upper-casing hexadecimal characters, and UTF-8 encoding for text value pairs.
|
Метод | Описание | |
---|---|---|
Concatenate ( ICollection |
||
EqualsIgnoreCase ( string left, string right ) : bool | ||
HashWith ( string input, |
||
IsNullOrBlank ( string value ) : bool | ||
OAuthTools ( ) : System | ||
PercentEncode ( string s ) : string | ||
ToUnixTime ( System.DateTime dateTime ) : long |
public static ConcatenateRequestElements ( string method, string url, WebParameterCollection parameters ) : string | ||
method | string | The request's HTTP method type |
url | string | The request URL |
parameters | WebParameterCollection | The request's parameters |
Результат | string |
public static ConstructRequestUrl ( |
||
url | The original request URL | |
Результат | string |
public static GetSignature ( OAuthSignatureMethod signatureMethod, OAuthSignatureTreatment signatureTreatment, string signatureBase, string consumerSecret ) : string | ||
signatureMethod | OAuthSignatureMethod | The hashing method |
signatureTreatment | OAuthSignatureTreatment | The treatment to use on a signature value |
signatureBase | string | The signature base |
consumerSecret | string | The consumer key |
Результат | string |
public static GetSignature ( OAuthSignatureMethod signatureMethod, OAuthSignatureTreatment signatureTreatment, string signatureBase, string consumerSecret, string tokenSecret ) : string | ||
signatureMethod | OAuthSignatureMethod | The hashing method |
signatureTreatment | OAuthSignatureTreatment | The treatment to use on a signature value |
signatureBase | string | The signature base |
consumerSecret | string | The consumer secret |
tokenSecret | string | The token secret |
Результат | string |
public static GetSignature ( OAuthSignatureMethod signatureMethod, string signatureBase, string consumerSecret ) : string | ||
signatureMethod | OAuthSignatureMethod | The hashing method |
signatureBase | string | The signature base |
consumerSecret | string | The consumer key |
Результат | string |
public static GetSignature ( OAuthSignatureMethod signatureMethod, string signatureBase, string consumerSecret, string tokenSecret ) : string | ||
signatureMethod | OAuthSignatureMethod | The hashing method |
signatureBase | string | The signature base |
consumerSecret | string | The consumer secret |
tokenSecret | string | The token secret |
Результат | string |
public static GetTimestamp ( System.DateTime dateTime ) : string | ||
dateTime | System.DateTime | A specified point in time. |
Результат | string |
public static NormalizeRequestParameters ( WebParameterCollection parameters ) : string | ||
parameters | WebParameterCollection | |
Результат | string |
public static SortParametersExcludingSignature ( WebParameterCollection parameters ) : WebParameterCollection | ||
parameters | WebParameterCollection | A collection of parameters to sort |
Результат | WebParameterCollection |
public static UrlEncodeRelaxed ( string value ) : string | ||
value | string | |
Результат | string |
public static UrlEncodeStrict ( string value ) : string | ||
value | string | |
Результат | string |