- Kotlin 99.9%
| Filename | Latest commit message | Latest commit date |
|---|---|---|
Updated terminology from 'Public Beta Trust Infrastructure' to 'Sandbox Trust Infrastructure' and refined project descriptions for clarity. |
||
| .resources | ||
| backup | ||
| build-logic | ||
| config/detekt | ||
| consistency | ||
| dcql | ||
| gradle | ||
| library | ||
| password-strength-estimator | ||
| proximity | ||
| .gitignore | ||
| build.gradle.kts | ||
| CONTRIBUTING.md | ||
| gradle.properties | ||
| gradlew | ||
| gradlew.bat | ||
| LICENSE | ||
| publiccode.yml | ||
| README.md | ||
| SECURITY.md | ||
| settings.gradle.kts | ||
swiyu - shared KMP libraries
An official Swiss Government project made by the Federal Office of Information Technology, Systems and Telecommunication FOITT as part of the electronic identity (e-ID) project.
Table of Contents
Overview
This repository is part of the swiyu ecosystem developed for the future official Swiss E-ID. It provides the shared Kotlin Multiplatform (KMP) libraries consumed by the swiyu Wallet on both iOS and Android, offering a single, versioned home for the shared code and a stable API surface for the platform clients.
The goal of this repository is to engage with the community and collaborate on developing the Swiss ecosystem for e-ID and other credentials. We warmly encourage you to engage with us by creating an issue in the repository.
For more information about the project please refer to the technical documentation. There you find an overview of all components, specifications, and standards of the swiyu Trust Infrastructure. You can find further community-related content in the Open Source Community repository.
Modules
The repository is a Gradle multi-module project containing the following Kotlin Multiplatform modules (no app UI or platform-specific app code):
dcql: DCQL (Digital Credentials Query Language) support — query matching, credential models and helpers built on top of the Kapun SDK DCQL libraries.proximity: Proximity presentation support for in-person / offline credential presentation, exposing the Kapun SDK proximity APIs.consistency: Check consistency between SD-JWTspassword-strength-estimator: Wrapper around zxcvbn to indicate strength of a password stringbackup: Export and import of Verifiable Credentials in Wallet Backup Containerslibrary: Umbrella module that exports the shared APIs and builds theBITSwiyuSharedKMPXCFramework for iOS.
Supported targets: android, iosArm64, iosSimulatorArm64 and jvm (used to run the tests).
Installation and building
The project targets Android and iOS. The iOS artifacts currently target at least iOS 16.0. The CI build uses Java 21.
In your terminal, after having cloned the current repository, run the following command:
./gradlew build
The command verifies that all modules compile and runs the configured tests.
iOS XCFramework
To build the iOS XCFramework, run:
./gradlew :library:assembleBITSwiyuSharedKMPXCFramework
For release packaging, the repository's CI runs:
./gradlew :library:assembleBITSwiyuSharedKMPReleaseXCFramework -PreleaseBuild=true -PforceBuildNativeLibs=true
The generated XCFramework can then be found under library/build/XCFrameworks/.
Android AARs
To build the Android AAR for a module, run:
./gradlew :<module>:assembleAndroidMain
The generated AAR for the module can then be found under <module>/build/outputs/aar/.
Consuming the libraries
Android
The release AARs for all Android modules are attached to each GitHub release as BITSwiyuSharedKMP-android-aars.zip.
Each Android module is published in Maven Central under the namespace ch.admin.swiyu.mobile.
dependencies {
implementation("ch.admin.swiyu.mobile:<module>-android:<version>")
}
iOS
For iOS, the library module produces the BITSwiyuSharedKMP XCFramework, which re-exports the shared APIs. The XCFramework is attached to each GitHub release as BITSwiyuSharedKMP.xcframework.zip and can be integrated into an Xcode project like any other binary framework.
Missing Features and Known Issues
The swiyu Sandbox Trust Infrastructure was deliberately released at an early stage to enable future ecosystem participants. The feature roadmap shows the current discrepancies between the Sandbox and the targeted productive Trust Infrastructure. There may still be minor bugs or security vulnerabilities in the test system. Repository-specific issues are tracked in the issue tracker.
Contributions and feedback
The code for this repository is developed privately and will be released after each sprint. The published code can therefore only be a snapshot of the current development and not a thoroughly tested version. However, we welcome any feedback on the code regarding both the implementation and security aspects. Please follow the guidelines for contributing found in CONTRIBUTING.md.
License
This project is licensed under the terms of the MIT license. See the LICENSE file for details.
