summaryrefslogtreecommitdiffstats
path: root/src/DotNetOpenAuth.OpenId
diff options
context:
space:
mode:
Diffstat (limited to 'src/DotNetOpenAuth.OpenId')
-rw-r--r--src/DotNetOpenAuth.OpenId/OpenId/ChannelElements/OpenIdMessageFactory.cs47
-rw-r--r--src/DotNetOpenAuth.OpenId/OpenId/Extensions/UI/UIRequest.cs28
-rw-r--r--src/DotNetOpenAuth.OpenId/OpenId/Messages/AssociateDiffieHellmanRequest.cs19
3 files changed, 2 insertions, 92 deletions
diff --git a/src/DotNetOpenAuth.OpenId/OpenId/ChannelElements/OpenIdMessageFactory.cs b/src/DotNetOpenAuth.OpenId/OpenId/ChannelElements/OpenIdMessageFactory.cs
index 98bbffa..e73baa0 100644
--- a/src/DotNetOpenAuth.OpenId/OpenId/ChannelElements/OpenIdMessageFactory.cs
+++ b/src/DotNetOpenAuth.OpenId/OpenId/ChannelElements/OpenIdMessageFactory.cs
@@ -93,51 +93,8 @@ namespace DotNetOpenAuth.OpenId.ChannelElements {
/// A newly instantiated <see cref="IProtocolMessage"/>-derived object that this message can
/// deserialize to. Null if the request isn't recognized as a valid protocol message.
/// </returns>
- public IDirectResponseProtocolMessage GetNewResponseMessage(IDirectedProtocolMessage request, IDictionary<string, string> fields) {
- DirectResponseBase message = null;
-
- // Discern the OpenID version of the message.
- Protocol protocol = Protocol.V11;
- string ns;
- if (fields.TryGetValue(Protocol.V20.openidnp.ns, out ns)) {
- ErrorUtilities.VerifyProtocol(string.Equals(ns, Protocol.OpenId2Namespace, StringComparison.Ordinal), MessagingStrings.UnexpectedMessagePartValue, Protocol.V20.openidnp.ns, ns);
- protocol = Protocol.V20;
- }
-
- // Handle error messages generally.
- if (fields.ContainsKey(protocol.openidnp.error)) {
- message = new DirectErrorResponse(protocol.Version, request);
- }
-
- var associateRequest = request as AssociateRequest;
- if (associateRequest != null) {
- if (protocol.Version.Major >= 2 && fields.ContainsKey(protocol.openidnp.error_code)) {
- // This is a special recognized error case that we create a special message for.
- message = new AssociateUnsuccessfulResponse(protocol.Version, associateRequest);
- } else if (message == null) {
- var associateDiffieHellmanRequest = request as AssociateDiffieHellmanRequest;
- var associateUnencryptedRequest = request as AssociateUnencryptedRequest;
-
- if (associateDiffieHellmanRequest != null) {
- ////message = new AssociateDiffieHellmanResponse(protocol.Version, associateDiffieHellmanRequest);
- }
-
- if (associateUnencryptedRequest != null) {
- message = new AssociateUnencryptedResponse(protocol.Version, associateUnencryptedRequest);
- }
- }
- }
-
- var checkAuthenticationRequest = request as CheckAuthenticationRequest;
- if (checkAuthenticationRequest != null && message == null) {
- message = new CheckAuthenticationResponse(protocol.Version, checkAuthenticationRequest);
- }
-
- if (message != null) {
- message.SetAsIncoming();
- }
-
- return message;
+ public virtual IDirectResponseProtocolMessage GetNewResponseMessage(IDirectedProtocolMessage request, IDictionary<string, string> fields) {
+ return null;
}
#endregion
diff --git a/src/DotNetOpenAuth.OpenId/OpenId/Extensions/UI/UIRequest.cs b/src/DotNetOpenAuth.OpenId/OpenId/Extensions/UI/UIRequest.cs
index cf3054d..5e70311 100644
--- a/src/DotNetOpenAuth.OpenId/OpenId/Extensions/UI/UIRequest.cs
+++ b/src/DotNetOpenAuth.OpenId/OpenId/Extensions/UI/UIRequest.cs
@@ -188,34 +188,6 @@ namespace DotNetOpenAuth.OpenId.Extensions.UI {
}
}
- /////// <summary>
- /////// Gets the URL of the RP icon for the OP to display.
- /////// </summary>
- /////// <param name="realm">The realm of the RP where the authentication request originated.</param>
- /////// <param name="provider">The Provider instance used to obtain the authentication request.</param>
- /////// <returns>
- /////// A sequence of the RP's icons it has available for the Provider to display, in decreasing preferred order.
- /////// </returns>
- /////// <value>The icon URL.</value>
- /////// <remarks>
- /////// This property is automatically set for the OP with the result of RP discovery.
- /////// RPs should set this value by including an entry such as this in their XRDS document.
- /////// <example>
- /////// &lt;Service xmlns="xri://$xrd*($v*2.0)"&gt;
- /////// &lt;Type&gt;http://specs.openid.net/extensions/ui/icon&lt;/Type&gt;
- /////// &lt;URI&gt;http://consumer.example.com/images/image.jpg&lt;/URI&gt;
- /////// &lt;/Service&gt;
- /////// </example>
- /////// </remarks>
- ////public static IEnumerable<Uri> GetRelyingPartyIconUrls(Realm realm, OpenIdProvider provider) {
- //// Contract.Requires(realm != null);
- //// Contract.Requires(provider != null);
- //// ErrorUtilities.VerifyArgumentNotNull(realm, "realm");
- //// ErrorUtilities.VerifyArgumentNotNull(provider, "provider");
-
- //// return GetRelyingPartyIconUrls(realm, provider.Channel.WebRequestHandler);
- ////}
-
#region IMessage methods
/// <summary>
diff --git a/src/DotNetOpenAuth.OpenId/OpenId/Messages/AssociateDiffieHellmanRequest.cs b/src/DotNetOpenAuth.OpenId/OpenId/Messages/AssociateDiffieHellmanRequest.cs
index 43a554c..5accf26 100644
--- a/src/DotNetOpenAuth.OpenId/OpenId/Messages/AssociateDiffieHellmanRequest.cs
+++ b/src/DotNetOpenAuth.OpenId/OpenId/Messages/AssociateDiffieHellmanRequest.cs
@@ -96,24 +96,5 @@ namespace DotNetOpenAuth.OpenId.Messages {
byte[] consumerPublicKeyExchange = this.Algorithm.CreateKeyExchange();
this.DiffieHellmanConsumerPublic = DiffieHellmanUtilities.EnsurePositive(consumerPublicKeyExchange);
}
-
- /// <summary>
- /// Creates a Provider's response to an incoming association request.
- /// </summary>
- /// <returns>
- /// The appropriate association response message.
- /// </returns>
- /// <remarks>
- /// <para>If an association can be successfully created, the
- /// <see cref="AssociateSuccessfulResponse.CreateAssociation"/> method must not be
- /// called by this method.</para>
- /// <para>Successful association response messages will derive from <see cref="AssociateSuccessfulResponse"/>.
- /// Failed association response messages will derive from <see cref="AssociateUnsuccessfulResponse"/>.</para>
- /// </remarks>
- ////protected /*override */ IProtocolMessage CreateResponseCore() {
- //// var response = new AssociateDiffieHellmanResponse(this.Version, this);
- //// response.AssociationType = this.AssociationType;
- //// return response;
- ////}
}
}