Discuss this help topic in SecureBlackbox Forum

Create response to the SP manually

You should create an instance of TElSAMLResponseElement. At least TElSAMLResponseElement.ID, TElSAMLResponseElement.IssueInstant and TElSAMLResponseElement.Issuer properties must be filled. TElSAMLResponseElement.ID should be assigned to random string value, TElSAMLResponseElement.IssueInstant is a time of request creation, TElSAMLResponseElement.Issuer can be assigned to an instance of TElSAMLIssuerElement representing the issuer of the request. A Response should have TElSAMLResponseElement.Status property set to an instance of TElSAMLStatusElement.

TElSAMLResponseElement.SaveToXML() method can be used to save the request and append it to an existing TElXMLDOMDocument object.



	TElSAMLResponseElement resp = new TElSAMLResponseElement();

	resp.ID = SBRandom.Unit.SBRndString(20);
	resp.IssueInstant = DateTime.UtcNow;
	resp.InResponseTo = SBRandom.Unit.SBRndString(20); // request ID

	resp.Issuer = new TElSAMLIssuerElement();
	resp.Issuer.Value = “http://myidp.com”;

	resp.Status = new TElSAMLStatusElement();
	resp.Status.StatusCode = new TElSAMLStatusCodeElement();
	resp.Status.StatusCode.Value = SBXMLSAMLProtocol.Unit.xmlSAMLStatusSuccess;

How To articles about SAML Identity Provider (IdP)

Discuss this help topic in SecureBlackbox Forum