Shielded vs Public Balances
Understanding Shielded vs Public Balances in Roru
Roru supports two types of balances: shielded balances (private) and public balances (visible on blockchain). Understanding the difference is crucial for using Roru effectively and maintaining your privacy.
Shielded Balances
What Are Shielded Balances?
Shielded balances are private balances stored in Roru's shielded state. They are:
Cryptographically Hidden: Represented as cryptographic commitments, not visible amounts
Private: Only you can see your shielded balances
Unlinkable: Cannot be linked to your identity or other transactions
Multi-Chain: Unified across all supported blockchains
How Shielded Balances Work
When you deposit assets into Roru:
Conversion: Assets are converted into shielded notes
Commitment: Each note is a cryptographic commitment to an amount
State Tree: Notes are stored in the shielded state Merkle tree
Privacy: The actual amount and owner are hidden
Shielded Balance Properties
Privacy:
Amounts are hidden via Pedersen commitments
Senders and receivers are cryptographically hidden
Transaction history is private and encrypted
Cannot be analyzed on public blockchains
Security:
Protected by zero-knowledge proofs
Double-spend prevention via nullifiers
State verified cryptographically
Keys stored securely (hardware with Roru One)
Functionality:
Can send private transfers
Can receive private deposits
Can perform private swaps
Can bridge privately between chains
Public Balances
What Are Public Balances?
Public balances are traditional blockchain balances that are:
Visible on Blockchain: All transactions are public and analyzable
Transparent: Amounts, senders, and receivers are visible
Permanent: Transaction history is permanent and public
Chain-Specific: Separate for each blockchain
When You Have Public Balances
You may have public balances when:
Direct Blockchain Interaction: You interact directly with a blockchain (outside Roru)
Withdrawal to Public Address: You withdraw from Roru to a public address
External Deposits: Someone sends to your public address directly
Legacy Assets: Assets that haven't been converted to shielded
Public Balance Properties
Transparency:
All transactions visible on blockchain
Amounts are public
Addresses are visible
Transaction history is permanent
Analysis:
Can be analyzed with blockchain explorers
Transaction graph analysis possible
Address correlation possible
Timing analysis possible
Functionality:
Standard blockchain functionality
Compatible with all blockchain tools
Works with all DeFi protocols
No privacy protection
Converting Between Shielded and Public
Converting Public to Shielded (Depositing)
When you deposit assets into Roru:
Send to Deposit Address: Send assets to a Roru deposit address
Conversion: Roru converts assets to shielded notes
Shielded Balance: Assets appear in your shielded balance
Privacy: Assets are now private and unlinkable
Process:
Generate a deposit address (one-time use recommended)
Send assets from your public address
Wait for confirmation (varies by chain)
Assets appear in shielded balance
Privacy Note: The deposit transaction itself is public, but once converted to shielded, the assets become private.
Converting Shielded to Public (Withdrawing)
When you withdraw assets from Roru:
Withdrawal Request: Request withdrawal to a public address
Proof Generation: Generate zero-knowledge proof
Settlement: Assets settled on target blockchain
Public Balance: Assets appear in public address
Process:
Enter recipient public address
Specify amount to withdraw
Confirm withdrawal
Wait for settlement (usually fast due to proofs)
Privacy Note: The withdrawal transaction is public, but the source (your shielded balance) remains private.
Balance Display in Wallet
Shielded Balance View
Your wallet displays:
Total Shielded Balance: Sum of all shielded notes
By Asset: Breakdown by cryptocurrency type
By Chain: Breakdown by blockchain (if applicable)
Private History: Encrypted transaction history
Public Balance View
If you have public balances:
Public Balance: Visible on blockchain
Chain-Specific: Separate for each chain
Public History: Visible on blockchain explorer
Warning: Wallet may warn about public balance privacy
Combined View
The wallet can show:
Total Balance: Shielded + Public (if you want)
Separate Views: Option to view separately
Privacy Recommendations: Suggestions to convert public to shielded
Privacy Implications
Shielded Balance Privacy
Full Privacy:
Amounts hidden
Senders/receivers hidden
Transaction history private
Cannot be analyzed
Guarantees:
Mathematical privacy guarantees
Unlinkability by design
Metadata protection
No correlation possible
Public Balance Privacy
No Privacy:
All transactions visible
Amounts visible
Addresses visible
Can be analyzed
Risks:
Transaction graph analysis
Address correlation
Timing analysis
Identity linking
Best Practices
Maximize Shielded Balances
Deposit Promptly: Convert public assets to shielded quickly
Use Shielded Addresses: Always use shielded addresses for receiving
Avoid Public Withdrawals: Minimize withdrawals to public addresses
Private Operations: Use private swaps and bridges
Minimize Public Exposure
One-Time Addresses: Use new addresses for each transaction
Avoid Reuse: Don't reuse public addresses
Time Obfuscation: Don't withdraw immediately after depositing
Amount Obfuscation: Vary withdrawal amounts
Balance Management
Keep Most Assets Shielded: Maintain most assets in shielded form
Public for Necessity: Only use public when necessary
Regular Conversion: Convert public to shielded regularly
Monitor Public: Monitor public balances and convert
Use Cases
When to Use Shielded
Private Payments: Sending/receiving private payments
Privacy-Critical: When privacy is essential
Long-Term Storage: Storing assets privately
Multi-Chain Operations: Unified multi-chain privacy
When Public Might Be Needed
DeFi Interactions: Some DeFi protocols require public addresses
Exchange Deposits: Some exchanges only accept public addresses
Legacy Systems: Interacting with systems that don't support shielded
Temporary: Temporary public balance before conversion
Technical Details
Shielded State Structure
The shielded state is a Merkle tree:
Leaves: Shielded notes (commitments)
Nodes: Hash of child nodes
Root: State root representing entire state
Updates: Efficient updates via Merkle proofs
Commitment Scheme
Shielded balances use Pedersen commitments:
Hiding: Amounts are cryptographically hidden
Binding: Commitments are binding (cannot change amount)
Additive: Commitments can be added (for balance calculations)
Efficient: Efficient to create and verify
Zero-Knowledge Proofs
Every shielded transaction uses zk-SNARKs:
Validity Proof: Proves transaction is valid
Privacy: Reveals no information about amounts or parties
Efficiency: Small proof size, fast verification
Security: Cryptographically secure
Migration Strategy
From Public to Shielded
If you have existing public balances:
Assess: Determine which assets to convert
Deposit: Send assets to Roru deposit address
Convert: Assets automatically convert to shielded
Verify: Verify assets appear in shielded balance
Clean Up: Consider cleaning up old public addresses
Gradual Migration
For large balances:
Start Small: Test with small amounts first
Gradual: Convert gradually over time
Monitor: Monitor conversion process
Complete: Complete migration when comfortable
FAQ
Can I have both shielded and public balances?
Yes, you can have both. The wallet will show them separately, and you can convert between them.
Are shielded balances less secure?
No, shielded balances are actually more secure in terms of privacy. They use the same cryptographic security as public blockchains, plus additional privacy protection.
Can I lose my shielded balance?
No more than you can lose a public balance. Both are protected by your private keys. The main risk is losing your recovery phrase.
How do I know my shielded balance is correct?
The wallet verifies balances using zero-knowledge proofs and Merkle tree verification. You can also verify state roots independently.
Can shielded balances be frozen or seized?
Shielded balances are as resistant to freezing/seizing as the underlying blockchains. The privacy makes it harder to identify balances, but the underlying security depends on the blockchain.
Conclusion
Understanding shielded vs public balances is essential for using Roru effectively:
Shielded: Private, hidden, unlinkable - use for privacy
Public: Transparent, visible, analyzable - use when necessary
Conversion: Easy conversion between the two
Best Practice: Maximize shielded, minimize public
By keeping most of your assets in shielded form, you maximize your privacy while maintaining the flexibility to interact with public blockchains when needed.
Last updated
