Cryptographic Operations
Key management, encryption, signatures, and zero-knowledge proofs
01
Overview
YieldFabric provides comprehensive cryptographic infrastructure:
Zero-Knowledge Privacy
Confidential transactions using ZK-proof technology
Secure Key Management
Asymmetric cryptography with secure keystore
Digital Signatures
Cryptographic verification for high-security operations
Encryption/Decryption
Data protection using public/private key pairs
02
Key Management
Generate User Keypair
curl -X POST https://auth.yieldfabric.com/api/v1/crypto/keypairs \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{
"entity_type": "user",
"entity_id": "user_abc123"
}'Generate Group Keypair
curl -X POST https://auth.yieldfabric.com/api/v1/crypto/keypairs \
-H "Authorization: Bearer $DELEGATION_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"entity_type": "group",
"entity_id": "group_xyz789"
}'List Keypairs
curl -X GET https://auth.yieldfabric.com/api/v1/crypto/keypairs \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{
"entity_type": "user",
"entity_id": "user_abc123"
}'03
Encryption and Decryption
Encrypt Data
Encrypt sensitive data using a public key:
curl -X POST https://auth.yieldfabric.com/api/v1/crypto/encrypt \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{
"data": "Confidential business data",
"public_key": "04a1b2c3d4e5f6789..."
}'Decrypt Data
curl -X POST https://auth.yieldfabric.com/api/v1/crypto/decrypt \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{
"encrypted_data": "eyJhbGciOiJIUzI1NiIs...",
"entity_type": "user",
"entity_id": "user_abc123"
}'04
Digital Signatures
Sign Data
curl -X POST https://auth.yieldfabric.com/api/v1/crypto/sign \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{
"data": "Contract terms to sign",
"entity_type": "user",
"entity_id": "user_abc123"
}'Verify Signature
curl -X POST https://auth.yieldfabric.com/api/v1/crypto/verify \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{
"data": "Contract terms to sign",
"signature": "3045022100a1b2c3d4...",
"public_key": "04a1b2c3d4e5f6789..."
}'05
Zero-Knowledge Proofs
YieldFabric uses zero-knowledge proofs for confidential transactions:
Balance Proofs
Prove balance without revealing amount
Range Proofs
Prove value is within range
Equality Proofs
Prove two values are equal
Membership Proofs
Prove value is in set
Privacy Features
- Confidential transaction amounts - Hidden from public view
- Hidden account balances - Privacy-preserving queries
- Private payment flows - Encrypted transaction details
- Anonymous transaction verification - Verify without revealing identity
06
Security Best Practices
Key Management
- Regular key rotation
- Use hardware security modules when possible
- Limit key access to authorized users
- Log all cryptographic operations
Encryption Guidelines
- Generate keys with sufficient entropy
- Use secure key exchange protocols
- Encrypt sensitive data appropriately
- Keep cryptographic libraries updated
Signature Security
- Use unique nonces for each signature
- Include timestamps in signed data
- Verify public keys before use
- Always verify signatures before processing