- π― What is SSI
- π Key Concepts
- β¨ Benefits
- π Trust Triangle
- π‘ How SSI Works
- βοΈ Technical Workflow
- π Demonstration Setup Guide
- π API Overview
- π Conclusion
- π§ Contact
π« Self-Sovereign Identity (SSI) is a digital identity model that allows individuals to own, control, and share their personal information without relying on a central authority. In SSI, users can create and manage their identities using decentralized technologies, such as blockchain, which enhances privacy, security, and user autonomy.
Concept | Traditional Way | SSI Way | Benefits |
---|---|---|---|
π― Decentralization "You're in Control" |
Need Facebook/Google accounts to log into websites. Companies control your digital identity. | You control your own digital identity, like your physical wallet. | β’ No dependency on companies β’ Full control over your identity β’ Single identity for all services |
π Verifiable Credentials "Digital Certificates" |
Physical certificates and ID cards in your wallet. | Digital versions of certificates that can't be forged. | β’ Can't be faked or altered β’ Instant sharing β’ Selective disclosure β’ Digital signatures from issuers |
π DIDs "Your Digital Identity Number" |
Email address or phone number owned by companies. | Your own unique digital ID that belongs only to you. | β’ You own it completely β’ Not controlled by companies β’ Can't be taken away β’ Permanent digital address |
πΌ Wallets "Your Digital Identity Vault" |
Physical wallet with ID cards, certificates, and licenses. | Secure app storing digital credentials. | β’ Digital storage of IDs β’ Enhanced security β’ Selective sharing β’ User control |
π€ Trust triangle "The Circle of Trust" |
Trust based on physical documents issued by authorities. | Digital credentials verified instantly through cryptography. | β’ Instant verification β’ Cryptographically secure β’ No need to contact issuer β’ Selective information sharing |
π Physical Documents | π± Digital SSI |
---|---|
Can be lost or stolen | Securely backed up |
Show all information | Share only what's needed |
Manual verification needed | Instant verification |
Multiple documents to carry | All-in-one digital solution |
Can be forged | Cryptographically secure |
Physical presence often required | Remote verification possible |
π€ The Trust Triangle is a foundational concept in Self-Sovereign Identity that illustrates the relationships between the three key parties involved in identity verification:
- ποΈ The Issuer
The trusted authority that issues verifiable credentials to the holder. This could be an educational institution, government agency, or any organization that can validate the information.
- π€ The Holder
The individual or entity that owns the identity and holds the credentials. They have full control over their personal information and can choose what to share.
- β
The Verifier
The party that needs to verify the holder's credentials. This could be a service provider, employer, or any entity that requires proof of identity or qualifications.
π« Key Insight: The Trust Triangle emphasizes that trust is established through the relationships between these three parties, allowing for secure and private interactions without the need for a central authority.
- Creates official digital documents (like a digital version of your degree)
- Ensures each document follows a standard format
- Adds their official digital signature
- Makes sure their documents can be verified by others
Just like a university issues paper degrees, in SSI they:
- Create digital degrees that can't be forged
- Include all necessary information (grades, date, major)
- Sign it digitally (like a traditional university seal)
- Have a digital wallet on your phone (like Apple Wallet, but for your ID documents)
- Receive official documents from organizations
- Store them securely in your digital wallet
- Share only what you want, when you want
Just like your physical wallet, but better:
- Store your university degree, driver's license, and certificates digitally
- Choose what to share (show age without revealing address)
- No risk of losing physical documents
- Ask for specific information they need
- Verify your digital documents instantly
- Trust the documents without calling the issuer
- Only see what you choose to share
When applying for a job:
- Employer asks for proof of degree
- You share just the relevant details from your digital degree
- They can verify it's real instantly
- No need to call the university to check
-
π DID Creation and Registration
- Issuer creates and registers institutional DID on ledger
- Holder creates personal DID for identity management
- Verifier establishes organizational DID for verification purposes
-
π Schema Registration (by Issuer)
- A schema defines the structure of the credentials that can be issued. It includes attributes such as name, version, and the specific data fields that will be included in the credential.
- Issuer registers schema on the ledger
- Example attributes:
name
,date
,degree_type
,institution
-
π Credential Definition Setup (by Issuer)
- A credential definition links a schema to a specific credential type and includes additional metadata, such as the issuer's DID and the credential's unique identifier. This allows for the creation of verifiable credentials based on the registered schema.
- Issuer publishes credential definition to ledger.
-
Connection Establishment
- Issuer and holder create secure DID connection
- Exchange connection protocols
- Establish encrypted channel
-
Credential Creation
- Issuer prepares credential data
- Maps data to schema structure
- Generates cryptographic signatures
- Issues credential to holder's wallet
-
Holder's Wallet
- Securely stores received credentials
- Maintains proof requests history
- Handles key management
-
Proof Request
- Verifier sends proof request
- Specifies required attributes
- Defines predicates (if any)
-
Proof Generation
- Holder receives proof request
- Selects appropriate credentials
- Generates zero-knowledge proofs
- Creates proof presentation
-
Verification Process
- Verifier receives proof presentation
- Validates cryptographic signatures
- Checks revocation status
- Verifies credential claims
We will use two different frameworks (Credo and ACAPY) to demonstrate the SSI workflow. Use any one of them.
- Language: Python
- Focus: Enterprise-grade SSI solutions
- Key Features:
- Robust credential management
- Advanced protocol support
- Extensive configuration options
- Two API versions (v1 and v2)
- Detailed Setup Guide
- Language: JavaScript/TypeScript
- Focus: Modern web and mobile SSI solutions
- Key Features:
- Easy web integration
- Mobile-friendly
- Modern JavaScript ecosystem
- Detailed Setup Guide
-
Core Functionality
- DID management
- Credential issuance
- Proof verification
- Connection protocols
-
Standards Compliance
- W3C DID specifications
- Verifiable Credentials
- DIDComm protocols
-
Security Features
- Secure messaging
- Encryption standards
- Key management
Feature | ACApy | Credo |
---|---|---|
Language | Python | JavaScript |
API Versions | v1 and v2 | Single version |
Setup Complexity | More complex | Simpler |
Target Use | Enterprise | Web/Mobile |
-
Connection Issues
- Ensure ngrok is running and URL is correctly set
- Check if ports are not in use
- Verify network connectivity
-
Wallet Errors
- Clear previous wallet data if exists
- Check permissions and storage
-
Ledger Connection
- Verify genesis URL is accessible
- Check network connectivity
- Generate invitation from issuer interface
- Scan the generated QR code by Bifold wallet (Holder's wallet)
- Issuer will send a credential offer to your connected wallet (Bifold wallet)
- Open the credential offer and accept credential from the wallet
- An issuer also can act as a verifier. Because sometimes issuer needs to verify your issued credential.
- In this setup, issuer will send you a credential proof request after credential issuance.
- Share your credential in the proof request.
Or, if you want to use different verifier:
- Generate invitation from verifier agent
- Scan the generated QR code by Bifold wallet (Holder's wallet)
- Send proof request to the holder
- Share proof from the Bifold wallet
- Verify received proof
For better view: Youtube link
This API provides endpoints for managing agents, credentials, and interactions in an SSI ecosystem. Below are the key routes defined in server.ts
.
ACAPY provides two API versions (v1 and v2) with different features and capabilities.
The legacy API version, still widely used and supported. (Will be removed in the upcoming acapy versions)
# Base URL format
http://localhost:{port}/v1/
The newer API version with enhanced features and improved consistency.
# Base URL format
http://localhost:{port}/v2/
β¨ SSI Feature | π Purpose | π API Endpoint |
---|---|---|
π Get Wallet DIDs | Retrieve the DIDs associated with the user's wallet. | GET /wallet-dids |
π Register Schema | Create a new schema for credentials. | POST /create-schema |
π Register Credential Definition | Create a new credential definition based on a schema. | POST /credential-definition |
π οΈ Create Connection Invitation | Create an invitation for a connection. | POST /create-invitation |
π Get All Connections | Retrieve details about existing connections. | GET /connections |
π§ Send Message | Send a message to a connection. | POST /send-message |
π Issue Credential | Issue a new credential to a connection. | POST /issue-credential |
π Get All Issued Credentials | Retrieve details of issued credentials. | GET /issued-credentials |
π Send Proof Request | Send a proof request to a connection. | POST /send-proof-request |
π Get All Proof Records | Retrieve proof records associated with a connection. | GET /proof-records |
π° Retrieve Proof Data | Retrieve proof data for a specific proof record. | GET /proof-data/:proofRecordId |
π Description: Retrieve the DIDs associated with the user's wallet.
π Query Parameters:
method
: The method to use for fetching DIDs.
π₯ Response: Returns a list of DIDs. β
π Description: Create an invitation for a connection.
π Request Body:
label
: A label for the invitation.alias
: An alias for the invitation.domain
: The domain associated with the invitation.
π₯ Response: Returns the invitation details. π¨
π Description: Retrieve connection details.
π Query Parameters:
connectionId
: The ID of the connection.outOfBandId
: The out-of-band ID for the connection.
π₯ Response: Returns connection details. π
π Description: Create a new schema for credentials.
π Request Body:
did
: The DID of the issuer.name
: The name of the schema.version
: The version of the schema.attributes
: An array of attributes for the schema.
π₯ Response: Returns the created schema details. π
π Description: Retrieve schema details.
π Query Parameters:
schemaId
: The ID of the schema to retrieve.
π₯ Response: Returns the schema details. ποΈ
π Description: Create a new credential definition.
π Request Body:
did
: The DID of the issuer.schemaId
: The ID of the schema.tag
: A tag for the credential definition.
π₯ Response: Returns the created credential definition details. π οΈ
π Description: Retrieve credential definition details.
π Query Parameters:
credentialDefinitionId
: The ID of the credential definition.
π₯ Response: Returns the credential definition details. π·οΈ
π Description: Issue a new credential to a connection.
π Request Body:
connectionId
: The ID of the connection.name
: The name of the credential holder.email
: The email of the credential holder.age
: The age of the credential holder.
π₯ Response: Returns the issued credential details. π
π Description: Retrieve issued credentials.
π Query Parameters:
credentialId
: The ID of the credential to retrieve.
π₯ Response: Returns the issued credential details. π
π Description: Send a proof request to a connection.
π Request Body:
proofRequestlabel
: A label for the proof request.connectionId
: The ID of the connection.version
: The version of the proof request.
π₯ Response: Returns the result of the proof request. π
π Description: Retrieve proof records.
π Query Parameters:
proofRecordId
: The ID of the proof record to retrieve.
π₯ Response: Returns the proof record details. π§Ύ
π Description: Retrieve proof data for a specific proof record.
π Path Parameters:
proofRecordId
: The ID of the proof record.
π₯ Response: Returns the proof data. π
π Description: Send a message to a connection.
π Request Body:
connectionId
: The ID of the connection.message
: The message content.
π₯ Response: Returns the result of the message sending. βοΈ
By leveraging the principles of SSI, users can maintain control over their personal information while interacting securely with various services.
For further information, please refer to the documentation of the underlying libraries and technologies used in this implementation.
https://github.com/animo/awesome-self-sovereign-identity
Feel free to contribute to this project! If you have any issues or suggestions, please open an issue. π οΈπ
For questions or support, reach out to Cryptic Consultancy Limited!
- You can mail us through [email protected]
Made with β€οΈ for the SSI community by Cryptic Consultancy Limited (CCL).
CCL is a London-based startup providing research and development conslutancy services on SSI, Federated Identity and Blockchain. We have a strong track record of develivering high quality solutions for challenging problems in the intersection of SSI, Federated Identity and Blockchain.