<?xml version='1.0' encoding='utf-8'?>
<!--
  FFFD22 - Parcel shipping label (generation 3 demo).

  A parcel label sealed when the sender drops the parcel off at an Aurora Parcel counter
  (Republic of Utopia). The signed part says what was handed over: the tracking number, the
  recipient, the destination, the weight, the declared value and two small photos of the
  parcel. Along the way the carrier's depots append tracking events as auxiliary data,
  outside the signature: a later scan updates them without breaking the seal.

  Ported from the BioSeal SDK test corpus (bioseal-sdk test/manifests/gen3/logistics/ffd060.xml,
  a test manifest without labels); there is no v1 POC use case. What generation 3 shows:
  - Schema AuxData: the last tracking event, its time and the depot travel with the seal
    but are not signed, and they have labels and a dictionary like signed fields;
  - a BinaryArray of photos of the parcel (each an ext:Image, WEBP, 32 x 32 at most) and a
    TimestampArray of the scan times at drop-off;
  - the weight as an Integer in grams and the declared value as a Float, each with its unit
    (bs:DisplayHint Unit);
  - a conditional field: the insurance reference is asked (bs:AskWhen) and then required
    (ext:Mandatory with a Float condition) only above a declared value of 500;
  - issuance form hints: an InputMask and an ErrorText on the tracking number, the postal
    code typed as POSTAL_CODE, the tracking number shown first (Emphasis PRIMARY);
  - a seal lifetime of six months (bs:VDSValidityPeriod): a label is useless once the
    parcel is delivered and the claims period is over;
  - NO custom presentation view: the SDK's generic view lays the label out from the
    manifest (labels, groups, units, dictionary).
