6
6
7
7
namespace RestSharp . Authenticators . OAuth
8
8
{
9
- #if ! SILVERLIGHT && ! WINDOWS_PHONE && ! PocketPC
9
+ #if ! SILVERLIGHT && ! WINDOWS_PHONE
10
10
[ Serializable ]
11
11
#endif
12
12
internal static class OAuthTools
@@ -20,13 +20,13 @@ internal static class OAuthTools
20
20
private static readonly Random _random ;
21
21
private static readonly object _randomLock = new object ( ) ;
22
22
23
- #if ! SILVERLIGHT && ! WINDOWS_PHONE && ! PocketPC
23
+ #if ! SILVERLIGHT && ! WINDOWS_PHONE
24
24
private static readonly RandomNumberGenerator _rng = RandomNumberGenerator . Create ( ) ;
25
25
#endif
26
26
27
27
static OAuthTools ( )
28
28
{
29
- #if ! SILVERLIGHT && ! WINDOWS_PHONE && ! PocketPC
29
+ #if ! SILVERLIGHT && ! WINDOWS_PHONE
30
30
var bytes = new byte [ 4 ] ;
31
31
_rng . GetNonZeroBytes ( bytes ) ;
32
32
_random = new Random ( BitConverter . ToInt32 ( bytes , 0 ) ) ;
@@ -312,7 +312,6 @@ public static string GetSignature(OAuthSignatureMethod signatureMethod,
312
312
313
313
switch ( signatureMethod )
314
314
{
315
- #if ! PocketPC
316
315
case OAuthSignatureMethod . HmacSha1 :
317
316
{
318
317
var crypto = new HMACSHA1 ( ) ;
@@ -323,7 +322,6 @@ public static string GetSignature(OAuthSignatureMethod signatureMethod,
323
322
324
323
break ;
325
324
}
326
- #endif
327
325
328
326
case OAuthSignatureMethod . PlainText :
329
327
{
@@ -333,11 +331,7 @@ public static string GetSignature(OAuthSignatureMethod signatureMethod,
333
331
}
334
332
335
333
default :
336
- #if PocketPC
337
- throw new NotImplementedException ( "Only PlainText is currently supported." ) ;
338
- #else
339
334
throw new NotImplementedException ( "Only HMAC-SHA1 is currently supported." ) ;
340
- #endif
341
335
}
342
336
343
337
var result = signatureTreatment == OAuthSignatureTreatment . Escaped
0 commit comments