<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE rfc [
  <!ENTITY nbsp "&#160;">
  <!ENTITY zwsp "&#8203;">
  <!ENTITY nbhy "&#8209;">
  <!ENTITY wj "&#8288;">
]>
<?xml-stylesheet type="text/xsl" href="rfc2629.xslt"?>
<rfc xmlns:xi="http://www.w3.org/2001/XInclude"
     ipr="trust200902"
     docName="draft-midwestcyber-dspip-01"
     category="std"
     submissionType="IETF"
     consensus="true"
     tocInclude="true"
     sortRefs="true"
     symRefs="true"
     version="3">

  <front>
    <title abbrev="DSPIP">Digital Signing of Physical Items Protocol (DSPIP)</title>

    <seriesInfo name="Internet-Draft" value="draft-midwestcyber-dspip-01"/>

    <author initials="A." surname="Boell" fullname="Andy Boell" role="editor">
      <organization>Midwest Cyber LLC</organization>
      <address>
        <postal>
          <street>1022 Brickyard Dr</street>
          <city>Hooper</city>
          <region>NE</region>
          <code>68031</code>
          <country>United States of America</country>
        </postal>
        <email>contact@dspip.io</email>
        <uri>https://dspip.io</uri>
      </address>
    </author>

    <date year="2026" month="January" day="13"/>

    <area>Security</area>
    <workgroup>Internet Engineering Task Force</workgroup>

    <keyword>digital-signature</keyword>
    <keyword>shipping</keyword>
    <keyword>qr-code</keyword>
    <keyword>cryptography</keyword>
    <keyword>dns</keyword>
    <keyword>pki</keyword>

    <abstract>
      <t>This document specifies the Digital Signing of Physical Items
      Protocol (DSPIP), a cryptographic protocol for authenticating
      physical items using digitally signed QR codes. This specification
      focuses on the SHIP type for shipping and logistics applications,
      providing cryptographic authentication of packages with chain of
      custody tracking.</t>

      <t>The protocol introduces privacy-preserving delivery mechanisms
      including encrypted recipient information, last mile provider
      selection, physical anti-cloning protections through split-key
      labels, and scalable revocation and delivery confirmation systems.
      DSPIP uses DNS-based public key distribution similar to DKIM and
      supports optional blockchain integration for immutable record
      keeping. While this specification focuses on shipping applications,
      the protocol includes a type field to enable future expansion to
      other use cases.</t>
    </abstract>
  </front>

  <middle>
    <!-- Section 1: Introduction -->
    <section anchor="introduction">
      <name>Introduction</name>
      <t>Supply chain logistics require verifiable proof of package
      authenticity, chain of custody, and delivery confirmation. Current
      shipping systems rely on proprietary tracking databases with varying
      security models and no cryptographic verification of package
      authenticity or delivery. QR codes on shipping labels can be easily
      copied, leading to fraud and misdirection of packages.</t>

      <t>DSPIP provides a cryptographic protocol specifically designed for
      shipping and logistics, enabling verification of package origin,
      custody chain, and delivery while protecting recipient privacy. The
      protocol addresses the fundamental challenge of QR code cloning
      through physical binding mechanisms and provides privacy-preserving
      delivery that reveals recipient information only to authorized last
      mile providers.</t>

      <t>By using the secp256k1 elliptic curve, DSPIP keys are compatible
      with major blockchain networks, allowing optional integration for
      immutable custody records while not requiring blockchain for basic
      operation. The protocol includes a type field set to "SHIP" for
      this specification, enabling future expansion to other applications.</t>

      <t>The design goals for DSPIP shipping protocol are:</t>
      <ul>
        <li>Cryptographic Authentication: Verify package origin and integrity
        through digital signatures</li>
        <li>Privacy Preservation: Protect recipient information during transit
        through encryption</li>
        <li>Anti-Cloning: Prevent QR code duplication through physical
        binding mechanisms</li>
        <li>Decentralized Verification: No central authority required for
        package validation</li>
        <li>Offline Capable: Verification possible without network
        connectivity</li>
        <li>Delivery Confirmation: Cryptographic proof of successful delivery</li>
        <li>Scalable Operations: Support high-volume shipping with efficient
        revocation and confirmation systems</li>
        <li>Standards Compliant: Integrate with existing logistics systems
        and standards</li>
        <li>Cost Effective: Near-zero marginal cost per package authenticated</li>
        <li>Blockchain Optional: Can integrate with blockchain but operates
        independently</li>
      </ul>

      <t>DSPIP follows a "digital envelope" paradigm for shipping labels:</t>
      <ul>
        <li>Envelope exterior (publicly readable): Sender identity, last mile
        provider destination, tracking number, and timestamp are encoded
        but not encrypted. This functions like the address on a physical
        envelope.</li>
        <li>Signature (authenticity seal): A cryptographic signature proves
        the label was created by the claimed sender and has not been
        tampered with, similar to a shipping seal.</li>
        <li>Private contents (encrypted): The actual recipient address and
        delivery instructions are encrypted for the last mile provider,
        like the contents of a sealed package that only the authorized
        recipient can access.</li>
      </ul>
      <t>This model protects recipient privacy while maintaining package
      routability and authenticity verification.</t>
    </section>

    <!-- Section 1.1: Requirements Language -->
    <section anchor="requirements-language">
      <name>Requirements Language</name>
      <t>The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",
      "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this
      document are to be interpreted as described in <xref target="RFC2119"/>
      <xref target="RFC8174"/> when, and only when, they appear in all
      capitals, as shown here.</t>
    </section>

    <!-- Section 2: Relationship to Existing Standards -->
    <section anchor="existing-standards">
      <name>Relationship to Existing Standards</name>
      <t>DSPIP builds upon established standards while introducing novel
      shipping-specific features:</t>

      <t>Standards This Document Builds Upon:</t>
      <ul>
        <li><xref target="RFC6376"/> (DKIM): DSPIP adopts DKIM's DNS-based public key
        distribution model for shipping providers</li>
        <li><xref target="RFC8017"/> (PKCS #1): Uses established cryptographic specifications</li>
        <li><xref target="ISO18004"/>: Utilizes QR code standards for label encoding</li>
        <li><xref target="SEC2"/>: Employs secp256k1 curve specifications (same curve
        as used by Bitcoin <xref target="Bitcoin"/> and Ethereum <xref target="Ethereum"/>)</li>
        <li><xref target="ECIES"/>: Elliptic Curve Integrated Encryption Scheme for
        recipient privacy</li>
        <li><xref target="Ed25519"/>: For split-key label authentication</li>
      </ul>

      <t>Related Shipping Standards:</t>
      <ul>
        <li><xref target="GS1-EPCIS"/>: DSPIP adds cryptographic authentication to event-
        based visibility</li>
        <li><xref target="EDI856"/> (ASN): DSPIP enables verification without central
        database</li>
        <li>Last Mile Standards: DSPIP adds encrypted routing for privacy</li>
      </ul>

      <t>Novel Contributions:</t>
      <ul>
        <li>Privacy-Preserving Delivery: Encrypted recipient information
        with last mile provider routing</li>
        <li>Physical Anti-Cloning: Split-key labels with destructive reveal
        prevent QR code duplication</li>
        <li>Cryptographic Proof of Delivery: Challenge-response confirmation
        without key exposure</li>
        <li>Scalable Confirmation Systems: Bulk revocation and delivery
        lists for high-volume operations</li>
      </ul>
    </section>

    <!-- Section 3: Protocol Overview -->
    <section anchor="protocol-overview">
      <name>Protocol Overview</name>

      <section anchor="data-flow">
        <name>Data Flow</name>
        <t>The DSPIP shipping protocol flow consists of the following steps:</t>
        <ol>
          <li>Payload Creation: Sender creates a JSON payload containing sender information, last mile provider or recipient, tracking number, and timestamp</li>
          <li>Privacy Selection: Choose privacy mode (standard, encrypted, or split-key) based on security requirements</li>
          <li>Recipient Encryption: For privacy modes, encrypt recipient information with last mile provider's public key</li>
          <li>Encoding: Payload is Base64 encoded to ensure consistent handling</li>
          <li>Signing: Sender signs the data using their private key (or label's private key for split-key mode)</li>
          <li>QR Generation: Complete data structure is serialized and encoded as a QR code</li>
          <li>Label Application: QR code is printed on shipping label and attached to package</li>
          <li>Transit Scanning: Carriers scan QR code at each custody transfer point</li>
          <li>DNS Lookup: Scanner queries DNS TXT record to retrieve public key</li>
          <li>Verification: Scanner verifies signature (or requests Zone B reveal for split-key)</li>
          <li>Privacy Decryption: Last mile provider decrypts recipient information using their private key</li>
          <li>Delivery: Package delivered to actual recipient address</li>
          <li>Confirmation: Cryptographic proof of delivery recorded</li>
          <li>Optional Blockchain: Custody chain recorded for audit trail</li>
        </ol>
      </section>

      <section anchor="protocol-workflow">
        <name>Protocol Workflow</name>
        <figure anchor="fig-workflow">
          <name>DSPIP Shipping Flow</name>
          <artwork type="ascii-art"><![CDATA[
+--------+                    +----------+              +---------+
| Sender |                    | Carrier  |              |Recipient|
+--------+                    +----------+              +---------+
    |                              |                        |
    | 1. Create Shipping Payload   |                        |
    |    {sender, provider,        |                        |
    |     trackingId, timestamp}   |                        |
    |                              |                        |
    | 2. Select Privacy Mode       |                        |
    | 3. Encrypt Recipient         |                        |
    | 4. Base64 Encode             |                        |
    | 5. Sign with Private Key     |                        |
    | 6. Generate QR Code          |                        |
    | 7. Attach Label to Package   |                        |
    |==============================|========================|
    |                    8. Scan QR Code                    |
    |                    9. Parse Data                      |
    |                   10. DNS Lookup                      |
    |                   11. Verify Signature                |
    |                   12. Check Revocation                |
    |                   13. Decrypt Recipient               |
    |                   14. Deliver Package                 |
    |                         |=========================>   |
    |                   15. Delivery Confirmation           |
    |                         |<========================    |
    |                   16. Record Proof                    |
]]></artwork>
        </figure>
      </section>
    </section>

    <!-- Section 4: Data Formats -->
    <section anchor="data-formats">
      <name>Data Formats</name>

      <section anchor="payload-structure">
        <name>Payload Structure</name>
        <t>The payload contains shipping information encoded as JSON. Country codes use <xref target="ISO3166"/> alpha-2 format:</t>
        <sourcecode type="json"><![CDATA[
{
  "type": "SHIP",               // REQUIRED: Fixed for shipping
  "issuer": {                   // REQUIRED: Sender information
    "name": "string",
    "organization": "string",
    "address": {
      "street1": "string",
      "city": "string",
      "state": "string",
      "postalCode": "string",
      "country": "string"       // REQUIRED: per ISO3166 alpha-2
    }
  },
  "subject": {                  // REQUIRED: Recipient/Provider
    "name": "string",
    "lastMileProvider": "string",
    "address": { ... }
  },
  "itemId": "string",           // REQUIRED: Tracking number
  "timestamp": number,          // REQUIRED: Unix timestamp (ms)
  "typeData": {}                // SHIP-specific fields
}
]]></sourcecode>
      </section>

      <section anchor="ship-type-fields">
        <name>SHIP Type Payload Fields</name>
        <t>The typeData object contains shipping-specific information including privacy mode, carrier details, customs information, and delivery confirmation settings.</t>
      </section>

      <section anchor="privacy-modes">
        <name>Privacy Modes</name>
        <t>DSPIP supports three privacy modes for shipping:</t>

        <section anchor="standard-mode">
          <name>Standard Mode (Legacy)</name>
          <t>Traditional shipping with full recipient information visible.</t>
        </section>

        <section anchor="encrypted-mode">
          <name>Encrypted Mode</name>
          <t>Privacy-preserving with encrypted recipient data. The recipient's address and delivery instructions are encrypted with the last mile provider's public key.</t>
        </section>

        <section anchor="split-key-mode">
          <name>Split-Key Mode</name>
          <t>Maximum security with physical anti-cloning. Uses Ed25519 keys printed in separate scratch-off zones on the physical label.</t>
        </section>
      </section>

      <section anchor="qr-data-structure">
        <name>QR Data Structure</name>
        <t>The complete QR code data structure contains:</t>
        <ul>
          <li>protocol: Fixed string "DSPIP"</li>
          <li>version: Semantic version string ("1.0")</li>
          <li>type: Fixed to "SHIP" for this specification</li>
          <li>keyLocator: DNS path for public key lookup</li>
          <li>encodedPayload: Base64-encoded JSON payload</li>
          <li>signature: Hex-encoded ECDSA signature</li>
          <li>privateMessage: Optional Base64-encoded encrypted message</li>
        </ul>
      </section>

      <section anchor="serialization-format">
        <name>Serialization Format</name>
        <t>QR data MUST be serialized using pipe (|) delimiters:</t>
        <artwork><![CDATA[
DSPIP|<version>|<type>|<keyLocator>|<payload>|<sig>[|<msg>]
]]></artwork>
        <t>The pipe delimiter was chosen for its low frequency in Base64 and domain names. Implementations MUST validate that exactly 6 or 7 pipe-delimited fields are present.</t>
      </section>
    </section>

    <!-- Section 5: DNS Key Distribution -->
    <section anchor="dns-key-distribution">
      <name>DNS Key Distribution</name>
      <t>DSPIP uses DNS TXT records for public key distribution, following the model established by DKIM <xref target="RFC6376"/>.</t>

      <section anchor="key-locator-format">
        <name>Key Locator Format</name>
        <t>Key locators MUST follow this pattern:</t>
        <artwork><![CDATA[
<selector>._dspip.<domain>
]]></artwork>
        <t>Where selector is a unique identifier for the specific key, _dspip is the fixed protocol subdomain (underscore prefix per <xref target="RFC8552"/>), and domain is the organization's domain name.</t>
      </section>

      <section anchor="dns-txt-record-format">
        <name>DNS TXT Record Format</name>
        <t>The DNS TXT record MUST contain a semicolon-separated list of tag=value pairs:</t>
        <artwork><![CDATA[
v=DSPIP1; k=ec; c=secp256k1; p=<base64_public_key>; [optional]
]]></artwork>
        <t>Required tags: v (protocol version), k (key type), c (curve identifier), p (public key in Base64).</t>
        <t>Optional tags: t (creation timestamp), x (expiration), n (notes), types, auth, address, coverage.</t>

        <section anchor="address-field-format">
          <name>Address Field Format</name>
          <t>The address field specifies the physical location of signing facilities, primarily for last mile providers. This enables verifiers to display facility location on shipping labels for encrypted privacy mode, where the recipient address is hidden.</t>
          <t>The address field uses a scheme prefix to indicate the encoding:</t>
          <ul>
            <li>plus: (DEFAULT) Open Location Code / Plus Code</li>
            <li>street: Percent-encoded street address per <xref target="RFC3986"/></li>
            <li>geo: Geographic coordinates (latitude,longitude)</li>
            <li>facility: Named facility reference</li>
          </ul>
          <t>If no scheme prefix is present, implementations MUST interpret the value as a Plus Code (plus: scheme).</t>

          <section anchor="plus-code-scheme">
            <name>Plus Code Scheme (Default)</name>
            <t>Plus Codes (Open Location Codes) are the RECOMMENDED addressing scheme due to their compact representation, open standard licensing, and global coverage.</t>
            <t>Format: address=plus:&lt;plus_code&gt;</t>
            <t>Short form: address=&lt;plus_code&gt;</t>
            <t>Examples:</t>
            <artwork><![CDATA[
address=plus:86HJW222+22        (full Plus Code, ~3m precision)
address=849VCWC8+R9             (implicit plus: scheme)
address=plus:CWC8+R9,Omaha      (short code with locality)
]]></artwork>
            <t>Plus Codes are 10-11 characters for full precision or 6-7 characters when combined with a locality reference. See <xref target="PLUSCODE"/> for the Open Location Code specification.</t>
          </section>

          <section anchor="street-address-scheme">
            <name>Street Address Scheme</name>
            <t>Traditional street addresses encoded using percent-encoding per <xref target="RFC3986"/>.</t>
            <t>Format: address=street:&lt;percent_encoded_address&gt;</t>
            <t>Examples:</t>
            <artwork><![CDATA[
address=street:1234%20Post%20Office%20Way%2C%20Omaha%2C%20NE%2068101
address=street:123%20Business%20Ave%2C%20Suite%20100
]]></artwork>
            <t>Street addresses SHOULD include city and postal code for clarity.</t>
          </section>

          <section anchor="geo-coordinate-scheme">
            <name>Geographic Coordinate Scheme</name>
            <t>Decimal latitude and longitude coordinates.</t>
            <t>Format: address=geo:&lt;latitude&gt;,&lt;longitude&gt;</t>
            <t>Examples:</t>
            <artwork><![CDATA[
address=geo:41.2565,-95.9345
address=geo:40.7128,-74.0060
]]></artwork>
            <t>Coordinates MUST use decimal degrees with negative values for South and West. Precision SHOULD be at least 4 decimal places (~11 meter accuracy).</t>
          </section>

          <section anchor="facility-reference-scheme">
            <name>Facility Reference Scheme</name>
            <t>Named facility reference for organizations with published facility directories.</t>
            <t>Format: address=facility:&lt;facility_id&gt;</t>
            <t>Examples:</t>
            <artwork><![CDATA[
address=facility:USPS-OMAHA-MAIN
address=facility:UPS-NE-401
]]></artwork>
            <t>Facility references require external directory lookup. Organizations using this scheme SHOULD publish facility directories at a well-known location or via the discovery record.</t>
          </section>

          <section anchor="address-field-requirements">
            <name>Address Field Requirements</name>
            <ul>
              <li>The address field is OPTIONAL for key records</li>
              <li>Last mile providers SHOULD include address for encrypted mode label display</li>
              <li>Implementations SHOULD prefer Plus Codes for new deployments</li>
              <li>Verifiers MUST support all four schemes</li>
              <li>When displaying addresses, verifiers MAY render Plus Codes as clickable links to mapping services</li>
            </ul>
          </section>
        </section>
      </section>

      <section anchor="selector-discovery">
        <name>Selector Discovery</name>
        <t>To enable discovery of available selectors for a domain, organizations MAY publish a discovery record at the base _dspip subdomain.</t>

        <section anchor="discovery-record-format">
          <name>Discovery Record Format</name>
          <artwork><![CDATA[
_dspip.example.com. IN TXT
  "v=DSPIP1; type=discovery;
   selectors=warehouse,fulfillment,returns;
   delegation=list"
]]></artwork>
          <t>Discovery record tags:</t>
          <ul>
            <li>v: Protocol version (MUST be "DSPIP1")</li>
            <li>type: Record type (MUST be "discovery" for discovery records)</li>
            <li>selectors: Comma-separated list of available selectors</li>
            <li>delegation: Delegation scheme for selector organization</li>
          </ul>
        </section>

        <section anchor="delegation-schemes">
          <name>Delegation Schemes</name>
          <t>The delegation tag indicates how selectors are organized:</t>
          <ul>
            <li>list: Explicit enumeration in selectors field</li>
            <li>geo: Geographic prefixes (e.g., us-west, eu-central)</li>
            <li>postal: Postal code prefixes (e.g., 68_, 90_)</li>
            <li>region: Regional identifiers (e.g., midwest, northeast)</li>
            <li>service: Service-based selectors (e.g., express, ground)</li>
          </ul>
          <t>Examples:</t>
          <artwork><![CDATA[
List delegation:
_dspip.example.com. IN TXT "v=DSPIP1; type=discovery;
  selectors=warehouse-a,warehouse-b,fulfillment; delegation=list"

Geographic delegation:
_dspip.globalcorp.example. IN TXT "v=DSPIP1; type=discovery;
  delegation=geo; pattern=<region>-<facility>"

Postal code delegation:
_dspip.usps.example. IN TXT "v=DSPIP1; type=discovery;
  delegation=postal; pattern=<zip5>; coverage=00000-99999"
]]></artwork>
        </section>

        <section anchor="discovery-requirements">
          <name>Discovery Requirements</name>
          <ul>
            <li>Discovery records are OPTIONAL</li>
            <li>Verifiers SHOULD NOT require discovery records for verification</li>
            <li>Discovery records SHOULD be cached according to DNS TTL</li>
            <li>Implementations MAY use discovery for user interfaces and directory services</li>
          </ul>
        </section>
      </section>

      <section anchor="key-lifecycle">
        <name>Key Lifecycle Management</name>
        <t>DSPIP keys have a defined lifecycle to ensure security while maintaining verification capability for in-transit packages.</t>

        <section anchor="key-record-fields">
          <name>Key Record Fields</name>
          <t>The DNS TXT record supports the following lifecycle fields:</t>
          <t>Required fields:</t>
          <ul>
            <li>v: Protocol version (MUST be "DSPIP1")</li>
            <li>k: Key type (MUST be "ec")</li>
            <li>c: Curve identifier (MUST be "secp256k1")</li>
            <li>p: Public key in Base64 encoding</li>
          </ul>
          <t>SHOULD include:</t>
          <ul>
            <li>t: Key creation timestamp (Unix time). If omitted, verifiers SHOULD treat the key as valid from an indefinite past.</li>
            <li>exp: Signing expiration timestamp (Unix time). After this time, the key MUST NOT be used to sign new items. If omitted, the key has no signing expiration.</li>
          </ul>
          <t>MAY include:</t>
          <ul>
            <li>exp-v: Verification expiration timestamp (Unix time). After this time, the key MUST NOT be used to verify any signatures. If omitted, defaults to exp value (if present) or no expiration.</li>
            <li>s: Key status. Values: "active" (default if omitted), "verify-only" (can verify but not sign), "revoked" (completely invalid).</li>
            <li>seq: Sequence number for key updates. Higher values supersede lower values for the same selector.</li>
            <li>n: Human-readable notes (percent-encoded)</li>
          </ul>
        </section>

        <section anchor="key-lifecycle-states">
          <name>Key Lifecycle States</name>
          <t>Keys transition through the following states:</t>
          <ol>
            <li>Active: Key can sign new items and verify existing signatures. Status: s=active (or omitted), current time &lt; exp</li>
            <li>Verify-Only: Key cannot sign new items but can verify existing signatures. Status: s=verify-only, or exp &lt; current time &lt; exp-v</li>
            <li>Expired: Key is completely invalid and MUST NOT be used. Status: s=revoked, or current time &gt; exp-v</li>
          </ol>
        </section>

        <section anchor="recommended-key-lifetime">
          <name>Recommended Key Lifetime</name>
          <t>For shipping applications, the following key lifetime is RECOMMENDED:</t>
          <ul>
            <li>Active signing period: 365 days (1 year)</li>
            <li>Verify-only period: 365 additional days (1 year)</li>
            <li>Total key lifetime: 730 days (2 years)</li>
          </ul>
          <t>This provides sufficient time for packages to complete transit (typically 1-30 days) while limiting exposure from compromised keys.</t>
          <t>Example DNS record with lifecycle fields:</t>
          <artwork><![CDATA[
warehouse._dspip.example.com. IN TXT "v=DSPIP1; k=ec; c=secp256k1;
  p=AzmjYBMwFZfa70H75ZOgLMUT0LVVJ+wt8QUOLo/0nIXC;
  t=1703548800; exp=1735084800; exp-v=1766620800;
  s=active; seq=1; n=Main%20Warehouse%20Key%202025"
]]></artwork>
        </section>

        <section anchor="key-rotation">
          <name>Key Rotation</name>
          <t>Organizations SHOULD implement key rotation:</t>
          <ul>
            <li>Generate new key before current key's exp timestamp</li>
            <li>Publish new key with incremented seq value</li>
            <li>Transition signing to new key</li>
            <li>Maintain old key for verification until exp-v</li>
            <li>Remove old key after exp-v passes</li>
          </ul>
        </section>

        <section anchor="field-omission-semantics">
          <name>Field Omission Semantics</name>
          <t>When lifecycle fields are omitted, verifiers MUST apply these rules:</t>
          <ul>
            <li>t omitted: Key has no creation date constraint</li>
            <li>exp omitted: Key has no signing expiration (signs indefinitely)</li>
            <li>exp-v omitted: Defaults to exp value; if exp also omitted, key verifies indefinitely</li>
            <li>s omitted: Key is "active"</li>
            <li>seq omitted: Treated as seq=0; cannot supersede keys with seq &gt; 0</li>
          </ul>
          <t>Note: While omitting fields is permitted for backwards compatibility, implementations SHOULD include t, exp, and exp-v for production keys to enable proper lifecycle management.</t>
        </section>

        <section anchor="record-signature">
          <name>Record Signature (rsig)</name>
          <t>The rsig field provides cryptographic authentication of lifecycle metadata within the DNS record itself. This protects against unauthorized modification of lifecycle fields (t, exp, exp-v, s, seq) by intermediate DNS resolvers or caches.</t>

          <section anchor="rsig-threat-model">
            <name>Threat Model</name>
            <t>Without rsig, an attacker with access to an intermediate DNS resolver or cache could modify lifecycle fields without invalidating QR code signatures. For example:</t>
            <ul>
              <li>Extending exp to hide that a key has expired</li>
              <li>Changing s=revoked to s=active to hide key compromise</li>
              <li>Modifying seq to prevent key rotation from taking effect</li>
            </ul>
            <t>The rsig field allows verifiers to detect such modifications by checking a signature over the lifecycle metadata.</t>
          </section>

          <section anchor="rsig-signable-content">
            <name>Signable Content</name>
            <t>The rsig signature covers a canonical string of lifecycle fields:</t>
            <artwork><![CDATA[
rsig_content = selector "|" t "|" exp "|" exp-v "|" s "|" seq
]]></artwork>
            <t>Where:</t>
            <ul>
              <li>selector: The selector portion of the key locator (e.g., "warehouse")</li>
              <li>t: Creation timestamp as decimal string, or empty if omitted</li>
              <li>exp: Signing expiration as decimal string, or empty if omitted</li>
              <li>exp-v: Verification expiration as decimal string, or empty if omitted</li>
              <li>s: Status value, or empty if omitted (defaults to "active")</li>
              <li>seq: Sequence number as decimal string, or empty if omitted</li>
            </ul>
            <t>Example signable content: "warehouse|1703548800|1735084800|1766620800|active|1"</t>
          </section>

          <section anchor="rsig-signature-generation">
            <name>Signature Generation</name>
            <t>The rsig value is generated as follows:</t>
            <ol>
              <li>Construct the signable content string as defined above</li>
              <li>Compute SHA-256 hash of the UTF-8 encoded signable content</li>
              <li>Sign the hash using ECDSA with the same private key that corresponds to the public key in the p= field</li>
              <li>Encode the signature in Base64</li>
            </ol>
            <t>The same key signs both QR codes and the rsig, providing proof that the key owner authorized the lifecycle metadata.</t>
          </section>

          <section anchor="rsig-verification-process">
            <name>Verification Process</name>
            <t>When rsig is present, verifiers SHOULD:</t>
            <ol>
              <li>Extract the rsig value from the DNS record</li>
              <li>Reconstruct the signable content from the record's lifecycle fields</li>
              <li>Compute SHA-256 hash of the signable content</li>
              <li>Verify the rsig signature using the public key from the p= field</li>
              <li>If verification fails, treat the record as untrusted</li>
            </ol>
          </section>

          <section anchor="rsig-requirements">
            <name>Requirements</name>
            <ul>
              <li>rsig is OPTIONAL for DNS records</li>
              <li>When rsig is present, verifiers SHOULD verify it</li>
              <li>If rsig verification fails, verifiers SHOULD reject the record or flag it with a LIFECYCLE_UNVERIFIED warning</li>
              <li>Implementations MAY operate in "rsig-required" mode for high-security deployments</li>
              <li>rsig provides defense-in-depth; DNSSEC provides stronger guarantees when available</li>
            </ul>
          </section>

          <section anchor="rsig-dnssec-relationship">
            <name>Relationship to DNSSEC</name>
            <t>DNSSEC and rsig serve complementary purposes:</t>
            <ul>
              <li>DNSSEC: Zone owner signs all records; proves record came from authoritative zone</li>
              <li>rsig: Key owner signs lifecycle metadata; proves the signing key holder authorized the lifecycle values</li>
            </ul>
            <t>For maximum security, deployments SHOULD use both DNSSEC and rsig. DNSSEC alone is sufficient if the organization controls their DNS infrastructure end-to-end.</t>
          </section>
        </section>
      </section>

      <section anchor="key-revocation">
        <name>Key Revocation</name>
        <t>When a signing key is compromised or must be retired, organizations MUST have a mechanism to inform verifiers that the key should no longer be trusted. While the s=revoked status in the key record provides this capability, DNS caching can delay propagation.</t>
        <t>The key revocation record provides a dedicated, frequently-checked endpoint for key status that operates independently of key record caching.</t>

        <section anchor="key-revocation-record-format">
          <name>Key Revocation Record Format</name>
          <artwork><![CDATA[
_revoked-key._dspip.example.com. IN TXT
  "v=DSPIP1; type=key-revocation;
   selector=warehouse;
   revoked=1703548900;
   reason=compromised;
   replacement=warehouse-v2"
]]></artwork>
          <t>Fields:</t>
          <ul>
            <li>v: Protocol version (MUST be "DSPIP1")</li>
            <li>type: Record type (MUST be "key-revocation")</li>
            <li>selector: The selector of the revoked key (REQUIRED)</li>
            <li>revoked: Unix timestamp when the key was revoked (REQUIRED)</li>
            <li>reason: Reason for revocation (REQUIRED). Values: compromised (private key was exposed or stolen), retired (key reached end of lifecycle), superseded (key replaced by newer key), suspended (temporarily disabled, may be reactivated)</li>
            <li>replacement: Selector of the replacement key (OPTIONAL)</li>
          </ul>
        </section>

        <section anchor="multiple-key-revocations">
          <name>Multiple Key Revocations</name>
          <t>Organizations with multiple revoked keys MAY use multiple TXT records or a bulk format:</t>
          <artwork><![CDATA[
Individual records:
_revoked-key._dspip.example.com. IN TXT "v=DSPIP1; type=key-revocation;
  selector=warehouse-a; revoked=1703548900; reason=compromised"
_revoked-key._dspip.example.com. IN TXT "v=DSPIP1; type=key-revocation;
  selector=warehouse-b; revoked=1703549000; reason=retired"

Bulk pointer:
_revoked-key._dspip.example.com. IN TXT
  "v=DSPIP1; type=key-revocation-list;
   url=https://example.com/dspip/revoked-keys.json;
   updated=1703548800"
]]></artwork>
        </section>

        <section anchor="verifier-requirements-key-revocation">
          <name>Verifier Requirements for Key Revocation</name>
          <t>Verifiers MUST check key revocation status before trusting signatures:</t>
          <ol>
            <li>Query _revoked-key._dspip.&lt;domain&gt; with minimal or no caching</li>
            <li>If the key's selector appears in the revocation record(s), REJECT the signature immediately</li>
            <li>Key revocation takes precedence over s=active in the key record</li>
            <li>Verifiers SHOULD use short TTLs (60-300 seconds) when caching key revocation records</li>
            <li>For high-security deployments, verifiers MAY query key revocation on every verification without caching</li>
          </ol>
        </section>

        <section anchor="relationship-key-record-status">
          <name>Relationship to Key Record Status</name>
          <t>The s (status) field in key records and _revoked-key records serve complementary purposes:</t>
          <ul>
            <li>s=revoked in key record: Authoritative status, but subject to DNS caching delays</li>
            <li>_revoked-key record: Dedicated revocation channel with shorter cache lifetime for faster propagation</li>
          </ul>
          <t>Organizations SHOULD update both when revoking a key:</t>
          <ol>
            <li>Publish _revoked-key record (immediate propagation)</li>
            <li>Update key record with s=revoked (authoritative status)</li>
          </ol>
          <t>Verifiers MUST treat a key as revoked if EITHER indicates revocation.</t>
        </section>
      </section>

      <section anchor="package-revocation">
        <name>Package Revocation</name>
        <t>Individual packages may need to be revoked due to loss, theft, or fraud without revoking the signing key. DSPIP provides two mechanisms for package revocation.</t>

        <section anchor="individual-package-revocation">
          <name>Individual Package Revocation Record</name>
          <t>For low-volume revocations, organizations MAY publish individual revocation records directly in DNS:</t>
          <artwork><![CDATA[
_revoked._dspip.example.com. IN TXT
  "v=DSPIP1; type=item-revocation;
   itemId=TRACK-2025-000123;
   revoked=1703548900;
   reason=lost"
]]></artwork>
          <t>Fields:</t>
          <ul>
            <li>v: Protocol version (MUST be "DSPIP1")</li>
            <li>type: Record type (MUST be "item-revocation")</li>
            <li>itemId: The revoked package identifier (REQUIRED)</li>
            <li>revoked: Unix timestamp when the package was revoked (REQUIRED)</li>
            <li>reason: Reason for revocation (REQUIRED). Values: lost (package lost in transit), stolen (package was stolen), damaged (package damaged and reshipped), recalled (package recalled by sender), fraud (fraudulent QR code detected)</li>
            <li>replacementId: New itemId for reshipped package (OPTIONAL)</li>
          </ul>
        </section>

        <section anchor="bulk-package-revocation">
          <name>Bulk Package Revocation</name>
          <t>For scalability, senders MAY publish bulk revocation lists:</t>

          <section anchor="revocation-pointer-record">
            <name>Revocation Pointer Record</name>
            <artwork><![CDATA[
revocation._dspip.example.com. IN TXT
  "v=DSPIP1; type=revocation;
   url=https://example.com/dspip/revoked.json;
   format=json|bloom;
   updated=1703548800;
   ttl=86400"
]]></artwork>
          </section>

          <section anchor="revocation-list-format">
            <name>Revocation List Format</name>
            <artwork><![CDATA[
{
  "version": "1.0",
  "issuer": "warehouse._dspip.example.com",
  "updated": 1703548800,
  "expires": 1719316800,
  "revoked": [
    {
      "itemId": "TRACK-2025-000123",
      "revoked": 1703548900,
      "reason": "lost|stolen|damaged|recalled",
      "expires": 1719316900,
      "replacementId": "TRACK-2025-000124"
    }
  ],
  "signature": "issuer_signature"
}
]]></artwork>
            <t>Bloom filter format (for privacy):</t>
            <artwork><![CDATA[
{
  "version": "1.0",
  "issuer": "warehouse._dspip.example.com",
  "updated": 1703548800,
  "filter": {
    "type": "bloom",
    "size": 1048576,
    "hashes": 7,
    "falsePositiveRate": 0.001,
    "data": "base64_bloom_filter_data"
  },
  "signature": "issuer_signature"
}
]]></artwork>
          </section>

          <section anchor="revocation-requirements">
            <name>Revocation Requirements</name>
            <ul>
              <li>Lists MUST be served over HTTPS</li>
              <li>Lists SHOULD auto-prune entries older than 180 days</li>
              <li>Lists MAY use <xref target="BLOOM"/> filters for privacy</li>
              <li>Verifiers SHOULD cache lists based on TTL</li>
            </ul>
          </section>

          <section anchor="revocation-freshness">
            <name>Revocation Freshness</name>
            <t>To ensure timely revocation detection, revocation records MUST NOT be cached indefinitely. The revocation list format includes freshness fields:</t>
            <artwork><![CDATA[
{
  "version": "1.0",
  "issuer": "warehouse._dspip.example.com",
  "ts": 1703548800,
  "max-age": 900,
  "updated": 1703548800,
  "revoked": [...]
}
]]></artwork>
            <t>Freshness field semantics:</t>
            <ul>
              <li>ts: Unix timestamp when the revocation list was generated. MUST be present. Verifiers MUST reject lists where current_time - ts exceeds max-age.</li>
              <li>max-age: Maximum age in seconds before the list must be refreshed. MUST be present. Recommended values: 300-900 seconds (5-15 min) for active verification, up to 3600 seconds (1 hour) for background checks.</li>
            </ul>
            <t>Verifier requirements:</t>
            <ul>
              <li>Verifiers MUST check ts + max-age &gt; current_time before using a cached revocation list</li>
              <li>Verifiers MUST refresh revocation lists when max-age expires</li>
              <li>Verifiers SHOULD NOT serve stale revocation data to end users</li>
              <li>Verifiers MAY implement background refresh to maintain fresh data</li>
            </ul>
            <t>Note: These freshness requirements apply to revocation lists only. Key records follow standard DNS TTL caching semantics.</t>
          </section>
        </section>
      </section>

      <section anchor="delivery-confirmation-dist">
        <name>Delivery Confirmation Distribution</name>
        <t>Last mile providers MAY publish delivery confirmations:</t>

        <section anchor="delivery-confirmation-pointer">
          <name>Delivery Confirmation Pointer</name>
          <artwork><![CDATA[
delivered._dspip.usps.example. IN TXT
  "v=DSPIP1; type=delivered;
   url=https://usps.example/dspip/delivered.json;
   updated=1703548800;
   ttl=3600"
]]></artwork>
        </section>

        <section anchor="delivery-confirmation-format">
          <name>Delivery Confirmation Format</name>
          <artwork><![CDATA[
{
  "version": "1.0",
  "provider": "omaha-main._dspip.usps.example",
  "updated": 1703548800,
  "expires": 1711324800,
  "delivered": [
    {
      "itemId": "TRACK-2025-000123",
      "deliveredAt": 1703548900,
      "deliveredTo": {
        "type": "signature|photo|cryptographic",
        "data": "base64_proof_data",
        "recipientKeyHash": "sha256_hash",
        "challenge": "base64_challenge",
        "response": "base64_signature"
      },
      "location": {
        "coordinates": "41.2565,-95.9345",
        "accuracy": 10,
        "address": "456 Main Street"
      },
      "carrier": {
        "driver": "driver123._dspip.usps.example",
        "signature": "carrier_attestation"
      }
    }
  ],
  "signature": "provider_signature"
}
]]></artwork>
        </section>

        <section anchor="callback-mechanism">
          <name>Callback Mechanism</name>
          <t>Senders MAY specify callback URLs for real-time confirmation:</t>
          <artwork><![CDATA[
"deliveryConfirmation": {
  "callbackUrl": "https://sender.com/dspip/confirm",
  "callbackAuth": "Bearer abc123xyz789",
  "callbackMethod": "POST"
}
]]></artwork>
          <t>Callback payload:</t>
          <artwork><![CDATA[
{
  "itemId": "TRACK-2025-000123",
  "status": "delivered|attempted|returned",
  "timestamp": 1703548900,
  "proof": {
    "type": "cryptographic",
    "challenge": "base64_challenge",
    "response": "base64_signature"
  },
  "signature": "provider_signature"
}
]]></artwork>
        </section>
      </section>
    </section>

    <!-- Section 6: Cryptographic Operations -->
    <section anchor="crypto-operations">
      <name>Cryptographic Operations</name>

      <section anchor="key-generation">
        <name>Key Generation</name>
        <t>DSPIP uses the secp256k1 elliptic curve as specified in <xref target="SEC2"/>:</t>
        <ul>
          <li>Curve: secp256k1</li>
          <li>Private key: 256 bits (32 bytes)</li>
          <li>Public key: 264 bits (33 bytes compressed)</li>
        </ul>
        <t>For split-key labels, <xref target="Ed25519"/> is used with 256-bit keys.</t>
      </section>

      <section anchor="signature-creation">
        <name>Signature Creation</name>
        <t>Standard signature using ECDSA:</t>
        <ol>
          <li>Construct signable content: signable = protocol | version | type | keyLocator | payload</li>
          <li>Calculate SHA-256 hash of signable content</li>
          <li>Sign hash using ECDSA with private key</li>
          <li>Encode signature in DER format</li>
          <li>Convert to hexadecimal string</li>
        </ol>
      </section>

      <section anchor="signature-verification">
        <name>Signature Verification</name>
        <t>Standard verification reconstructs signable content, calculates SHA-256 hash, retrieves public key from DNS, and verifies ECDSA signature.</t>
        <t>Split-key verification requires Zone B reveal and uses Ed25519 verification without DNS lookup.</t>
      </section>
    </section>

    <!-- Section 7: Verification Process -->
    <section anchor="verification-process">
      <name>Verification Process</name>

      <section anchor="verification-algorithm">
        <name>Verification Algorithm</name>
        <t>Input: QR code data string. Output: Verification result with validity status.</t>
        <ol>
          <li>PARSE: Split QR data by pipe delimiter, validate 6 or 7 fields present</li>
          <li>VALIDATE PROTOCOL: Protocol MUST equal "DSPIP", Version MUST be compatible, Type MUST equal "SHIP"</li>
          <li>DECODE PAYLOAD: Base64 decode and parse JSON</li>
          <li>DNS LOOKUP: Query DNS TXT record for keyLocator</li>
          <li>VERIFY SIGNATURE: Verify with public key</li>
          <li>PRIVACY DECRYPTION: Decrypt encryptedRecipient if last mile provider</li>
          <li>REVOCATION CHECK: Query revocation list</li>
          <li>OPTIONAL BLOCKCHAIN: Record custody transfer</li>
        </ol>
      </section>

      <section anchor="privacy-delivery-protocol">
        <name>Privacy-Preserving Delivery Protocol</name>
        <t>The privacy-preserving delivery protocol protects recipient information during transit.</t>

        <section anchor="protocol-overview-privacy">
          <name>Protocol Overview</name>
          <ol>
            <li>Recipient Selection: At checkout, recipient selects their preferred last mile provider (post office, corporate mailroom, residential carrier)</li>
            <li>Key Retrieval: System retrieves the last mile provider's public key from DNS or directory service</li>
            <li>Encryption: Recipient's address and delivery instructions are encrypted with the last mile provider's public key</li>
            <li>Label Creation: Shipping label shows only the last mile provider destination in cleartext</li>
            <li>Transit: Package routes to last mile provider with encrypted recipient data</li>
            <li>Decryption: Last mile provider decrypts recipient information using their private key</li>
            <li>Final Delivery: Provider completes delivery to actual recipient</li>
            <li>Confirmation: Cryptographic proof of delivery recorded</li>
          </ol>
        </section>

        <section anchor="last-mile-registration">
          <name>Last Mile Provider Registration</name>
          <t>Organizations register as last mile providers by publishing keys:</t>
          <t>Post office:</t>
          <artwork><![CDATA[
omaha-main._dspip.usps.example. IN TXT
  "v=DSPIP1; k=ec; c=secp256k1;
   p=AzmjYBMwFZfa70H75ZOgLMUT0LVVJ+wt8QUOLo/0nIXC;
   types=SHIP; auth=government;
   address=1234 Post Office Way, Omaha, NE 68102;
   coverage=68101,68102,68103,68104,68105"
]]></artwork>
          <t>Corporate mailroom:</t>
          <artwork><![CDATA[
mailroom._dspip.acmecorp.example. IN TXT
  "v=DSPIP1; k=ec; c=secp256k1;
   p=CylmZCNxGafb91I86BPhNNVV2NXYL+yu8SVQNq/2pKZE;
   types=SHIP; auth=organization;
   address=123 Business Ave"
]]></artwork>
        </section>

        <section anchor="encryption-specification">
          <name>Encryption Specification</name>
          <t>Recipients are encrypted using ECIES over secp256k1 per <xref target="ECIES"/>:</t>
          <ol>
            <li>Generate ephemeral key pair (r, R = rG)</li>
            <li>Compute shared secret: S = r * LastMilePublicKey</li>
            <li>Derive encryption key: K = KDF(S || R) using <xref target="SHA256"/></li>
            <li>Encrypt: C = AES-256-GCM(K, recipient_data) per <xref target="AES"/></li>
            <li>Output: R || C || tag (R: ephemeral public key 33 bytes, C: ciphertext variable length, tag: authentication tag 16 bytes)</li>
          </ol>
        </section>

        <section anchor="organizational-hierarchies">
          <name>Organizational Hierarchies</name>
          <t>Large organizations MAY implement tiered decryption:</t>
          <t>Organization Master: mailroom._dspip.acmecorp.example</t>
          <ul>
            <li>Decrypts all packages to organization</li>
            <li>Routes internally based on decrypted data</li>
          </ul>
          <t>Department Level: engineering._dspip.acmecorp.example</t>
          <ul>
            <li>Department-specific packages only</li>
          </ul>
          <t>Individual Level: john.doe._dspip.acmecorp.example</t>
          <ul>
            <li>Personal packages only</li>
          </ul>
        </section>

        <section anchor="directory-services">
          <name>Directory Services</name>
          <t>Vendors MAY use directory services to map addresses to providers:</t>
          <t>Request:</t>
          <artwork><![CDATA[
GET https://directory.dspip.org/providers?zip=68102
]]></artwork>
          <t>Response:</t>
          <sourcecode type="json"><![CDATA[
{
  "providers": [
    {
      "name": "USPS Omaha Main",
      "keyLocator": "omaha-main._dspip.usps.example",
      "services": ["standard", "express", "certified"],
      "coverage": ["68101", "68102", "68103"],
      "publicKey": "AzmjYBMwFZfa70H75ZOgLMUT0LVVJ+wt8QUOLo/0nIXC"
    },
    {
      "name": "FedEx Omaha Hub",
      "keyLocator": "omaha._dspip.fedex.example",
      "services": ["overnight", "2day", "ground"],
      "coverage": ["68101-68199"],
      "publicKey": "BxkiXPQwFZfe80J86AOhMMVU1MWWK+xu9RVPMp/1oJYD"
    }
  ]
}
]]></sourcecode>
        </section>

        <section anchor="fallback-mechanism">
          <name>Fallback Mechanism</name>
          <t>If decryption fails:</t>
          <ol>
            <li>Provider attempts decryption -> Fails</li>
            <li>Provider looks up sender from issuer field</li>
            <li>Provider contacts sender with parcelId</li>
            <li>Sender provides recipient information via secure channel</li>
            <li>Delivery proceeds normally</li>
            <li>Incident logged for audit</li>
          </ol>
        </section>

        <section anchor="customs-compliance">
          <name>Customs Compliance</name>
          <t>For international shipping:</t>
          <sourcecode type="json"><![CDATA[
{
  "typeData": {
    "customsInfo": {
      "contents": "Electronics",
      "value": 500,
      "hsCode": "8471.30",
      "originCountry": "US",
      "destinationCountry": "CA"
    },
    "lastMileProvider": "toronto._dspip.canadapost.example",
    "encryptedRecipient": "base64_encrypted"
  }
}
]]></sourcecode>
        </section>
      </section>

      <section anchor="split-key-authentication">
        <name>Physical Authentication via Split-Key Labels</name>
        <t>Split-key labels prevent QR code cloning through physical cryptographic binding.</t>

        <section anchor="label-manufacturing">
          <name>Label Manufacturing</name>
          <t>Secure labels with embedded key pairs:</t>
          <artwork type="ascii-art"><![CDATA[
Physical Layout:
+--------------------------------+
| DSPIP Authentication Label     |
| Serial: LABEL-2025-ABC123      |
|                                |
| Zone A: <SCRATCH OFF>          |
| Private Key (Sender Reveal)    |
| ████████████████████████████   |
|                                |
| Zone B: <SCRATCH OFF>          |
| Public Key (Receiver Reveal)   |
| ████████████████████████████   |
|                                |
| Apply QR Code Here: <    >     |
| Security Features:             |
| - Holographic seal             |
| - Tamper-evident material      |
| - UV-reactive fibers           |
+--------------------------------+
]]></artwork>
        </section>

        <section anchor="manufacturing-requirements">
          <name>Manufacturing Requirements</name>
          <t>Label producers MUST:</t>
          <ul>
            <li>Generate unique key pairs using HSM</li>
            <li>Use cryptographically secure random generation</li>
            <li>Print using secure facilities</li>
            <li>Use tamper-evident scratch-off material</li>
            <li>Destroy all digital copies after printing</li>
            <li>Never retain private keys</li>
            <li>Maintain audit log of serial numbers</li>
          </ul>
        </section>

        <section anchor="split-key-protocol-detail">
          <name>Split-Key Protocol</name>
          <t>MANUFACTURING:</t>
          <ol>
            <li>Generate keypair (sk, pk) using <xref target="Ed25519"/></li>
            <li>Print sk under Zone A (32 bytes hex)</li>
            <li>Print pk under Zone B (32 bytes hex)</li>
            <li>Destroy digital copies</li>
            <li>Package in tamper-evident packaging</li>
          </ol>
          <t>SENDER:</t>
          <ol>
            <li>Purchase authenticated label</li>
            <li>Verify label authenticity</li>
            <li>Scratch Zone A -> reveal sk</li>
            <li>Create payload with privacyMode = "split-key", authenticationProfile = "PHYSICAL-SPLIT-KEY", labelSerial = "LABEL-2025-ABC123"</li>
            <li>Sign: signature = Sign_Ed25519(sk, payload)</li>
            <li>Generate QR code</li>
            <li>Apply to label</li>
            <li>Destroy revealed sk</li>
          </ol>
          <t>RECEIVER:</t>
          <ol>
            <li>Receive package with intact Zone B</li>
            <li>Scan QR -> extract payload + signature</li>
            <li>Scratch Zone B -> reveal pk</li>
            <li>Verify: Verify_Ed25519(pk, payload, signature)</li>
            <li>If valid: Package authentic</li>
            <li>If invalid: Package cloned/tampered</li>
          </ol>
        </section>

        <section anchor="security-properties">
          <name>Security Properties</name>
          <t>This mechanism provides:</t>
          <ul>
            <li>Clone Detection: Cloned QRs lack matching public keys</li>
            <li>Tamper Evidence: Scratch-offs show if revealed</li>
            <li>Non-transferable: Cannot move QR to different label</li>
            <li>Offline Verification: No network required</li>
            <li>Forward Secrecy: Private key destroyed after use</li>
          </ul>
        </section>

        <section anchor="anti-cloning-analysis">
          <name>Anti-Cloning Analysis</name>
          <t>Attack: Copy QR to new package</t>
          <ul>
            <li>-> No matching public key on new label</li>
            <li>-> Verification fails</li>
          </ul>
          <t>Attack: Copy entire label</t>
          <ul>
            <li>-> Cannot manufacture same key pair</li>
            <li>-> Different keys = verification fails</li>
          </ul>
          <t>Attack: Intercept and re-sign</t>
          <ul>
            <li>-> Private key already destroyed</li>
            <li>-> Cannot create valid signature</li>
          </ul>
          <t>Attack: Photograph public key area</t>
          <ul>
            <li>-> Still need private key for forgery</li>
            <li>-> Cannot create fake packages</li>
          </ul>
        </section>
      </section>

      <section anchor="delivery-confirmation-protocol">
        <name>Delivery Confirmation Protocol</name>
        <t>DSPIP supports cryptographic proof of delivery.</t>

        <section anchor="challenge-response-proof">
          <name>Challenge-Response Proof</name>
          <t>At delivery:</t>
          <ol>
            <li>Carrier generates: challenge = nonce || parcelId || timestamp || location</li>
            <li>Carrier presents challenge to recipient</li>
            <li>Recipient signs: proof = Sign(recipient_key, challenge)</li>
            <li>Carrier verifies proof</li>
            <li>Carrier records the confirmation</li>
          </ol>
          <t>Confirmation record format:</t>
          <sourcecode type="json"><![CDATA[
{
  "parcelId": "TRACK-2025-000123",
  "challenge": "base64_challenge",
  "proof": "base64_proof",
  "timestamp": 1703548900,
  "location": "41.2565,-95.9345"
}
]]></sourcecode>
        </section>

        <section anchor="single-use-delivery-keys">
          <name>Single-Use Delivery Keys</name>
          <t>Recipients MAY generate ephemeral keys:</t>
          <t>At checkout:</t>
          <sourcecode type="json"><![CDATA[
{
  "deliveryConfirmation": {
    "publicKey": "ephemeral_pubkey",
    "validUntil": 1704153600
  }
}
]]></sourcecode>
          <t>At delivery:</t>
          <sourcecode type="json"><![CDATA[
{
  "challenge": "nonce:abc123:1703548900",
  "response": "Sign(ephemeral_key, challenge)",
  "discardKey": true
}
]]></sourcecode>
        </section>

        <section anchor="proof-storage">
          <name>Proof Storage</name>
          <t>Delivery proofs are published:</t>
          <sourcecode type="json"><![CDATA[
{
  "itemId": "TRACK-2025-000123",
  "delivered": {
    "timestamp": 1703548900,
    "recipientKeyHash": "sha256_hash",
    "challenge": "base64_challenge",
    "response": "base64_signature",
    "carrier": {
      "driver": "driver123._dspip.fedex.example",
      "signature": "carrier_attestation"
    },
    "location": {
      "coordinates": "41.2565,-95.9345",
      "accuracy": 10
    }
  }
}
]]></sourcecode>
        </section>

        <section anchor="multi-party-confirmation">
          <name>Multi-Party Confirmation</name>
          <t>For high-value shipments:</t>
          <sourcecode type="json"><![CDATA[
{
  "itemId": "TRACK-2025-000123",
  "confirmations": [
    {
      "party": "recipient",
      "signature": "recipient_signature",
      "timestamp": 1703548900
    },
    {
      "party": "carrier",
      "signature": "carrier_signature",
      "timestamp": 1703548905
    },
    {
      "party": "witness",
      "signature": "witness_signature",
      "timestamp": 1703548910
    }
  ]
}
]]></sourcecode>
        </section>
      </section>
    </section>

    <!-- Section 8: Security Considerations -->
    <section anchor="security-considerations">
      <name>Security Considerations</name>

      <section anchor="threat-model">
        <name>Threat Model</name>
        <t>DSPIP addresses the following shipping-specific threats:</t>
        <ul>
          <li>Package Forgery: Mitigated through cryptographic signatures</li>
          <li>QR Code Cloning: Prevented through split-key labels</li>
          <li>Recipient Privacy Breach: Protected through encryption</li>
          <li>Delivery Fraud: Cryptographic proof prevents false claims</li>
          <li>Package Tampering: Signatures detect modifications</li>
          <li>Replay Attacks: Unique tracking IDs prevent reuse</li>
          <li>Man-in-the-Middle: DNSSEC protects key lookups</li>
          <li>Tracking Attacks: Privacy modes prevent correlation</li>
        </ul>
      </section>

      <section anchor="key-management-security">
        <name>Key Management</name>
        <t>Private Key Protection:</t>
        <ul>
          <li>Shipping keys SHOULD use hardware security modules</li>
          <li>Last mile providers MUST secure decryption keys</li>
          <li>Split-key labels provide one-time-use keys</li>
        </ul>
        <t>Key Rotation:</t>
        <ul>
          <li>Organizations SHOULD rotate keys annually</li>
          <li>Old keys remain in DNS for verification</li>
          <li>Emergency rotation procedures required</li>
        </ul>
        <t>Key Revocation:</t>
        <ul>
          <li>Compromised keys removed from DNS immediately</li>
          <li>Affected packages reissued</li>
          <li>Revocation lists updated</li>
        </ul>
      </section>

      <section anchor="privacy-considerations">
        <name>Privacy Considerations</name>
        <t>Data Minimization:</t>
        <ul>
          <li>Use encrypted mode for consumer deliveries</li>
          <li>Limit address fields to necessary information</li>
          <li>Comply with <xref target="GDPR"/> where applicable</li>
        </ul>
        <t>Privacy Modes:</t>
        <ul>
          <li>Standard: Business shipments with transparency</li>
          <li>Encrypted: Consumer privacy protection</li>
          <li>Split-key: Maximum security for valuable items</li>
        </ul>
        <t>Correlation Prevention:</t>
        <ul>
          <li>Random tracking IDs</li>
          <li>Limited timestamp precision</li>
          <li>Different encryption per package</li>
        </ul>
      </section>

      <section anchor="revocation-mechanisms">
        <name>Revocation Mechanisms</name>
        <t>Package revocation for lost/stolen items:</t>
        <t>Individual records:</t>
        <artwork><![CDATA[
_revoked._dspip.example.com IN TXT
  "v=DSPIP1; itemId=TRACK-2025-000123;
   revoked=1703548900; reason=lost"
]]></artwork>
        <t>Bulk lists:</t>
        <artwork><![CDATA[
revocation._dspip.example.com IN TXT
  "v=DSPIP1; type=revocation;
   url=https://example.com/dspip/revoked.json;
   updated=1703548800"
]]></artwork>
        <t>Auto-pruning:</t>
        <ul>
          <li>SHIP entries expire after 180 days</li>
        </ul>
        <t>Privacy option:</t>
        <ul>
          <li><xref target="BLOOM"/> filters hide specific revoked items</li>
        </ul>
      </section>

      <section anchor="operational-security">
        <name>Operational Security</name>
        <t>Label Manufacturing:</t>
        <ul>
          <li>Secure facilities required</li>
          <li>Audit trails for serial numbers</li>
          <li>No retention of private keys</li>
          <li>Tamper-evident packaging</li>
        </ul>
        <t>Directory Services:</t>
        <ul>
          <li>HTTPS required</li>
          <li>Authentication for updates</li>
          <li>Rate limiting</li>
          <li>Cache poisoning prevention</li>
        </ul>
        <t>Delivery Confirmation:</t>
        <ul>
          <li>Time-bounded challenges</li>
          <li>Location verification</li>
          <li>Multi-party attestation for high value</li>
        </ul>
      </section>
    </section>

    <!-- Section 9: IANA Considerations -->
    <section anchor="iana-considerations">
      <name>IANA Considerations</name>
      <t>This document requests IANA to register the following:</t>
      <ol>
        <li>Registration of "_dspip" in the "Underscored and Globally Scoped DNS Node Names" registry per <xref target="RFC8552"/></li>
        <li>Reservation of "DSPIP" as a protocol identifier</li>
        <li>Registration of DSPIP-specific DNS TXT record tags</li>
        <li>Creation of DSPIP Type Registry with initial value SHIP</li>
        <li>Creation of DSPIP Privacy Mode Registry (standard, encrypted, split-key)</li>
        <li>Creation of DSPIP Authentication Profile Registry</li>
        <li>Creation of DSPIP Key Revocation Reason Registry</li>
        <li>Creation of DSPIP Item Revocation Reason Registry</li>
        <li>Creation of DSPIP Delivery Confirmation Type Registry</li>
        <li>Creation of DSPIP Key Status Registry</li>
        <li>Creation of DSPIP Delegation Scheme Registry</li>
        <li>Creation of DSPIP Address Scheme Registry</li>
      </ol>
    </section>

  </middle>

  <back>
    <!-- References -->
    <references>
      <name>Normative References</name>

      <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.2119.xml"/>
      <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.8174.xml"/>
      <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.6376.xml"/>
      <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.3986.xml"/>
      <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.8552.xml"/>

      <reference anchor="SEC2" target="https://www.secg.org/sec2-v2.pdf">
        <front>
          <title>SEC 2: Recommended Elliptic Curve Domain Parameters</title>
          <author>
            <organization>Standards for Efficient Cryptography Group</organization>
          </author>
          <date year="2010" month="January"/>
        </front>
        <refcontent>Version 2.0</refcontent>
      </reference>

      <reference anchor="ECIES">
        <front>
          <title>A Survey of the Elliptic Curve Integrated Encryption Scheme</title>
          <author initials="V." surname="Gayoso Martinez" fullname="V. Gayoso Martinez"/>
          <author initials="L." surname="Hernandez Encinas" fullname="L. Hernandez Encinas"/>
          <author initials="C." surname="Sanchez Avila" fullname="C. Sanchez Avila"/>
          <date year="2010" month="August"/>
        </front>
        <refcontent>Journal of Computer Science and Engineering, Volume 2, Issue 2</refcontent>
      </reference>

      <reference anchor="Ed25519">
        <front>
          <title>High-speed high-security signatures</title>
          <author initials="D." surname="Bernstein" fullname="D. Bernstein"/>
          <date year="2012" month="September"/>
        </front>
        <seriesInfo name="DOI" value="10.1007/s13389-012-0027-1"/>
        <refcontent>Journal of Cryptographic Engineering, Volume 2, pp 77-89</refcontent>
      </reference>
    </references>

    <references>
      <name>Informative References</name>

      <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.8017.xml"/>

      <reference anchor="ISO18004">
        <front>
          <title>Information technology - Automatic identification and data capture techniques - QR Code bar code symbology specification</title>
          <author>
            <organization>ISO/IEC</organization>
          </author>
          <date year="2015"/>
        </front>
        <refcontent>ISO/IEC 18004:2015</refcontent>
      </reference>

      <reference anchor="ISO3166">
        <front>
          <title>Codes for the representation of names of countries and their subdivisions</title>
          <author>
            <organization>ISO</organization>
          </author>
          <date year="2020"/>
        </front>
        <refcontent>ISO 3166-1:2020</refcontent>
      </reference>

      <reference anchor="GS1-EPCIS" target="https://www.gs1.org/standards/epcis">
        <front>
          <title>EPCIS (Electronic Product Code Information Services) Standard</title>
          <author>
            <organization>GS1</organization>
          </author>
          <date year="2022"/>
        </front>
        <refcontent>Version 2.0</refcontent>
      </reference>

      <reference anchor="EDI856">
        <front>
          <title>Ship Notice/Manifest Transaction Set</title>
          <author>
            <organization>X12</organization>
          </author>
          <date year="2020"/>
        </front>
        <refcontent>ASC X12 Standard EDI 856</refcontent>
      </reference>

      <reference anchor="Bitcoin" target="https://bitcoin.org/bitcoin.pdf">
        <front>
          <title>Bitcoin: A Peer-to-Peer Electronic Cash System</title>
          <author initials="S." surname="Nakamoto" fullname="Satoshi Nakamoto"/>
          <date year="2008"/>
        </front>
      </reference>

      <reference anchor="Ethereum" target="https://ethereum.org/whitepaper/">
        <front>
          <title>Ethereum: A Next-Generation Smart Contract and Decentralized Application Platform</title>
          <author initials="V." surname="Buterin" fullname="Vitalik Buterin"/>
          <date year="2014"/>
        </front>
      </reference>

      <reference anchor="GDPR">
        <front>
          <title>Regulation (EU) 2016/679 (General Data Protection Regulation)</title>
          <author>
            <organization>European Parliament and Council</organization>
          </author>
          <date year="2016" month="April"/>
        </front>
      </reference>

      <reference anchor="AES">
        <front>
          <title>Advanced Encryption Standard (AES)</title>
          <author>
            <organization>National Institute of Standards and Technology</organization>
          </author>
          <date year="2001" month="November"/>
        </front>
        <refcontent>FIPS PUB 197</refcontent>
      </reference>

      <reference anchor="SHA256">
        <front>
          <title>Secure Hash Standard (SHS)</title>
          <author>
            <organization>National Institute of Standards and Technology</organization>
          </author>
          <date year="2015" month="August"/>
        </front>
        <refcontent>FIPS PUB 180-4</refcontent>
      </reference>

      <reference anchor="PLUSCODE" target="https://github.com/google/open-location-code">
        <front>
          <title>Open Location Code (Plus Codes)</title>
          <author>
            <organization>Google</organization>
          </author>
        </front>
        <annotation>An open-source system for encoding geographic coordinates into a compact, URL-safe string.</annotation>
      </reference>

      <reference anchor="BLOOM">
        <front>
          <title>Space/Time Trade-offs in Hash Coding with Allowable Errors</title>
          <author initials="B." surname="Bloom" fullname="Burton Bloom"/>
          <date year="1970" month="July"/>
        </front>
        <refcontent>Communications of the ACM, Volume 13, Issue 7, pp 422-426</refcontent>
      </reference>
    </references>

    <!-- Appendix A: Test Vectors -->
    <section anchor="test-vectors" numbered="true" toc="include">
      <name>Test Vectors</name>

      <section anchor="test-key-pair">
        <name>Test Key Pair</name>
        <t>Private Key (hex):</t>
        <artwork><![CDATA[
e8f32e723decf4051aefac8e2c93c9c5b214313817cdb01a1494b917c8436b35
]]></artwork>
        <t>Public Key Compressed (hex):</t>
        <artwork><![CDATA[
0339a36013301597daef41fbe593a02cc513d0b55527ec2df1050e2e8ff49c85c2
]]></artwork>
        <t>Public Key Base64 (for DNS):</t>
        <artwork><![CDATA[
AzmjYBMwFZfa70H75ZOgLMUT0LVVJ+wt8QUOLo/0nIXC
]]></artwork>
      </section>

      <section anchor="test-standard-mode">
        <name>Standard Mode Shipping</name>
        <t>Payload:</t>
        <sourcecode type="json"><![CDATA[
{
  "type": "SHIP",
  "issuer": {
    "organization": "ACME Logistics",
    "address": {"city": "Omaha", "state": "NE", "country": "US"}
  },
  "subject": {
    "name": "Bob Jones",
    "address": {
      "street1": "456 Main Street",
      "city": "Lincoln",
      "state": "NE",
      "postalCode": "68501",
      "country": "US"
    }
  },
  "itemId": "TRACK-2025-000123",
  "timestamp": 1703548800000,
  "typeData": {
    "privacyMode": "standard",
    "parcelId": "TRACK-2025-000123",
    "carrier": "ACME",
    "service": "Ground"
  }
}
]]></sourcecode>
        <t>Signature (DER-encoded ECDSA/secp256k1, hex):</t>
        <artwork><![CDATA[
30440220250f55bf60f3f82031677d17e6202fbf12e31b9ce8d1541e287e1fdd8
ce40a41022056ef5cd183a674c4f5fdc5e0cac1dcfd386de2e7d505681f83104e
2b1f53a315
]]></artwork>
      </section>

      <section anchor="test-privacy-mode">
        <name>Privacy Mode Shipping</name>
        <t>Recipient data (to be encrypted):</t>
        <sourcecode type="json"><![CDATA[
{
  "recipientName": "Bob Jones",
  "address": {
    "street1": "456 Main Street",
    "apartment": "4B",
    "city": "Lincoln",
    "state": "NE",
    "postalCode": "68501"
  },
  "deliveryInstructions": "Use back door, code 4321"
}
]]></sourcecode>
      </section>

      <section anchor="test-split-key-mode">
        <name>Split-Key Mode</name>
        <t>Label Serial: LABEL-2025-ABC123</t>
        <t>Zone A Private Key (Ed25519, hex):</t>
        <artwork><![CDATA[
9d61b19deffd5a60ba844af492ec2cc44449c5697b326919703bac031cae7f60
]]></artwork>
        <t>Zone B Public Key (Ed25519, hex):</t>
        <artwork><![CDATA[
d75a980182b10ab7d54bfed3c964073a0ee172f3daa62325af021a68f707511a
]]></artwork>
        <t>Signature (Ed25519, hex):</t>
        <artwork><![CDATA[
1fb94d499a504e201433d0e783906a013e26c21daca3ab8c5ad1e9fcf73a1c58
c9ed3abd60802f3abaac01d35bada76ab1bf571ca1641b8d3ea62f7468fbef0f
]]></artwork>
      </section>

      <section anchor="test-dns-records">
        <name>DNS TXT Records</name>
        <t>Warehouse:</t>
        <artwork><![CDATA[
warehouse._dspip.example.com. IN TXT "v=DSPIP1; k=ec; c=secp256k1;
  p=AzmjYBMwFZfa70H75ZOgLMUT0LVVJ+wt8QUOLo/0nIXC; types=SHIP"
]]></artwork>
      </section>

      <section anchor="test-revocation-list">
        <name>Revocation List</name>
        <sourcecode type="json"><![CDATA[
{
  "version": "1.0",
  "issuer": "warehouse._dspip.example.com",
  "updated": 1703548800,
  "revoked": [
    {
      "itemId": "TRACK-2025-000123",
      "revoked": 1703548900,
      "reason": "lost"
    }
  ],
  "signature": "base64_signature"
}
]]></sourcecode>
      </section>
    </section>

    <!-- Appendix B: Implementation Guidelines -->
    <section anchor="implementation-guidelines" numbered="true" toc="include">
      <name>Implementation Guidelines</name>

      <section anchor="qr-code-generation">
        <name>QR Code Generation</name>
        <t>Recommended settings:</t>
        <ul>
          <li>Error correction level M (15%) for standard labels</li>
          <li>Error correction level Q (25%) for split-key labels</li>
          <li>Error correction level H (30%) for outdoor use</li>
          <li>Automatic version selection</li>
          <li>Binary encoding mode</li>
        </ul>
      </section>

      <section anchor="performance-benchmarks">
        <name>Performance Benchmarks</name>
        <t>Expected operation times:</t>
        <ul>
          <li>Key generation: 5-10 ms</li>
          <li>Signature creation: 2-5 ms</li>
          <li>DNS lookup: 20-100 ms (cacheable)</li>
          <li>Signature verification: 3-8 ms</li>
          <li>ECIES encryption: 10-20 ms</li>
          <li>ECIES decryption: 10-20 ms</li>
        </ul>
      </section>

      <section anchor="caching-strategy">
        <name>Caching Strategy</name>

        <section anchor="dns-key-record-caching">
          <name>DNS Key Record Caching</name>
          <t>Key records follow standard DNS caching semantics:</t>
          <ul>
            <li>Cache based on DNS TTL (recommended: 3600-86400 seconds)</li>
            <li>Minimum recommended TTL: 300 seconds (5 minutes)</li>
            <li>Maximum recommended TTL: 86400 seconds (24 hours)</li>
            <li>Implement negative caching for failed lookups</li>
            <li>Honor emergency flush requests via TTL=0</li>
          </ul>
        </section>

        <section anchor="revocation-list-caching">
          <name>Revocation List Caching</name>
          <t>Revocation lists require stricter freshness controls:</t>
          <ul>
            <li>Respect max-age field in revocation records</li>
            <li>Recommended refresh interval: 5-15 minutes for active verification</li>
            <li>MUST NOT serve revocation data older than max-age</li>
            <li>Use bloom filters for privacy when appropriate</li>
          </ul>
        </section>

        <section anchor="organizational-caching-architecture">
          <name>Organizational Caching Architecture</name>
          <t>Large-scale logistics operations (thousands of daily verifications) SHOULD implement centralized caching infrastructure:</t>
          <t>Recommended architecture:</t>
          <artwork><![CDATA[
(Scanning Devices) --> (Regional Cache) --> (Central Cache) --> (DNS)
                            |
                            v
                    (Revocation Service)
]]></artwork>
          <t>Tier 1 - Device Level:</t>
          <ul>
            <li>Hot cache for current shift's frequent senders</li>
            <li>TTL: 5-15 minutes</li>
            <li>Capacity: 100-500 most recent key locators</li>
          </ul>
          <t>Tier 2 - Regional/Facility Level:</t>
          <ul>
            <li>Serves all devices in a geographic area</li>
            <li>TTL: 1-4 hours</li>
            <li>Maintains revocation list copies</li>
          </ul>
          <t>Tier 3 - Central/Organization Level:</t>
          <ul>
            <li>Single point of external DNS queries</li>
            <li>TTL: Full DNS TTL</li>
            <li>Authoritative cache for the organization</li>
          </ul>
          <t>Benefits:</t>
          <ul>
            <li>Dramatic reduction in external DNS queries (95%+ reduction)</li>
            <li>Predictable DNS load on signing domains</li>
            <li>Offline resilience when network connectivity is interrupted</li>
            <li>Centralized revocation monitoring and push updates</li>
          </ul>
        </section>

        <section anchor="offline-operation">
          <name>Offline Operation</name>
          <t>Devices MAY operate offline with cached data:</t>
          <table>
            <thead>
              <tr>
                <th>Cache Age</th>
                <th>Verification Behavior</th>
              </tr>
            </thead>
            <tbody>
              <tr>
                <td>&lt; TTL</td>
                <td>Normal verification, full trust</td>
              </tr>
              <tr>
                <td>TTL to 4 hours</td>
                <td>Verify with CACHE_STALE warning flag</td>
              </tr>
              <tr>
                <td>4-24 hours</td>
                <td>Verify with OFFLINE_MODE warning flag</td>
              </tr>
              <tr>
                <td>&gt; 24 hours</td>
                <td>Fail verification, queue for re-check</td>
              </tr>
            </tbody>
          </table>
          <t>Organizations SHOULD define acceptable staleness thresholds based on their security requirements and operational constraints.</t>
          <t>Note: Revocation checks MUST use fresh data when network is available. Offline verification without revocation checks SHOULD be flagged.</t>
        </section>

        <section anchor="directory-services-caching">
          <name>Directory Services Caching</name>
          <t>Directory service responses (provider lists, coverage data):</t>
          <ul>
            <li>Cache provider lists by region</li>
            <li>Update daily or on configuration change</li>
            <li>Implement failover mechanisms for service outages</li>
          </ul>
        </section>
      </section>
    </section>

    <!-- Appendix C: Use Case Examples -->
    <section anchor="use-case-examples" numbered="true" toc="include">
      <name>Use Case Examples</name>

      <section anchor="ecommerce-privacy">
        <name>E-commerce Order with Privacy</name>
        <t>Customer checkout flow with privacy-preserving delivery:</t>
        <ol>
          <li>Customer enters address, selects preferred carrier</li>
          <li>System retrieves carrier's public key, encrypts recipient</li>
          <li>Label shows only carrier destination</li>
          <li>Carrier decrypts at delivery, completes with proof</li>
        </ol>
      </section>

      <section anchor="high-value-anticloning">
        <name>High-Value Package with Anti-Cloning</name>
        <t>Split-key label flow for valuable items:</t>
        <ol>
          <li>Sender scratches Zone A, signs package, destroys private key</li>
          <li>Package transits with unverifiable signature (cloning prevented)</li>
          <li>Recipient scratches Zone B, reveals public key, verifies</li>
        </ol>
      </section>

      <section anchor="corporate-mailroom">
        <name>Corporate Mailroom Delivery</name>
        <t>Internal routing with organizational keys:</t>
        <ol>
          <li>Employee selects corporate mailroom as destination</li>
          <li>System encrypts internal routing (dept, room number)</li>
          <li>Mailroom decrypts and routes internally</li>
        </ol>
      </section>

      <section anchor="international-shipping">
        <name>International Shipping</name>
        <t>Cross-border delivery with customs compliance:</t>
        <ol>
          <li>Customs info public, recipient encrypted</li>
          <li>Customs verifies declarations, cannot see recipient</li>
          <li>Local provider decrypts and completes delivery</li>
        </ol>
      </section>
    </section>
  </back>
</rfc>
