Permalink
Browse files

Merge branch 'v3.2' into gsa

  • Loading branch information...
AArnott committed Sep 9, 2009
2 parents c0f1c84 + 6513d4d commit 637fb7dd7c44f4a36e45bc18122cf035038c775f
Showing with 2,068 additions and 261 deletions.
  1. +5 −2 build.proj
  2. +116 −0 doc/api/Web.config
  3. +35 −0 doc/api/default.aspx
  4. BIN lib/DotNetOpenAuth.BuildTasks.dll
  5. BIN lib/DotNetOpenAuth.BuildTasks.pdb
  6. +19 −0 lib/DotNetOpenAuth.BuildTasks.targets
  7. BIN lib/DotNetOpenId.BuildTasks.dll
  8. BIN lib/DotNetOpenId.BuildTasks.pdb
  9. +0 −12 lib/DotNetOpenId.BuildTasks.targets
  10. +34 −0 samples/OAuthConsumerWpf/App.config
  11. +7 −8 samples/OAuthConsumerWpf/Authorize.xaml.cs
  12. +71 −45 samples/OAuthConsumerWpf/MainWindow.xaml
  13. +79 −12 samples/OAuthConsumerWpf/MainWindow.xaml.cs
  14. +36 −0 samples/OAuthConsumerWpf/OAuthConsumerWpf.csproj
  15. +4 −0 samples/OAuthConsumerWpf/Service References/WcfSampleService/DataApi.disco
  16. +310 −0 samples/OAuthConsumerWpf/Service References/WcfSampleService/DataApi.wsdl
  17. +9 −0 samples/OAuthConsumerWpf/Service References/WcfSampleService/DataApi.xsd
  18. +40 −0 samples/OAuthConsumerWpf/Service References/WcfSampleService/DataApi1.xsd
  19. +42 −0 samples/OAuthConsumerWpf/Service References/WcfSampleService/DataApi2.xsd
  20. +67 −0 samples/OAuthConsumerWpf/Service References/WcfSampleService/Reference.cs
  21. +33 −0 samples/OAuthConsumerWpf/Service References/WcfSampleService/Reference.svcmap
  22. +10 −0 samples/OAuthConsumerWpf/Service References/WcfSampleService/configuration.svcinfo
  23. +210 −0 samples/OAuthConsumerWpf/Service References/WcfSampleService/configuration91.svcinfo
  24. +9 −4 samples/OAuthServiceProvider/App_Code/DataApi.cs
  25. +8 −1 samples/OAuthServiceProvider/App_Code/OAuthAuthorizationManager.cs
  26. +1 −1 samples/OAuthServiceProvider/App_Code/OAuthConsumer.cs
  27. +1 −1 samples/OAuthServiceProvider/App_Code/OAuthToken.cs
  28. +26 −0 samples/OAuthServiceProvider/App_Code/Utilities.cs
  29. +3 −0 samples/OAuthServiceProvider/Default.aspx
  30. +1 −1 samples/OpenIdProviderMvc/Controllers/UserController.cs
  31. +4 −0 samples/OpenIdProviderMvc/Web.config
  32. +4 −2 samples/OpenIdProviderWebForms/Web.config
  33. +2 −1 samples/OpenIdRelyingPartyMvc/Controllers/UserController.cs
  34. +4 −0 samples/OpenIdRelyingPartyMvc/Web.config
  35. +6 −2 samples/OpenIdRelyingPartyWebForms/Web.config
  36. +4 −0 samples/OpenIdRelyingPartyWebForms/ajaxlogin.aspx
  37. +1 −0 src/DotNetOpenAuth.Test/DotNetOpenAuth.Test.csproj
  38. +11 −7 src/DotNetOpenAuth.Test/Hosting/HostingTests.cs
  39. +44 −0 src/DotNetOpenAuth.Test/Messaging/HttpRequestInfoTests.cs
  40. +1 −1 src/DotNetOpenAuth.Test/Messaging/Reflection/MessagePartTests.cs
  41. +42 −0 src/DotNetOpenAuth.Test/Mocks/MockRealm.cs
  42. +1 −1 src/DotNetOpenAuth.Test/OpenId/ChannelElements/SigningBindingElementTests.cs
  43. +13 −0 src/DotNetOpenAuth.Test/OpenId/OpenIdTestBase.cs
  44. +14 −9 src/DotNetOpenAuth.Test/OpenId/Provider/OpenIdProviderTests.cs
  45. +41 −0 src/DotNetOpenAuth.Test/OpenId/RelyingParty/OpenIdRelyingPartyTests.cs
  46. +12 −0 src/DotNetOpenAuth.Test/OpenId/RelyingParty/PositiveAuthenticationResponseTests.cs
  47. +3 −0 src/DotNetOpenAuth.sln
  48. +69 −64 src/DotNetOpenAuth.vsmdi
  49. +2 −0 src/DotNetOpenAuth/Configuration/OAuthConsumerSecuritySettingsElement.cs
  50. +17 −1 src/DotNetOpenAuth/Configuration/TypeConfigurationElement.cs
  51. +2 −0 src/DotNetOpenAuth/DotNetOpenAuth.csproj
  52. +2 −0 src/DotNetOpenAuth/GlobalSuppressions.cs
  53. +49 −4 src/DotNetOpenAuth/InfoCard/InfoCardSelector.cs
  54. +10 −1 src/DotNetOpenAuth/InfoCard/InfoCardStrings.Designer.cs
  55. +3 −0 src/DotNetOpenAuth/InfoCard/InfoCardStrings.resx
  56. +2 −2 src/DotNetOpenAuth/Messaging/Bindings/NonceMemoryStore.cs
  57. +1 −1 src/DotNetOpenAuth/Messaging/Bindings/StandardExpirationBindingElement.cs
  58. +2 −0 src/DotNetOpenAuth/Messaging/HostErrorException.cs
  59. +5 −6 src/DotNetOpenAuth/Messaging/HttpRequestInfo.cs
  60. +1 −0 src/DotNetOpenAuth/Messaging/MessageReceivingEndpoint.cs
  61. +26 −0 src/DotNetOpenAuth/Messaging/MessagingUtilities.cs
  62. +1 −1 src/DotNetOpenAuth/Messaging/Reflection/MessagePart.cs
  63. +3 −0 src/DotNetOpenAuth/OAuth/ChannelElements/IServiceProviderAccessToken.cs
  64. +5 −2 src/DotNetOpenAuth/OAuth/ChannelElements/OAuthChannel.cs
  65. +2 −0 src/DotNetOpenAuth/OAuth/ChannelElements/OAuthIdentity.cs
  66. +2 −0 src/DotNetOpenAuth/OAuth/ChannelElements/OAuthPrincipal.cs
  67. +1 −1 src/DotNetOpenAuth/OAuth/ChannelElements/OAuthServiceProviderMessageFactory.cs
  68. +3 −3 src/DotNetOpenAuth/OAuth/ChannelElements/TokenHandlingBindingElement.cs
  69. +1 −0 src/DotNetOpenAuth/OAuth/Messages/MessageBase.cs
  70. +2 −0 src/DotNetOpenAuth/OAuth/Messages/UnauthorizedTokenResponse.cs
  71. +1 −0 src/DotNetOpenAuth/OAuth/Messages/UserAuthorizationRequest.cs
  72. +1 −0 src/DotNetOpenAuth/OAuth/Messages/UserAuthorizationResponse.cs
  73. +2 −0 src/DotNetOpenAuth/OAuth/Protocol.cs
  74. +24 −3 src/DotNetOpenAuth/OAuth/ServiceProvider.cs
  75. +4 −0 src/DotNetOpenAuth/OAuth/VerificationCodeFormat.cs
  76. +1 −1 src/DotNetOpenAuth/OpenId/Association.cs
  77. +2 −0 src/DotNetOpenAuth/OpenId/Behaviors/AXFetchAsSregTransform.cs
  78. +3 −0 src/DotNetOpenAuth/OpenId/Behaviors/PpidGeneration.cs
  79. +16 −15 src/DotNetOpenAuth/OpenId/ChannelElements/ExtensionsBindingElement.cs
  80. +2 −2 src/DotNetOpenAuth/OpenId/DiffieHellmanUtilities.cs
  81. +1 −1 src/DotNetOpenAuth/OpenId/Extensions/AttributeExchange/AXAttributeFormats.cs
  82. +3 −0 src/DotNetOpenAuth/OpenId/Extensions/ExtensionsInteropHelper.cs
  83. +2 −1 src/DotNetOpenAuth/OpenId/Extensions/ProviderAuthenticationPolicy/DateTimeEncoder.cs
  84. +1 −1 src/DotNetOpenAuth/OpenId/Extensions/ProviderAuthenticationPolicy/PolicyResponse.cs
  85. +2 −0 src/DotNetOpenAuth/OpenId/Extensions/SimpleRegistration/ClaimsRequest.cs
  86. +28 −0 src/DotNetOpenAuth/OpenId/Extensions/UI/UIConstants.cs
  87. +20 −5 src/DotNetOpenAuth/OpenId/Extensions/UI/UIRequest.cs
  88. +2 −2 src/DotNetOpenAuth/OpenId/HmacShaAssociation.cs
  89. +10 −0 src/DotNetOpenAuth/OpenId/Identifier.cs
  90. +9 −9 src/DotNetOpenAuth/OpenId/Interop/OpenIdRelyingPartyShim.cs
  91. +1 −1 src/DotNetOpenAuth/OpenId/Messages/IndirectSignedResponse.cs
  92. +28 −1 src/DotNetOpenAuth/OpenId/OpenIdStrings.Designer.cs
  93. +10 −1 src/DotNetOpenAuth/OpenId/OpenIdStrings.resx
  94. +2 −0 src/DotNetOpenAuth/OpenId/Provider/AnonymousRequest.cs
  95. +0 −1 src/DotNetOpenAuth/OpenId/Provider/HostProcessedRequest.cs
  96. +1 −2 src/DotNetOpenAuth/OpenId/Provider/IDirectedIdentityIdentifierProvider.cs
  97. +1 −1 src/DotNetOpenAuth/OpenId/Provider/OpenIdProvider.cs
  98. +4 −1 src/DotNetOpenAuth/OpenId/Provider/PrivatePersonalIdentifierProviderBase.cs
  99. +2 −2 src/DotNetOpenAuth/OpenId/Realm.cs
  100. +1 −0 src/DotNetOpenAuth/OpenId/RelyingParty/OpenIdButton.cs
  101. +10 −0 src/DotNetOpenAuth/OpenId/RelyingParty/OpenIdRelyingParty.cs
  102. +0 −1 src/DotNetOpenAuth/OpenId/RelyingParty/OpenIdRelyingPartyAjaxControlBase.cs
  103. +10 −1 src/DotNetOpenAuth/OpenId/RelyingParty/PositiveAuthenticationResponse.cs
  104. +115 −0 src/DotNetOpenAuth/OpenId/RelyingParty/SimpleXrdsProviderEndpoint.cs
  105. +3 −3 src/DotNetOpenAuth/OpenId/RelyingParty/StandardRelyingPartyApplicationStore.cs
  106. +5 −0 src/DotNetOpenAuth/OpenId/RelyingParty/WellKnownProviders.cs
  107. +4 −0 src/DotNetOpenAuth/OpenId/RelyingPartyDescription.cs
  108. +14 −6 src/DotNetOpenAuth/OpenId/UriIdentifier.cs
  109. +3 −0 src/DotNetOpenAuth/OpenId/XriIdentifier.cs
  110. +1 −1 src/version.txt
  111. +1 −1 tools/DotNetOpenAuth.Versioning.targets
  112. +122 −0 tools/Publish.targets
  113. +1 −1 tools/Sandcastle/Presentation/vs2005/Content/feedBack_content.xml
  114. +1 −1 tools/Sandcastle/Presentation/vs2005/Content/shared_content.xml