--><Manifest xmlns="https://gov.otentik.codes/schemas/manifest/v3" xmlns:ext="urn:vdsic:manifest:extensions:3" xmlns:bs="urn:id3:bioseal:manifest:extensions:3" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" version="1">
    <Id>FFFD22</Id>
    <Version>1</Version>
    <Name>
        <Value xml:lang="en">Parcel shipping label</Value>
        <Value xml:lang="fr">Étiquette de colis</Value>
    </Name>
    <Description>
        <Value xml:lang="en">Demo: parcel label sealed at drop-off, with photos and scan times; the carrier appends tracking events outside the signature.</Value>
        <Value xml:lang="fr">Démo : étiquette de colis signée au dépôt, avec photos et horodatages ; le transporteur ajoute les événements de suivi hors signature.</Value>
    </Description>
    <Schema>
        <Payload>
            <Fields>
                <String name="tracking_number">
                    <StringConstraints>
                        <MinLength>13</MinLength>
                        <MaxLength>13</MaxLength>
                        <Pattern>^[A-Z]{2}[0-9]{9}[A-Z]{2}$</Pattern>
                        <Encoding>C40</Encoding>
                    </StringConstraints>
                    <Extension xsi:type="ext:LabelExtensionType">
                        <ext:Value xml:lang="en">Tracking number</ext:Value>
                        <ext:Value xml:lang="fr">Numéro de suivi</ext:Value>
                    </Extension>
                    <Extension xsi:type="bs:InputHintExtensionType">
                        <bs:ErrorText xml:lang="en">2 letters, 9 digits, then 2 letters (e.g. AP123456785UT).</bs:ErrorText>
                        <bs:ErrorText xml:lang="fr">2 lettres, 9 chiffres, puis 2 lettres (par ex. AP123456785UT).</bs:ErrorText>
                        <bs:InputMask>AA999999999AA</bs:InputMask>
                    </Extension>
                    <Extension xsi:type="bs:DisplayHintExtensionType">
                        <bs:Emphasis>PRIMARY</bs:Emphasis>
                    </Extension>
                </String>
                <String name="recipient">
                    <StringConstraints>
                        <MinLength>1</MinLength>
                        <MaxLength>40</MaxLength>
                    </StringConstraints>
                    <Extension xsi:type="ext:LabelExtensionType">
                        <ext:Value xml:lang="en">Recipient</ext:Value>
                        <ext:Value xml:lang="fr">Destinataire</ext:Value>
                    </Extension>
                </String>
                <String name="destination_postal_code">
                    <StringConstraints>
                        <MinLength>3</MinLength>
                        <MaxLength>10</MaxLength>
                    </StringConstraints>
                    <Extension xsi:type="ext:LabelExtensionType">
                        <ext:Value xml:lang="en">Destination postal code</ext:Value>
                        <ext:Value xml:lang="fr">Code postal de destination</ext:Value>
                    </Extension>
                    <Extension xsi:type="bs:InputHintExtensionType">
                        <bs:Placeholder xml:lang="en">e.g. 10420</bs:Placeholder>
                        <bs:Placeholder xml:lang="fr">ex. 10420</bs:Placeholder>
                        <bs:SemanticType>POSTAL_CODE</bs:SemanticType>
                    </Extension>
                </String>
                <Integer name="weight_g">
                    <IntegerConstraints>
                        <Min>1</Min>
                        <Max>30000</Max>
                    </IntegerConstraints>
                    <Extension xsi:type="ext:LabelExtensionType">
                        <ext:Value xml:lang="en">Weight</ext:Value>
                        <ext:Value xml:lang="fr">Poids</ext:Value>
                    </Extension>
                    <Extension xsi:type="bs:InputHintExtensionType">
                        <bs:HelpText xml:lang="en">In grams, as weighed at the counter (30 kg at most).</bs:HelpText>
                        <bs:HelpText xml:lang="fr">En grammes, tel que pesé au guichet (30 kg au plus).</bs:HelpText>
                    </Extension>
                    <Extension xsi:type="bs:DisplayHintExtensionType">
                        <bs:Unit xml:lang="en">g</bs:Unit>
                        <bs:Unit xml:lang="fr">g</bs:Unit>
                    </Extension>
                </Integer>
                <Float name="declared_value">
                    <FloatConstraints>
                        <Nillable/>
                        <Min>0</Min>
                    </FloatConstraints>
                    <Extension xsi:type="ext:LabelExtensionType">
                        <ext:Value xml:lang="en">Declared value</ext:Value>
                        <ext:Value xml:lang="fr">Valeur déclarée</ext:Value>
                    </Extension>
                    <Extension xsi:type="bs:InputHintExtensionType">
                        <bs:HelpText xml:lang="en">Leave empty for an uninsured parcel. Above 500 EUR the parcel is insured.</bs:HelpText>
                        <bs:HelpText xml:lang="fr">Laisser vide pour un colis non assuré. Au-delà de 500 EUR, le colis est assuré.</bs:HelpText>
                    </Extension>
                    <Extension xsi:type="bs:DisplayHintExtensionType">
                        <bs:Unit xml:lang="en">EUR</bs:Unit>
                        <bs:Unit xml:lang="fr">EUR</bs:Unit>
                    </Extension>
                </Float>
                <String name="insurance_ref">
                    <StringConstraints>
                        <Nillable/>
                        <MaxLength>12</MaxLength>
                    </StringConstraints>
                    <Extension xsi:type="ext:LabelExtensionType">
                        <ext:Value xml:lang="en">Insurance reference</ext:Value>
                        <ext:Value xml:lang="fr">Référence d'assurance</ext:Value>
                    </Extension>
                    <!-- Insured when the declared value exceeds 500: the form asks for the
                         reference only then, and then requires it. -->
                    <Extension xsi:type="ext:MandatoryExtensionType">
                        <ext:Condition xsi:type="ext:FloatConditionType">
                            <ext:FieldName>declared_value</ext:FieldName>
                            <ext:Min>500.01</ext:Min>
                        </ext:Condition>
                    </Extension>
                    <Extension xsi:type="bs:AskWhenExtensionType">
                        <bs:Condition xsi:type="ext:FloatConditionType">
                            <ext:FieldName>declared_value</ext:FieldName>
                            <ext:Min>500.01</ext:Min>
                        </bs:Condition>
                    </Extension>
                </String>
                <BinaryArray name="photos">
                    <ArrayConstraints>
                        <MaxSize>3</MaxSize>
                    </ArrayConstraints>
                    <Extension xsi:type="ext:LabelExtensionType">
                        <ext:Value xml:lang="en">Photos of the parcel</ext:Value>
                        <ext:Value xml:lang="fr">Photos du colis</ext:Value>
                    </Extension>
                    <Extension xsi:type="ext:ImageExtensionType">
                        <ext:Format>WEBP</ext:Format>
                        <ext:MaxHeight>32</ext:MaxHeight>
                        <ext:MaxWidth>32</ext:MaxWidth>
                    </Extension>
                    <Extension xsi:type="bs:InputHintExtensionType">
                        <bs:HelpText xml:lang="en">Taken at the counter, reduced to a thumbnail (32 x 32 at most).</bs:HelpText>
                        <bs:HelpText xml:lang="fr">Prises au guichet, réduites en vignette (32 x 32 au plus).</bs:HelpText>
                        <bs:ItemLabel xml:lang="en">Photo</bs:ItemLabel>
                        <bs:ItemLabel xml:lang="fr">Photo</bs:ItemLabel>
                        <bs:AddLabel xml:lang="en">Add a photo</bs:AddLabel>
                        <bs:AddLabel xml:lang="fr">Ajouter une photo</bs:AddLabel>
                    </Extension>
                    <BinaryConstraints>
                        <MaxLength>400</MaxLength>
                    </BinaryConstraints>
                </BinaryArray>
                <TimestampArray name="scanned_at">
                    <ArrayConstraints>
                        <MinSize>1</MinSize>
                        <MaxSize>4</MaxSize>
                    </ArrayConstraints>
                    <Extension xsi:type="ext:LabelExtensionType">
                        <ext:Value xml:lang="en">Scanned at drop-off</ext:Value>
                        <ext:Value xml:lang="fr">Scanné au dépôt</ext:Value>
                    </Extension>
                    <TimestampConstraints>
                        <NotBefore>2024-01-01T00:00:00</NotBefore>
                    </TimestampConstraints>
                </TimestampArray>
                <!-- The issuance service that produced the seal (ext:IssuanceService): the
                     platform writes its CIN, the verifier checks it against the Scheme List.
                     Neither the issuance form (Entry PLATFORM) nor any view (NEVER) shows it. -->
                <String name="issuance_service">
                    <StringConstraints>
                        <MinLength>3</MinLength>
                        <MaxLength>3</MaxLength>
                        <Pattern>^[A-Z0-9]{3}$</Pattern>
                        <Encoding>C40</Encoding>
                    </StringConstraints>
                    <Extension xsi:type="ext:LabelExtensionType">
                        <ext:Value xml:lang="en">Issuance service</ext:Value>
                        <ext:Value xml:lang="fr">Service d'émission</ext:Value>
                    </Extension>
                    <Extension xsi:type="ext:VisibilityExtensionType">
                        <ext:Condition xsi:type="ext:ApplicationConditionType">
                            <ext:Value>NEVER</ext:Value>
                        </ext:Condition>
                    </Extension>
                    <Extension xsi:type="bs:InputHintExtensionType">
                        <bs:Entry>PLATFORM</bs:Entry>
                    </Extension>
                </String>
            </Fields>
        </Payload>
        <!-- Auxiliary data: written by the carrier's depots after the seal is signed, outside
             the signature. A verifier shows it as unsigned tracking information. -->
        <AuxData>
            <Fields>
                <String name="last_event">
                    <StringConstraints>
                        <MaxLength>20</MaxLength>
                        <Pattern>^(ACCEPTED|SORTED|IN_TRANSIT|OUT_FOR_DELIVERY|DELIVERED|HELD)$</Pattern>
                    </StringConstraints>
                    <Extension xsi:type="ext:LabelExtensionType">
                        <ext:Value xml:lang="en">Last tracking event</ext:Value>
                        <ext:Value xml:lang="fr">Dernier événement de suivi</ext:Value>
                    </Extension>
                    <Extension xsi:type="ext:DictionaryLookupExtensionType">
                        <ext:Dictionary>tracking_event</ext:Dictionary>
                    </Extension>
                </String>
                <Timestamp name="last_event_at">
                    <Extension xsi:type="ext:LabelExtensionType">
                        <ext:Value xml:lang="en">Event time</ext:Value>
                        <ext:Value xml:lang="fr">Heure de l'événement</ext:Value>
                    </Extension>
                </Timestamp>
                <String name="depot">
                    <StringConstraints><MaxLength>8</MaxLength></StringConstraints>
                    <Extension xsi:type="ext:LabelExtensionType">
                        <ext:Value xml:lang="en">Depot</ext:Value>
                        <ext:Value xml:lang="fr">Dépôt</ext:Value>
                    </Extension>
                </String>
            </Fields>
        </AuxData>
    </Schema>
    <Extensions>
        <Extension xsi:type="ext:DictionariesExtensionType">
            <ext:Dictionary name="tracking_event">
                <ext:Entry key="ACCEPTED"><ext:Value xml:lang="en">Accepted at the counter</ext:Value><ext:Value xml:lang="fr">Pris en charge au guichet</ext:Value></ext:Entry>
                <ext:Entry key="SORTED"><ext:Value xml:lang="en">Sorted at the depot</ext:Value><ext:Value xml:lang="fr">Trié au dépôt</ext:Value></ext:Entry>
                <ext:Entry key="IN_TRANSIT"><ext:Value xml:lang="en">In transit</ext:Value><ext:Value xml:lang="fr">En transit</ext:Value></ext:Entry>
                <ext:Entry key="OUT_FOR_DELIVERY"><ext:Value xml:lang="en">Out for delivery</ext:Value><ext:Value xml:lang="fr">En cours de livraison</ext:Value></ext:Entry>
                <ext:Entry key="DELIVERED"><ext:Value xml:lang="en">Delivered</ext:Value><ext:Value xml:lang="fr">Livré</ext:Value></ext:Entry>
                <ext:Entry key="HELD"><ext:Value xml:lang="en">Held at the depot</ext:Value><ext:Value xml:lang="fr">En instance au dépôt</ext:Value></ext:Entry>
            </ext:Dictionary>
        </Extension>
        <Extension xsi:type="ext:PoliciesExtensionType">
            <ext:AuthorizedUsage>
                <ext:oid>1.3.6.1.4.1.51528.1.1</ext:oid>
                <ext:uuid>0945dbd91c8d425685733a4c7eee3a6a</ext:uuid>
            </ext:AuthorizedUsage>
            <!-- The label has no expiry date of its own: the seal lives six months, the time
                 to deliver the parcel and to settle a claim. -->
            <bs:VDSValidityPeriod>
                <bs:Value>6</bs:Value>
                <bs:Unit>MONTHS</bs:Unit>
            </bs:VDSValidityPeriod>
            <bs:CertificateValidity>
                <bs:ExpiryDateGracePeriod><bs:Value>30</bs:Value><bs:Unit>DAYS</bs:Unit></bs:ExpiryDateGracePeriod>
                <bs:RevocationInfoGracePeriod><bs:Value>2</bs:Value><bs:Unit>DAYS</bs:Unit></bs:RevocationInfoGracePeriod>
            </bs:CertificateValidity>
        </Extension>
        <Extension xsi:type="ext:IssuanceServiceExtensionType">
            <ext:PayloadField>issuance_service</ext:PayloadField>
        </Extension>
        <Extension xsi:type="bs:IssuancePoliciesExtensionType">
            <bs:KeyProtection>
                <bs:MinimumLevel>L1</bs:MinimumLevel>
                <bs:Rationale>
                    <bs:Value xml:lang="en">Demo: signed with a software key; a production issuer declares a stronger level.</bs:Value>
                    <bs:Value xml:lang="fr">Démo : signé avec une clé logicielle ; un émetteur en production déclare un niveau supérieur.</bs:Value>
                </bs:Rationale>
            </bs:KeyProtection>
        </Extension>
        <Extension xsi:type="bs:AdditionalInformationExtensionType">
            <bs:DataPrivacy>
                <bs:Value xml:lang="en">The seal carries the recipient's name and postal code, the parcel's weight, value and thumbnails; the tracking events are added by the carrier and are not signed.</bs:Value>
                <bs:Value xml:lang="fr">Le cachet contient le nom et le code postal du destinataire, le poids, la valeur et les vignettes du colis ; les événements de suivi sont ajoutés par le transporteur et ne sont pas signés.</bs:Value>
            </bs:DataPrivacy>
            <bs:PointOfContact>
                <bs:Value xml:lang="en">contact@id3.eu</bs:Value>
                <bs:Value xml:lang="fr">contact@id3.eu</bs:Value>
            </bs:PointOfContact>
        </Extension>
        <Extension xsi:type="bs:IssuanceParametersExtensionType">
            <bs:Encoding>BASE45</bs:Encoding>
            <bs:QuietZone>4</bs:QuietZone>
            <bs:Symbology>QRCODE</bs:Symbology>
            <bs:QrcodeParameters>
                <bs:ErrorCorrectionLevel>M</bs:ErrorCorrectionLevel>
                <bs:Version>AUTOMATIC</bs:Version>
            </bs:QrcodeParameters>
            <bs:Caption>
                <bs:Text>AURORA PARCEL</bs:Text>
                <bs:Position>BOTTOM</bs:Position>
                <bs:Color>#FFFFFF</bs:Color>
                <bs:FontFamily>SANS_SERIF</bs:FontFamily>
                <bs:Style>FRAME</bs:Style>
                <bs:FrameColor>#8A4B08</bs:FrameColor>
                <bs:CornerRadius>4</bs:CornerRadius>
                <bs:FontWeight>700</bs:FontWeight>
            </bs:Caption>
        </Extension>
        <Extension xsi:type="bs:FieldGroupsExtensionType">
            <bs:Group Name="parcel" Scope="BOTH">
                <bs:Label xml:lang="en">Parcel</bs:Label>
                <bs:Label xml:lang="fr">Colis</bs:Label>
                <bs:PayloadField>tracking_number</bs:PayloadField>
                <bs:PayloadField>recipient</bs:PayloadField>
                <bs:PayloadField>destination_postal_code</bs:PayloadField>
                <bs:PayloadField>weight_g</bs:PayloadField>
            </bs:Group>
            <bs:Group Name="value" Scope="BOTH">
                <bs:Label xml:lang="en">Value and insurance</bs:Label>
                <bs:Label xml:lang="fr">Valeur et assurance</bs:Label>
                <bs:PayloadField>declared_value</bs:PayloadField>
                <bs:PayloadField>insurance_ref</bs:PayloadField>
            </bs:Group>
            <bs:Group Name="drop_off" Scope="BOTH">
                <bs:Label xml:lang="en">Drop-off</bs:Label>
                <bs:Label xml:lang="fr">Dépôt</bs:Label>
                <bs:Description xml:lang="en">Recorded at the Aurora Parcel counter when the parcel was handed over.</bs:Description>
                <bs:Description xml:lang="fr">Enregistré au guichet Aurora Parcel lors de la remise du colis.</bs:Description>
                <bs:PayloadField>photos</bs:PayloadField>
                <bs:PayloadField>scanned_at</bs:PayloadField>
            </bs:Group>
        </Extension>
    </Extensions>
<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#ecdsa-sha256"/><ds:Reference URI=""><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>pwA5D5P9URTWp3XJm5QOCBO5JfEtv6ysVExTJYq1swc=</ds:DigestValue></ds:Reference></ds:SignedInfo><ds:Signat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