# SAMLWriter Class

The SAMLWriter class offers SAML message generation functions.

## Class Name

**SecureBlackbox_SAMLWriter**

## Procedural Interface

```text
 secureblackbox_samlwriter_open();
 secureblackbox_samlwriter_close($res);
 secureblackbox_samlwriter_register_callback($res, $id, $function);
 secureblackbox_samlwriter_get_last_error($res);
 secureblackbox_samlwriter_get_last_error_code($res);
 secureblackbox_samlwriter_set($res, $id, $index, $value);
 secureblackbox_samlwriter_get($res, $id, $index);
 secureblackbox_samlwriter_do_addattribute($res, $attributename, $attributevalue, $nameformat, $contenttype, $statementindex);
 secureblackbox_samlwriter_do_addattributestatement($res);
 secureblackbox_samlwriter_do_addauthnstatement($res, $authninstant, $sessionindex, $notonorafter, $classref);
 secureblackbox_samlwriter_do_addauthzdecisionstatement($res, $decision, $evidence, $resource, $actions);
 secureblackbox_samlwriter_do_addcondition($res, $conditiontype, $conditionvalue);
 secureblackbox_samlwriter_do_addscopingidp($res, $name, $providerid, $loc);
 secureblackbox_samlwriter_do_addsubjectconfirmation($res, $method, $address, $recipient, $inresponseto, $notbefore, $notonorafter, $id, $datatype, $data);
 secureblackbox_samlwriter_do_beginassertion($res);
 secureblackbox_samlwriter_do_completeassertion($res);
 secureblackbox_samlwriter_do_config($res, $configurationstring);
 secureblackbox_samlwriter_do_createnew($res, $contenttype);
 secureblackbox_samlwriter_do_doaction($res, $actionid, $actionparams);
 secureblackbox_samlwriter_do_formatid($res, $value, $idtype, $format, $namequalifier, $spnamequalifier, $spprovidedid);
 secureblackbox_samlwriter_do_reset($res);
 secureblackbox_samlwriter_do_save($res);
 secureblackbox_samlwriter_do_savebytes($res);
 secureblackbox_samlwriter_do_savefile($res, $filename);
```

## Remarks

SAMLWriter provides means of serialization of SAML entities into valid SAML protocol messages. Together with SAMLReader, this class provides fine-grained access to the composition of SAML requests, responses, assertions, and statements. You can use it as part of your SAML client or SAML server implementation for creating individual SAML entities.

SAMLReader and SAMLWriter are independent of SAML server controls that are also included in SecureBlackbox, and are aimed at scenarios that require lower-level access to SAML functionality than that provided by the server controls.

SAMLWriter can create the following kinds of SAML messages:

- AssertionIDRequest
- SubjectQuery
- AuthnQuery
- AttributeQuery
- AuthzDecisionQuery
- AuthnRequest
- ManageNameIDRequest
- LogoutRequest
- NameIDMappingRequest
- ArtifactResolve
- Response

Please find below a quick-and-dirty example of the use of SAMLWriter class for creating a signed AuthnRequest message:

```text
  Samlwriter writer = new Samlwriter();

  // configuring general message properties
  writer.Destination = "http://destination-url.com";
  writer.IssueInstant = DateTime.UtcNow.ToString("yyyy-MM-ddTHH:mm:ss.fffZ");
  writer.Issuer = "Value=https://issuer-url.com;Format=urn:oasis:names:tc:SAML:2.0:nameid-format:entity;IDType=Issuer";

  // configuring general AuthnRequest properties
  writer.AuthnRequest.IsPassive = false;
  writer.AuthnRequest.UseIsPassive = true;
  writer.AuthnRequest.ForceAuthn = true;
  writer.AuthnRequest.ProtocolBinding = "urn:oasis:names:tc:SAML:2.0:bindings:HTTP-POST";
  writer.AuthnRequest.AssertionConsumerServiceURL = "https://assertion-consumer-url.com";
  writer.AuthnRequest.AttributeConsumingServiceIndex = 1;
  writer.AuthnRequest.NameIDPolicyAllowCreate = false;
  writer.AuthnRequest.NameIDPolicyFormat = "urn:oasis:names:tc:SAML:2.0:nameid-format:persistent";
  writer.AuthnRequest.ConditionsNotBefore = DateTime.UtcNow.ToString("yyyy-MM-ddTHH:mm:ss.fffZ");
  writer.AuthnRequest.ConditionsNotOnOrAfter = DateTime.UtcNow.AddMinutes(30).ToString("yyyy-MM-ddTHH:mm:ss.fffZ");

  // adjusting request conditions if required
  SAMLAssertionCondition cond = new SAMLAssertionCondition();
  cond.ConditionType = SAMLConditionTypes.csctOneTimeUse;
  writer.AuthnRequestConditions.Add(cond);

  // configuring signing properties
  Certificate certificate = new Certificate("C:\\Certs\\samlCert.pfx", "password");
  writer.Sign = true;
  writer.SigningCertificate = certificate;

  // creating the SAML entity of the required type
  writer.CreateNew((int)SamlwriterOutputTypes.cstyAuthnRequest);

  // adjusting low-level signature parameters
  writer.Config("SigDigestMethod=http://www.w3.org/2001/04/xmlenc#sha256");
  writer.Config("SigMethod=http://www.w3.org/2001/04/xmldsig-more#rsa-sha256");

  // signing the request and serializing it to XML
  string request = writer.Save();
```

 The above code produces the following AuthnRequest:

```text
  <samlp:AuthnRequest
    xmlns:saml="urn:oasis:names:tc:SAML:2.0:assertion" ID="53GhrzQ5f89fu214ANAR" Version="2.0"
    IssueInstant="2021-12-15T10:39:31Z" Destination="http://destination-url.com" IsPassive="false"
    ProtocolBinding="urn:oasis:names:tc:SAML:2.0:bindings:HTTP-POST"
    AssertionConsumerServiceURL="https://assertion-consumer-url.com" AttributeConsumingServiceIndex="1"
    xmlns:samlp="urn:oasis:names:tc:SAML:2.0:protocol">
    <saml:Issuer Format="urn:oasis:names:tc:SAML:2.0:nameid-format:entity">https://issuer-url.com</saml:Issuer>
    <ds:Signature xmlns:ds="http://www.w3.org/2000/09/xmldsig#">
      <ds:SignedInfo>
        <ds:CanonicalizationMethod Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#"/>
        <ds:SignatureMethod Algorithm="http://www.w3.org/2001/04/xmldsig-more#rsa-sha256"/>
        <ds:Reference URI="#53GhrzQ5f89fu214ANAR">
          <ds:Transforms>
            <ds:Transform Algorithm="http://www.w3.org/2000/09/xmldsig#enveloped-signature"/>
            <ds:Transform Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#"/>
          </ds:Transforms>
          <ds:DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256"/><ds:DigestValue>+xhhgXtwYN0/r9h7WAwg=</ds:DigestValue>
        </ds:Reference>
      </ds:SignedInfo>
      <ds:SignatureValue>
        jfYeIq/z8D1tJZYbVqDMoqKpdrfGMj8/zI7gbUsJbECAr00cN34md2QG0mo4cOx7pny+5
        Tht7tUzqENHqcZdmlOcZc2JcJqokVxIcLEluFiWKlNjpexkXFQKzOC1peRfTZm8SQTqtP
        Cz8IknLUc6Scfml29PHmks1PxjJDteGb/+FggsZRTGZC3a05nvH3ayvHukPeHuHssx5dX
        nj0quT8salR6fdx6lAJo/AnDHzcfBNyxAMn+ebk5VOOgVD1L3PayvXib/maj8aVI2I5UT
        o4vmfybTWKzeS8DX9We7UV+4Xowwe647t1A912xLVub/e23A18Yf1V0PXC87kttTkA==
      </ds:SignatureValue>
      <ds:KeyInfo>
        <ds:X509Data><ds:X509Certificate>
          MIIEKDCCAxCgAwIBAgIFYA3A3gIwDQYJKoZIhvcNAQELBQAwfjELMAkGA1UEBhMCVVMxC
          zAJBgNVBAgTAk5DMRQwEgYDVQQHEwtDaGFwZWwgSGlsbDEiMCAGCSqGSIb3DQEJARMTc2
          FsZXNAbnNvZnR3YXJlLmNvbTEoMCYGA1UEAxMfU2VjdXJlQmxhY2tib3ggRGVtbyBDZXJ
          0aWZpY2F0ZTAeFw0xNzA5MDEwMDAwMDBaFw0yMjA5MDEwMDAwMDBaMH4xCzAJBgNVBAYT
          AlVTMQswCQYDVQQIEwJOQzEUMBIGA1UEBxMLQ2hhcGVsIEhpbGwxIjAgBgkqhkiG9w0BC
          QETE3NhbGVzQG5zb2Z0d2FyZS5jb20xKDAmBgNVBAMTH1NlY3VyZUJsYWNrYm94IERlbW
          8gQ2VydGlmaWNhdGUwggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQCfAVIcq9o
          eoIbw56LsPjxWsX3YGkqasBQzgQymhfcDZeSvFKFis8iqArGLTUUWOaImO5t2UmjIa+4n
          YP39hb9Z1r0CMy53p83oYbbZZ7qMeji0pMAufJHqKCN8t2HNWf2HE8S9UOU7R/UHdrSAN
          JitBKV9lSG9f450yWoGNwt35ZCsOp0zqtCgvkEvteGsz01R5DDjOccs3QNu25K/Sf27KP
          CYabS6A1ehYNY/G32qoKNJhu3DN4bWje57gBWi9WSfQ3tZUOV5q2ozaNJA78Wl4fXC6RB
          CaBh0GOwXeyZoH13LJdn+lqlCSMz024ImG4yFQEENbWvE9Elku8RYTn73AgMBAAGjgaww
          gakwHwYDVR0jBBgwFoAUmt/L7GI1SH36Sp8EUBxTwuzSgqMwHQYDVR0OBBYEFJrfy+xiN
          Uh9+kqfBFAcU8Ls0oKjMA8GA1UdEwEB/wQFMAMBAf8wDwYDVR0PAQH/BAUDAwDuADBFBg
          NVHSUEPjA8BggrBgEFBQcDAQYIKwYBBQUHAwIGCCsGAQUFBwMDBggrBgEFBQcDBAYIKwY
          BBQUHAwgGCCsGAQUFBwMJMA0GCSqGSIb3DQEBCwUAA4IBAQBovHBbMsW/k/5iuLQQqsYS
          ng5X2iy1W+5BRb1hz0MGnHGLqJWy1ty5+bTo6g/zvT65dXIPIexLkInEenYSy75Lthr6a
          ewUcvwfl1TYXjWlMD5Nm5pM9As71+XsGSdYGXoKohbEzbT6RDByjwR+yxtatqko7e1Eg6
          InNJRTRt7al/63FSPEgSCqOX6asDVDNZ83db0dOcoeaPEiDz3liE3+tYHtKXj5/qwTtYd
          aqBZxdJfuCKZveEFe1DO3/ayDvIvG9Eme+rEjntErF+Cw9a8ukesvDuT49cRE9oTs3O7f
          6LUbhCv5zJN+dTFr75NSdWdp4yvn3nK3i2udeMnTWK0U
        </ds:X509Certificate></ds:X509Data>
      </ds:KeyInfo>
    </ds:Signature>
    <samlp:NameIDPolicy Format="urn:oasis:names:tc:SAML:2.0:nameid-format:persistent"/>
    <saml:Conditions NotBefore="2021-12-15T10:39:31Z" NotOnOrAfter="2021-12-15T11:09:31Z"><saml:OneTimeUse/></saml:Conditions>
  </samlp:AuthnRequest>
```

