taler-www

Main taler.net website
Log | Files | Refs | Submodules | README | LICENSE

2025-11.html.j2 (15011B)


      1 {% extends "common/news.j2" %}
      2 {% block body_content %}
      3 <h1>2025-10: Onboarding the Swiyu Trust Infrastructure as a Verifier</h1>
      4 
      5 <p>
      6 We are pleased to announce the availability of comprehensive documentation for integrating GNU Taler with the Swiyu trust infrastructure for digital identity verification. This integration will enable GNU Taler exchanges to perform Know Your Customer (KYC) processes using Switzerland's digital identity infrastructure, particularly relevant for regulatory compliance in Swiss financial services.
      7 </p>
      8 
      9 <p>
     10 This guide enables developers to onboard as credential verifiers in the Swiss digital identity ecosystem, enabling the verification of user identity attributes from Swiyu eID credentials.
     11 </p>
     12 
     13 <h2 id="about-swiyu">About Swiyu</h2>
     14 
     15 <p>
     16 <a href="https://swiyu-admin-ch.github.io/">Swiyu</a> is Switzerland's decentralized trust infrastructure for digital identity management. Swiyu is currently in public beta, allowing organizations to act as credential issuers or verifiers. The <a href="https://github.com/swiyu-admin-ch/swiyu-verifier">Generic Verifier</a> component enables registered third-party entities to request and verify identity attributes from Swiyu eID credentials.
     17 </p>
     18 
     19 <p>
     20 <strong>Important:</strong> Swiyu is in Public Beta and is provided on a best-effort basis. The system will continue to evolve over time.
     21 </p>
     22 
     23 <h2 id="architecture">System Architecture and Components</h2>
     24 
     25 <p>
     26 The Swiyu ecosystem consists of several key components that work together to enable secure digital identity verification:
     27 </p>
     28 
     29 <h3>Core Components</h3>
     30 
     31 <ul>
     32 <li><strong>Swiyu Base Registry:</strong> The foundational decentralized identifier (DID) registry that stores and manages DIDs for all participants in the ecosystem. This is where organizations register their identity and cryptographic keys.</li>
     33 <li><strong>Swiyu Wallet:</strong> Mobile application held by end users that stores their verifiable credentials (eID). The Swiyu wallet communicates with verifiers to present identity attributes upon request.</li>
     34 <li><strong>Issuers:</strong> Trusted entities (such as government agencies) that issue verifiable credentials to users' Swiyu wallets after identity verification.</li>
     35 <li><strong>Verifiers:</strong> Services operated by organizations that request and verify identity attributes from user Swiyu wallets.</li>
     36 <li><strong>DID Toolbox:</strong> A command-line tool for generating cryptographic keys and DID documents required for onboarding to the Base Registry.</li>
     37 </ul>
     38 
     39 <h3>How Components Interact</h3>
     40 
     41 <p>
     42 The verification flow works as follows:
     43 </p>
     44 
     45 <ol>
     46 <li>A <strong>Verifier Service</strong> creates a verification request specifying which identity attributes are needed (e.g., date of birth, name)</li>
     47 <li>The request is presented to the user's <strong>Swiyu wallet</strong> (typically via QR code)</li>
     48 <li>The <strong>Swiyu wallet</strong> displays which attributes are being requested and asks for user consent</li>
     49 <li>Upon consent, the <strong>Swiyu wallet</strong> presents the requested attributes from the user's credentials to the <strong>Verifier Service</strong></li>
     50 <li>The <strong>Verifier Service</strong> validates the credentials by checking signatures against the <strong>Base Registry</strong> and verifying the issuer is trusted</li>
     51 <li>The verified attributes are made available to the requesting business system (e.g., a Taler exchange's KYC module)</li>
     52 </ol>
     53 
     54 <p>
     55 All participants (issuers and verifiers) must register their DIDs in the <strong>Base Registry</strong> to participate in the trust infrastructure. The registry ensures that all cryptographic keys can be discovered and verified by other participants.
     56 </p>
     57 
     58 <h2 id="prerequisites">Prerequisites</h2>
     59 
     60 <p>Before deploying a <a href="https://github.com/swiyu-admin-ch/swiyu-verifier">generic verifier</a> in the beta, you must first onboard to the Swiyu Base Registry. Ensure you have:</p>
     61 
     62 <ul>
     63 <li>An AGOV or CH-Login account for accessing the ePortal</li>
     64 <li>Java Runtime Environment (JRE) 21 or higher installed</li>
     65 <li>Sufficient disk space (approximately 100 MB)</li>
     66 <li>Internet connection</li>
     67 <li>Operating system: Linux x64/AArch64, macOS (AArch64), or Windows (x64)</li>
     68 </ul>
     69 
     70 <h2 id="onboarding-process">Onboarding Process</h2>
     71 
     72 <p>The onboarding process consists of the following steps:</p>
     73 
     74 <ol>
     75 <li>Sign-in or sign-up to the Swiss Confederacy ePortal</li>
     76 <li>Register as Business Partner</li>
     77 <li>Get API keys from the self-service portal</li>
     78 <li>Allocate DID space on the Swiyu Base Registry</li>
     79 <li>Generate cryptographic keys and DID log using the Swiyu DID Toolbox</li>
     80 <li>Create and upload the DID log</li>
     81 <li>(Optional) Become a trusted participant</li>
     82 </ol>
     83 
     84 <p>
     85 The official Swiyu technical documentation offers detailed guides—cookbooks—that guide you through this process in a detailed manner. Follow <a href="https://swiyu-admin-ch.github.io/cookbooks/onboarding-generic-verifier/">this</a> cookbook to complete the necessary steps to onboard the Swiyu Base Registry before continuing.
     86 </p>
     87 
     88 <h2 id="configuring-the-swiyu-generic-verifier">Configuring the Swiyu Generic Verifier</h2>
     89 
     90 <p>
     91 With the Base Registry onboarding process complete, it is necessary to configure the <a href="https://github.com/swiyu-admin-ch/swiyu-verifier">Swiyu Generic Verifier</a> with the generated keys and DID obtained in the Base Registry Onboarding <a href="https://swiyu-admin-ch.github.io/cookbooks/onboarding-base-and-trust-registry/">cookbook</a>.
     92 </p>
     93 
     94 <h3>Locate the Configuration File</h3>
     95 
     96 <p>
     97 The Generic Verifier uses a YAML configuration file, located in <tt>/swiyu-verifier/verifier-application/src/main/resources/application.yml</tt>.
     98 </p>
     99 
    100 <h3>Understanding the Required Configuration Parameters</h3>
    101 
    102 <p>
    103 The configuration parameters are obtained from files generated during the Base Registry onboarding process. When you run the <a href="https://swiyu-admin-ch.github.io/cookbooks/onboarding-base-and-trust-registry/#quickstart--create-your-first-did">DID Toolbox</a> during onboarding, it creates a <tt>.didtoolbox</tt> directory containing the necessary files:
    104 </p>
    105 
    106 <ul>
    107 <li><strong>DID Log location:</strong> The DID log is generated by the DID Toolbox and saved as a JSONL (JSON Lines) file in the <tt>.didtoolbox</tt> directory. This file contains your DID and public key references in the format specified by the <a href="https://swiyu-admin-ch.github.io/cookbooks/onboarding-base-and-trust-registry/#quickstart--create-your-first-did">DID creation cookbook</a>.</li>
    108 <li><strong>Private keys location:</strong> Private keys are stored in separate PEM files within the <tt>.didtoolbox</tt> directory with names corresponding to their purpose (e.g., <tt>auth-key-01</tt>, <tt>agree-key-01</tt>, etc.).</li>
    109 </ul>
    110 
    111 <p>
    112 Extract the following parameters from these files for your Generic Verifier configuration:
    113 </p>
    114 
    115 <ul>
    116 <li><strong>client_id:</strong> Your DID identifier found in the <tt>value.id</tt> field of the DID log JSONL file. This is a unique identifier in the format <tt>did:tdw:&lt;hash&gt;:&lt;registry-domain&gt;:api:v1:did:&lt;uuid&gt;</tt></li>
    117 <li><strong>signing-key-verification-method:</strong> Your DID with the authentication key fragment appended. Found in the <tt>value.assertionMethod</tt> array in the DID log. The format is: <tt>&lt;your-did&gt;#auth-key-01</tt>. This specifies which key in your DID document is used for signing authorization requests.</li>
    118 <li><strong>signing-key:</strong> The private EC256 (Elliptic Curve P-256) authentication key from the file <tt>.didtoolbox/auth-key-01</tt>. This is a PEM-encoded private key used to sign requests sent to the Swiyu wallet. Copy the entire content including the <tt>-----BEGIN EC PRIVATE KEY-----</tt> and <tt>-----END EC PRIVATE KEY-----</tt> markers.</li>
    119 </ul>
    120 
    121 <h3>Example Configuration</h3>
    122 
    123 <p>
    124 Create your configuration profile by copying the template from the local deployment YAML in the repository (<tt>application-local.yml</tt>). After replacing with your specific values, the <tt>application.yaml</tt> configuration will look similar to this:
    125 </p>
    126 
    127 <pre><code>application:
    128   signing-key: |
    129     -----BEGIN EC PRIVATE KEY-----
    130     MHcCAQEEIABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstu
    131     oAoGCCqGSM49AwEHoUQDQgAE5cice+6ILYCD2gFEVFMLPt3HPf5n/Oef
    132     zOOoP+3SLDAlh/YkKQvF/1xv0uYuvy1t6wpDM7au1dMEg2L1I9wDxE==
    133     -----END EC PRIVATE KEY-----
    134   signing-key-verification-method: "did:tdw:
    135     Qmd9bwsodZ1GAz4h8D7Vy6qRio78voXifDrnXokSTsMVQK:
    136     identifier-reg.trust-infra.swiyu-int.admin.ch:api:v1:
    137     did:18fa7c77-9dd1-4e20-a147-fb1bec146085#auth-key-01"
    138   external-url: "https://yourdomain.com"
    139   client_id: "did:tdw:
    140     Qmd9bwsodZ1GAz4h8D7Vy6qRio78voXifDrnXokSTsMVQK:
    141     identifier-reg.trust-infra.swiyu-int.admin.ch:api:v1:
    142     did:18fa7c77-9dd1-4e20-a147-fb1bec146085"
    143   client_id_scheme: "did"
    144   client-metadata-file: "classpath:/client_metadata.json"
    145 </code></pre>
    146 
    147 <p>
    148 To make sure the Generic Verifier uses your configuration, specify your <tt>.yaml</tt> run profile when booting the server:
    149 </p>
    150 
    151 <pre><code>./mvnw spring-boot:run -pl verifier-application -Dspring-boot.run.profiles=application
    152 </code></pre>
    153 
    154 <p>Where 'application' is the name of your configuration <tt>.yaml</tt> file.</p>
    155 
    156 <h2 id="https-configuration">HTTPS/TLS Configuration</h2>
    157 
    158 <p>
    159 <strong>Important:</strong> The Swiyu wallet only accepts HTTPS connections. Ensure your verifier is accessible via HTTPS with a valid TLS/SSL certificate from a trusted Certificate Authority.
    160 </p>
    161 
    162 <h2 id="testing">Testing Your Verifier Setup</h2>
    163 
    164 <p>
    165 Once your verifier is configured and running, you should test the complete verification flow to ensure everything works correctly. This section guides you through obtaining a test wallet, getting test credentials, and performing a verification.
    166 </p>
    167 
    168 <h3>1. Get the Swiyu Wallet</h3>
    169 
    170 <p>
    171 Download the Swiyu BetaID wallet application for your mobile device (iOS or Android). Links can be found under 'Information for private individuals' <a href="https://www.eid.admin.ch/en/public-beta-e">here</a>.
    172 </p>
    173 
    174 <p>
    175 Install the app and complete the initial setup by setting your password and optionally setting a biometric login with your fingerprint. Since Swiyu is in public beta, you will need to obtain a BetaID credential directly:
    176 </p>
    177 
    178 <ol>
    179 <li>Follow the link displayed after the initial setup to the Beta-ID <a href="https://www.bcs.admin.ch/bcs-web/#/">website</a></li>
    180 <li>Request</a> a Beta-ID</a>
    181 <li>Choose a Beta-ID from a template (Helvetia or Marco), optionally upload a ID picture</li>
    182 <li>Click the 'Request the issuing of a Beta-ID' button and then the 'Add to wallet' button</li>
    183 <li>Once back in the Swiyu wallet app, click on 'Add' to add the Beta-ID to your wallet</li>
    184 </ol>
    185 Congratulations! Your unique Beta-ID is now on your wallet (and nowhere else!).
    186 
    187 <h3>2. Create a Verification Request</h3>
    188 
    189 <p>
    190 With your verifier service running, create a test verification request using the management API. The following example verification request can be performed using <tt>curl</tt> to verify if a user is over 18 years old:
    191 </p>
    192 
    193 <pre><code>curl -X POST https://your-verifier-domain.com/management/api/verifications \
    194   -H "Content-Type: application/json" \
    195   -d '{
    196     "jwt_secured_authorization_request": true,
    197     "response_mode": "direct_post",
    198     "response_type": "vp_token",
    199     "presentation_definition": {
    200       "id": "00000000-0000-0000-0000-000000000000",
    201       "name": "Over 18 Verification",
    202       "purpose": "Verify age is over 18",
    203       "input_descriptors": [
    204         {
    205           "id": "11111111-1111-1111-1111-111111111111",
    206           "format": {
    207             "vc+sd-jwt": {
    208               "sd-jwt_alg_values": ["ES256"],
    209               "kb-jwt_alg_values": ["ES256"]
    210             }
    211           },
    212           "constraints": {
    213             "fields": [
    214               {
    215                 "path": ["$.vct"],
    216                 "filter": {
    217                   "type": "string",
    218                   "const": "betaid-sdjwt"
    219                 }
    220               },
    221               {
    222                 "path": ["$.age_over_18"]
    223               }
    224             ]
    225           }
    226         }
    227       ]
    228     },
    229     "configuration_override": {}
    230   }'
    231 </code></pre>
    232 
    233 <p>
    234 This request asks the Swiyu wallet to provide proof that the user is over 18 years old from their BetaID credential.
    235 </p>
    236 
    237 <h3>3. Generate and Scan QR Code</h3>
    238 
    239 <p>
    240 The verification request response will contain a verification ID. You need to convert the request URL in the response to a QR code for the Swiyu wallet to scan. The request URL format is:
    241 </p>
    242 
    243 <pre><code>https://your-verifier-domain.com/oid4vp/api/request-object/&lt;verificationId&gt;</code></pre>
    244 
    245 <p>
    246 For example, if your verification ID is <tt>abc123def456</tt>, the URL would be:
    247 </p>
    248 
    249 <pre><code>https://your-verifier-domain.com/oid4vp/api/request-object/abc123def456</code></pre>
    250 
    251 <p>
    252 Convert this URL to a QR code using for example <a href="https://fukuchi.org/en/works/qrencode/">qrencode</a> (a CLI QR code generation tool available in most package managers):
    253 
    254 </p>
    255 
    256 <ol>
    257 <li>Install qrencode if not already available:
    258 <pre><code># macOS, requires homebrew
    259 brew install qrencode
    260 
    261 # Ubuntu/Debian
    262 sudo apt-get install qrencode</code></pre>
    263 </li>
    264 <li>Generate a QR code PNG from your the terminal:
    265 <pre><code>qrencode -o verification-qr.png "https://your-verifier-domain.com/oid4vp/api/request-object/abc123def456"</code></pre>
    266 </li>
    267 <li>Open your Swiyu wallet app and scan the generated QR code</li>
    268 </ol>
    269 
    270 <h3>4. Complete the Verification</h3>
    271 
    272 <p>
    273 After scanning the QR code:
    274 </p>
    275 
    276 <ol>
    277 <li>The Swiyu wallet will display which attributes are being requested</li>
    278 <li>Review the request and tap to approve sharing the requested attributes</li>
    279 <li>The Swiyu wallet sends the selected Beta-ID attributes to your verifier service</li>
    280 </ol>
    281 
    282 <h3>5. Check Verification Results</h3>
    283 
    284 <p>
    285 Query your verifier's management API to retrieve the verification results:
    286 </p>
    287 
    288 <pre><code>curl https://your-verifier-domain.com/management/api/verifications/&lt;verificationId&gt;
    289 </code></pre>
    290 
    291 <p>
    292 A successful verification will show a status indicating completion, along with the verified attributes that were presented by the Swiyu wallet.
    293 </p>
    294 
    295 <h3>Troubleshooting</h3>
    296 
    297 <p>Here are some common errors you might encounter during the configuration of the generic verifier and during QR code generation and scanning:</p>
    298 
    299 <ul>
    300 <li><strong>Swiyu wallet cannot connect:</strong> Ensure your verifier is accessible via HTTPS with a valid certificate</li>
    301 <li><strong>Verification fails:</strong>The format of the signing key in the .yaml configuration of your Verifier must be exactly as specified in the example configuration file and cannot contain literal <tt>\n</tt> escape sequences or extra quotation marks (<tt>"</tt>). The signing key field should use YAML's multiline string format with the pipe (<tt>|</tt>) operator.</li>
    302 </ul>
    303 
    304 {% endblock body_content %}