public Response(byte[] certificate) { RSAPKCS1SHA256SignatureDescription.Init(); //init the SHA256 crypto provider (for needed for .NET 4.0 and lower) _certificate = new Certificate(); _certificate.LoadCertificate(certificate); }
public AuthRequest(string issuer, string assertionConsumerServiceUrl) { RSAPKCS1SHA256SignatureDescription.Init(); //init the SHA256 crypto provider (for needed for .NET 4.0 and lower) _id = "_" + System.Guid.NewGuid().ToString(); _issue_instant = DateTime.Now.ToUniversalTime().ToString("yyyy-MM-ddTHH:mm:ssZ"); _issuer = issuer; _assertionConsumerServiceUrl = assertionConsumerServiceUrl; }
public SignoutRequest(string issuer, string nameId, string logoutCallbackUrl) { RSAPKCS1SHA256SignatureDescription.Init(); //init the SHA256 crypto provider (for needed for .NET 4.0 and lower) _id = "_" + Guid.NewGuid().ToString(); _issue_instant = DateTime.Now.ToUniversalTime().ToString("yyyy-MM-ddTHH:mm:ssZ", System.Globalization.CultureInfo.InvariantCulture); _issuer = issuer; _nameId = nameId; _logoutCallbackUrl = logoutCallbackUrl; }
public Response(byte[] certificateBytes) { RSAPKCS1SHA256SignatureDescription.Init(); //init the SHA256 crypto provider (for needed for .NET 4.0 and lower) try { _certificate = new X509Certificate2(certificateBytes); } catch (Exception ex) { throw new LoadCertificateException("Failed to load certificate", ex); } }
public AuthRequest(string issuer, string assertionConsumerServiceUrl) { RSAPKCS1SHA256SignatureDescription.Init(); //init the SHA256 crypto provider (for needed for .NET 4.0 and lower) if (issuer == null || assertionConsumerServiceUrl == null) { throw new NullReferenceException(); } _id = "_" + Guid.NewGuid().ToString(); _issue_instant = DateTime.Now.ToUniversalTime().ToString("yyyy-MM-ddTHH:mm:ssZ", System.Globalization.CultureInfo.InvariantCulture); _issuer = issuer; _assertionConsumerServiceUrl = assertionConsumerServiceUrl; }
public BaseResponse(byte[] certificateBytes) { RSAPKCS1SHA256SignatureDescription.Init(); //init the SHA256 crypto provider (for needed for .NET 4.0 and lower) _certificate = new X509Certificate2(certificateBytes); }