Encapsulates the ArtificatResponse schema class
        /// <summary>
        /// Gets a default instance of this class with proper values set.
        /// </summary>
        /// <returns></returns>
        public static Saml20ArtifactResponse GetDefault()
        {
            Saml20ArtifactResponse result = new Saml20ArtifactResponse();

            SAML20FederationConfig config = SAML20FederationConfig.GetConfig();

            if (config.ServiceProvider == null || string.IsNullOrEmpty(config.ServiceProvider.ID))
            {
                throw new Saml20FormatException(Resources.ServiceProviderNotSet);
            }

            result.Issuer = config.ServiceProvider.ID;

            return(result);
        }
Exemplo n.º 2
0
        /// <summary>
        /// Gets a default instance of this class with proper values set.
        /// </summary>
        /// <returns></returns>
        public static Saml20ArtifactResponse GetDefault()
        {
            Saml20ArtifactResponse result = new Saml20ArtifactResponse();

            SAML20FederationConfig config = SAML20FederationConfig.GetConfig();

            if (config.ServiceProvider == null || string.IsNullOrEmpty(config.ServiceProvider.ID))
                throw new Saml20FormatException(Resources.ServiceProviderNotSet);

            result.Issuer = config.ServiceProvider.ID;

            return result;
        }