Note that you need to set the signing certificate before calling [CreateNew](#createnew-method-secureblackbox_samlwriter-class).

## Property List

*The following is the full list of the properties of the class with short descriptions. Click on the links for further details.*

|  |  |
| --- | --- |
| [ArtifactEndpointIndex](#artifactendpointindex-property-secureblackbox_samlwriter-class) | An accessor to the EndpointIndex entry of the artifact. |
| [ArtifactMessageHandle](#artifactmessagehandle-property-secureblackbox_samlwriter-class) | An accessor to the MessageHandle property of the artifact. |
| [ArtifactRemainingArtifact](#artifactremainingartifact-property-secureblackbox_samlwriter-class) | Returns the contents of the artifact. |
| [ArtifactSourceID](#artifactsourceid-property-secureblackbox_samlwriter-class) | An accessor to the SourceID property of the artifact. |
| [ArtifactTypeCode](#artifacttypecode-property-secureblackbox_samlwriter-class) | The TypeCode property of the artifact. |
| [ArtifactURI](#artifacturi-property-secureblackbox_samlwriter-class) | An accessor to the URI property of the artifact. |
| [ArtifactResolveQuery](#artifactresolvequery-property-secureblackbox_samlwriter-class) | Contains the artifact resolve query. |
| [AssertionType](#assertiontype-property-secureblackbox_samlwriter-class) | Specifies the type of the assertion. |
| [AssertionEncryptedContent](#assertionencryptedcontent-property-secureblackbox_samlwriter-class) | Represents the encrypted assertion content. |
| [AssertionID](#assertionid-property-secureblackbox_samlwriter-class) | Represents the ID of the assertion. |
| [AssertionIDRef](#assertionidref-property-secureblackbox_samlwriter-class) | Represents an ID reference value. |
| [AssertionIssueInstant](#assertionissueinstant-property-secureblackbox_samlwriter-class) | Contains the assertion issuance time stamp. |
| [AssertionIssuer](#assertionissuer-property-secureblackbox_samlwriter-class) | Specifies the assertion issuer. |
| [AssertionParentAssertion](#assertionparentassertion-property-secureblackbox_samlwriter-class) | Contains the index of the parent assertion in the assertion list. |
| [AssertionSignatureValidationResult](#assertionsignaturevalidationresult-property-secureblackbox_samlwriter-class) | The outcome of the cryptographic signature validation. |
| [AssertionSigned](#assertionsigned-property-secureblackbox_samlwriter-class) | Specifies whether the assertion is signed. |
| [AssertionSubject](#assertionsubject-property-secureblackbox_samlwriter-class) | Specifies the assertion subject. |
| [AssertionURIRef](#assertionuriref-property-secureblackbox_samlwriter-class) | Represents an URI reference value. |
| [AssertionVersion](#assertionversion-property-secureblackbox_samlwriter-class) | Specifies the SAML protocol version used. |
| [AssertionCount](#assertioncount-property-secureblackbox_samlwriter-class) | Returns the number of assertions in the message. |
| [AttributeCount](#attributecount-property-secureblackbox_samlwriter-class) | The number of records in the Attribute arrays. |
| [AttributeFriendlyName](#attributefriendlyname-property-secureblackbox_samlwriter-class) | Specifies the friendly name of the attribute Use this property to access or set the friendly name of a SAML attribute (e. |
| [AttributeName](#attributename-property-secureblackbox_samlwriter-class) | Specifies the name of the attribute. |
| [AttributeNameFormat](#attributenameformat-property-secureblackbox_samlwriter-class) | Indicates the format used to reference the attribute. |
| [AttributeStatementIndex](#attributestatementindex-property-secureblackbox_samlwriter-class) | Contains the index of the statement the attribute corresponds to. |
| [AttributeValues](#attributevalues-property-secureblackbox_samlwriter-class) | Contains a list of attribute values. |
| [AuthnQueryComparison](#authnquerycomparison-property-secureblackbox_samlwriter-class) | Specifies the authentication context comparison method. |
| [AuthnQueryContextClassRefs](#authnquerycontextclassrefs-property-secureblackbox_samlwriter-class) | Specifies the context class reference. |
| [AuthnQueryRefType](#authnqueryreftype-property-secureblackbox_samlwriter-class) | Specifies the context reference type. |
| [AuthnQuerySessionIndex](#authnquerysessionindex-property-secureblackbox_samlwriter-class) | Specifies the index of the session to the authentication entity. |
| [AuthnRequestAssertionConsumerServiceIndex](#authnrequestassertionconsumerserviceindex-property-secureblackbox_samlwriter-class) | Specifies the assertion consumer service index. |
| [AuthnRequestAssertionConsumerServiceURL](#authnrequestassertionconsumerserviceurl-property-secureblackbox_samlwriter-class) | Specifies the assertion consumer service URL. |
| [AuthnRequestAttributeConsumingServiceIndex](#authnrequestattributeconsumingserviceindex-property-secureblackbox_samlwriter-class) | Specifies the attribute consuming service index. |
| [AuthnRequestContextClassRefs](#authnrequestcontextclassrefs-property-secureblackbox_samlwriter-class) | Provides access to the authentication context class references. |
| [AuthnRequestContextComparison](#authnrequestcontextcomparison-property-secureblackbox_samlwriter-class) | Specifies the AuthnContext comparison method. |
| [AuthnRequestContextRefType](#authnrequestcontextreftype-property-secureblackbox_samlwriter-class) | Specifies the context reference type. |
| [AuthnRequestFlags](#authnrequestflags-property-secureblackbox_samlwriter-class) | Adjusts secondary serialization properties. |
| [AuthnRequestForceAuthn](#authnrequestforceauthn-property-secureblackbox_samlwriter-class) | Corresponds to the ForceAuthn parameter of the request. |
| [AuthnRequestIsPassive](#authnrequestispassive-property-secureblackbox_samlwriter-class) | Maps to the IsPassive parameter of the request. |
| [AuthnRequestNameIDPolicyAllowCreate](#authnrequestnameidpolicyallowcreate-property-secureblackbox_samlwriter-class) | Matches the AllowCreate attribute of NameIDPolicy element of the request. |
| [AuthnRequestNameIDPolicyFormat](#authnrequestnameidpolicyformat-property-secureblackbox_samlwriter-class) | Matches to the Format attribute of the NameIDPolicy element of the request. |
| [AuthnRequestNameIDPolicySPNameQualifier](#authnrequestnameidpolicyspnamequalifier-property-secureblackbox_samlwriter-class) | Matches to the SP name qualifier attribute of the request. |
| [AuthnRequestProtocolBinding](#authnrequestprotocolbinding-property-secureblackbox_samlwriter-class) | Specifies the protocol binding to be requested in the authentication request. |
| [AuthnRequestProviderName](#authnrequestprovidername-property-secureblackbox_samlwriter-class) | Specifies the name of the requestor. |
| [AuthnRequestScopingGetComplete](#authnrequestscopinggetcomplete-property-secureblackbox_samlwriter-class) | Matches the GetComplete element of the IDPList entry of the Scoping object. |
| [AuthnRequestScopingProxyCount](#authnrequestscopingproxycount-property-secureblackbox_samlwriter-class) | The maximum number of proxies on the way between the requestor and the provider. |
| [AuthnRequestScopingRequesterIDs](#authnrequestscopingrequesterids-property-secureblackbox_samlwriter-class) | A collection of requestor IDs on whose behalf the request is being sent. |
| [AuthzDecisionQueryActions](#authzdecisionqueryactions-property-secureblackbox_samlwriter-class) | Specifies the list of actions included in the query. |
| [AuthzDecisionQueryResource](#authzdecisionqueryresource-property-secureblackbox_samlwriter-class) | Matches the Resource element of the query. |
| [BindingType](#bindingtype-property-secureblackbox_samlwriter-class) | Specifies the type of SAML binding to use. |
| [BindingBody](#bindingbody-property-secureblackbox_samlwriter-class) | Contains the POST binding form body. |
| [BindingEncoding](#bindingencoding-property-secureblackbox_samlwriter-class) | Specifies the message encoding. |
| [BindingForceSign](#bindingforcesign-property-secureblackbox_samlwriter-class) | Enforces a signature over all outgoing messages. |
| [BindingFormTemplate](#bindingformtemplate-property-secureblackbox_samlwriter-class) | Contains the XHTML form template returned by the service provider. |
| [BindingPOSTMode](#bindingpostmode-property-secureblackbox_samlwriter-class) | Specifies whether binding is applied on the server, or on the client side. |
| [BindingRelayState](#bindingrelaystate-property-secureblackbox_samlwriter-class) | Contains the RelayState parameter of the binding. |
| [BindingSignatureAlgorithm](#bindingsignaturealgorithm-property-secureblackbox_samlwriter-class) | Contains the signature algorithm. |
| [BindingSignatureValidationResult](#bindingsignaturevalidationresult-property-secureblackbox_samlwriter-class) | The outcome of the cryptographic signature validation. |
| [BindingSigned](#bindingsigned-property-secureblackbox_samlwriter-class) | Specifies whether to sign the binding. |
| [BindingURL](#bindingurl-property-secureblackbox_samlwriter-class) | Contains the URL of the request query. |
| [BindingVerifySignatures](#bindingverifysignatures-property-secureblackbox_samlwriter-class) | Instructs the class whether to verify incoming signatures. |
| [BindingKeyHandle](#bindingkeyhandle-property-secureblackbox_samlwriter-class) | Allows to get or set a 'handle', a unique identifier of the underlying property object. |
| [ConditionCount](#conditioncount-property-secureblackbox_samlwriter-class) | The number of records in the Condition arrays. |
| [Condition](#condition-property-secureblackbox_samlwriter-class) | The condition set in accordance with the ConditionType . |
| [ConditionType](#conditiontype-property-secureblackbox_samlwriter-class) | Specifies a type of the condition object. |
| [EncryptionCertBytes](#encryptioncertbytes-property-secureblackbox_samlwriter-class) | Returns the raw certificate data in DER format. |
| [EncryptionCertHandle](#encryptioncerthandle-property-secureblackbox_samlwriter-class) | Allows to get or set a 'handle', a unique identifier of the underlying property object. |
| [FIPSMode](#fipsmode-property-secureblackbox_samlwriter-class) | Reserved. |
| [LogoutRequestNameID](#logoutrequestnameid-property-secureblackbox_samlwriter-class) | Contains the value of the NameID parameter. |
| [LogoutRequestNotOnOrAfter](#logoutrequestnotonorafter-property-secureblackbox_samlwriter-class) | Contains the value of the NotOnOrAfter parameter. |
| [LogoutRequestReason](#logoutrequestreason-property-secureblackbox_samlwriter-class) | Contains the value of the Reason parameter. |
| [LogoutRequestSessionIndexes](#logoutrequestsessionindexes-property-secureblackbox_samlwriter-class) | Contains the list of session indices. |
| [ManageNameIDRequestNameID](#managenameidrequestnameid-property-secureblackbox_samlwriter-class) | Contains the value of the NameID parameter of the request. |
| [ManageNameIDRequestNewEncryptedID](#managenameidrequestnewencryptedid-property-secureblackbox_samlwriter-class) | Contains the value of the NewEncryptedID parameter of the request. |
| [ManageNameIDRequestNewID](#managenameidrequestnewid-property-secureblackbox_samlwriter-class) | Contains the value of the NewID parameter. |
| [ManageNameIDRequestTerminate](#managenameidrequestterminate-property-secureblackbox_samlwriter-class) | Contains the value of the Terminate parameter of the request. |
| [MessageConsent](#messageconsent-property-secureblackbox_samlwriter-class) | Contains the Consent parameter of the SAML message. |
| [MessageContentType](#messagecontenttype-property-secureblackbox_samlwriter-class) | Returns the SAML type of the current message. |
| [MessageContentTypeString](#messagecontenttypestring-property-secureblackbox_samlwriter-class) | Returns the type of the processed message, as an original string. |
| [MessageDestination](#messagedestination-property-secureblackbox_samlwriter-class) | Contains the Destination parameter of the SAML message. |
| [MessageID](#messageid-property-secureblackbox_samlwriter-class) | The ID of the request. |
| [MessageInResponseTo](#messageinresponseto-property-secureblackbox_samlwriter-class) | Contains the InResponseTo property of the SAML request. |
| [MessageIssueInstant](#messageissueinstant-property-secureblackbox_samlwriter-class) | Contains request issuance timestamp. |
| [MessageIssuer](#messageissuer-property-secureblackbox_samlwriter-class) | Sets the issuer of the message. |
| [MessageSignatureValidationResult](#messagesignaturevalidationresult-property-secureblackbox_samlwriter-class) | The outcome of the cryptographic signature validation. |
| [MessageSigned](#messagesigned-property-secureblackbox_samlwriter-class) | Specifies whether the SAML message is or should be signed. |
| [MessageSubject](#messagesubject-property-secureblackbox_samlwriter-class) | Gets or sets the subject of the message. |
| [MessageVersion](#messageversion-property-secureblackbox_samlwriter-class) | Specifies the protocol version to use for the SAML message. |
| [MessageXMLHeader](#messagexmlheader-property-secureblackbox_samlwriter-class) | Controls the inclusion of an XML header in the message. |
| [NameIDMappingRequestNameID](#nameidmappingrequestnameid-property-secureblackbox_samlwriter-class) | An accessor to the NameID parameter of the request. |
| [NameIDMappingRequestNameIDPolicyAllowCreate](#nameidmappingrequestnameidpolicyallowcreate-property-secureblackbox_samlwriter-class) | Contains the value of AllowCreate parameter of the NameIDPolicy object. |
| [NameIDMappingRequestNameIDPolicyFormat](#nameidmappingrequestnameidpolicyformat-property-secureblackbox_samlwriter-class) | Specifies the format of the NameIDPolicy element. |
| [NameIDMappingRequestNameIDPolicySPNameQualifier](#nameidmappingrequestnameidpolicyspnamequalifier-property-secureblackbox_samlwriter-class) | Contains the SPNameQualifier parameter of the NameIDPolicy element. |
| [NameIDMappingRequestNameIDPolicyUseAllowCreate](#nameidmappingrequestnameidpolicyuseallowcreate-property-secureblackbox_samlwriter-class) | Controls inclusion of UseAllow modifier in the NameIDPolicy object. |
| [Profile](#profile-property-secureblackbox_samlwriter-class) | Specifies a pre-defined profile to apply when creating the signature. |
| [References](#references-property-secureblackbox_samlwriter-class) | Contains the References entry of the SAML AssertionIDRequest message. |
| [ResponseNameID](#responsenameid-property-secureblackbox_samlwriter-class) | Contains the NameID parameter of a NameIDMapping response. |
| [ResponseOptionalElement](#responseoptionalelement-property-secureblackbox_samlwriter-class) | An optional message element to be returned with the response. |
| [ResponseType](#responsetype-property-secureblackbox_samlwriter-class) | Contains the type of the response. |
| [ResponseStatus](#responsestatus-property-secureblackbox_samlwriter-class) | Gets or sets the status of the response. |
| [ResponseStatusCodeSubValue](#responsestatuscodesubvalue-property-secureblackbox_samlwriter-class) | The value of the nested StatusCode. |
| [ResponseStatusCodeValue](#responsestatuscodevalue-property-secureblackbox_samlwriter-class) | Contains the status code value. |
| [ResponseStatusDetail](#responsestatusdetail-property-secureblackbox_samlwriter-class) | Contains additional information on the status of the request. |
| [ResponseStatusMessage](#responsestatusmessage-property-secureblackbox_samlwriter-class) | Contains a status message (optional). |
| [ScopingIDPCount](#scopingidpcount-property-secureblackbox_samlwriter-class) | The number of records in the ScopingIDP arrays. |
| [ScopingIDPLoc](#scopingidploc-property-secureblackbox_samlwriter-class) | Contains the value of the Loc attribute. |
| [ScopingIDPName](#scopingidpname-property-secureblackbox_samlwriter-class) | Contains the name of the IdP provider. |
| [ScopingIDPProviderID](#scopingidpproviderid-property-secureblackbox_samlwriter-class) | Contains the provider ID. |
| [SecurityCanonicalizationMethod](#securitycanonicalizationmethod-property-secureblackbox_samlwriter-class) | The canonicalization method to use in the signature. |
| [SecurityDigestMethod](#securitydigestmethod-property-secureblackbox_samlwriter-class) | The digest method to use. |
| [SecurityEncryptionMethod](#securityencryptionmethod-property-secureblackbox_samlwriter-class) | The encryption method used to encrypt the assertion. |
| [SecurityFlags](#securityflags-property-secureblackbox_samlwriter-class) | Provides access to secondary security parameters and tweaks. |
| [SecuritySigMethod](#securitysigmethod-property-secureblackbox_samlwriter-class) | The signature method to use. |
| [SecuritySignaturePolicy](#securitysignaturepolicy-property-secureblackbox_samlwriter-class) | Specifies the signature validation policy. |
| [SigningCertBytes](#signingcertbytes-property-secureblackbox_samlwriter-class) | Returns the raw certificate data in DER format. |
| [SigningCertHandle](#signingcerthandle-property-secureblackbox_samlwriter-class) | Allows to get or set a 'handle', a unique identifier of the underlying property object. |
| [SigningChainCount](#signingchaincount-property-secureblackbox_samlwriter-class) | The number of records in the SigningChain arrays. |
| [SigningChainBytes](#signingchainbytes-property-secureblackbox_samlwriter-class) | Returns the raw certificate data in DER format. |
| [SigningChainHandle](#signingchainhandle-property-secureblackbox_samlwriter-class) | Allows to get or set a 'handle', a unique identifier of the underlying property object. |
| [StatementCount](#statementcount-property-secureblackbox_samlwriter-class) | The number of records in the Statement arrays. |
| [StatementAuthnContextAuthenticatingAuthorities](#statementauthncontextauthenticatingauthorities-property-secureblackbox_samlwriter-class) | Contains the list of authenticating authorities. |
| [StatementAuthnContextChoice](#statementauthncontextchoice-property-secureblackbox_samlwriter-class) | Specifies the authentication context choice variant. |
| [StatementAuthnContextClassRef](#statementauthncontextclassref-property-secureblackbox_samlwriter-class) | Indicates the authentication contexts class reference. |
| [StatementAuthnContextDecl](#statementauthncontextdecl-property-secureblackbox_samlwriter-class) | Specifies the authentication contexts declaration. |
| [StatementAuthnContextDeclRef](#statementauthncontextdeclref-property-secureblackbox_samlwriter-class) | Specifies the authentication contexts declaration reference. |
| [StatementAuthnInstant](#statementauthninstant-property-secureblackbox_samlwriter-class) | Specifies the authentication event timestamp. |
| [StatementAuthnSessionIndex](#statementauthnsessionindex-property-secureblackbox_samlwriter-class) | Contains the authentication session index. |
| [StatementAuthnSessionNotOnOrAfter](#statementauthnsessionnotonorafter-property-secureblackbox_samlwriter-class) | Maps to the SessionNotOnOrAfter parameter of the authentication statement. |
| [StatementAuthnSubjectLocalityAddress](#statementauthnsubjectlocalityaddress-property-secureblackbox_samlwriter-class) | Specifies the authentication subjects address. |
| [StatementAuthnSubjectLocalityDNSName](#statementauthnsubjectlocalitydnsname-property-secureblackbox_samlwriter-class) | Maps to the authentication subjects DNS name parameter. |
| [StatementAuthzActions](#statementauthzactions-property-secureblackbox_samlwriter-class) | Provides access to the list of actions of the authorization statement. |
| [StatementAuthzDecision](#statementauthzdecision-property-secureblackbox_samlwriter-class) | Specifies the authorization decision. |
| [StatementAuthzDecisionEvidence](#statementauthzdecisionevidence-property-secureblackbox_samlwriter-class) | Manages the authorization decision statement evidence parameter. |
| [StatementAuthzDecisionResource](#statementauthzdecisionresource-property-secureblackbox_samlwriter-class) | Specifies the authorization decision statement resource parameter. |
| [StatementType](#statementtype-property-secureblackbox_samlwriter-class) | Specifies the assertion statement type. |
| [SubjectConfirmationCount](#subjectconfirmationcount-property-secureblackbox_samlwriter-class) | The number of records in the SubjectConfirmation arrays. |
| [SubjectConfirmationAddress](#subjectconfirmationaddress-property-secureblackbox_samlwriter-class) | Contains the address enabled for presenting assertions. |
| [SubjectConfirmationData](#subjectconfirmationdata-property-secureblackbox_samlwriter-class) | The uninterpreted value of data entry in the subject confirmation. |
| [SubjectConfirmationDataType](#subjectconfirmationdatatype-property-secureblackbox_samlwriter-class) | The type of data contained in the confirmation. |
| [SubjectConfirmationID](#subjectconfirmationid-property-secureblackbox_samlwriter-class) | The identifier of the entity which can satisfy the subject confirmation requirements. |
| [SubjectConfirmationInResponseTo](#subjectconfirmationinresponseto-property-secureblackbox_samlwriter-class) | The ID of the SAML message in response to which the assertion is issued. |
| [SubjectConfirmationMethod](#subjectconfirmationmethod-property-secureblackbox_samlwriter-class) | Specifies the mechanism to be used to confirm the subject. |
| [SubjectConfirmationNotBefore](#subjectconfirmationnotbefore-property-secureblackbox_samlwriter-class) | Time moment before which the subject cannot be confirmed. |
| [SubjectConfirmationNotOnOrAfter](#subjectconfirmationnotonorafter-property-secureblackbox_samlwriter-class) | Limits the time until which the subject can be confirmed. |
| [SubjectConfirmationRecipient](#subjectconfirmationrecipient-property-secureblackbox_samlwriter-class) | The URI of the entity or the location of the resource to which the assertion should be presented. |

## Method List

*The following is the full list of the methods of the class with short descriptions. Click on the links for further details.*

|  |  |
| --- | --- |
| [AddAttribute](#addattribute-method-secureblackbox_samlwriter-class) | Adds an attribute to an existing attribute statement. |
| [AddAttributeStatement](#addattributestatement-method-secureblackbox_samlwriter-class) | Adds an attribute statement to the assertion. |
| [AddAuthnStatement](#addauthnstatement-method-secureblackbox_samlwriter-class) | Adds an authentication statement to the assertion. |
| [AddAuthzDecisionStatement](#addauthzdecisionstatement-method-secureblackbox_samlwriter-class) | Adds an authorization decision statement to the assertion. |
| [AddCondition](#addcondition-method-secureblackbox_samlwriter-class) | Adds a condition to the object (assertion or authn request) being edited. |
| [AddScopingIDP](#addscopingidp-method-secureblackbox_samlwriter-class) | Adds a scoping IDP to the object being currently edited. |
| [AddSubjectConfirmation](#addsubjectconfirmation-method-secureblackbox_samlwriter-class) | Adds a subject confirmation to the object being edited. |
| [BeginAssertion](#beginassertion-method-secureblackbox_samlwriter-class) | Initiates the process of creating a new assertion. |
| [CompleteAssertion](#completeassertion-method-secureblackbox_samlwriter-class) | Adds a completed assertion to a SAML message. |
| [Config](#config-method-secureblackbox_samlwriter-class) | Sets or retrieves a configuration setting. |
| [CreateNew](#createnew-method-secureblackbox_samlwriter-class) | Creates a new SAML message with the given type. |
| [DoAction](#doaction-method-secureblackbox_samlwriter-class) | Performs an additional action. |
| [FormatID](#formatid-method-secureblackbox_samlwriter-class) | Formats a SAML ID in the form in which it can be assigned to the Issuer or Subject fields. |
| [Reset](#reset-method-secureblackbox_samlwriter-class) | Resets the class settings. |
| [Save](#save-method-secureblackbox_samlwriter-class) | Saves the configured message to a string. |
| [SaveBytes](#savebytes-method-secureblackbox_samlwriter-class) | Saves the configured message to a byte array. |
| [SaveFile](#savefile-method-secureblackbox_samlwriter-class) | Saves the configured message to a file. |

## Event List

*The following is the full list of the events fired by the class with short descriptions. Click on the links for further details.*

|  |  |
| --- | --- |
| [Error](#error-event-secureblackbox_samlwriter-class) | Fires to report an error condition. |
| [Notification](#notification-event-secureblackbox_samlwriter-class) | This event notifies the application about an underlying control flow event. |

## Config Settings

*The following is a list of config settings for the class with short descriptions. Click on the links for further details.*

|  |  |
| --- | --- |
| [BodyOnly](#BodyOnly) | TBD. |
| [DateTimeFormat](#DateTimeFormat) | TBD. |
| [KeyDataElements](#KeyDataElements) | TBD. |
| [SAMLPrefix](#SAMLPrefix) | TBD. |
| [SAMLProtocolPrefix](#SAMLProtocolPrefix) | TBD. |
| [SigAfterIssuer](#SigAfterIssuer) | Specifies whether to insert the signature after the issuer tag in the SAML document. |
| [SigCanonicalizationMethod](#SigCanonicalizationMethod) | TBD. |
| [SigDigestMethod](#SigDigestMethod) | TBD. |
| [SigMethod](#SigMethod) | TBD. |
| [TimeZoneOffset](#TimeZoneOffset) | TBD. |
| [ASN1UseGlobalTagCache](#ASN1UseGlobalTagCache) | Controls whether ASN.1 module should use a global object cache. |
| [AssignSystemSmartCardPins](#AssignSystemSmartCardPins) | Specifies whether CSP-level PINs should be assigned to CNG keys. |
| [CheckKeyIntegrityBeforeUse](#CheckKeyIntegrityBeforeUse) | Enables or disable private key integrity check before use. |
| [CookieCaching](#CookieCaching) | Specifies whether a cookie cache should be used for HTTP(S) transports. |
| [Cookies](#Cookies) | Gets or sets local cookies for the class. |
| [DefDeriveKeyIterations](#DefDeriveKeyIterations) | Specifies the default key derivation algorithm iteration count. |
| [DNSLocalSuffix](#DNSLocalSuffix) | The suffix to assign for TLD names. |
| [EnableClientSideSSLFFDHE](#EnableClientSideSSLFFDHE) | Enables or disables finite field DHE key exchange support in TLS clients. |
| [EnableSSHMLKEM](#EnableSSHMLKEM) | Enables support for ML-KEM/hybrid key exchange algorithms in SSH client and server classes. |
| [EnableTLSMLKEM](#EnableTLSMLKEM) | Enables support for ML-KEM and hybrid groups in TLS client and server classes. |
| [GlobalCookies](#GlobalCookies) | Gets or sets global cookies for all the HTTP transports. |
| [HardwareCryptoUsePolicy](#HardwareCryptoUsePolicy) | The hardware crypto usage policy. |
| [HttpUserAgent](#HttpUserAgent) | Specifies the user agent name to be used by all HTTP clients. |
| [HttpVersion](#HttpVersion) | The HTTP version to use in any inner HTTP client classes created. |
| [IgnoreExpiredMSCTLSigningCert](#IgnoreExpiredMSCTLSigningCert) | Whether to tolerate the expired Windows Update signing certificate. |
| [ListDelimiter](#ListDelimiter) | The delimiter character for multi-element lists. |
| [LogDestination](#LogDestination) | Specifies the debug log destination. |
| [LogDetails](#LogDetails) | Specifies the debug log details to dump. |
| [LogFile](#LogFile) | Specifies the debug log filename. |
| [LogFilters](#LogFilters) | Specifies the debug log filters. |
| [LogFlushMode](#LogFlushMode) | Specifies the log flush mode. |
| [LogLevel](#LogLevel) | Specifies the debug log level. |
| [LogMaxEventCount](#LogMaxEventCount) | Specifies the maximum number of events to cache before further action is taken. |
| [LogRotationMode](#LogRotationMode) | Specifies the log rotation mode. |
| [MaxASN1BufferLength](#MaxASN1BufferLength) | Specifies the maximal allowed length for ASN.1 primitive tag data. |
| [MaxASN1TreeDepth](#MaxASN1TreeDepth) | Specifies the maximal depth for processed ASN.1 trees. |
| [OCSPHashAlgorithm](#OCSPHashAlgorithm) | Specifies the hash algorithm to be used to identify certificates in OCSP requests. |
| [OldClientSideRSAFallback](#OldClientSideRSAFallback) | Specifies whether the SSH client should use a SHA1 fallback. |
| [PKICache](#PKICache) | Specifies which PKI elements (certificates, CRLs, OCSP responses) should be cached. |
| [PKICachePath](#PKICachePath) | Specifies the file system path where cached PKI data is stored. |
| [ProductVersion](#ProductVersion) | Returns the version of the SecureBlackbox library. |
| [ServerSSLDHKeyLength](#ServerSSLDHKeyLength) | Sets the size of the TLS DHE key exchange group. |
| [StaticDNS](#StaticDNS) | Specifies whether static DNS rules should be used. |
| [StaticIPAddress\[domain\]](#StaticIPAddress[domain]) | Gets or sets an IP address for the specified domain name. |
| [StaticIPAddresses](#StaticIPAddresses) | Gets or sets all the static DNS rules. |
| [Tag](#Tag) | Allows to store any custom data. |
| [TLSSessionGroup](#TLSSessionGroup) | Specifies the group name of TLS sessions to be used for session resumption. |
| [TLSSessionLifetime](#TLSSessionLifetime) | Specifies lifetime in seconds of the cached TLS session. |
| [TLSSessionPurgeInterval](#TLSSessionPurgeInterval) | Specifies how often the session cache should remove the expired TLS sessions. |
| [UseCRLObjectCaching](#UseCRLObjectCaching) | Specifies whether reuse of loaded CRL objects is enabled. |
| [UseInternalRandom](#UseInternalRandom) | Switches between SecureBlackbox-own and platform PRNGs. |
| [UseLegacyAdESValidation](#UseLegacyAdESValidation) | Enables legacy AdES validation mode. |
| [UseOCSPResponseObjectCaching](#UseOCSPResponseObjectCaching) | Specifies whether reuse of loaded OCSP response objects is enabled. |
| [UseOwnDNSResolver](#UseOwnDNSResolver) | Specifies whether the client classes should use own DNS resolver. |
| [UseSharedSystemStorages](#UseSharedSystemStorages) | Specifies whether the validation engine should use a global per-process copy of the system certificate stores. |
| [UseSystemNativeSizeCalculation](#UseSystemNativeSizeCalculation) | An internal CryptoAPI access tweak. |
| [UseSystemOAEPAndPSS](#UseSystemOAEPAndPSS) | Enforces or disables the use of system-driven RSA OAEP and PSS computations. |
| [UseSystemRandom](#UseSystemRandom) | Enables or disables the use of the OS PRNG. |
| [XMLRDNDescriptorName\[OID\]](#XMLRDNDescriptorName[OID]) | Defines an OID mapping to descriptor names for the certificate's IssuerRDN or SubjectRDN. |
| [XMLRDNDescriptorPriority\[OID\]](#XMLRDNDescriptorPriority[OID]) | Specifies the priority of descriptor names associated with a specific OID. |
| [XMLRDNDescriptorReverseOrder](#XMLRDNDescriptorReverseOrder) | Specifies whether to reverse the order of descriptors in RDN. |
| [XMLRDNDescriptorSeparator](#XMLRDNDescriptorSeparator) | Specifies the separator used between descriptors in RDN. |

# ArtifactEndpointIndex Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

An accessor to the EndpointIndex entry of the artifact.

## Object Oriented Interface

```text
public function getArtifactEndpointIndex();
public function setArtifactEndpointIndex($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 1 );
secureblackbox_samlwriter_set($res, 1, $value );
```

## Default Value

0

## Remarks

An accessor to the EndpointIndex entry of the artifact.

The EndpointIndex references a specific artifact resolution endpoint (IdP or SP) managed by the artifact issuer.

This property is not available at design time.

## Data Type

Integer

# ArtifactMessageHandle Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

An accessor to the MessageHandle property of the artifact.

## Object Oriented Interface

```text
public function getArtifactMessageHandle();
public function setArtifactMessageHandle($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 2 );
secureblackbox_samlwriter_set($res, 2, $value );
```

## Remarks

An accessor to the MessageHandle property of the artifact.

A message handle is a unique reference to a SAML message that can be produced by the artifact issuer upon request.

This property is not available at design time.

## Data Type

Byte Array

# ArtifactRemainingArtifact Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Returns the contents of the artifact.

## Object Oriented Interface

```text
public function getArtifactRemainingArtifact();
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 3 );
```

## Remarks

Returns the contents of the artifact.

Check this property to access the encoded contents of the artifact. This property is updated internally from the parameters of the artifact.

This property is read-only and not available at design time.

## Data Type

Byte Array

# ArtifactSourceID Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

An accessor to the SourceID property of the artifact.

## Object Oriented Interface

```text
public function getArtifactSourceID();
public function setArtifactSourceID($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 4 );
secureblackbox_samlwriter_set($res, 4, $value );
```

## Remarks

An accessor to the SourceID property of the artifact.

SourceID uniquely identifies the issuer of the artifact.

This property is not available at design time.

## Data Type

Byte Array

# ArtifactTypeCode Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

The TypeCode property of the artifact.

## Object Oriented Interface

```text
public function getArtifactTypeCode();
public function setArtifactTypeCode($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 5 );
secureblackbox_samlwriter_set($res, 5, $value );
```

## Default Value

0

## Remarks

The TypeCode field of the artifact.

The type code artifact parameter uniquely identifies the artifact format. Currently (as per SAML 2.0) the only type code of 4 is defined. This format assumes the presence of [ArtifactRemainingArtifact](#artifactremainingartifact-property-secureblackbox_samlwriter-class), [ArtifactSourceID](#artifactsourceid-property-secureblackbox_samlwriter-class), and [ArtifactMessageHandle](#artifactmessagehandle-property-secureblackbox_samlwriter-class) parameters.

This property is not available at design time.

## Data Type

Integer

# ArtifactURI Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

An accessor to the URI property of the artifact.

## Object Oriented Interface

```text
public function getArtifactURI();
public function setArtifactURI($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 6 );
secureblackbox_samlwriter_set($res, 6, $value );
```

## Default Value

''

## Remarks

An accessor to the URI property of the artifact.

The URI property contains the origin of the artifact.

This property is not available at design time.

## Data Type

String

# ArtifactResolveQuery Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Contains the artifact resolve query.

## Object Oriented Interface

```text
public function getArtifactResolveQuery();
public function setArtifactResolveQuery($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 7 );
secureblackbox_samlwriter_set($res, 7, $value );
```

## Default Value

''

## Remarks

Use this property to read or set the artifact resolve query.

This property is not available at design time.

## Data Type

String

# AssertionType Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Specifies the type of the assertion.

## Object Oriented Interface

```text
public function getAssertionType();
public function setAssertionType($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 8 );
secureblackbox_samlwriter_set($res, 8, $value );
```

## Possible Values

```text
SAMLWRITER_ASSERTIONTYPE_ASSERTION_IDREF(0), SAMLWRITER_ASSERTIONTYPE_ASSERTION_URIREF(1), SAMLWRITER_ASSERTIONTYPE_ASSERTION(2), SAMLWRITER_ASSERTIONTYPE_ENCRYPTED_ASSERTION(3)
```

## Default Value

2

## Remarks

Specifies the type of the assertion.

Use this property to check or set the type of the assertion.

This property is not available at design time.

## Data Type

Integer

# AssertionEncryptedContent Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Represents the encrypted assertion content.

## Object Oriented Interface

```text
public function getAssertionEncryptedContent();
public function setAssertionEncryptedContent($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 9 );
secureblackbox_samlwriter_set($res, 9, $value );
```

## Default Value

''

## Remarks

Represents the encrypted assertion content.

Use this property to get or set the encrypted assertion content.

This property is not available at design time.

## Data Type

String

# AssertionID Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Represents the ID of the assertion.

## Object Oriented Interface

```text
public function getAssertionID();
public function setAssertionID($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 10 );
secureblackbox_samlwriter_set($res, 10, $value );
```

## Default Value

''

## Remarks

Represents the ID of the assertion.

Use this property to read or set the unique ID of the assertion.

This property is not available at design time.

## Data Type

String

# AssertionIDRef Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Represents an ID reference value.

## Object Oriented Interface

```text
public function getAssertionIDRef();
public function setAssertionIDRef($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 11 );
secureblackbox_samlwriter_set($res, 11, $value );
```

## Default Value

''

## Remarks

Represents an ID reference value.

Use this property to read or set the ID reference value for assertions of csatAssertionIDRef type.

This property is not available at design time.

## Data Type

String

# AssertionIssueInstant Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Contains the assertion issuance time stamp.

## Object Oriented Interface

```text
public function getAssertionIssueInstant();
public function setAssertionIssueInstant($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 12 );
secureblackbox_samlwriter_set($res, 12, $value );
```

## Default Value

''

## Remarks

Contains the assertion issuance time stamp.

Use this property to check or set the assertion issuance time.

This property is not available at design time.

## Data Type

String

# AssertionIssuer Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Specifies the assertion issuer.

## Object Oriented Interface

```text
public function getAssertionIssuer();
public function setAssertionIssuer($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 13 );
secureblackbox_samlwriter_set($res, 13, $value );
```

## Default Value

''

## Remarks

Specifies the assertion issuer.

Use this property to provide the assertion issuer ID.

This property is not available at design time.

## Data Type

String

# AssertionParentAssertion Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Contains the index of the parent assertion in the assertion list.

## Object Oriented Interface

```text
public function getAssertionParentAssertion();
public function setAssertionParentAssertion($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 14 );
secureblackbox_samlwriter_set($res, 14, $value );
```

## Default Value

-1

## Remarks

Contains the index of the parent assertion in the assertion list.

This property is set to -1 for normal assertions. ParentAssertion set to a non-negative value indicates that the assertion is an advice assertion incorporated into a top-level assertion. Advice assertions are typically used by service providers to provide additional information about the SAML assertion issuing authority.

This property is not available at design time.

## Data Type

Integer

# AssertionSignatureValidationResult Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

The outcome of the cryptographic signature validation.

## Object Oriented Interface

```text
public function getAssertionSignatureValidationResult();
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 15 );
```

## Possible Values

```text
SAMLWRITER_ASSERTIONSIGNATUREVALIDATIONRESULT_VALID(0), SAMLWRITER_ASSERTIONSIGNATUREVALIDATIONRESULT_UNKNOWN(1), SAMLWRITER_ASSERTIONSIGNATUREVALIDATIONRESULT_CORRUPTED(2), SAMLWRITER_ASSERTIONSIGNATUREVALIDATIONRESULT_SIGNER_NOT_FOUND(3), SAMLWRITER_ASSERTIONSIGNATUREVALIDATIONRESULT_FAILURE(4), SAMLWRITER_ASSERTIONSIGNATUREVALIDATIONRESULT_REFERENCE_CORRUPTED(5)
```

## Default Value

0

## Remarks

The outcome of the cryptographic signature validation.

The following signature validity values are supported:

|  |  |  |
| --- | --- | --- |
| svtValid | 0 | The signature is valid |
| svtUnknown | 1 | Signature validity is unknown |
| svtCorrupted | 2 | The signature is corrupted |
| svtSignerNotFound | 3 | Failed to acquire the signing certificate. The signature cannot be validated. |
| svtFailure | 4 | General failure |
| svtReferenceCorrupted | 5 | Reference corrupted (XML-based signatures only) |

This property is read-only and not available at design time.

## Data Type

Integer

# AssertionSigned Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Specifies whether the assertion is signed.

## Object Oriented Interface

```text
public function getAssertionSigned();
public function setAssertionSigned($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 16 );
secureblackbox_samlwriter_set($res, 16, $value );
```

## Default Value

false

## Remarks

Specifies whether the assertion is signed.

Use this property to establish whether the assertion is signed.

This property is not available at design time.

## Data Type

Boolean

# AssertionSubject Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Specifies the assertion subject.

## Object Oriented Interface

```text
public function getAssertionSubject();
public function setAssertionSubject($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 17 );
secureblackbox_samlwriter_set($res, 17, $value );
```

## Default Value

''

## Remarks

Specifies the assertion subject.

Use this property to provide the assertion's subject SAML ID.

This property is not available at design time.

## Data Type

String

# AssertionURIRef Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Represents an URI reference value.

## Object Oriented Interface

```text
public function getAssertionURIRef();
public function setAssertionURIRef($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 18 );
secureblackbox_samlwriter_set($res, 18, $value );
```

## Default Value

''

## Remarks

Represents an URI reference value.

Use this property to read or set the URI reference value for assertions of csatAssertionURIRef type.

This property is not available at design time.

## Data Type

String

# AssertionVersion Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Specifies the SAML protocol version used.

## Object Oriented Interface

```text
public function getAssertionVersion();
public function setAssertionVersion($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 19 );
secureblackbox_samlwriter_set($res, 19, $value );
```

## Default Value

''

## Remarks

Specifies the SAML protocol version used.

This property specifies the SAML protocol version. The default value is *2.0*.

This property is not available at design time.

## Data Type

String

# AssertionCount Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Returns the number of assertions in the message.

## Object Oriented Interface

```text
public function getAssertionCount();
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 20 );
```

## Default Value

0

## Remarks

This property returns the total number of assertions currently defined in the SAML message.

This property is read-only and not available at design time.

## Data Type

Integer

# AttributeCount Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

The number of records in the Attribute arrays.

## Object Oriented Interface

```text
public function getAttributeCount();
public function setAttributeCount($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 21 );
secureblackbox_samlwriter_set($res, 21, $value );
```

## Default Value

0

## Remarks

This property controls the size of the following arrays:

- [AttributeFriendlyName](#attributefriendlyname-property-secureblackbox_samlwriter-class)
- [AttributeName](#attributename-property-secureblackbox_samlwriter-class)
- [AttributeNameFormat](#attributenameformat-property-secureblackbox_samlwriter-class)
- [AttributeStatementIndex](#attributestatementindex-property-secureblackbox_samlwriter-class)
- [AttributeValues](#attributevalues-property-secureblackbox_samlwriter-class)

The array indices start at *0* and end at *AttributeCount - 1*.

This property is not available at design time.

## Data Type

Integer

# AttributeFriendlyName Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Specifies the friendly name of the attribute Use this property to access or set the friendly name of a SAML attribute (e.

## Object Oriented Interface

```text
public function getAttributeFriendlyName($attributeindex);
public function setAttributeFriendlyName($attributeindex, $value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 22 , $attributeindex);
secureblackbox_samlwriter_set($res, 22, $value , $attributeindex);
```

## Default Value

''

## Remarks

Specifies the friendly name of the attribute

Use this property to access or set the friendly name of a SAML attribute (e.g. *givenName*).

The *$attributeindex* parameter specifies the index of the item in the array. The size of the array is controlled by the [AttributeCount](#attributecount-property-secureblackbox_samlwriter-class) property.

This property is not available at design time.

## Data Type

String

# AttributeName Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Specifies the name of the attribute.

## Object Oriented Interface

```text
public function getAttributeName($attributeindex);
public function setAttributeName($attributeindex, $value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 23 , $attributeindex);
secureblackbox_samlwriter_set($res, 23, $value , $attributeindex);
```

## Default Value

''

## Remarks

Specifies the name of the attribute.

Use this property to read or set the formal name of the attribute (e.g. *urn:oid:2.5.4.42*).

The *$attributeindex* parameter specifies the index of the item in the array. The size of the array is controlled by the [AttributeCount](#attributecount-property-secureblackbox_samlwriter-class) property.

This property is not available at design time.

## Data Type

String

# AttributeNameFormat Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Indicates the format used to reference the attribute.

## Object Oriented Interface

```text
public function getAttributeNameFormat($attributeindex);
public function setAttributeNameFormat($attributeindex, $value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 24 , $attributeindex);
secureblackbox_samlwriter_set($res, 24, $value , $attributeindex);
```

## Default Value

''

## Remarks

Indicates the format used to reference the attribute.

This property specifies the format that is used to reference the attribute (e.g. *urn:oasis:names:tc:SAML:2.0:attrname-format:uri*).

The *$attributeindex* parameter specifies the index of the item in the array. The size of the array is controlled by the [AttributeCount](#attributecount-property-secureblackbox_samlwriter-class) property.

This property is not available at design time.

## Data Type

String

# AttributeStatementIndex Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Contains the index of the statement the attribute corresponds to.

## Object Oriented Interface

```text
public function getAttributeStatementIndex($attributeindex);
public function setAttributeStatementIndex($attributeindex, $value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 25 , $attributeindex);
secureblackbox_samlwriter_set($res, 25, $value , $attributeindex);
```

## Default Value

-1

## Remarks

Contains the index of the statement the attribute corresponds to.

Use this property to read or set the index of the statement in the statement list that this attribute corresponds to.

The *$attributeindex* parameter specifies the index of the item in the array. The size of the array is controlled by the [AttributeCount](#attributecount-property-secureblackbox_samlwriter-class) property.

This property is not available at design time.

## Data Type

Integer

# AttributeValues Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Contains a list of attribute values.

## Object Oriented Interface

```text
public function getAttributeValues($attributeindex);
public function setAttributeValues($attributeindex, $value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 26 , $attributeindex);
secureblackbox_samlwriter_set($res, 26, $value , $attributeindex);
```

## Default Value

''

## Remarks

Contains a list of attribute values.

Use this property to access or set the value(s) included with the attribute. The value contains a list of strings of ContentType=*contentType*;Value=*value* format, separated with CRLF.

The *$attributeindex* parameter specifies the index of the item in the array. The size of the array is controlled by the [AttributeCount](#attributecount-property-secureblackbox_samlwriter-class) property.

This property is not available at design time.

## Data Type

String

# AuthnQueryComparison Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Specifies the authentication context comparison method.

## Object Oriented Interface

```text
public function getAuthnQueryComparison();
public function setAuthnQueryComparison($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 27 );
secureblackbox_samlwriter_set($res, 27, $value );
```

## Possible Values

```text
SAMLWRITER_AUTHNQUERYCOMPARISON_NONE(0), SAMLWRITER_AUTHNQUERYCOMPARISON_EXACT(1), SAMLWRITER_AUTHNQUERYCOMPARISON_MINIMUM(2), SAMLWRITER_AUTHNQUERYCOMPARISON_MAXIMUM(3), SAMLWRITER_AUTHNQUERYCOMPARISON_BETTER(4)
```

## Default Value

0

## Remarks

Specifies the authentication context comparison method.

Use this property to access or set the authentication contexts comparison method (none, exact, minimum, maximum, or better).

This property is not available at design time.

## Data Type

Integer

# AuthnQueryContextClassRefs Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Specifies the context class reference.

## Object Oriented Interface

```text
public function getAuthnQueryContextClassRefs();
public function setAuthnQueryContextClassRefs($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 28 );
secureblackbox_samlwriter_set($res, 28, $value );
```

## Default Value

''

## Remarks

Specifies the context class reference.

Use this property to access or set the authentication context class reference.

This property is not available at design time.

## Data Type

String

# AuthnQueryRefType Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Specifies the context reference type.

## Object Oriented Interface

```text
public function getAuthnQueryRefType();
public function setAuthnQueryRefType($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 29 );
secureblackbox_samlwriter_set($res, 29, $value );
```

## Possible Values

```text
SAMLWRITER_AUTHNQUERYREFTYPE_UNKNOWN(0), SAMLWRITER_AUTHNQUERYREFTYPE_CLASS(1), SAMLWRITER_AUTHNQUERYREFTYPE_DECL(2)
```

## Default Value

0

## Remarks

Specifies the context reference type.

Use this property to access or set the authentication contexts reference type (class or declaration).

This property is not available at design time.

## Data Type

Integer

# AuthnQuerySessionIndex Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Specifies the index of the session to the authentication entity.

## Object Oriented Interface

```text
public function getAuthnQuerySessionIndex();
public function setAuthnQuerySessionIndex($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 30 );
secureblackbox_samlwriter_set($res, 30, $value );
```

## Default Value

''

## Remarks

Specifies the index of the session to the authentication entity.

Use this property to access or set the index of the session to the authentication entity.

This property is not available at design time.

## Data Type

String

# AuthnRequestAssertionConsumerServiceIndex Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Specifies the assertion consumer service index.

## Object Oriented Interface

```text
public function getAuthnRequestAssertionConsumerServiceIndex();
public function setAuthnRequestAssertionConsumerServiceIndex($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 31 );
secureblackbox_samlwriter_set($res, 31, $value );
```

## Default Value

0

## Remarks

Specifies the assertion consumer service index.

Use this property to access or set the location index to which the response has to be returned.

This property is not available at design time.

## Data Type

Integer

# AuthnRequestAssertionConsumerServiceURL Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Specifies the assertion consumer service URL.

## Object Oriented Interface

```text
public function getAuthnRequestAssertionConsumerServiceURL();
public function setAuthnRequestAssertionConsumerServiceURL($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 32 );
secureblackbox_samlwriter_set($res, 32, $value );
```

## Default Value

''

## Remarks

Specifies the assertion consumer service URL.

Use this property to access or set the URL of the location to which the response has to be returned.

This property is not available at design time.

## Data Type

String

# AuthnRequestAttributeConsumingServiceIndex Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Specifies the attribute consuming service index.

## Object Oriented Interface

```text
public function getAuthnRequestAttributeConsumingServiceIndex();
public function setAuthnRequestAttributeConsumingServiceIndex($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 33 );
secureblackbox_samlwriter_set($res, 33, $value );
```

## Default Value

0

## Remarks

Specifies the attribute consuming service index.

Use this property to read or set the attribute consuming service index.

This property is not available at design time.

## Data Type

Integer

# AuthnRequestContextClassRefs Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Provides access to the authentication context class references.

## Object Oriented Interface

```text
public function getAuthnRequestContextClassRefs();
public function setAuthnRequestContextClassRefs($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 34 );
secureblackbox_samlwriter_set($res, 34, $value );
```

## Default Value

''

## Remarks

Provides access to the authentication context class references.

Use this property to access or set the class references of the authentication context. This property may contain a list of CRLF-separated strings.

This property is not available at design time.

## Data Type

String

# AuthnRequestContextComparison Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Specifies the AuthnContext comparison method.

## Object Oriented Interface

```text
public function getAuthnRequestContextComparison();
public function setAuthnRequestContextComparison($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 35 );
secureblackbox_samlwriter_set($res, 35, $value );
```

## Possible Values

```text
SAMLWRITER_AUTHNREQUESTCONTEXTCOMPARISON_NONE(0), SAMLWRITER_AUTHNREQUESTCONTEXTCOMPARISON_EXACT(1), SAMLWRITER_AUTHNREQUESTCONTEXTCOMPARISON_MINIMUM(2), SAMLWRITER_AUTHNREQUESTCONTEXTCOMPARISON_MAXIMUM(3), SAMLWRITER_AUTHNREQUESTCONTEXTCOMPARISON_BETTER(4)
```

## Default Value

0

## Remarks

Specifies the AuthnContext comparison method.

Use this property to access or set the authentication contexts comparison method (none, exact, minimum, maximum, or better).

This property is not available at design time.

## Data Type

Integer

# AuthnRequestContextRefType Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Specifies the context reference type.

## Object Oriented Interface

```text
public function getAuthnRequestContextRefType();
public function setAuthnRequestContextRefType($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 36 );
secureblackbox_samlwriter_set($res, 36, $value );
```

## Possible Values

```text
SAMLWRITER_AUTHNREQUESTCONTEXTREFTYPE_UNKNOWN(0), SAMLWRITER_AUTHNREQUESTCONTEXTREFTYPE_CLASS(1), SAMLWRITER_AUTHNREQUESTCONTEXTREFTYPE_DECL(2)
```

## Default Value

0

## Remarks

Specifies the context reference type.

Use this property to get or set the context reference type (Class or Declaration).

This property is not available at design time.

## Data Type

Integer

# AuthnRequestFlags Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Adjusts secondary serialization properties.

## Object Oriented Interface

```text
public function getAuthnRequestFlags();
public function setAuthnRequestFlags($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 37 );
secureblackbox_samlwriter_set($res, 37, $value );
```

## Default Value

0

## Remarks

Adjusts secondary serialization properties.

Use this bit mask property to adjust how certain properties will be saved. The following flags are supported:

|  |  |  |
| --- | --- | --- |
| arfAllowCreate | 1 | Enforces inclusion of NameIDPolicyAllowCreate element in the NameIDPolicy record |
| arfForceAuthn | 2 | Enforces inclusion of the ForceAuthn element |
| arfIsPassive | 4 | Enforces saving of IsPassive element |

This property is not available at design time.

## Data Type

Integer

# AuthnRequestForceAuthn Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Corresponds to the ForceAuthn parameter of the request.

## Object Oriented Interface

```text
public function getAuthnRequestForceAuthn();
public function setAuthnRequestForceAuthn($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 38 );
secureblackbox_samlwriter_set($res, 38, $value );
```

## Default Value

false

## Remarks

Corresponds to the ForceAuthn parameter of the request.

Use this property to check or set the ForceAuthn parameter of the request, which enforces the identity provider to re-authenticate the presenter.

This property is not available at design time.

## Data Type

Boolean

# AuthnRequestIsPassive Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Maps to the IsPassive parameter of the request.

## Object Oriented Interface

```text
public function getAuthnRequestIsPassive();
public function setAuthnRequestIsPassive($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 39 );
secureblackbox_samlwriter_set($res, 39, $value );
```

## Default Value

false

## Remarks

Maps to the IsPassive parameter of the request.

Use this property to access or set the IsPassive parameter of the authentication request. IsPassive sets out the control the identity provider and user agent have over the authenticating users UI.

This property is not available at design time.

## Data Type

Boolean

# AuthnRequestNameIDPolicyAllowCreate Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Matches the AllowCreate attribute of NameIDPolicy element of the request.

## Object Oriented Interface

```text
public function getAuthnRequestNameIDPolicyAllowCreate();
public function setAuthnRequestNameIDPolicyAllowCreate($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 40 );
secureblackbox_samlwriter_set($res, 40, $value );
```

## Default Value

false

## Remarks

Matches the AllowCreate attribute of NameIDPolicy element of the request.

Use this property to access or set the AllowCreate attribute of NameIDPolicy, which allows or disallows the identity provider to create a new identifier when processing the authentication request.

This property is not available at design time.

## Data Type

Boolean

# AuthnRequestNameIDPolicyFormat Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Matches to the Format attribute of the NameIDPolicy element of the request.

## Object Oriented Interface

```text
public function getAuthnRequestNameIDPolicyFormat();
public function setAuthnRequestNameIDPolicyFormat($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 41 );
secureblackbox_samlwriter_set($res, 41, $value );
```

## Default Value

''

## Remarks

Matches to the Format attribute of the NameIDPolicy element of the request.

Use this property to access or set the Format attribute of NameIDPolicy.

This property is not available at design time.

## Data Type

String

# AuthnRequestNameIDPolicySPNameQualifier Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Matches to the SP name qualifier attribute of the request.

## Object Oriented Interface

```text
public function getAuthnRequestNameIDPolicySPNameQualifier();
public function setAuthnRequestNameIDPolicySPNameQualifier($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 42 );
secureblackbox_samlwriter_set($res, 42, $value );
```

## Default Value

''

## Remarks

Matches to the SP name qualifier attribute of the request.

Use this property to access or set the SP name qualifier attribute of the authentication request.

This property is not available at design time.

## Data Type

String

# AuthnRequestProtocolBinding Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Specifies the protocol binding to be requested in the authentication request.

## Object Oriented Interface

```text
public function getAuthnRequestProtocolBinding();
public function setAuthnRequestProtocolBinding($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 43 );
secureblackbox_samlwriter_set($res, 43, $value );
```

## Default Value

''

## Remarks

Specifies the protocol binding to be requested in the authentication request.

Use this property to check or set the protocol binding to be used when responding to this request.

This property is not available at design time.

## Data Type

String

# AuthnRequestProviderName Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Specifies the name of the requestor.

## Object Oriented Interface

```text
public function getAuthnRequestProviderName();
public function setAuthnRequestProviderName($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 44 );
secureblackbox_samlwriter_set($res, 44, $value );
```

## Default Value

''

## Remarks

Specifies the name of the requestor.

Use this property to read or set the name of the requestor.

This property is not available at design time.

## Data Type

String

# AuthnRequestScopingGetComplete Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Matches the GetComplete element of the IDPList entry of the Scoping object.

## Object Oriented Interface

```text
public function getAuthnRequestScopingGetComplete();
public function setAuthnRequestScopingGetComplete($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 45 );
secureblackbox_samlwriter_set($res, 45, $value );
```

## Default Value

''

## Remarks

Matches the GetComplete element of the IDPList entry of the Scoping object.

Use this property to access or set the GetComplete element of the IDPList entry of the Scoping object of the authentication request. This property typically contains an URI that allows to retrieve a complete list of identity providers.

This property is not available at design time.

## Data Type

String

# AuthnRequestScopingProxyCount Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

The maximum number of proxies on the way between the requestor and the provider.

## Object Oriented Interface

```text
public function getAuthnRequestScopingProxyCount();
public function setAuthnRequestScopingProxyCount($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 46 );
secureblackbox_samlwriter_set($res, 46, $value );
```

## Default Value

0

## Remarks

The maximum number of proxies on the way between the requestor and the provider.

Use this property to get or set the maximum number of intermediaries allowed between the requestor and the provider.

This property is not available at design time.

## Data Type

Integer

# AuthnRequestScopingRequesterIDs Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

A collection of requestor IDs on whose behalf the request is being sent.

## Object Oriented Interface

```text
public function getAuthnRequestScopingRequesterIDs();
public function setAuthnRequestScopingRequesterIDs($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 47 );
secureblackbox_samlwriter_set($res, 47, $value );
```

## Default Value

''

## Remarks

A collection of requestor IDs on whose behalf the request is being sent.

Use this property to specify or read the requestor IDs, in the form of CRLF-separated strings, on whose behalf the request is being sent.

This property is not available at design time.

## Data Type

String

# AuthzDecisionQueryActions Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Specifies the list of actions included in the query.

## Object Oriented Interface

```text
public function getAuthzDecisionQueryActions();
public function setAuthzDecisionQueryActions($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 48 );
secureblackbox_samlwriter_set($res, 48, $value );
```

## Default Value

''

## Remarks

Specifies the list of actions included in the query.

Read or set this property to access the list of actions (as CRLF-separated strings) included in the query.

This property is not available at design time.

## Data Type

String

# AuthzDecisionQueryResource Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Matches the Resource element of the query.

## Object Oriented Interface

```text
public function getAuthzDecisionQueryResource();
public function setAuthzDecisionQueryResource($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 49 );
secureblackbox_samlwriter_set($res, 49, $value );
```

## Default Value

''

## Remarks

Matches the Resource element of the query.

Use this property to read or set the Resource element of the authorization decision query.

This property is not available at design time.

## Data Type

String

# BindingType Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Specifies the type of SAML binding to use.

## Object Oriented Interface

```text
public function getBindingType();
public function setBindingType($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 50 );
secureblackbox_samlwriter_set($res, 50, $value );
```

## Possible Values

```text
SAMLWRITER_BINDINGTYPE_NONE(0), SAMLWRITER_BINDINGTYPE_SOAP(1), SAMLWRITER_BINDINGTYPE_PAOS(2), SAMLWRITER_BINDINGTYPE_REDIRECT(3), SAMLWRITER_BINDINGTYPE_POST(4), SAMLWRITER_BINDINGTYPE_ARTIFACT(5)
```

## Default Value

0

## Remarks

Specifies the type of SAML binding to use.

Use this property to specify the binding type to use with the request.

This property is not available at design time.

## Data Type

Integer

# BindingBody Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Contains the POST binding form body.

## Object Oriented Interface

```text
public function getBindingBody();
public function setBindingBody($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 51 );
secureblackbox_samlwriter_set($res, 51, $value );
```

## Default Value

''

## Remarks

Contains the POST binding form body.

Use this property to read or set the body of the form returned by the service provider.

This property is not available at design time.

## Data Type

String

# BindingEncoding Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Specifies the message encoding.

## Object Oriented Interface

```text
public function getBindingEncoding();
public function setBindingEncoding($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 52 );
secureblackbox_samlwriter_set($res, 52, $value );
```

## Default Value

''

## Remarks

Specifies the message encoding.

Use this property to access or set the message encoding.

This property is not available at design time.

## Data Type

String

# BindingForceSign Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Enforces a signature over all outgoing messages.

## Object Oriented Interface

```text
public function getBindingForceSign();
public function setBindingForceSign($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 53 );
secureblackbox_samlwriter_set($res, 53, $value );
```

## Default Value

false

## Remarks

Enforces a signature over all outgoing messages.

Use this property to enforce signing of all outgoing messages, independently of whether the original message was signed or not. See also [BindingSign](#SAMLWriter_p_BindingSign).

This property is not available at design time.

## Data Type

Boolean

# BindingFormTemplate Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Contains the XHTML form template returned by the service provider.

## Object Oriented Interface

```text
public function getBindingFormTemplate();
public function setBindingFormTemplate($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 54 );
secureblackbox_samlwriter_set($res, 54, $value );
```

## Default Value

''

## Remarks

Contains the XHTML form template returned by the service provider.

Use this property to access or set the template of a POST form provided by the service provider (POST binding only).

This property is not available at design time.

## Data Type

String

# BindingPOSTMode Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Specifies whether binding is applied on the server, or on the client side.

## Object Oriented Interface

```text
public function getBindingPOSTMode();
public function setBindingPOSTMode($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 55 );
secureblackbox_samlwriter_set($res, 55, $value );
```

## Possible Values

```text
SAMLWRITER_BINDINGPOSTMODE_CLIENT(0), SAMLWRITER_BINDINGPOSTMODE_SERVER(1)
```

## Default Value

0

## Remarks

Specifies whether binding is applied on the server, or on the client side.

Use this property to specify whether POST binding is used on the server or client side of the communication. The default value is cspmClient.

This property is not available at design time.

## Data Type

Integer

# BindingRelayState Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Contains the RelayState parameter of the binding.

## Object Oriented Interface

```text
public function getBindingRelayState();
public function setBindingRelayState($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 56 );
secureblackbox_samlwriter_set($res, 56, $value );
```

## Default Value

''

## Remarks

Contains the RelayState parameter of the binding.

Use this property to access or set the RelayState parameter of the binding. This is an uninterpreted state string that should be passed back to the service provider with subsequent requests.

This property is not available at design time.

## Data Type

String

# BindingSignatureAlgorithm Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Contains the signature algorithm.

## Object Oriented Interface

```text
public function getBindingSignatureAlgorithm();
public function setBindingSignatureAlgorithm($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 57 );
secureblackbox_samlwriter_set($res, 57, $value );
```

## Default Value

''

## Remarks

Contains the signature algorithm.

Use this property to get or set the signature algorithm. This corresponds to the SigAlg query string parameter, and contains the URI of the signature algorithm.

This property is not available at design time.

## Data Type

String

# BindingSignatureValidationResult Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

The outcome of the cryptographic signature validation.

## Object Oriented Interface

```text
public function getBindingSignatureValidationResult();
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 58 );
```

## Possible Values

```text
SAMLWRITER_BINDINGSIGNATUREVALIDATIONRESULT_VALID(0), SAMLWRITER_BINDINGSIGNATUREVALIDATIONRESULT_UNKNOWN(1), SAMLWRITER_BINDINGSIGNATUREVALIDATIONRESULT_CORRUPTED(2), SAMLWRITER_BINDINGSIGNATUREVALIDATIONRESULT_SIGNER_NOT_FOUND(3), SAMLWRITER_BINDINGSIGNATUREVALIDATIONRESULT_FAILURE(4), SAMLWRITER_BINDINGSIGNATUREVALIDATIONRESULT_REFERENCE_CORRUPTED(5)
```

## Default Value

0

## Remarks

The outcome of the cryptographic signature validation.

The following signature validity values are supported:

|  |  |  |
| --- | --- | --- |
| svtValid | 0 | The signature is valid |
| svtUnknown | 1 | Signature validity is unknown |
| svtCorrupted | 2 | The signature is corrupted |
| svtSignerNotFound | 3 | Failed to acquire the signing certificate. The signature cannot be validated. |
| svtFailure | 4 | General failure |
| svtReferenceCorrupted | 5 | Reference corrupted (XML-based signatures only) |

This property is read-only and not available at design time.

## Data Type

Integer

# BindingSigned Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Specifies whether to sign the binding.

## Object Oriented Interface

```text
public function getBindingSigned();
public function setBindingSigned($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 59 );
secureblackbox_samlwriter_set($res, 59, $value );
```

## Default Value

false

## Remarks

Specifies whether to sign the binding.

Use this property to enable or disable signing of generated binding entities. The SAML specification instructs that the binding should only be signed if the original XML was. This property therefore is only taken into account if the original XML was signed. With that in mind, certain service providers demand the binding to be signed at all times. Use [BindingForceSign](#bindingforcesign-property-secureblackbox_samlwriter-class) property to enforce signatures on all binding entities.

This property is not available at design time.

## Data Type

Boolean

# BindingURL Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Contains the URL of the request query.

## Object Oriented Interface

```text
public function getBindingURL();
public function setBindingURL($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 60 );
secureblackbox_samlwriter_set($res, 60, $value );
```

## Default Value

''

## Remarks

Contains the URL of the request query.

Use this property to read or set the URL of the request query or POST target.

This property is not available at design time.

## Data Type

String

# BindingVerifySignatures Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Instructs the class whether to verify incoming signatures.

## Object Oriented Interface

```text
public function getBindingVerifySignatures();
public function setBindingVerifySignatures($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 61 );
secureblackbox_samlwriter_set($res, 61, $value );
```

## Default Value

true

## Remarks

Instructs the component whether to verify incoming signatures.

Use this property to activate or deactivate verification of signatures in incoming requests.

This property is not available at design time.

## Data Type

Boolean

# BindingKeyHandle Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Allows to get or set a 'handle', a unique identifier of the underlying property object.

## Object Oriented Interface

```text
public function getBindingKeyHandle();
public function setBindingKeyHandle($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 67 );
secureblackbox_samlwriter_set($res, 67, $value );
```

## Default Value

0

## Remarks

Allows to get or set a 'handle', a unique identifier of the underlying property object. Use this property to assign objects of the same type in a quicker manner, without copying them fieldwise.

When you pass a handle of one object to another, the source object is copied to the destination rather than assigned. It is safe to get rid of the original object after such operation.

```text
  pdfSigner.setSigningCertHandle(certMgr.getCertHandle());
```

This property is not available at design time.

## Data Type

Long64

# ConditionCount Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

The number of records in the Condition arrays.

## Object Oriented Interface

```text
public function getConditionCount();
public function setConditionCount($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 77 );
secureblackbox_samlwriter_set($res, 77, $value );
```

## Default Value

0

## Remarks

This property controls the size of the following arrays:

- [Condition](#condition-property-secureblackbox_samlwriter-class)
- [ConditionType](#conditiontype-property-secureblackbox_samlwriter-class)

The array indices start at *0* and end at *ConditionCount - 1*.

This property is not available at design time.

## Data Type

Integer

# Condition Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

The condition set in accordance with the ConditionType .

## Object Oriented Interface

```text
public function getCondition($conditionindex);
public function setCondition($conditionindex, $value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 78 , $conditionindex);
secureblackbox_samlwriter_set($res, 78, $value , $conditionindex);
```

## Default Value

''

## Remarks

The condition set in accordance with the [ConditionType](#conditiontype-property-secureblackbox_samlwriter-class).

For csctAudienceRestriction conditions, read or set a list of audiences included in the restriction. Each audience is represented by an URI. Provide multiple audiences by splitting them with CRLF separators.

For csctProxyRestriction conditions, check or set the value of the proxy count restriction.

For csctNotBefore and csctNotOnOrAfter, check or set the respective date/time values.

The *$conditionindex* parameter specifies the index of the item in the array. The size of the array is controlled by the [ConditionCount](#conditioncount-property-secureblackbox_samlwriter-class) property.

This property is not available at design time.

## Data Type

String

# ConditionType Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Specifies a type of the condition object.

## Object Oriented Interface

```text
public function getConditionType($conditionindex);
public function setConditionType($conditionindex, $value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 79 , $conditionindex);
secureblackbox_samlwriter_set($res, 79, $value , $conditionindex);
```

## Possible Values

```text
SAMLWRITER_CONDITIONTYPE_AUDIENCE_RESTRICTION(0), SAMLWRITER_CONDITIONTYPE_ONE_TIME_USE(1), SAMLWRITER_CONDITIONTYPE_PROXY_RESTRICTION(2), SAMLWRITER_CONDITIONTYPE_NOT_BEFORE(3), SAMLWRITER_CONDITIONTYPE_NOT_ON_OR_AFTER(4)
```

## Default Value

0

## Remarks

Specifies a type of the condition object.

Use this property to check or specify the type of the condition object. This can be either an audience restriction, a one time use limitation, or a proxy restriction.

The *$conditionindex* parameter specifies the index of the item in the array. The size of the array is controlled by the [ConditionCount](#conditioncount-property-secureblackbox_samlwriter-class) property.

This property is not available at design time.

## Data Type

Integer

# EncryptionCertBytes Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Returns the raw certificate data in DER format.

## Object Oriented Interface

```text
public function getEncryptionCertBytes();
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 80 );
```

## Remarks

Returns the raw certificate data in DER format.

This property is read-only and not available at design time.

## Data Type

Byte Array

# EncryptionCertHandle Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Allows to get or set a 'handle', a unique identifier of the underlying property object.

## Object Oriented Interface

```text
public function getEncryptionCertHandle();
public function setEncryptionCertHandle($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 88 );
secureblackbox_samlwriter_set($res, 88, $value );
```

## Default Value

0

## Remarks

Allows to get or set a 'handle', a unique identifier of the underlying property object. Use this property to assign objects of the same type in a quicker manner, without copying them fieldwise.

When you pass a handle of one object to another, the source object is copied to the destination rather than assigned. It is safe to get rid of the original object after such operation.

```text
  pdfSigner.setSigningCertHandle(certMgr.getCertHandle());
```

This property is not available at design time.

## Data Type

Long64

# FIPSMode Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Reserved.

## Object Oriented Interface

```text
public function getFIPSMode();
public function setFIPSMode($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 119 );
secureblackbox_samlwriter_set($res, 119, $value );
```

## Default Value

false

## Remarks

This property is reserved for future use.

## Data Type

Boolean

# LogoutRequestNameID Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Contains the value of the NameID parameter.

## Object Oriented Interface

```text
public function getLogoutRequestNameID();
public function setLogoutRequestNameID($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 120 );
secureblackbox_samlwriter_set($res, 120, $value );
```

## Default Value

''

## Remarks

Contains the value of the NameID parameter.

Use this property to access or set the value of the NameID parameter of the request.

This property is not available at design time.

## Data Type

String

# LogoutRequestNotOnOrAfter Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Contains the value of the NotOnOrAfter parameter.

## Object Oriented Interface

```text
public function getLogoutRequestNotOnOrAfter();
public function setLogoutRequestNotOnOrAfter($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 121 );
secureblackbox_samlwriter_set($res, 121, $value );
```

## Default Value

''

## Remarks

Contains the value of the NotOnOrAfter parameter.

Use this property to access or set the value of the NotOnOrAfter parameter.

This property is not available at design time.

## Data Type

String

# LogoutRequestReason Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Contains the value of the Reason parameter.

## Object Oriented Interface

```text
public function getLogoutRequestReason();
public function setLogoutRequestReason($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 122 );
secureblackbox_samlwriter_set($res, 122, $value );
```

## Default Value

''

## Remarks

Contains the value of the Reason parameter.

Use this property to read or set the value of the Reason parameter.

This property is not available at design time.

## Data Type

String

# LogoutRequestSessionIndexes Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Contains the list of session indices.

## Object Oriented Interface

```text
public function getLogoutRequestSessionIndexes();
public function setLogoutRequestSessionIndexes($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 123 );
secureblackbox_samlwriter_set($res, 123, $value );
```

## Default Value

''

## Remarks

Contains the list of session indices.

Use this property to access or set the list of session indices, as a CRLF-separated list of strings.

This property is not available at design time.

## Data Type

String

# ManageNameIDRequestNameID Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Contains the value of the NameID parameter of the request.

## Object Oriented Interface

```text
public function getManageNameIDRequestNameID();
public function setManageNameIDRequestNameID($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 124 );
secureblackbox_samlwriter_set($res, 124, $value );
```

## Default Value

''

## Remarks

Contains the value of the NameID parameter of the request.

Use this property to read or set the value of the NameID parameter of the request.

This property is not available at design time.

## Data Type

String

# ManageNameIDRequestNewEncryptedID Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Contains the value of the NewEncryptedID parameter of the request.

## Object Oriented Interface

```text
public function getManageNameIDRequestNewEncryptedID();
public function setManageNameIDRequestNewEncryptedID($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 125 );
secureblackbox_samlwriter_set($res, 125, $value );
```

## Default Value

''

## Remarks

Contains the value of the NewEncryptedID parameter of the request.

Use this property to check or set the value of the NewEncryptedID parameter of the request.

This property is not available at design time.

## Data Type

String

# ManageNameIDRequestNewID Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Contains the value of the NewID parameter.

## Object Oriented Interface

```text
public function getManageNameIDRequestNewID();
public function setManageNameIDRequestNewID($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 126 );
secureblackbox_samlwriter_set($res, 126, $value );
```

## Default Value

''

## Remarks

Contains the value of the NewID parameter.

Use this property to access or set the NewID parameter of the request.

This property is not available at design time.

## Data Type

String

# ManageNameIDRequestTerminate Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Contains the value of the Terminate parameter of the request.

## Object Oriented Interface

```text
public function getManageNameIDRequestTerminate();
public function setManageNameIDRequestTerminate($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 127 );
secureblackbox_samlwriter_set($res, 127, $value );
```

## Default Value

''

## Remarks

Contains the value of the Terminate parameter of the request.

Use this property to read or set the value of the Terminate parameter of the request.

This property is not available at design time.

## Data Type

String

# MessageConsent Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Contains the Consent parameter of the SAML message.

## Object Oriented Interface

```text
public function getMessageConsent();
public function setMessageConsent($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 128 );
secureblackbox_samlwriter_set($res, 128, $value );
```

## Default Value

''

## Remarks

Contains the Consent parameter of the SAML message.

Use this property to specify the Consent parameter of the SAML entity.

This property is not available at design time.

## Data Type

String

# MessageContentType Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Returns the SAML type of the current message.

## Object Oriented Interface

```text
public function getMessageContentType();
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 129 );
```

## Possible Values

```text
SAMLWRITER_MESSAGECONTENTTYPE_NONE(0), SAMLWRITER_MESSAGECONTENTTYPE_ASSERTION_IDREQUEST(1), SAMLWRITER_MESSAGECONTENTTYPE_SUBJECT_QUERY(2), SAMLWRITER_MESSAGECONTENTTYPE_AUTHN_QUERY(3), SAMLWRITER_MESSAGECONTENTTYPE_ATTRIBUTE_QUERY(4), SAMLWRITER_MESSAGECONTENTTYPE_AUTHZ_DECISION_QUERY(5), SAMLWRITER_MESSAGECONTENTTYPE_AUTHN_REQUEST(6), SAMLWRITER_MESSAGECONTENTTYPE_MANAGE_NAME_IDREQUEST(7), SAMLWRITER_MESSAGECONTENTTYPE_LOGOUT_REQUEST(8), SAMLWRITER_MESSAGECONTENTTYPE_NAME_IDMAPPING_REQUEST(9), SAMLWRITER_MESSAGECONTENTTYPE_ARTIFACT_RESOLVE(10), SAMLWRITER_MESSAGECONTENTTYPE_RESPONSE(11), SAMLWRITER_MESSAGECONTENTTYPE_ASSERTION(12)
```

## Default Value

0

## Remarks

Returns the SAML type of the current message.

Use this property to check the type of SAML message being created. This is the same value that was passed to CreateNew call.

Depending on the assigned type, use properties of class to tune up the parameters of the chosen message type. For example, if the content type is cstyAuthnQuery, use AuthnQuery property to adjust context class references or comparison settings.

This property is read-only and not available at design time.

## Data Type

Integer

# MessageContentTypeString Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Returns the type of the processed message, as an original string.

## Object Oriented Interface

```text
public function getMessageContentTypeString();
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 130 );
```

## Default Value

''

## Remarks

Returns the type of the processed message, as an original string.

Check this property to find out the content type of the data stored in the processed message. This returns a string originally included in the SAML message, which may be helpful when processing non-standard types.

Known SAML content types are:

- AssertionIDRequest
- SubjectQuery
- AuthnQuery
- AttributeQuery
- AuthzDecisionQuery
- AuthnRequest
- ManageNameIDRequest
- NameIDMappingRequest
- LogoutRequest
- ArtifactResolve
- Response
- LogoutResponse
- ArtifactResponse
- NameIDMappingResponse

This property is read-only and not available at design time.

## Data Type

String

# MessageDestination Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Contains the Destination parameter of the SAML message.

## Object Oriented Interface

```text
public function getMessageDestination();
public function setMessageDestination($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 131 );
secureblackbox_samlwriter_set($res, 131, $value );
```

## Default Value

''

## Remarks

Contains the Destination parameter of the SAML message.

Use this property to set the Destination parameter of the created SAML object.

This property is not available at design time.

## Data Type

String

# MessageID Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

The ID of the request.

## Object Oriented Interface

```text
public function getMessageID();
public function setMessageID($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 132 );
secureblackbox_samlwriter_set($res, 132, $value );
```

## Default Value

''

## Remarks

The ID of the request.

Use this property to specify the ID of the SAML request or response.

This property is not available at design time.

## Data Type

String

# MessageInResponseTo Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Contains the InResponseTo property of the SAML request.

## Object Oriented Interface

```text
public function getMessageInResponseTo();
public function setMessageInResponseTo($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 133 );
secureblackbox_samlwriter_set($res, 133, $value );
```

## Default Value

''

## Remarks

Contains the InResponseTo property of the SAML request.

Use this property to specify the ID of the message in response to which the current entity is provided.

This property is not available at design time.

## Data Type

String

# MessageIssueInstant Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Contains request issuance timestamp.

## Object Oriented Interface

```text
public function getMessageIssueInstant();
public function setMessageIssueInstant($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 134 );
secureblackbox_samlwriter_set($res, 134, $value );
```

## Default Value

''

## Remarks

Contains request issuance timestamp.

Set this property to specify the time moment of the request formation. Leave it empty to use the current system time.

This property is not available at design time.

## Data Type

String

# MessageIssuer Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Sets the issuer of the message.

## Object Oriented Interface

```text
public function getMessageIssuer();
public function setMessageIssuer($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 135 );
secureblackbox_samlwriter_set($res, 135, $value );
```

## Default Value

''

## Remarks

Sets the issuer of the message.

Set this property to include the SAML ID of the issuer of the SAML message. A typical SAML ID is a string of semicolon-separated elements of one or more of the following elements:

- Format
- NameQualifier
- Value
- IDType
- SPNameQualifier
- SPProvidedID

 For example,

```text
  writer.Message.Issuer = "Value=https://saml.entity.org/resource;Format=urn:oasis:names:tc:SAML:2.0:nameid-format:entity;IDType=Issuer";
```

This property is not available at design time.

## Data Type

String

# MessageSignatureValidationResult Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

The outcome of the cryptographic signature validation.

## Object Oriented Interface

```text
public function getMessageSignatureValidationResult();
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 136 );
```

## Possible Values

```text
SAMLWRITER_MESSAGESIGNATUREVALIDATIONRESULT_VALID(0), SAMLWRITER_MESSAGESIGNATUREVALIDATIONRESULT_UNKNOWN(1), SAMLWRITER_MESSAGESIGNATUREVALIDATIONRESULT_CORRUPTED(2), SAMLWRITER_MESSAGESIGNATUREVALIDATIONRESULT_SIGNER_NOT_FOUND(3), SAMLWRITER_MESSAGESIGNATUREVALIDATIONRESULT_FAILURE(4), SAMLWRITER_MESSAGESIGNATUREVALIDATIONRESULT_REFERENCE_CORRUPTED(5)
```

## Default Value

0

## Remarks

The outcome of the cryptographic signature validation.

The following signature validity values are supported:

|  |  |  |
| --- | --- | --- |
| svtValid | 0 | The signature is valid |
| svtUnknown | 1 | Signature validity is unknown |
| svtCorrupted | 2 | The signature is corrupted |
| svtSignerNotFound | 3 | Failed to acquire the signing certificate. The signature cannot be validated. |
| svtFailure | 4 | General failure |
| svtReferenceCorrupted | 5 | Reference corrupted (XML-based signatures only) |

This property is read-only and not available at design time.

## Data Type

Integer

# MessageSigned Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Specifies whether the SAML message is or should be signed.

## Object Oriented Interface

```text
public function getMessageSigned();
public function setMessageSigned($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 137 );
secureblackbox_samlwriter_set($res, 137, $value );
```

## Default Value

false

## Remarks

Specifies whether the SAML message is or should be signed.

Check this property to find out whether the processed message was signed by the sender, or set this property to true to indicate that the created message should be signed.

This property is not available at design time.

## Data Type

Boolean

# MessageSubject Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Gets or sets the subject of the message.

## Object Oriented Interface

```text
public function getMessageSubject();
public function setMessageSubject($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 138 );
secureblackbox_samlwriter_set($res, 138, $value );
```

## Default Value

''

## Remarks

Gets or sets the subject of the message.

Check this property to obtain the SAML ID of the message subject.

Set this property to include the SAML ID of the issuer of the SAML message. A typical SAML ID is a string of semicolon-separated elements of one or more of the following elements:

- Format
- NameQualifier
- Value
- IDType
- SPNameQualifier
- SPProvidedID

 For example,

```text
  writer.Message.Subject = "Value=https://saml.entity.org/resource;Format=urn:oasis:names:tc:SAML:2.0:nameid-format:entity;IDType=Issuer";
```

This property is not available at design time.

## Data Type

String

# MessageVersion Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Specifies the protocol version to use for the SAML message.

## Object Oriented Interface

```text
public function getMessageVersion();
public function setMessageVersion($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 139 );
secureblackbox_samlwriter_set($res, 139, $value );
```

## Default Value

'2.0'

## Remarks

Specifies the protocol version to use for the SAML message.

Use this property to change the SAML version that the message complies to. This is set to 2.0 by default, and rarely needs to change.

This property is not available at design time.

## Data Type

String

# MessageXMLHeader Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Controls the inclusion of an XML header in the message.

## Object Oriented Interface

```text
public function getMessageXMLHeader();
public function setMessageXMLHeader($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 140 );
secureblackbox_samlwriter_set($res, 140, $value );
```

## Default Value

false

## Remarks

Controls the inclusion of an XML header in the message.

Use this property to enable or disable inclusion of the XML header in the SAML message.

This property is not available at design time.

## Data Type

Boolean

# NameIDMappingRequestNameID Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

An accessor to the NameID parameter of the request.

## Object Oriented Interface

```text
public function getNameIDMappingRequestNameID();
public function setNameIDMappingRequestNameID($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 141 );
secureblackbox_samlwriter_set($res, 141, $value );
```

## Default Value

''

## Remarks

An accessor to the NameID parameter of the request.

Use this property to read or set the value of the NameID parameter of the request object.

This property is not available at design time.

## Data Type

String

# NameIDMappingRequestNameIDPolicyAllowCreate Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Contains the value of AllowCreate parameter of the NameIDPolicy object.

## Object Oriented Interface

```text
public function getNameIDMappingRequestNameIDPolicyAllowCreate();
public function setNameIDMappingRequestNameIDPolicyAllowCreate($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 142 );
secureblackbox_samlwriter_set($res, 142, $value );
```

## Default Value

false

## Remarks

Contains the value of AllowCreate parameter of the NameIDPolicy object.

Use this property to read or set the value of the AllowCreate parameter of the NameIDPolicy object. AllowCreate regulates whether the identity provider is given permission to create new subject identifiers.

This property is not available at design time.

## Data Type

Boolean

# NameIDMappingRequestNameIDPolicyFormat Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Specifies the format of the NameIDPolicy element.

## Object Oriented Interface

```text
public function getNameIDMappingRequestNameIDPolicyFormat();
public function setNameIDMappingRequestNameIDPolicyFormat($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 143 );
secureblackbox_samlwriter_set($res, 143, $value );
```

## Default Value

''

## Remarks

Specifies the format of the NameIDPolicy element.

Use this property to set or read the value of the Format parameter of the NameIDPolicy object.

This property is not available at design time.

## Data Type

String

# NameIDMappingRequestNameIDPolicySPNameQualifier Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Contains the SPNameQualifier parameter of the NameIDPolicy element.

## Object Oriented Interface

```text
public function getNameIDMappingRequestNameIDPolicySPNameQualifier();
public function setNameIDMappingRequestNameIDPolicySPNameQualifier($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 144 );
secureblackbox_samlwriter_set($res, 144, $value );
```

## Default Value

''

## Remarks

Contains the SPNameQualifier parameter of the NameIDPolicy element.

Use this property to specify or read the value of the SPNameQualifier parameter of the NameIDPolicy element of the request.

This property is not available at design time.

## Data Type

String

# NameIDMappingRequestNameIDPolicyUseAllowCreate Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Controls inclusion of UseAllow modifier in the NameIDPolicy object.

## Object Oriented Interface

```text
public function getNameIDMappingRequestNameIDPolicyUseAllowCreate();
public function setNameIDMappingRequestNameIDPolicyUseAllowCreate($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 145 );
secureblackbox_samlwriter_set($res, 145, $value );
```

## Default Value

false

## Remarks

Controls inclusion of UseAllow modifier in the NameIDPolicy object.

Use this property to include or exclude the UseAllow parameter from the NameIDPolicy object.

This property is not available at design time.

## Data Type

Boolean

# Profile Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Specifies a pre-defined profile to apply when creating the signature.

## Object Oriented Interface

```text
public function getProfile();
public function setProfile($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 146 );
secureblackbox_samlwriter_set($res, 146, $value );
```

## Default Value

''

## Remarks

Advanced signatures come in many variants, which are often defined by parties that needs to process them or by local standards. SecureBlackbox profiles are sets of pre-defined configurations which correspond to particular signature variants. By specifying a profile, you are pre-configuring the component to make it produce the signature that matches the configuration corresponding to that profile.

## Data Type

String

# References Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Contains the References entry of the SAML AssertionIDRequest message.

## Object Oriented Interface

```text
public function getReferences();
public function setReferences($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 147 );
secureblackbox_samlwriter_set($res, 147, $value );
```

## Default Value

''

## Remarks

Use this property to read or specify the value of the References entry of the AssertionIDRequest message.

This property is not available at design time.

## Data Type

String

# ResponseNameID Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Contains the NameID parameter of a NameIDMapping response.

## Object Oriented Interface

```text
public function getResponseNameID();
public function setResponseNameID($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 148 );
secureblackbox_samlwriter_set($res, 148, $value );
```

## Default Value

''

## Remarks

Contains the NameID parameter of a NameIDMapping response.

Use this property to read or set the NameID parameter of the NameIDMapping response.

This property is not available at design time.

## Data Type

String

# ResponseOptionalElement Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

An optional message element to be returned with the response.

## Object Oriented Interface

```text
public function getResponseOptionalElement();
public function setResponseOptionalElement($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 149 );
secureblackbox_samlwriter_set($res, 149, $value );
```

## Default Value

''

## Remarks

An optional message element to be returned with the response.

Use this property to access or set the optional XML element returned with the response.

This property is not available at design time.

## Data Type

String

# ResponseType Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Contains the type of the response.

## Object Oriented Interface

```text
public function getResponseType();
public function setResponseType($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 150 );
secureblackbox_samlwriter_set($res, 150, $value );
```

## Possible Values

```text
SAMLWRITER_RESPONSETYPE_RESPONSE(0), SAMLWRITER_RESPONSETYPE_ARTIFACT_RESPONSE(1), SAMLWRITER_RESPONSETYPE_NAME_IDMAPPING_RESPONSE(2), SAMLWRITER_RESPONSETYPE_LOGOUT_RESPONSE(3)
```

## Default Value

0

## Remarks

Contains the type of the response.

Use this property to get or set the type of the SAML response.

This property is not available at design time.

## Data Type

Integer

# ResponseStatus Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Gets or sets the status of the response.

## Object Oriented Interface

```text
public function getResponseStatus();
public function setResponseStatus($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 151 );
secureblackbox_samlwriter_set($res, 151, $value );
```

## Default Value

0

## Remarks

Gets or sets the status of the response.

This property specifies the status code to include in the response. This property adjusts the values of the [ResponseStatusCodeValue](#responsestatuscodevalue-property-secureblackbox_samlwriter-class) and other status properties.

This property is a bitwise combination of the status facility and an error code. The facility mask can be one of the following:

- 0x00000000 - Success (urn:oasis:names:tc:SAML:2.0:status:Success)
- 0x00010000 - Requester Error (urn:oasis:names:tc:SAML:2.0:status:Requester)
- 0x00020000 - Responder Error (urn:oasis:names:tc:SAML:2.0:status:Responder)
- 0x00030000 - Version Mismatch (urn:oasis:names:tc:SAML:2.0:status:VersionMismatch)
- 0x00FF0000 - Undefined or Unknown

The code assigned to the setting is saved in the response as the status given in the brackets.

 The error code can take one of the following values:

- 0x00000001 - Authentication Failed (urn:oasis:names:tc:SAML:2.0:status:AuthnFailed)
- 0x00000002 - Unsupported content received within the received Attribute structure (urn:oasis:names:tc:SAML:2.0:status:InvalidAttrNameOrValue)
- 0x00000003 - The requested Name Identifier policy is not supported by the provider (urn:oasis:names:tc:SAML:2.0:status:InvalidNameIDPolicy)
- 0x00000004 - The requested Authentication Context requirements cannot be satisfied by the provider (urn:oasis:names:tc:SAML:2.0:status:NoAuthnContext)
- 0x00000005 - None of the elements in the IDP list can be resolved (urn:oasis:names:tc:SAML:2.0:status:NoAvailableIDP)
- 0x00000006 - The provider cannot authenticate the requestor passively (urn:oasis:names:tc:SAML:2.0:status:NoPassive)
- 0x00000007 - None of the requested providers in the IDP list are supported (urn:oasis:names:tc:SAML:2.0:status:NoSupportedIDP)
- 0x00000008 - The Logout request could not be passed on to other session participants (urn:oasis:names:tc:SAML:2.0:status:PartialLogout)
- 0x00000009 - Proxy count exceeded (urn:oasis:names:tc:SAML:2.0:status:ProxyCountExceeded)
- 0x0000000A - Request denied for internal reasons (urn:oasis:names:tc:SAML:2.0:status:RequestDenied)
- 0x0000000B - The request or its type is not supported by the provider (urn:oasis:names:tc:SAML:2.0:status:RequestUnsupported)
- 0x0000000C - The version of the request has been deprecated (urn:oasis:names:tc:SAML:2.0:status:RequestVersionDeprecated)
- 0x0000000D - The version of the request is too high (urn:oasis:names:tc:SAML:2.0:status:RequestVersionTooHigh)
- 0x0000000E - The version of the request is too low (urn:oasis:names:tc:SAML:2.0:status:RequestVersionTooLow)
- 0x0000000F - The resource included in the request has not been recognised (urn:oasis:names:tc:SAML:2.0:status:ResourceNotRecognized)
- 0x00000010 - The number of responses to be returned is too high for the provider to satisfy (urn:oasis:names:tc:SAML:2.0:status:TooManyResponses)
- 0x00000011 - The attribute profile is unknown to the provider (urn:oasis:names:tc:SAML:2.0:status:UnknownAttrProfile)
- 0x00000012 - The principal mentioned in the request is unknown to the provider (urn:oasis:names:tc:SAML:2.0:status:UnknownPrincipal)
- 0x00000013 - Unsupported binding type (urn:oasis:names:tc:SAML:2.0:status:UnsupportedBinding)

To return a custom error code not available via the above flags, use [ResponseStatusCodeValue](#responsestatuscodevalue-property-secureblackbox_samlwriter-class) and [ResponseStatusCodeSubValue](#responsestatuscodesubvalue-property-secureblackbox_samlwriter-class) properties.

This property is not available at design time.

## Data Type

Integer

# ResponseStatusCodeSubValue Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

The value of the nested StatusCode.

## Object Oriented Interface

```text
public function getResponseStatusCodeSubValue();
public function setResponseStatusCodeSubValue($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 152 );
secureblackbox_samlwriter_set($res, 152, $value );
```

## Default Value

''

## Remarks

The value of the nested StatusCode.

This property contains the value of the nested StatusCode element.

This property is not available at design time.

## Data Type

String

# ResponseStatusCodeValue Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Contains the status code value.

## Object Oriented Interface

```text
public function getResponseStatusCodeValue();
public function setResponseStatusCodeValue($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 153 );
secureblackbox_samlwriter_set($res, 153, $value );
```

## Default Value

''

## Remarks

Contains the status code value.

Use this property to read or set one of the status codes defined by SAML specification, such as 'urn:oasis:names:tc:SAML:2.0:status:Success' or 'urn:oasis:names:tc:SAML:2.0:status:Requester'.

This property is not available at design time.

## Data Type

String

# ResponseStatusDetail Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Contains additional information on the status of the request.

## Object Oriented Interface

```text
public function getResponseStatusDetail();
public function setResponseStatusDetail($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 154 );
secureblackbox_samlwriter_set($res, 154, $value );
```

## Default Value

''

## Remarks

Contains additional information on the status of the request.

The StatusDetail element contains additional request status information.

This property is not available at design time.

## Data Type

String

# ResponseStatusMessage Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Contains a status message (optional).

## Object Oriented Interface

```text
public function getResponseStatusMessage();
public function setResponseStatusMessage($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 155 );
secureblackbox_samlwriter_set($res, 155, $value );
```

## Default Value

''

## Remarks

Contains a status message (optional).

This property specifies the status message which may, optionally, be returned to an operator.

This property is not available at design time.

## Data Type

String

# ScopingIDPCount Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

The number of records in the ScopingIDP arrays.

## Object Oriented Interface

```text
public function getScopingIDPCount();
public function setScopingIDPCount($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 156 );
secureblackbox_samlwriter_set($res, 156, $value );
```

## Default Value

0

## Remarks

This property controls the size of the following arrays:

- [ScopingIDPLoc](#scopingidploc-property-secureblackbox_samlwriter-class)
- [ScopingIDPName](#scopingidpname-property-secureblackbox_samlwriter-class)
- [ScopingIDPProviderID](#scopingidpproviderid-property-secureblackbox_samlwriter-class)

The array indices start at *0* and end at *ScopingIDPCount - 1*.

This property is not available at design time.

## Data Type

Integer

# ScopingIDPLoc Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Contains the value of the Loc attribute.

## Object Oriented Interface

```text
public function getScopingIDPLoc($scopingidpindex);
public function setScopingIDPLoc($scopingidpindex, $value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 157 , $scopingidpindex);
secureblackbox_samlwriter_set($res, 157, $value , $scopingidpindex);
```

## Default Value

''

## Remarks

Contains the value of the Loc attribute.

Use this property to access or set the value of the Loc (location) attribute.

The *$scopingidpindex* parameter specifies the index of the item in the array. The size of the array is controlled by the [ScopingIDPCount](#scopingidpcount-property-secureblackbox_samlwriter-class) property.

This property is not available at design time.

## Data Type

String

# ScopingIDPName Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Contains the name of the IdP provider.

## Object Oriented Interface

```text
public function getScopingIDPName($scopingidpindex);
public function setScopingIDPName($scopingidpindex, $value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 158 , $scopingidpindex);
secureblackbox_samlwriter_set($res, 158, $value , $scopingidpindex);
```

## Default Value

''

## Remarks

Contains the name of the IdP provider.

Use this property to retrieve or set the *Name* attribute of the IdP provider.

The *$scopingidpindex* parameter specifies the index of the item in the array. The size of the array is controlled by the [ScopingIDPCount](#scopingidpcount-property-secureblackbox_samlwriter-class) property.

This property is not available at design time.

## Data Type

String

# ScopingIDPProviderID Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Contains the provider ID.

## Object Oriented Interface

```text
public function getScopingIDPProviderID($scopingidpindex);
public function setScopingIDPProviderID($scopingidpindex, $value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 159 , $scopingidpindex);
secureblackbox_samlwriter_set($res, 159, $value , $scopingidpindex);
```

## Default Value

''

## Remarks

Contains the provider ID.

Use this property to read or set the identity provider ID.

The *$scopingidpindex* parameter specifies the index of the item in the array. The size of the array is controlled by the [ScopingIDPCount](#scopingidpcount-property-secureblackbox_samlwriter-class) property.

This property is not available at design time.

## Data Type

String

# SecurityCanonicalizationMethod Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

The canonicalization method to use in the signature.

## Object Oriented Interface

```text
public function getSecurityCanonicalizationMethod();
public function setSecurityCanonicalizationMethod($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 160 );
secureblackbox_samlwriter_set($res, 160, $value );
```

## Default Value

''

## Remarks

The canonicalization method to use in the signature.

The URI of the canonicalization method to use in the signature (e.g. http://www.w3.org/TR/xml-exc-c14n/)

This property is not available at design time.

## Data Type

String

# SecurityDigestMethod Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

The digest method to use.

## Object Oriented Interface

```text
public function getSecurityDigestMethod();
public function setSecurityDigestMethod($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 161 );
secureblackbox_samlwriter_set($res, 161, $value );
```

## Default Value

''

## Remarks

The digest method to use.

The URI of the digest method to use for signing, as defined in XMLDSIG or XMLENC: http://www.w3.org/2000/09/xmldsig#sha256.

This property is not available at design time.

## Data Type

String

# SecurityEncryptionMethod Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

The encryption method used to encrypt the assertion.

## Object Oriented Interface

```text
public function getSecurityEncryptionMethod();
public function setSecurityEncryptionMethod($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 162 );
secureblackbox_samlwriter_set($res, 162, $value );
```

## Default Value

'AES256'

## Remarks

The encryption method used to encrypt the assertion.

This property contains the encryption algorithm used to encrypt the XML assertion.

Supported values:

|  |  |  |
| --- | --- | --- |
| SB_XML_ENCRYPTION_ALGORITHM_RC4 | RC4 |  |
| SB_XML_ENCRYPTION_ALGORITHM_DES | DES |  |
| SB_XML_ENCRYPTION_ALGORITHM_3DES | 3DEST |  |
| SB_XML_ENCRYPTION_ALGORITHM_AES128 | AES128 |  |
| SB_XML_ENCRYPTION_ALGORITHM_AES192 | AES192 |  |
| SB_XML_ENCRYPTION_ALGORITHM_AES256 | AES256 |  |
| SB_XML_ENCRYPTION_ALGORITHM_CAMELLIA128 | Camellia128 |  |
| SB_XML_ENCRYPTION_ALGORITHM_CAMELLIA192 | Camellia192 |  |
| SB_XML_ENCRYPTION_ALGORITHM_CAMELLIA256 | Camellia256 |  |
| SB_XML_ENCRYPTION_ALGORITHM_SEED | SEED |  |

This property is not available at design time.

## Data Type

String

# SecurityFlags Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Provides access to secondary security parameters and tweaks.

## Object Oriented Interface

```text
public function getSecurityFlags();
public function setSecurityFlags($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 163 );
secureblackbox_samlwriter_set($res, 163, $value );
```

## Default Value

1

## Remarks

Provides access to secondary security parameters and tweaks.

This property is a bitwise combination of zero or more flags. The following flags are currently supported: The following flags can be used with any SAML component (although they may not apply in all modes of use):

|  |  |  |
| --- | --- | --- |
| ssfSignatureAfterIssuer | 1 | Place the Signature tag after the issuer tag in the XML document |
| ssfSignatureBeforeDescriptor | 2 | Place the Signature tag before the entity descriptor tag in the XML metadata |
| ssfKeyDataIssuerSerial | 4 | Include the IssuerSerial key data element |
| ssfKeyDataSKI | 8 | Include the SubjectKeyIdentifier key data element |
| ssfKeyDataSubjectName | 16 | Include the SubjectName key data element |
| ssfKeyDataCertificate | 32 | Include the Certificate key data element |
| ssfKeyDataCRL | 64 | Include the CRL key data element |
| ssfSignAuthnRequests | 65536 | Sign authentication requests (SP only) |
| ssfSignArtifactResolveRequests | 131072 | Sign artifact resolve requests |
| ssfSignLogoutRequests | 262144 | Sign logout requests |
| ssfSignAssertions | 524288 | Sign outgoing assertions (IdP only) |
| ssfSignResponses | 1048576 | Sign all responses (IdP only) |
| ssfEncryptAssertions | 2097152 | Encrypt generated assertions (IdP only) |

This property is not available at design time.

## Data Type

Integer

# SecuritySigMethod Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

The signature method to use.

## Object Oriented Interface

```text
public function getSecuritySigMethod();
public function setSecuritySigMethod($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 164 );
secureblackbox_samlwriter_set($res, 164, $value );
```

## Default Value

''

## Remarks

The signature method to use.

The URI specifying the signature method to use for signing, for example http://www.w3.org/2001/04/xmldsig-more#rsa-sha256.

This property is not available at design time.

## Data Type

String

# SecuritySignaturePolicy Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Specifies the signature validation policy.

## Object Oriented Interface

```text
public function getSecuritySignaturePolicy();
public function setSecuritySignaturePolicy($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 165 );
secureblackbox_samlwriter_set($res, 165, $value );
```

## Possible Values

```text
SAMLWRITER_SECURITYSIGNATUREPOLICY_AUTO(0), SAMLWRITER_SECURITYSIGNATUREPOLICY_VALIDATE(1), SAMLWRITER_SECURITYSIGNATUREPOLICY_REQUIRE(2), SAMLWRITER_SECURITYSIGNATUREPOLICY_IGNORE(3)
```

## Default Value

0

## Remarks

Specifies the signature validation policy.

Use this property to specify the signature validation policy for the component.

This property is not available at design time.

## Data Type

Integer

# SigningCertBytes Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Returns the raw certificate data in DER format.

## Object Oriented Interface

```text
public function getSigningCertBytes();
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 166 );
```

## Remarks

Returns the raw certificate data in DER format.

This property is read-only and not available at design time.

## Data Type

Byte Array

# SigningCertHandle Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Allows to get or set a 'handle', a unique identifier of the underlying property object.

## Object Oriented Interface

```text
public function getSigningCertHandle();
public function setSigningCertHandle($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 174 );
secureblackbox_samlwriter_set($res, 174, $value );
```

## Default Value

0

## Remarks

Allows to get or set a 'handle', a unique identifier of the underlying property object. Use this property to assign objects of the same type in a quicker manner, without copying them fieldwise.

When you pass a handle of one object to another, the source object is copied to the destination rather than assigned. It is safe to get rid of the original object after such operation.

```text
  pdfSigner.setSigningCertHandle(certMgr.getCertHandle());
```

This property is not available at design time.

## Data Type

Long64

# SigningChainCount Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

The number of records in the SigningChain arrays.

## Object Oriented Interface

```text
public function getSigningChainCount();
public function setSigningChainCount($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 205 );
secureblackbox_samlwriter_set($res, 205, $value );
```

## Default Value

0

## Remarks

This property controls the size of the following arrays:

- [SigningChainBytes](#signingchainbytes-property-secureblackbox_samlwriter-class)
- [SigningChainHandle](#signingchainhandle-property-secureblackbox_samlwriter-class)

The array indices start at *0* and end at *SigningChainCount - 1*.

This property is not available at design time.

## Data Type

Integer

# SigningChainBytes Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Returns the raw certificate data in DER format.

## Object Oriented Interface

```text
public function getSigningChainBytes($signingchainindex);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 206 , $signingchainindex);
```

## Remarks

Returns the raw certificate data in DER format.

The *$signingchainindex* parameter specifies the index of the item in the array. The size of the array is controlled by the [SigningChainCount](#signingchaincount-property-secureblackbox_samlwriter-class) property.

This property is read-only and not available at design time.

## Data Type

Byte Array

# SigningChainHandle Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Allows to get or set a 'handle', a unique identifier of the underlying property object.

## Object Oriented Interface

```text
public function getSigningChainHandle($signingchainindex);
public function setSigningChainHandle($signingchainindex, $value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 214 , $signingchainindex);
secureblackbox_samlwriter_set($res, 214, $value , $signingchainindex);
```

## Default Value

0

## Remarks

Allows to get or set a 'handle', a unique identifier of the underlying property object. Use this property to assign objects of the same type in a quicker manner, without copying them fieldwise.

When you pass a handle of one object to another, the source object is copied to the destination rather than assigned. It is safe to get rid of the original object after such operation.

```text
  pdfSigner.setSigningCertHandle(certMgr.getCertHandle());
```

The *$signingchainindex* parameter specifies the index of the item in the array. The size of the array is controlled by the [SigningChainCount](#signingchaincount-property-secureblackbox_samlwriter-class) property.

This property is not available at design time.

## Data Type

Long64

# StatementCount Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

The number of records in the Statement arrays.

## Object Oriented Interface

```text
public function getStatementCount();
public function setStatementCount($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 245 );
secureblackbox_samlwriter_set($res, 245, $value );
```

## Default Value

0

## Remarks

This property controls the size of the following arrays:

- [StatementAuthnContextAuthenticatingAuthorities](#statementauthncontextauthenticatingauthorities-property-secureblackbox_samlwriter-class)
- [StatementAuthnContextChoice](#statementauthncontextchoice-property-secureblackbox_samlwriter-class)
- [StatementAuthnContextClassRef](#statementauthncontextclassref-property-secureblackbox_samlwriter-class)
- [StatementAuthnContextDecl](#statementauthncontextdecl-property-secureblackbox_samlwriter-class)
- [StatementAuthnContextDeclRef](#statementauthncontextdeclref-property-secureblackbox_samlwriter-class)
- [StatementAuthnInstant](#statementauthninstant-property-secureblackbox_samlwriter-class)
- [StatementAuthnSessionIndex](#statementauthnsessionindex-property-secureblackbox_samlwriter-class)
- [StatementAuthnSessionNotOnOrAfter](#statementauthnsessionnotonorafter-property-secureblackbox_samlwriter-class)
- [StatementAuthnSubjectLocalityAddress](#statementauthnsubjectlocalityaddress-property-secureblackbox_samlwriter-class)
- [StatementAuthnSubjectLocalityDNSName](#statementauthnsubjectlocalitydnsname-property-secureblackbox_samlwriter-class)
- [StatementAuthzActions](#statementauthzactions-property-secureblackbox_samlwriter-class)
- [StatementAuthzDecision](#statementauthzdecision-property-secureblackbox_samlwriter-class)
- [StatementAuthzDecisionEvidence](#statementauthzdecisionevidence-property-secureblackbox_samlwriter-class)
- [StatementAuthzDecisionResource](#statementauthzdecisionresource-property-secureblackbox_samlwriter-class)
- [StatementType](#statementtype-property-secureblackbox_samlwriter-class)

The array indices start at *0* and end at *StatementCount - 1*.

This property is not available at design time.

## Data Type

Integer

# StatementAuthnContextAuthenticatingAuthorities Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Contains the list of authenticating authorities.

## Object Oriented Interface

```text
public function getStatementAuthnContextAuthenticatingAuthorities($statementindex);
public function setStatementAuthnContextAuthenticatingAuthorities($statementindex, $value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 246 , $statementindex);
secureblackbox_samlwriter_set($res, 246, $value , $statementindex);
```

## Default Value

''

## Remarks

Contains the list of authenticating authorities.

Use this property to access the list of URIs of authenticating authorities (IdP entity IDs).

The *$statementindex* parameter specifies the index of the item in the array. The size of the array is controlled by the [StatementCount](#statementcount-property-secureblackbox_samlwriter-class) property.

This property is not available at design time.

## Data Type

String

# StatementAuthnContextChoice Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Specifies the authentication context choice variant.

## Object Oriented Interface

```text
public function getStatementAuthnContextChoice($statementindex);
public function setStatementAuthnContextChoice($statementindex, $value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 247 , $statementindex);
secureblackbox_samlwriter_set($res, 247, $value , $statementindex);
```

## Default Value

''

## Remarks

Specifies the authentication context choice variant.

Use this property to set the authentication context choice variant. The currently supported values are *v1* and *v2*. If this setting is left empty, the *v1* variant is assumed.

The *$statementindex* parameter specifies the index of the item in the array. The size of the array is controlled by the [StatementCount](#statementcount-property-secureblackbox_samlwriter-class) property.

This property is not available at design time.

## Data Type

String

# StatementAuthnContextClassRef Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Indicates the authentication contexts class reference.

## Object Oriented Interface

```text
public function getStatementAuthnContextClassRef($statementindex);
public function setStatementAuthnContextClassRef($statementindex, $value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 248 , $statementindex);
secureblackbox_samlwriter_set($res, 248, $value , $statementindex);
```

## Default Value

''

## Remarks

Indicates the authentication contexts class reference.

Use this property to get or set the authentication contexts class reference attribute.

The *$statementindex* parameter specifies the index of the item in the array. The size of the array is controlled by the [StatementCount](#statementcount-property-secureblackbox_samlwriter-class) property.

This property is not available at design time.

## Data Type

String

# StatementAuthnContextDecl Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Specifies the authentication contexts declaration.

## Object Oriented Interface

```text
public function getStatementAuthnContextDecl($statementindex);
public function setStatementAuthnContextDecl($statementindex, $value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 249 , $statementindex);
secureblackbox_samlwriter_set($res, 249, $value , $statementindex);
```

## Default Value

''

## Remarks

Specifies the authentication contexts declaration.

Use this property to access or set the declaration element of the authentication context.

The *$statementindex* parameter specifies the index of the item in the array. The size of the array is controlled by the [StatementCount](#statementcount-property-secureblackbox_samlwriter-class) property.

This property is not available at design time.

## Data Type

String

# StatementAuthnContextDeclRef Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Specifies the authentication contexts declaration reference.

## Object Oriented Interface

```text
public function getStatementAuthnContextDeclRef($statementindex);
public function setStatementAuthnContextDeclRef($statementindex, $value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 250 , $statementindex);
secureblackbox_samlwriter_set($res, 250, $value , $statementindex);
```

## Default Value

''

## Remarks

Specifies the authentication contexts declaration reference.

Use this property to get or set the declaration reference of the authentication context.

The *$statementindex* parameter specifies the index of the item in the array. The size of the array is controlled by the [StatementCount](#statementcount-property-secureblackbox_samlwriter-class) property.

This property is not available at design time.

## Data Type

String

# StatementAuthnInstant Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Specifies the authentication event timestamp.

## Object Oriented Interface

```text
public function getStatementAuthnInstant($statementindex);
public function setStatementAuthnInstant($statementindex, $value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 251 , $statementindex);
secureblackbox_samlwriter_set($res, 251, $value , $statementindex);
```

## Default Value

''

## Remarks

Specifies the authentication event timestamp.

Use this property to read or set the moment in time the authentication event took place.

The *$statementindex* parameter specifies the index of the item in the array. The size of the array is controlled by the [StatementCount](#statementcount-property-secureblackbox_samlwriter-class) property.

This property is not available at design time.

## Data Type

String

# StatementAuthnSessionIndex Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Contains the authentication session index.

## Object Oriented Interface

```text
public function getStatementAuthnSessionIndex($statementindex);
public function setStatementAuthnSessionIndex($statementindex, $value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 252 , $statementindex);
secureblackbox_samlwriter_set($res, 252, $value , $statementindex);
```

## Default Value

''

## Remarks

Contains the authentication session index.

Use this property to access or set the authentication session index.

The *$statementindex* parameter specifies the index of the item in the array. The size of the array is controlled by the [StatementCount](#statementcount-property-secureblackbox_samlwriter-class) property.

This property is not available at design time.

## Data Type

String

# StatementAuthnSessionNotOnOrAfter Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Maps to the SessionNotOnOrAfter parameter of the authentication statement.

## Object Oriented Interface

```text
public function getStatementAuthnSessionNotOnOrAfter($statementindex);
public function setStatementAuthnSessionNotOnOrAfter($statementindex, $value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 253 , $statementindex);
secureblackbox_samlwriter_set($res, 253, $value , $statementindex);
```

## Default Value

''

## Remarks

Maps to the SessionNotOnOrAfter parameter of the authentication statement.

Use this property to access or set the SessionNotOnOrAfter parameter of the authentication statement.

The *$statementindex* parameter specifies the index of the item in the array. The size of the array is controlled by the [StatementCount](#statementcount-property-secureblackbox_samlwriter-class) property.

This property is not available at design time.

## Data Type

String

# StatementAuthnSubjectLocalityAddress Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Specifies the authentication subjects address.

## Object Oriented Interface

```text
public function getStatementAuthnSubjectLocalityAddress($statementindex);
public function setStatementAuthnSubjectLocalityAddress($statementindex, $value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 254 , $statementindex);
secureblackbox_samlwriter_set($res, 254, $value , $statementindex);
```

## Default Value

''

## Remarks

Specifies the authentication subjects address.

Use this property to specify the address parameter of the authentication subjects locality.

The *$statementindex* parameter specifies the index of the item in the array. The size of the array is controlled by the [StatementCount](#statementcount-property-secureblackbox_samlwriter-class) property.

This property is not available at design time.

## Data Type

String

# StatementAuthnSubjectLocalityDNSName Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Maps to the authentication subjects DNS name parameter.

## Object Oriented Interface

```text
public function getStatementAuthnSubjectLocalityDNSName($statementindex);
public function setStatementAuthnSubjectLocalityDNSName($statementindex, $value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 255 , $statementindex);
secureblackbox_samlwriter_set($res, 255, $value , $statementindex);
```

## Default Value

''

## Remarks

Maps to the authentication subjects DNS name parameter.

Use this property to access or set the authentication subjects DNS name locality parameter.

The *$statementindex* parameter specifies the index of the item in the array. The size of the array is controlled by the [StatementCount](#statementcount-property-secureblackbox_samlwriter-class) property.

This property is not available at design time.

## Data Type

String

# StatementAuthzActions Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Provides access to the list of actions of the authorization statement.

## Object Oriented Interface

```text
public function getStatementAuthzActions($statementindex);
public function setStatementAuthzActions($statementindex, $value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 256 , $statementindex);
secureblackbox_samlwriter_set($res, 256, $value , $statementindex);
```

## Default Value

''

## Remarks

Provides access to the list of actions of the authorization statement.

Use this property to read or set the actions of the authorization statement. Actions are represented as a list of Namespace=*namespace*;Value=*Value* strings, separated with CRLFs.

The *$statementindex* parameter specifies the index of the item in the array. The size of the array is controlled by the [StatementCount](#statementcount-property-secureblackbox_samlwriter-class) property.

This property is not available at design time.

## Data Type

String

# StatementAuthzDecision Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Specifies the authorization decision.

## Object Oriented Interface

```text
public function getStatementAuthzDecision($statementindex);
public function setStatementAuthzDecision($statementindex, $value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 257 , $statementindex);
secureblackbox_samlwriter_set($res, 257, $value , $statementindex);
```

## Possible Values

```text
SAMLWRITER_STATEMENTAUTHZDECISION_PERMIT(0), SAMLWRITER_STATEMENTAUTHZDECISION_DENY(1), SAMLWRITER_STATEMENTAUTHZDECISION_INDETERMINATE(2)
```

## Default Value

0

## Remarks

Specifies the authorization decision.

Use this property to check or set the authorization decision. This can be one of Permit, Deny, or Indeterminate.

The *$statementindex* parameter specifies the index of the item in the array. The size of the array is controlled by the [StatementCount](#statementcount-property-secureblackbox_samlwriter-class) property.

This property is not available at design time.

## Data Type

Integer

# StatementAuthzDecisionEvidence Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Manages the authorization decision statement evidence parameter.

## Object Oriented Interface

```text
public function getStatementAuthzDecisionEvidence($statementindex);
public function setStatementAuthzDecisionEvidence($statementindex, $value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 258 , $statementindex);
secureblackbox_samlwriter_set($res, 258, $value , $statementindex);
```

## Default Value

''

## Remarks

Manages the authorization decision statement evidence parameter.

Use this property to read or set the authorization decision statement evidence parameter.

The *$statementindex* parameter specifies the index of the item in the array. The size of the array is controlled by the [StatementCount](#statementcount-property-secureblackbox_samlwriter-class) property.

This property is not available at design time.

## Data Type

String

# StatementAuthzDecisionResource Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Specifies the authorization decision statement resource parameter.

## Object Oriented Interface

```text
public function getStatementAuthzDecisionResource($statementindex);
public function setStatementAuthzDecisionResource($statementindex, $value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 259 , $statementindex);
secureblackbox_samlwriter_set($res, 259, $value , $statementindex);
```

## Default Value

''

## Remarks

Specifies the authorization decision statement resource parameter.

Use this property to access or set the resource parameter of the authorization statement.

The *$statementindex* parameter specifies the index of the item in the array. The size of the array is controlled by the [StatementCount](#statementcount-property-secureblackbox_samlwriter-class) property.

This property is not available at design time.

## Data Type

String

# StatementType Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Specifies the assertion statement type.

## Object Oriented Interface

```text
public function getStatementType($statementindex);
public function setStatementType($statementindex, $value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 260 , $statementindex);
secureblackbox_samlwriter_set($res, 260, $value , $statementindex);
```

## Possible Values

```text
SAMLWRITER_STATEMENTTYPE_AUTHN(0), SAMLWRITER_STATEMENTTYPE_ATTRIBUTE(1), SAMLWRITER_STATEMENTTYPE_AUTHZ_DECISION(2)
```

## Default Value

0

## Remarks

Specifies the assertion statement type.

This property specifies the assertion statement type. A statement can carry an authentication assertion, an attribute assertion, or an authorization decision assertion.

The *$statementindex* parameter specifies the index of the item in the array. The size of the array is controlled by the [StatementCount](#statementcount-property-secureblackbox_samlwriter-class) property.

This property is not available at design time.

## Data Type

Integer

# SubjectConfirmationCount Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

The number of records in the SubjectConfirmation arrays.

## Object Oriented Interface

```text
public function getSubjectConfirmationCount();
public function setSubjectConfirmationCount($value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 261 );
secureblackbox_samlwriter_set($res, 261, $value );
```

## Default Value

0

## Remarks

This property controls the size of the following arrays:

- [SubjectConfirmationAddress](#subjectconfirmationaddress-property-secureblackbox_samlwriter-class)
- [SubjectConfirmationData](#subjectconfirmationdata-property-secureblackbox_samlwriter-class)
- [SubjectConfirmationDataType](#subjectconfirmationdatatype-property-secureblackbox_samlwriter-class)
- [SubjectConfirmationID](#subjectconfirmationid-property-secureblackbox_samlwriter-class)
- [SubjectConfirmationInResponseTo](#subjectconfirmationinresponseto-property-secureblackbox_samlwriter-class)
- [SubjectConfirmationMethod](#subjectconfirmationmethod-property-secureblackbox_samlwriter-class)
- [SubjectConfirmationNotBefore](#subjectconfirmationnotbefore-property-secureblackbox_samlwriter-class)
- [SubjectConfirmationNotOnOrAfter](#subjectconfirmationnotonorafter-property-secureblackbox_samlwriter-class)
- [SubjectConfirmationRecipient](#subjectconfirmationrecipient-property-secureblackbox_samlwriter-class)

The array indices start at *0* and end at *SubjectConfirmationCount - 1*.

This property is not available at design time.

## Data Type

Integer

# SubjectConfirmationAddress Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Contains the address enabled for presenting assertions.

## Object Oriented Interface

```text
public function getSubjectConfirmationAddress($subjectconfirmationindex);
public function setSubjectConfirmationAddress($subjectconfirmationindex, $value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 262 , $subjectconfirmationindex);
secureblackbox_samlwriter_set($res, 262, $value , $subjectconfirmationindex);
```

## Default Value

''

## Remarks

Contains the address enabled for presenting assertions.

Use this property to specify the network address or location from which the subject confirmation should be issued. This optional element can be used to restrict the possibilities of an attacker to steal the assertion and present it from another IP address.

The *$subjectconfirmationindex* parameter specifies the index of the item in the array. The size of the array is controlled by the [SubjectConfirmationCount](#subjectconfirmationcount-property-secureblackbox_samlwriter-class) property.

This property is not available at design time.

## Data Type

String

# SubjectConfirmationData Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

The uninterpreted value of data entry in the subject confirmation.

## Object Oriented Interface

```text
public function getSubjectConfirmationData($subjectconfirmationindex);
public function setSubjectConfirmationData($subjectconfirmationindex, $value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 263 , $subjectconfirmationindex);
secureblackbox_samlwriter_set($res, 263, $value , $subjectconfirmationindex);
```

## Default Value

''

## Remarks

The uninterpreted value of data entry in the subject confirmation.

Use this property to read or specify the uninterpreted value of the Data entry in the subject confirmation blob.

The *$subjectconfirmationindex* parameter specifies the index of the item in the array. The size of the array is controlled by the [SubjectConfirmationCount](#subjectconfirmationcount-property-secureblackbox_samlwriter-class) property.

This property is not available at design time.

## Data Type

String

# SubjectConfirmationDataType Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

The type of data contained in the confirmation.

## Object Oriented Interface

```text
public function getSubjectConfirmationDataType($subjectconfirmationindex);
public function setSubjectConfirmationDataType($subjectconfirmationindex, $value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 264 , $subjectconfirmationindex);
secureblackbox_samlwriter_set($res, 264, $value , $subjectconfirmationindex);
```

## Default Value

''

## Remarks

The type of data contained in the confirmation.

Use this property to read or specify the type of confirmation data included in the object.

The *$subjectconfirmationindex* parameter specifies the index of the item in the array. The size of the array is controlled by the [SubjectConfirmationCount](#subjectconfirmationcount-property-secureblackbox_samlwriter-class) property.

This property is not available at design time.

## Data Type

String

# SubjectConfirmationID Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

The identifier of the entity which can satisfy the subject confirmation requirements.

## Object Oriented Interface

```text
public function getSubjectConfirmationID($subjectconfirmationindex);
public function setSubjectConfirmationID($subjectconfirmationindex, $value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 265 , $subjectconfirmationindex);
secureblackbox_samlwriter_set($res, 265, $value , $subjectconfirmationindex);
```

## Default Value

''

## Remarks

The identifier of the entity which can satisfy the subject confirmation requirements.

This property specifies the identifier of the entity which is expected to satisfy the subject confirmation requirements.

The *$subjectconfirmationindex* parameter specifies the index of the item in the array. The size of the array is controlled by the [SubjectConfirmationCount](#subjectconfirmationcount-property-secureblackbox_samlwriter-class) property.

This property is not available at design time.

## Data Type

String

# SubjectConfirmationInResponseTo Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

The ID of the SAML message in response to which the assertion is issued.

## Object Oriented Interface

```text
public function getSubjectConfirmationInResponseTo($subjectconfirmationindex);
public function setSubjectConfirmationInResponseTo($subjectconfirmationindex, $value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 266 , $subjectconfirmationindex);
secureblackbox_samlwriter_set($res, 266, $value , $subjectconfirmationindex);
```

## Default Value

''

## Remarks

The ID of the SAML message in response to which the assertion is issued.

This property specifies the ID of the SAML message in response to which the assertion is issued.

The *$subjectconfirmationindex* parameter specifies the index of the item in the array. The size of the array is controlled by the [SubjectConfirmationCount](#subjectconfirmationcount-property-secureblackbox_samlwriter-class) property.

This property is not available at design time.

## Data Type

String

# SubjectConfirmationMethod Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Specifies the mechanism to be used to confirm the subject.

## Object Oriented Interface

```text
public function getSubjectConfirmationMethod($subjectconfirmationindex);
public function setSubjectConfirmationMethod($subjectconfirmationindex, $value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 267 , $subjectconfirmationindex);
secureblackbox_samlwriter_set($res, 267, $value , $subjectconfirmationindex);
```

## Default Value

''

## Remarks

Specifies the mechanism to be used to confirm the subject.

This property contains a URI reference that identifies the mechanism to be used to confirm the subject.

The *$subjectconfirmationindex* parameter specifies the index of the item in the array. The size of the array is controlled by the [SubjectConfirmationCount](#subjectconfirmationcount-property-secureblackbox_samlwriter-class) property.

This property is not available at design time.

## Data Type

String

# SubjectConfirmationNotBefore Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Time moment before which the subject cannot be confirmed.

## Object Oriented Interface

```text
public function getSubjectConfirmationNotBefore($subjectconfirmationindex);
public function setSubjectConfirmationNotBefore($subjectconfirmationindex, $value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 268 , $subjectconfirmationindex);
secureblackbox_samlwriter_set($res, 268, $value , $subjectconfirmationindex);
```

## Default Value

''

## Remarks

Time moment before which the subject cannot be confirmed.

This property specifies the time before which the subject cannot be confirmed.

The *$subjectconfirmationindex* parameter specifies the index of the item in the array. The size of the array is controlled by the [SubjectConfirmationCount](#subjectconfirmationcount-property-secureblackbox_samlwriter-class) property.

This property is not available at design time.

## Data Type

String

# SubjectConfirmationNotOnOrAfter Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Limits the time until which the subject can be confirmed.

## Object Oriented Interface

```text
public function getSubjectConfirmationNotOnOrAfter($subjectconfirmationindex);
public function setSubjectConfirmationNotOnOrAfter($subjectconfirmationindex, $value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 269 , $subjectconfirmationindex);
secureblackbox_samlwriter_set($res, 269, $value , $subjectconfirmationindex);
```

## Default Value

''

## Remarks

Limits the time until which the subject can be confirmed.

This property specifies the time on (or after) which the subject cannot be confirmed.

The *$subjectconfirmationindex* parameter specifies the index of the item in the array. The size of the array is controlled by the [SubjectConfirmationCount](#subjectconfirmationcount-property-secureblackbox_samlwriter-class) property.

This property is not available at design time.

## Data Type

String

# SubjectConfirmationRecipient Property ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

The URI of the entity or the location of the resource to which the assertion should be presented.

## Object Oriented Interface

```text
public function getSubjectConfirmationRecipient($subjectconfirmationindex);
public function setSubjectConfirmationRecipient($subjectconfirmationindex, $value);
```

## Procedural Interface

```text
secureblackbox_samlwriter_get($res, 270 , $subjectconfirmationindex);
secureblackbox_samlwriter_set($res, 270, $value , $subjectconfirmationindex);
```

## Default Value

''

## Remarks

The URI of the entity or the location of the resource to which the assertion should be presented.

This property specifies The URI of the entity or the location of the resource to which the assertion should be presented.

The *$subjectconfirmationindex* parameter specifies the index of the item in the array. The size of the array is controlled by the [SubjectConfirmationCount](#subjectconfirmationcount-property-secureblackbox_samlwriter-class) property.

This property is not available at design time.

## Data Type

String

# AddAttribute Method ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Adds an attribute to an existing attribute statement.

## Object Oriented Interface

```text
public function doAddAttribute($attributename, $attributevalue, $nameformat, $contenttype, $statementindex);
```

## Procedural Interface

```text
secureblackbox_samlwriter_do_addattribute($res, $attributename, $attributevalue, $nameformat, $contenttype, $statementindex);
```

## Remarks

Use this method to add an attribute to an attribute statement. The method returns the index of the newly added attribute in the statement.

Use the method parameters to provide the parameters of the new attribute:

```text
  <saml:Attribute
    Name="uid" <!-- AttributeName -->
    NameFormat="urn:oasis:names:tc:SAML:2.0:attrname-format:basic" <!-- NameFormat -->
  >
    <saml:AttributeValue xsi:type="xs:string" <!-- ContentType --> >test <!-- AttributeValue --> </saml:AttributeValue>
  </saml:Attribute>
</code>
```

Note: if *StatementIndex* is set to -1, the attribute will be added to the last attribute statement in the collection. If no attribute statements are available in the collection, one will be created automatically.

If *StatementIndex* exceeds the index of the last statement in the Statements collection, a new attribute statement will be created (even if there are other attribute statements in the list), and the attribute added to it.

If *StatementIndex* points to an existing statement but that statement is not an attribute statement, an exception will be thrown.

# AddAttributeStatement Method ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Adds an attribute statement to the assertion.

## Object Oriented Interface

```text
public function doAddAttributeStatement();
```

## Procedural Interface

```text
secureblackbox_samlwriter_do_addattributestatement($res);
```

## Remarks

Use this method to add an attribute statement to the currently edited assertion. The method returns the index of the newly added statement in the Statements collection.

Note that a call to [AddAttribute](#addattribute-method-secureblackbox_samlwriter-class) adds a new attribute statement behind the scenes if no attribute statements have been added by that time.

# AddAuthnStatement Method ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Adds an authentication statement to the assertion.

## Object Oriented Interface

```text
public function doAddAuthnStatement($authninstant, $sessionindex, $notonorafter, $classref);
```

## Procedural Interface

```text
secureblackbox_samlwriter_do_addauthnstatement($res, $authninstant, $sessionindex, $notonorafter, $classref);
```

## Remarks

Use this method to add an authentication statement to the currently edited assertion. The method returns the index of the newly added statement in the Statements collection.

# AddAuthzDecisionStatement Method ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Adds an authorization decision statement to the assertion.

## Object Oriented Interface

```text
public function doAddAuthzDecisionStatement($decision, $evidence, $resource, $actions);
```

## Procedural Interface

```text
secureblackbox_samlwriter_do_addauthzdecisionstatement($res, $decision, $evidence, $resource, $actions);
```

## Remarks

Use this method to add an authorization decision statement to the currently edited assertion. The method returns the index of the newly added statement in the Statements collection.

# AddCondition Method ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Adds a condition to the object (assertion or authn request) being edited.

## Object Oriented Interface

```text
public function doAddCondition($conditiontype, $conditionvalue);
```

## Procedural Interface

```text
secureblackbox_samlwriter_do_addcondition($res, $conditiontype, $conditionvalue);
```

## Remarks

Use this method to quickly add a condition to the SAML object you are creating.

# AddScopingIDP Method ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Adds a scoping IDP to the object being currently edited.

## Object Oriented Interface

```text
public function doAddScopingIDP($name, $providerid, $loc);
```

## Procedural Interface

```text
secureblackbox_samlwriter_do_addscopingidp($res, $name, $providerid, $loc);
```

## Remarks

Use this method to quickly add a scoping IDP to the SAML object you are creating. The method returns the index of the new element in the ScopingIDPs collection.

# AddSubjectConfirmation Method ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Adds a subject confirmation to the object being edited.

## Object Oriented Interface

```text
public function doAddSubjectConfirmation($method, $address, $recipient, $inresponseto, $notbefore, $notonorafter, $id, $datatype, $data);
```

## Procedural Interface

```text
secureblackbox_samlwriter_do_addsubjectconfirmation($res, $method, $address, $recipient, $inresponseto, $notbefore, $notonorafter, $id, $datatype, $data);
```

## Remarks

Use this method to quickly add a subject confirmation to the SAML object you are creating. The method returns the index of the new subject confirmation in the list.

# BeginAssertion Method ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Initiates the process of creating a new assertion.

## Object Oriented Interface

```text
public function doBeginAssertion();
```

## Procedural Interface

```text
secureblackbox_samlwriter_do_beginassertion($res);
```

## Remarks

This method resets the contents of all assertion-related properties and prepares the component for creating a new assertion.

Use the methods and properties of the component, such as Assertion, as well as Statements and Attributes to prepare the new assertion. When ready, call [CompleteAssertion](#completeassertion-method-secureblackbox_samlwriter-class) to commit the provided details to the message.

# CompleteAssertion Method ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Adds a completed assertion to a SAML message.

## Object Oriented Interface

```text
public function doCompleteAssertion();
```

## Procedural Interface

```text
secureblackbox_samlwriter_do_completeassertion($res);
```

## Remarks

Use this method to commit an assertion to the SAML message being created. Before calling this method, prepare the assertion by calling [BeginAssertion](#beginassertion-method-secureblackbox_samlwriter-class) and filling in the details via the Assertion, Attributes, and Statements properties.

The method returns the index of the new assertion in the list.

# Config Method ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Sets or retrieves a configuration setting.

## Object Oriented Interface

```text
public function doConfig($configurationstring);
```

## Procedural Interface

```text
secureblackbox_samlwriter_do_config($res, $configurationstring);
```

## Remarks

Config is a generic method available in every class. It is used to set and retrieve [configuration settings](#config-settings-samlwriter-class) for the class.

These settings are similar in functionality to properties, but they are rarely used. In order to avoid "polluting" the property namespace of the class, access to these *internal properties* is provided through the Config method.

To set a configuration setting named *PROPERTY*, you must call *Config("PROPERTY=VALUE")*, where *VALUE* is the value of the setting expressed as a string. For boolean values, use the strings "True", "False", "0", "1", "Yes", or "No" (case does not matter).

To read (query) the value of a [configuration setting](#config-settings-samlwriter-class), you must call *Config("PROPERTY")*. The value will be returned as a string.

# CreateNew Method ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Creates a new SAML message with the given type.

## Object Oriented Interface

```text
public function doCreateNew($contenttype);
```

## Procedural Interface

```text
secureblackbox_samlwriter_do_createnew($res, $contenttype);
```

## Remarks

Use this method to create a new SAML message with the specified content type. The following values are supported:

- cstyNone (0)
- cstyAssertionIDRequest (1)
- cstySubjectQuery (2)
- cstyAuthnQuery (3)
- cstyAttributeQuery (4)
- cstyAuthzDecisionQuery (5)
- cstyAuthnRequest (6)
- cstyManageNameIDRequest (7)
- cstyLogoutRequest (8)
- cstyNameIDMappingRequest (9)
- cstyArtifactResolve (10)
- cstyResponse (11)
- cstyAssertion (12)

 Depending on the chosen content type, use properties of class to tune up the parameters of the chosen subtype. For example, if using cstyAuthnQuery as your content type, use AuthnQuery property to adjust context class references or comparison settings.

# DoAction Method ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Performs an additional action.

## Object Oriented Interface

```text
public function doDoAction($actionid, $actionparams);
```

## Procedural Interface

```text
secureblackbox_samlwriter_do_doaction($res, $actionid, $actionparams);
```

## Remarks

DoAction is a generic method available in every class. It is used to perform an additional action introduced after the product major release. The list of actions is not fixed, and may be flexibly extended over time.

The unique identifier (case insensitive) of the action is provided in the *ActionID* parameter.

*ActionParams* contains the value of a single parameter, or a list of multiple parameters for the action in the form of *PARAM1=VALUE1;PARAM2=VALUE2;...*.

Common ActionIDs:

|  |  |  |  |
| --- | --- | --- | --- |
| Action | Parameters | Returned value | Description |
| ResetTrustedListCache | none | none | Clears the cached list of trusted lists. |
| ResetCertificateCache | none | none | Clears the cached certificates. |
| ResetCRLCache | none | none | Clears the cached CRLs. |
| ResetOCSPResponseCache | none | none | Clears the cached OCSP responses. |

# FormatID Method ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Formats a SAML ID in the form in which it can be assigned to the Issuer or Subject fields.

## Object Oriented Interface

```text
public function doFormatID($value, $idtype, $format, $namequalifier, $spnamequalifier, $spprovidedid);
```

## Procedural Interface

```text
secureblackbox_samlwriter_do_formatid($res, $value, $idtype, $format, $namequalifier, $spnamequalifier, $spprovidedid);
```

## Remarks

This is a utility method that simplifies formatting of SAML IDs. Pass the components of the SAML ID to this method, and assign the resulting string to the required property.

Example:

```text
  // you can provide some of the values; the optional values will be omitted from the output
  writer.Issuer = writer.FormatID("https://saml.mysite.com", "Issuer", "urn:oasis:names:tc:SAML:2.0:nameid-format:entity", "", "", "");

  // this call will just return the bare value, with no attributes
  writer.Issuer = writer.FormatID("https://saml.mysite.com", "", "", "", "", "");
```

# Reset Method ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Resets the class settings.

## Object Oriented Interface

```text
public function doReset();
```

## Procedural Interface

```text
secureblackbox_samlwriter_do_reset($res);
```

## Remarks

Reset is a generic method available in every class.

# Save Method ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Saves the configured message to a string.

## Object Oriented Interface

```text
public function doSave();
```

## Procedural Interface

```text
secureblackbox_samlwriter_do_save($res);
```

## Remarks

Use this method to save the created SAML message to a string.

# SaveBytes Method ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Saves the configured message to a byte array.

## Object Oriented Interface

```text
public function doSaveBytes();
```

## Procedural Interface

```text
secureblackbox_samlwriter_do_savebytes($res);
```

## Remarks

Use this method to save the formed SAML message to a byte array.

# SaveFile Method ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Saves the configured message to a file.

## Object Oriented Interface

```text
public function doSaveFile($filename);
```

## Procedural Interface

```text
secureblackbox_samlwriter_do_savefile($res, $filename);
```

## Remarks

Use this method to save the created SAML message to a file.

# Error Event ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

Fires to report an error condition.

## Object Oriented Interface

```text
public function fireError($param);
```

## Procedural Interface

```text
secureblackbox_samlwriter_register_callback($res, 1, array($this, 'fireError'));
```

## Parameter List

```text
 'errorcode' 'description'
```

## Remarks

Subscribe to this event to be notified about any error conditions occurring during the component's work. *ErrorCode* and *Description* provide the details of the error.

# Notification Event ([SecureBlackbox_SAMLWriter](#samlwriter-class) Class)

This event notifies the application about an underlying control flow event.

## Object Oriented Interface

```text
public function fireNotification($param);
```

## Procedural Interface

```text
secureblackbox_samlwriter_register_callback($res, 2, array($this, 'fireNotification'));
```

## Parameter List

```text
 'eventid' 'eventparam'
```

## Remarks

The class fires this event to let the application know about some event, occurrence, or milestone in the class. For example, it may fire to report completion of the document processing. The list of events being reported is not fixed, and may be flexibly extended over time.

The unique identifier of the event is provided in the *EventID* parameter. *EventParam* contains any parameters accompanying the occurrence. Depending on the type of the class, the exact action it is performing, or the document being processed, one or both may be omitted.

# Config Settings ([SAMLWriter](#samlwriter-class) Class)

 The class accepts one or more of the following *configuration settings*. Configuration settings are similar in functionality to properties, but they are rarely used. In order to avoid "polluting" the property namespace of the class, access to these *internal properties* is provided through the [Config](#config-method-secureblackbox_samlwriter-class) method.

### SAMLWriter Config Settings

**BodyOnly**: TBD.TBD

**DateTimeFormat**: TBD.TBD

**KeyDataElements**: TBD.TBD

**SAMLPrefix**: TBD.TBD

**SAMLProtocolPrefix**: TBD.TBD

**SigAfterIssuer**: Specifies whether to insert the signature after the issuer tag in the SAML document.Use this setting to tune up the location of the signature tag in the resulting document. The default value is true.

**SigCanonicalizationMethod**: TBD.TBD

**SigDigestMethod**: TBD.TBD

**SigMethod**: TBD.TBD

**TimeZoneOffset**: TBD.TBD

### Base Config Settings

**ASN1UseGlobalTagCache**: Controls whether ASN.1 module should use a global object cache.This is a performance setting. It is unlikely that you will ever need to adjust it.

**AssignSystemSmartCardPins**: Specifies whether CSP-level PINs should be assigned to CNG keys.This is a low-level tweak for certain cryptographic providers. It is unlikely that you will ever need to adjust it.

**CheckKeyIntegrityBeforeUse**: Enables or disable private key integrity check before use.This global property enables or disables private key material check before each signing operation. This slows down performance a bit, but prevents a selection of attacks on RSA keys where keys with unknown origins are used.

You can switch this property off to improve performance if your project only uses known, good private keys.

**CookieCaching**: Specifies whether a cookie cache should be used for HTTP(S) transports.Set this property to enable or disable cookies caching for the class.

Supported values are:

|  |  |  |
| --- | --- | --- |
| off |  | No caching (default) |
| local |  | Local caching |
| global |  | Global caching |

**Cookies**: Gets or sets local cookies for the class.Use this property to get cookies from the internal cookie storage of the class and/or restore them back between application sessions.

**DefDeriveKeyIterations**: Specifies the default key derivation algorithm iteration count.This global property sets the default number of iterations for all supported key derivation algorithms. Note that you can provide the required number of iterations by using properties of the relevant key generation component; this global setting is used in scenarios where specific iteration count is not or cannot be provided.

**DNSLocalSuffix**: The suffix to assign for TLD names.Use this global setting to adjust the default suffix to assign to top-level domain names. The default is *.local*.

**EnableClientSideSSLFFDHE**: Enables or disables finite field DHE key exchange support in TLS clients.This global property enables or disables support for finite field DHE key exchange methods in TLS clients. FF DHE is a slower algorithm if compared to EC DHE; enabling it may result in slower connections.

This setting only applies to sessions negotiated with TLS version 1.3.

**EnableSSHMLKEM**: Enables support for ML-KEM/hybrid key exchange algorithms in SSH client and server components.Use this setting to enable hybrid key exchange algorithms in client and server SSH and SFTP components. This is a global setting that enables ML-KEM blanketly in all SSH-dependent components.

**EnableTLSMLKEM**: Enables support for ML-KEM and hybrid groups in TLS client and server components.Use this setting to enable ML-KEM and hybrid key exchange groups in client and server TLS components. This is a global setting that enables ML-KEM blanketly in all TLS-dependent components.

**GlobalCookies**: Gets or sets global cookies for all the HTTP transports.Use this property to get cookies from the GLOBAL cookie storage or restore them back between application sessions. These cookies will be used by all the classes that have its *CookieCaching* property set to "global".

**HardwareCryptoUsePolicy**: The hardware crypto usage policy.This global setting controls the hardware cryptography usage policy.

Supported Values:

|  |  |
| --- | --- |
| auto | Use hardware cryptography if available; otherwise, fall back to software-based cryptography (default). |
| enable | Always attempt to use hardware cryptography. If unavailable, exception will be thrown. |
| disable | Do not use hardware cryptography. |

**HttpUserAgent**: Specifies the user agent name to be used by all HTTP clients.This global setting defines the User-Agent field of the HTTP request provides information about the software that initiates the request. This value will be used by all the HTTP clients including the ones used internally in other classes.

**HttpVersion**: The HTTP version to use in any inner HTTP client components created.Set this property to 1.0 or 1.1 to indicate the HTTP version that any internal HTTP clients should use.

**IgnoreExpiredMSCTLSigningCert**: Whether to tolerate the expired Windows Update signing certificate.It is not uncommon for Microsoft Windows Update Certificate Trust List to be signed with an expired Microsoft certificate. Setting this global property to true makes SBB ignore the expired factor and take the Trust List into account.

**ListDelimiter**: The delimiter character for multi-element lists.Allows to set the delimiter for any multi-entry values returned by the component as a string object, such as file lists. For most of the components, this property is set to a newline sequence.

**LogDestination**: Specifies the debug log destination.Contains a comma-separated list of values that specifies where debug log should be dumped.

Supported values are:

|  |  |  |
| --- | --- | --- |
| file |  | File |
| console |  | Console |
| systemlog |  | System Log (supported for Android only) |
| debugger |  | Debugger (supported for VCL for Windows and .Net) |

**LogDetails**: Specifies the debug log details to dump.Contains a comma-separated list of values that specifies which debug log details to dump.

Supported values are:

|  |  |  |
| --- | --- | --- |
| time |  | Current time |
| level |  | Level |
| package |  | Package name |
| module |  | Module name |
| class |  | Class name |
| method |  | Method name |
| threadid |  | Thread Id |
| contenttype |  | Content type |
| content |  | Content |
| all |  | All details |

**LogFile**: Specifies the debug log filename.Use this property to provide a path to the log file.

**LogFilters**: Specifies the debug log filters.Contains a comma-separated list of value pairs ("name:value") that describe filters.

Supported filter names are:

|  |  |  |
| --- | --- | --- |
| exclude-package |  | Exclude a package specified in the value |
| exclude-module |  | Exclude a module specified in the value |
| exclude-class |  | Exclude a class specified in the value |
| exclude-method |  | Exclude a method specified in the value |
| include-package |  | Include a package specified in the value |
| include-module |  | Include a module specified in the value |
| include-class |  | Include a class specified in the value |
| include-method |  | Include a method specified in the value |

**LogFlushMode**: Specifies the log flush mode.Use this property to set the log flush mode. The following values are defined:

|  |  |  |
| --- | --- | --- |
| none |  | No flush (caching only) |
| immediate |  | Immediate flush (real-time logging) |
| maxcount |  | Flush cached entries upon reaching LogMaxEventCount entries in the cache. |

**LogLevel**: Specifies the debug log level.Use this property to provide the desired debug log level.

Supported values are:

|  |  |  |
| --- | --- | --- |
| none |  | None (by default) |
| fatal |  | Severe errors that cause premature termination. |
| error |  | Other runtime errors or unexpected conditions. |
| warning |  | Use of deprecated APIs, poor use of API, 'almost' errors, other runtime situations that are undesirable or unexpected, but not necessarily "wrong". |
| info |  | Interesting runtime events (startup/shutdown). |
| debug |  | Detailed information on flow of through the system. |
| trace |  | More detailed information. |

**LogMaxEventCount**: Specifies the maximum number of events to cache before further action is taken.Use this property to specify the log event number threshold. This threshold may have different effects, depending on the rotation setting and/or the flush mode.

The default value of this setting is 100.

**LogRotationMode**: Specifies the log rotation mode.Use this property to set the log rotation mode. The following values are defined:

|  |  |  |
| --- | --- | --- |
| none |  | No rotation |
| deleteolder |  | Delete older entries from the cache upon reaching LogMaxEventCount |
| keepolder |  | Keep older entries in the cache upon reaching LogMaxEventCount (newer entries are discarded) |

**MaxASN1BufferLength**: Specifies the maximal allowed length for ASN.1 primitive tag data.This global property limits the maximal allowed length for ASN.1 tag data for non-content-carrying structures, such as certificates, CRLs, or timestamps. It does not affect structures that can carry content, such as CMS/CAdES messages. This is a security property aiming at preventing DoS attacks.

**MaxASN1TreeDepth**: Specifies the maximal depth for processed ASN.1 trees.This global property limits the maximal depth of ASN.1 trees that the component can handle without throwing an error. This is a security property aiming at preventing DoS attacks.

**OCSPHashAlgorithm**: Specifies the hash algorithm to be used to identify certificates in OCSP requests.This global setting defines the hash algorithm to use in OCSP requests during chain validation. Some OCSP responders can only use older algorithms, in which case setting this property to SHA1 may be helpful.

**OldClientSideRSAFallback**: Specifies whether the SSH client should use a SHA1 fallback.Tells the SSH client to use a legacy ssh-rsa authentication even if the server indicates support for newer algorithms, such as rsa-sha-256. This is a backward-compatibility tweak.

**PKICache**: Specifies which PKI elements (certificates, CRLs, OCSP responses) should be cached.The PKICache setting specifies which Public Key Infrastructure (PKI) elements should be cached to optimize performance and reduce retrieval times. It supports comma-separated values to indicate the specific types of PKI data that should be cached.

Supported Values:

|  |  |
| --- | --- |
| certificate | Enables caching of certificates. |
| crl | Enables caching of Certificate Revocation Lists (CRLs). |
| ocsp | Enables caching of OCSP (Online Certificate Status Protocol) responses. |

Example (default value):

```text
PKICache=certificate,crl,ocsp
```

 In this example, the component caches certificates, CRLs, and OCSP responses.

**PKICachePath**: Specifies the file system path where cached PKI data is stored.The PKICachePath setting defines the file system path where cached PKI data (e.g., certificates, CRLs, OCSP responses and Trusted Lists) will be stored. This allows the system to persistently save and retrieve PKI cache data, even across application restarts.

The default value is an empty string - no cached PKI data is stored on disk.

Example:

```text
PKICachePath=C:\Temp\cache
```

 In this example, the cached PKI data is stored in the C:\Temp\cache directory.

**ProductVersion**: Returns the version of the SecureBlackbox library.This property returns the long version string of the SecureBlackbox library being used (major.minor.build.revision).

**ServerSSLDHKeyLength**: Sets the size of the TLS DHE key exchange group.Use this property to adjust the length, in bits, of the DHE prime to be used by the TLS server.

**StaticDNS**: Specifies whether static DNS rules should be used.Set this property to enable or disable static DNS rules for the class. Works only if *UseOwnDNSResolver* is set to *true*.

Supported values are:

|  |  |  |
| --- | --- | --- |
| none |  | No static DNS rules (default) |
| local |  | Local static DNS rules |
| global |  | Global static DNS rules |

**StaticIPAddress[domain]**: Gets or sets an IP address for the specified domain name.Use this property to get or set an IP address for the specified domain name in the internal (of the class) or global DNS rules storage depending on the *StaticDNS* value. The type of the IP address (IPv4 or IPv6) is determined automatically. If both addresses are available, they are divided by the | (pipe) character.

**StaticIPAddresses**: Gets or sets all the static DNS rules.Use this property to get static DNS rules from the current rules storage or restore them back between application sessions. If *StaticDNS* of the class is set to "*local*", the property returns/restores the rules from/to the internal storage of the class. If *StaticDNS* of the class is set to "*global*", the property returns/restores the rules from/to the GLOBAL storage. The rules list is returned and accepted in JSON format.

**Tag**: Allows to store any custom data.Use this config property to store any custom data.

**TLSSessionGroup**: Specifies the group name of TLS sessions to be used for session resumption.Use this property to limit the search of cached TLS sessions to the specified group. Sessions from other groups will be ignored. By default, all sessions are cached with an empty group name and available to all the classes.

**TLSSessionLifetime**: Specifies lifetime in seconds of the cached TLS session.Use this property to specify how much time the TLS session should be kept in the session cache. After this time, the session expires and will be automatically removed from the cache. Default value is 300 seconds (5 minutes).

**TLSSessionPurgeInterval**: Specifies how often the session cache should remove the expired TLS sessions.Use this property to specify the time interval of purging the expired TLS sessions from the session cache. Default value is 60 seconds (1 minute).

**UseCRLObjectCaching**: Specifies whether reuse of loaded CRL objects is enabled.This setting enables or disables the caching of CRL objects. When set to true (the default value), the system checks if a CRL object is already loaded in memory before attempting to load a new instance. If the object is found, the existing instance is reused, and its reference count is incremented to track its usage. When the reference count reaches zero, indicating that no references to the object remain, the system will free the object from memory. This setting enhances performance by minimizing unnecessary object instantiation and promotes efficient memory management, particularly in scenarios where CRL objects are frequently used.

**UseInternalRandom**: Switches between SecureBlackbox-own and platform PRNGs.Allows to switch between internal/native PRNG implementation and the one provided by the platform.

**UseLegacyAdESValidation**: Enables legacy AdES validation mode.Use this setting to switch the AdES component to the validation approach that was used in SBB 2020/SBB 2022 (less attention to temporal details).

**UseOCSPResponseObjectCaching**: Specifies whether reuse of loaded OCSP response objects is enabled.This setting enables or disables the caching of OCSP response objects. When set to true (the default value), the system checks if a OCSP response object is already loaded in memory before attempting to load a new instance. If the object is found, the existing instance is reused, and its reference count is incremented to track its usage. When the reference count reaches zero, indicating that no references to the object remain, the system will free the object from memory. This setting enhances performance by minimizing unnecessary object instantiation and promotes efficient memory management, particularly in scenarios where OCSP response objects are frequently used.

**UseOwnDNSResolver**: Specifies whether the client components should use own DNS resolver.Set this global property to false to force all the client components to use the DNS resolver provided by the target OS instead of using own one.

**UseSharedSystemStorages**: Specifies whether the validation engine should use a global per-process copy of the system certificate stores.Set this global property to false to make each validation run use its own copy of system certificate stores.

**UseSystemNativeSizeCalculation**: An internal CryptoAPI access tweak.This is an internal setting. Please do not use it unless instructed by the support team.

**UseSystemOAEPAndPSS**: Enforces or disables the use of system-driven RSA OAEP and PSS computations.This global setting defines who is responsible for performing RSA-OAEP and RSA-PSS computations where the private key is stored in a Windows system store and is exportable. If set to true, SBB will delegate the computations to Windows via a CryptoAPI call. Otherwise, it will export the key material and perform the computations using its own OAEP/PSS implementation.

This setting only applies to certificates originating from a Windows system store.

**UseSystemRandom**: Enables or disables the use of the OS PRNG.Use this global property to enable or disable the use of operating system-driven pseudorandom number generation.

**XMLRDNDescriptorName[OID]**: Defines an OID mapping to descriptor names for the certificate's IssuerRDN or SubjectRDN.This property defines custom mappings between Object Identifiers (OIDs) and descriptor names. This mapping specifies how the certificate's issuer and subject information (ds:IssuerRDN and ds:SubjectRDN elements respectively) are represented in XML signatures.

The property accepts comma-separated values where the first descriptor name is used when the OID is mapped, and subsequent values act as aliases for parsing.

Syntax:

```text
Config("XMLRDNDescriptorName[OID]=PrimaryName,Alias1,Alias2");
```

Where:

OID: The Object Identifier from the certificate's IssuerRDN or SubjectRDN that you want to map.

PrimaryName: The main descriptor name used in the XML signature when the OID is encountered.

Alias1, Alias2, ...: Optional alternative names recognized during parsing.

Usage Examples:

Map OID 2.5.4.5 to SERIALNUMBER:

```text
Config("XMLRDNDescriptorName[2.5.4.5]=SERIALNUMBER");
```

Map OID 1.2.840.113549.1.9.1 to E, with aliases EMAIL and EMAILADDRESS:

```text
Config("XMLRDNDescriptorName[1.2.840.113549.1.9.1]=E,EMAIL,EMAILADDRESS");
```

**XMLRDNDescriptorPriority[OID]**: Specifies the priority of descriptor names associated with a specific OID.This property specifies the priority of descriptor names associated with a specific OID that allows to reorder descriptors in the ds:IssuerRDN and ds:SubjectRDN elements during signing.

**XMLRDNDescriptorReverseOrder**: Specifies whether to reverse the order of descriptors in RDN.Specifies whether to reverse the order of descriptors in the ds:IssuerRDN and ds:SubjectRDN elements during XML signing. By default, this property is set to true (as specified in RFC 2253, 2.1).

**XMLRDNDescriptorSeparator**: Specifies the separator used between descriptors in RDN.Specifies the separator used between descriptors in the ds:IssuerRDN and ds:SubjectRDN elements during XML signing. By default, this property is set to ", " value.

# Trappable Errors ([SAMLWriter](#samlwriter-class) Class)
