//-----------------------------------------------------------------------
//
// Copyright (c) Outercurve Foundation. All rights reserved.
//
//-----------------------------------------------------------------------
namespace DotNetOpenAuth.OpenId.Provider {
using System;
using System.Net.Http;
using System.Threading;
using System.Threading.Tasks;
using DotNetOpenAuth.Messaging;
using DotNetOpenAuth.OpenId.Messages;
using Validation;
///
/// Interface exposing incoming messages to the OpenID Provider that
/// require interaction with the host site.
///
public interface IHostProcessedRequest : IRequest {
///
/// Gets the version of OpenID being used by the relying party that sent the request.
///
ProtocolVersion RelyingPartyVersion { get; }
///
/// Gets the URL the consumer site claims to use as its 'base' address.
///
Realm Realm { get; }
///
/// Gets a value indicating whether the consumer demands an immediate response.
/// If false, the consumer is willing to wait for the identity provider
/// to authenticate the user.
///
bool Immediate { get; }
///
/// Gets or sets the provider endpoint claimed in the positive assertion.
///
///
/// The default value is the URL that the request came in on from the relying party.
/// This value MUST match the value for the OP Endpoint in the discovery results for the
/// claimed identifier being asserted in a positive response.
///
Uri ProviderEndpoint { get; set; }
///
/// Attempts to perform relying party discovery of the return URL claimed by the Relying Party.
///
/// The host factories.
/// The cancellation token.
///
/// The details of how successful the relying party discovery was.
///
///
/// Return URL verification is only attempted if this method is called.
/// See OpenID Authentication 2.0 spec section 9.2.1.
///
Task IsReturnUrlDiscoverableAsync(IHostFactories hostFactories, CancellationToken cancellationToken = default(CancellationToken));
}
}