View
@@ -7,14 +7,15 @@
<Import Project="$(ProjectRoot)\tools\$(ProductName).Versioning.targets"/>
<Import Project="$(ProjectRoot)\tools\Documentation.targets"/>
<Import Project="$(ProjectRoot)\tools\Publish.targets"/>
<UsingTask AssemblyFile="$(ProjectRoot)\lib\MSBuild.Community.Tasks.dll" TaskName="Zip"/>
<ItemGroup>
<SampleProjects Include="$(ProjectRoot)\samples\**\*.csproj" />
<SampleSites Include="OAuthConsumer;OAuthServiceProvider;InfoCardRelyingParty" />
</ItemGroup>
<Target Name="Clean" DependsOnTargets="CleanDocumentation">
<Target Name="Clean" DependsOnTargets="CleanDocumentation;UnpublishSamples;UnpublishDocumentation">
<MSBuild Projects="$(SolutionPath)" Targets="Clean" />
<ItemGroup>
<DirtyDirectories Include="
@@ -239,7 +240,9 @@
<Zip Files="@(AllDropTargets)" ZipFileName="$(DropZip)" WorkingDirectory="$(ProjectRoot)\drops" />
</Target>
<Target Name="Nightly" DependsOnTargets="Drop;Tools">
<!-- Although Nightly includes publishing samples and docs, those targets are conditioned for
running only when the SampleWebRoot and DocWebRoot properties are set, respectively. -->
<Target Name="Nightly" DependsOnTargets="Drop;Tools;PublishSamples;PublishDocumentation">
</Target>
View
@@ -0,0 +1,116 @@
<?xml version="1.0"?>
<!--
Note: As an alternative to hand editing this file you can use the
web admin tool to configure settings for your application. Use
the Website->Asp.Net Configuration option in Visual Studio.
A full list of settings and comments can be found in
machine.config.comments usually located in
\Windows\Microsoft.Net\Framework\v2.x\Config
-->
<configuration>
<configSections>
<sectionGroup name="system.web.extensions" type="System.Web.Configuration.SystemWebExtensionsSectionGroup, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
<sectionGroup name="scripting" type="System.Web.Configuration.ScriptingSectionGroup, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
<section name="scriptResourceHandler" type="System.Web.Configuration.ScriptingScriptResourceHandlerSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" allowDefinition="MachineToApplication"/>
<sectionGroup name="webServices" type="System.Web.Configuration.ScriptingWebServicesSectionGroup, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
<section name="jsonSerialization" type="System.Web.Configuration.ScriptingJsonSerializationSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" allowDefinition="Everywhere"/>
<section name="profileService" type="System.Web.Configuration.ScriptingProfileServiceSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" allowDefinition="MachineToApplication"/>
<section name="authenticationService" type="System.Web.Configuration.ScriptingAuthenticationServiceSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" allowDefinition="MachineToApplication"/>
<section name="roleService" type="System.Web.Configuration.ScriptingRoleServiceSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" allowDefinition="MachineToApplication"/>
</sectionGroup>
</sectionGroup>
</sectionGroup>
</configSections>
<appSettings/>
<connectionStrings/>
<system.web>
<!--
Set compilation debug="true" to insert debugging
symbols into the compiled page. Because this
affects performance, set this value to true only
during development.
-->
<compilation debug="false">
<assemblies>
<add assembly="System.Core, Version=3.5.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/>
<add assembly="System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
<add assembly="System.Xml.Linq, Version=3.5.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/>
<add assembly="System.Data.DataSetExtensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/>
</assemblies>
</compilation>
<!--
The <authentication> section enables configuration
of the security authentication mode used by
ASP.NET to identify an incoming user.
-->
<authentication mode="Windows"/>
<!--
The <customErrors> section enables configuration
of what to do if/when an unhandled error occurs
during the execution of a request. Specifically,
it enables developers to configure html error pages
to be displayed in place of a error stack trace.
<customErrors mode="RemoteOnly" defaultRedirect="GenericErrorPage.htm">
<error statusCode="403" redirect="NoAccess.htm" />
<error statusCode="404" redirect="FileNotFound.htm" />
</customErrors>
-->
<pages>
<controls>
<add tagPrefix="asp" namespace="System.Web.UI" assembly="System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
<add tagPrefix="asp" namespace="System.Web.UI.WebControls" assembly="System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
</controls>
</pages>
<httpHandlers>
<remove verb="*" path="*.asmx"/>
<add verb="*" path="*.asmx" validate="false" type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
<add verb="*" path="*_AppService.axd" validate="false" type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
<add verb="GET,HEAD" path="ScriptResource.axd" validate="false" type="System.Web.Handlers.ScriptResourceHandler, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
</httpHandlers>
<httpModules>
<add name="ScriptModule" type="System.Web.Handlers.ScriptModule, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
</httpModules>
</system.web>
<system.codedom>
<compilers>
<compiler language="c#;cs;csharp" extension=".cs" type="Microsoft.CSharp.CSharpCodeProvider,System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" warningLevel="4">
<providerOption name="CompilerVersion" value="v3.5"/>
<providerOption name="WarnAsError" value="false"/>
</compiler>
<compiler language="vb;vbs;visualbasic;vbscript" extension=".vb" type="Microsoft.VisualBasic.VBCodeProvider, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" warningLevel="4">
<providerOption name="CompilerVersion" value="v3.5"/>
<providerOption name="OptionInfer" value="true"/>
<providerOption name="WarnAsError" value="false"/>
</compiler>
</compilers>
</system.codedom>
<system.webServer>
<validation validateIntegratedModeConfiguration="false"/>
<modules>
<remove name="ScriptModule"/>
<add name="ScriptModule" preCondition="managedHandler" type="System.Web.Handlers.ScriptModule, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
</modules>
<handlers>
<remove name="WebServiceHandlerFactory-Integrated"/>
<remove name="ScriptHandlerFactory"/>
<remove name="ScriptHandlerFactoryAppServices"/>
<remove name="ScriptResource"/>
<add name="ScriptHandlerFactory" verb="*" path="*.asmx" preCondition="integratedMode" type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
<add name="ScriptHandlerFactoryAppServices" verb="*" path="*_AppService.axd" preCondition="integratedMode" type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
<add name="ScriptResource" verb="GET,HEAD" path="ScriptResource.axd" preCondition="integratedMode" type="System.Web.Handlers.ScriptResourceHandler, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
</handlers>
</system.webServer>
<runtime>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly>
<assemblyIdentity name="System.Web.Extensions" publicKeyToken="31bf3856ad364e35"/>
<bindingRedirect oldVersion="1.0.0.0-1.1.0.0" newVersion="3.5.0.0"/>
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="System.Web.Extensions.Design" publicKeyToken="31bf3856ad364e35"/>
<bindingRedirect oldVersion="1.0.0.0-1.1.0.0" newVersion="3.5.0.0"/>
</dependentAssembly>
</assemblyBinding>
</runtime>
</configuration>
View
@@ -0,0 +1,35 @@
<%@ Page Language="C#" %>
<%@ Import Namespace="System.IO" %>
<%@ Import Namespace="System.Linq" %>
<script runat="server">
protected virtual void Page_Load(object sender, EventArgs e) {
string apiPath = Path.GetDirectoryName(Request.PhysicalPath);
string htmlPath = Path.Combine(apiPath, "html");
var namespaceFiles = Directory.GetFiles(htmlPath, "N_*.htm*").Select(ns => Path.GetFileName(ns));
NamespaceRepeater.DataSource = namespaceFiles.Select(ns => new {
Href = "html/" + ns,
Title = Path.GetFileNameWithoutExtension(ns).Substring(2).Replace("_", "."),
});
NamespaceRepeater.DataBind();
}
</script>
<html>
<head>
<title>DotNetOpenAuth API documentation</title>
</head>
<body>
<h1>DotNetOpenAuth API documentation</h1>
<h2>Documentation by namespace</h2>
<ul>
<asp:Repeater runat="server" ID="NamespaceRepeater">
<ItemTemplate>
<li><a href="<%# Eval("Href") %>">
<%# Eval("Title") %></a></li>
</ItemTemplate>
</asp:Repeater>
</ul>
</body>
</html>
Binary file not shown.
Binary file not shown.
@@ -0,0 +1,19 @@
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" ToolsVersion="3.5">
<PropertyGroup>
<ProjectRoot Condition="'$(ProjectRoot)' == ''">$(MSBuildProjectDirectory)\..\..</ProjectRoot>
</PropertyGroup>
<UsingTask AssemblyFile="$(ProjectRoot)\lib\DotNetOpenAuth.BuildTasks.dll" TaskName="GetBuildVersion" />
<UsingTask AssemblyFile="$(ProjectRoot)\lib\DotNetOpenAuth.BuildTasks.dll" TaskName="SetEnvironmentVariable" />
<UsingTask AssemblyFile="$(ProjectRoot)\lib\DotNetOpenAuth.BuildTasks.dll" TaskName="ChangeProjectReferenceToAssemblyReference" />
<UsingTask AssemblyFile="$(ProjectRoot)\lib\DotNetOpenAuth.BuildTasks.dll" TaskName="CompareFiles" />
<UsingTask AssemblyFile="$(ProjectRoot)\lib\DotNetOpenAuth.BuildTasks.dll" TaskName="ReSignDelaySignedAssemblies" />
<UsingTask AssemblyFile="$(ProjectRoot)\lib\DotNetOpenAuth.BuildTasks.dll" TaskName="SignatureVerification" />
<UsingTask AssemblyFile="$(ProjectRoot)\lib\DotNetOpenAuth.BuildTasks.dll" TaskName="CheckAdminRights" />
<UsingTask AssemblyFile="$(ProjectRoot)\lib\DotNetOpenAuth.BuildTasks.dll" TaskName="CreateWebApplication" />
<UsingTask AssemblyFile="$(ProjectRoot)\lib\DotNetOpenAuth.BuildTasks.dll" TaskName="DeleteWebApplication" />
<UsingTask AssemblyFile="$(ProjectRoot)\lib\DotNetOpenAuth.BuildTasks.dll" TaskName="Trim" />
<UsingTask AssemblyFile="$(ProjectRoot)\lib\DotNetOpenAuth.BuildTasks.dll" TaskName="FilterItems" />
</Project>
Binary file not shown.
Binary file not shown.

