diff options
author | Andrew Arnott <andrewarnott@gmail.com> | 2008-09-13 17:20:53 -0700 |
---|---|---|
committer | Andrew <andrewarnott@gmail.com> | 2008-09-13 17:20:53 -0700 |
commit | 09722c436047dccfb6b6294906013786f78d5d53 (patch) | |
tree | b266c794ee5662235063e0ec37d6b938674084f6 /src/DotNetOAuth/OAuthChannel.cs | |
parent | f665e1e639319918385fcc8397f8c0d5009e3bdd (diff) | |
download | DotNetOpenAuth-09722c436047dccfb6b6294906013786f78d5d53.zip DotNetOpenAuth-09722c436047dccfb6b6294906013786f78d5d53.tar.gz DotNetOpenAuth-09722c436047dccfb6b6294906013786f78d5d53.tar.bz2 |
Refactored several Messaging classes into the Messaging.Bindings namespace.
Diffstat (limited to 'src/DotNetOAuth/OAuthChannel.cs')
-rw-r--r-- | src/DotNetOAuth/OAuthChannel.cs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/DotNetOAuth/OAuthChannel.cs b/src/DotNetOAuth/OAuthChannel.cs index 5ca973e..47f445f 100644 --- a/src/DotNetOAuth/OAuthChannel.cs +++ b/src/DotNetOAuth/OAuthChannel.cs @@ -195,11 +195,12 @@ namespace DotNetOAuth { private HttpWebRequest InitializeRequestAsAuthHeader(IDirectedProtocolMessage requestMessage) {
var serializer = MessageSerializer.Get(requestMessage.GetType());
var fields = serializer.Serialize(requestMessage);
+ var protocol = Protocol.Lookup(requestMessage.ProtocolVersion);
HttpWebRequest httpRequest = (HttpWebRequest)WebRequest.Create(requestMessage.Recipient);
StringBuilder authorization = new StringBuilder();
- authorization.Append(requestMessage.Protocol.AuthorizationHeaderScheme);
+ authorization.Append(protocol.AuthorizationHeaderScheme);
authorization.Append(" ");
foreach (var pair in fields) {
string key = Uri.EscapeDataString(pair.Key);
|