Skip to content

Fortified IDDocs

Signature formats

Select XML, PDF, CMS, UTF-8 text or PAdES/XAdES/JAdES Baseline profiles and prepare the correct signing inputs.

Signing Server signs the prepared inputs for the selected profile. Your application keeps the original bytes, checks the response, assembles the final signature and verifies it against those originals and its certificate trust policy.

For the meaning of B-B, B-T, B-LT and B-LTA, selection guidance and external dependencies, see Signature levels and dependencies.

Format Prepared input and binding Credential requirement
Generic XML Canonical XML SignedInfo, standard DSS SigType="XML"; AdESType omitted or None, no ProcessingRules. Supplied or the supported dynamic human-signing selection.
Generic PDF Prepared DER CMS SignedAttrs, standard DSS SigType="PDF"; no ProcessingRules. Supplied or the supported dynamic human-signing selection.
PAdES PDF/BES with the exact PAdES processing rule and certificate-bound DER attributes; consumer composition for B-B/B-T/B-LT/B-LTA. Preknown actual signing leaf; supplied or statically activated credential.
Detached CMS DER SET OF signed attributes with SHA-256 of the retained original; SigType="CMS" and the exact CMS rule below. Supplied or the supported dynamic human-signing selection.
Generic text / exact UTF-8 The same detached CMS binding; the application retains and delivers the exact UTF-8 original separately. Same as CMS.
Detached XAdES XML/BES plus exact XAdES ProcessingRules, immutable SignedInfo/AdESObject; consumer composition for B-B/B-T/B-LT/B-LTA. Preknown static signing-leaf certificate.
Detached JAdES Explicit local DSS root profile and local task collection, with exact protected signing message; consumer composition for B-B/B-T/B-LT/B-LTA. Preknown static signing-leaf certificate; explicitly enabled requester profile.

A CMS signature can cover arbitrary file bytes. The exact UTF-8 example is a consumer specialization, not a new server task type. Generic PDF and XML support does not imply every PAdES or XAdES level. The selected XAdES and JAdES subsets are described below.

Use SigType="PDF", AdESType="BES" and ProcessingRules="urn:se:idombud:signing:pades:baseline-b-sha256-rsa:v1" together. The consumer owns PDF preparation, complete-level assembly, validation material and archival renewal. The signing request has no Baseline-level field. Follow PAdES signatures and the downloadable preparation guide for exact attributes, certificate requirements and failure handling.

Sign plain text, a text string or text-file bytes through the detached CMS binding (SigType="CMS"). Keep the exact encoded original with the support service, prepare its CMS signed attributes and assemble the returned signature as a separate .p7s file. Recipients verify the signature against those same original bytes. The original text is not uploaded to Signing Server.

Choose and freeze the text encoding before hashing. Generic CMS signs the bytes without interpreting their encoding or MIME type; the UTF-8 consumer profile below adds explicit text-validation and preservation rules. Other encodings use the generic CMS workflow over their exact bytes. Use the CMS preparation and verification steps for the request and result handling.

Freeze the original before hashing or preparing consent. Preserve its BOM, line endings, trailing whitespace and Unicode representation. Decoding and re-encoding, normalizing Unicode or changing a final newline changes the signed original.

The example consumer accepts strict UTF-8, including empty text, up to 1,048,576 bytes. That is a consumer limit: the server receives the prepared CMS attributes, not the text. Use the existing CMS rule:

urn:se:idombud:signing:cms:detached-sha256-rsa:v1

See the detached CMS preparation steps and the complete UTF-8 consumer guide.

Select these values together:

  • SigType="XML".
  • AdESType="BES".
  • ProcessingRules="urn:se:idombud:signing:xades:detached-b-b-sha256-rsa:v1".

Supply the exact canonical SignedInfo and the complete immutable ds:Object as AdESObject, including the matching signature ID. The object binds signed properties and SHA-256 of the complete actual signing-leaf certificate DER. Keep the original outside the request and use the supported opaque reference URI; the server never fetches it.

The original-reference digest and the certificate binding must be fixed before consent. Each prepared input is bounded to 8,192 bytes, and the normal whole-envelope limits still apply. Assemble the returned raw signature with the unchanged inputs, then independently verify the final XAdES and the exact retained original. A changed object, reference, certificate or signature must fail.

The consumer selects the completed B-B/B-T/B-LT/B-LTA level after the unchanged original signing binding. Add signature time over the canonical complete SignatureValue element, embed configured-root chains/complete CRLs, and renew archive protection while preserving all signed and earlier unsigned canonical bytes. No Baseline-level field or new signing endpoint is added. The preknown leaf requirement excludes fresh dynamic-certificate selection for this profile. Follow XAdES signatures and the complete binding reference.

The administrator enables urn:se:idombud:signing:dss:jades:v1 in the registered requester's additional_signing_profiles. Set the request's root Profile to that same URI and use the local urn:se:idombud:signing:jades:dss:v1 task collection. It is a local DSS extension, not a standard Sweden Connect SigType value; do not mix it with standard SignTasks.

The selected RS256 profile uses b64=false, crit=["b64","sigD"] and an ObjectIdByURIHash declaration over the exact original bytes. The protected x5c and x5t#S256 bind the actual preknown signing leaf. Freeze the serialized protected header and its signing message before sending the request. Return values must match the exact ordered task IDs, rule and signing input.

Assemble the B-B flattened detached JWS JSON from the unchanged protected header and returned signature; retain the original separately. Verify the RS256 signature, original-byte digest and configured certificate trust. For B-T, timestamp the ASCII unpadded base64url signature member. For B-LT, embed complete signer/TSA chains and direct-issuer CRLs in encoded anyValData; for B-LTA, add and renew archive timestamps over exact original, protected header, signature and prior encoded history. Validate the complete requested level offline under independently configured roots. The consumer supports up to eight archives without another original signing operation. This profile is default-off and requires the same preknown static leaf for every level. Follow JAdES signatures for exact coverage, limits and renewal. Complete JAdES binding reference and local JAdES task schema.

The downloadable guides describe input preparation, result assembly and signature verification for version 1.0.0. HTTP contracts and configuration schemas are available from the relevant integration pages.

A valid server response or HTTP 200 alone is insufficient. Validate the signed response and its result, correlate the request, verify signer and credential constraints, preserve every prepared input and verify the completed document. Claimed signing time and MIME/document descriptions remain requester assertions; trusted time stamps are obtained through the separate time stamping service.