This file was deleted.

Oops, something went wrong.
@@ -57,4 +57,38 @@
<level value="ALL" />
</logger>
</log4net>
<system.serviceModel>
<bindings>
<wsHttpBinding>
<binding name="WSHttpBinding_IDataApi" closeTimeout="00:01:00"
openTimeout="00:01:00" receiveTimeout="00:10:00" sendTimeout="00:01:00"
bypassProxyOnLocal="false" transactionFlow="false" hostNameComparisonMode="StrongWildcard"
maxBufferPoolSize="524288" maxReceivedMessageSize="65536"
messageEncoding="Text" textEncoding="utf-8" useDefaultWebProxy="true"
allowCookies="false">
<readerQuotas maxDepth="32" maxStringContentLength="8192" maxArrayLength="16384"
maxBytesPerRead="4096" maxNameTableCharCount="16384" />
<reliableSession ordered="true" inactivityTimeout="00:10:00"
enabled="false" />
<security mode="Message">
<transport clientCredentialType="Windows" proxyCredentialType="None"
realm="">
<extendedProtectionPolicy policyEnforcement="Never" />
</transport>
<message clientCredentialType="Windows" negotiateServiceCredential="true"
algorithmSuite="Default" establishSecurityContext="true" />
</security>
</binding>
</wsHttpBinding>
</bindings>
<client>
<endpoint address="http://localhost:65169/OAuthServiceProvider/DataApi.svc"
binding="wsHttpBinding" bindingConfiguration="WSHttpBinding_IDataApi"
contract="WcfSampleService.IDataApi" name="WSHttpBinding_IDataApi">
<identity>
<dns value="localhost" />
</identity>
</endpoint>
</client>
</system.serviceModel>
</configuration>
@@ -20,20 +20,17 @@
/// Interaction logic for Authorize.xaml
/// </summary>
public partial class Authorize : Window {
private DesktopConsumer google;
private DesktopConsumer consumer;
private string requestToken;
internal Authorize(DesktopConsumer consumer) {
internal Authorize(DesktopConsumer consumer, FetchUri fetchUriCallback) {
InitializeComponent();
this.google = consumer;
this.consumer = consumer;
Cursor original = this.Cursor;
this.Cursor = Cursors.Wait;
ThreadPool.QueueUserWorkItem(delegate(object state) {
Uri browserAuthorizationLocation = GoogleConsumer.RequestAuthorization(
this.google,
GoogleConsumer.Applications.Contacts | GoogleConsumer.Applications.Blogger,
out this.requestToken);
Uri browserAuthorizationLocation = fetchUriCallback(this.consumer, out this.requestToken);
System.Diagnostics.Process.Start(browserAuthorizationLocation.AbsoluteUri);
this.Dispatcher.BeginInvoke(new Action(() => {
this.Cursor = original;
@@ -42,10 +39,12 @@ public partial class Authorize : Window {
});
}
internal delegate Uri FetchUri(DesktopConsumer consumer, out string requestToken);
internal string AccessToken { get; set; }
private void finishButton_Click(object sender, RoutedEventArgs e) {
var grantedAccess = this.google.ProcessUserAuthorization(this.requestToken, verifierBox.Text);
var grantedAccess = this.consumer.ProcessUserAuthorization(this.requestToken, verifierBox.Text);
this.AccessToken = grantedAccess.AccessToken;
DialogResult = true;
Close();
Oops, something went wrong.

0 comments on commit 637fb7d

Please sign in to comment.