Skip to content Skip to footer

What’s Next? Exploring Advanced Capabilities

ECDH (Shared Secrets)

Let’s start with shared secrets using Elliptic-Curve Diffie-Hellman (ECDH). We previously discussed end-to-end encryption, but let’s go deeper. In confidential smart contracts, encryption happens transparently between your device and the smart contract. However, you can also split a key between your device and the blockchain—combining these parts allows access to the data.

Sapphire supports on-chain encryption primitives, enabling secure operations like DX in several examples. For instance, a local shop could issue you a partial coupon, while the other part is stored securely on-chain. Combining these parts unlocks rewards or bonuses.

Signing & Verification

Sapphire supports on-chain transaction generation and signing, which is significant. You can create, sign, and return a transaction directly on-chain, allowing the user to broadcast it themselves. This aligns with Ethereum’s “account abstraction” concept, where smart contracts can maintain balances and sign transactions on behalf of users.

Since the confidential state is protected, private keys can securely reside on-chain, facilitating “gasless transactions.” This eliminates intermediaries and simplifies processes.

On-Chain SSO (Single Sign-On)

Gasless transactions remove the need for third-party relayers like OpenGSN. Instead, you can request the contract itself to sign transactions. Contracts can hold tokens for gas fees, ensuring seamless user experiences. For example, a view call (free of charge) could generate a transaction that the user broadcasts.

This approach minimizes censorship risks and enables direct blockchain interaction. It also supports bridging to other networks like Bitcoin, allowing features such as minting on-chain tokens without intermediaries.

Autonomous Contracts

With Sapphire, you can securely store proofs of identity on-chain. Services like email providers or GitHub can verify these proofs via view calls, granting access without exposing sensitive data. This is only possible due to Sapphire’s confidential contract storage.

Autonomous contracts enable smart contracts to generate and broadcast transactions independently. This is supported by the Sapphire pre-compiled library and aligns with Ethereum standards like EIP-4337.

Oasis Playground

Visit playground.oasis.io to explore demos and examples showcasing these features. For instance, you can vote on a poll without paying any fees, thanks to deposited tokens covering costs. This eliminates the need for GSN relayers and facilitates direct interaction between clients and the blockchain.

If you have a dApp you’d like to showcase, submit a pull request, and we’ll add it to the list!

6. Oasis Privacy Layer (OPL)

OPL connects Sapphire to other networks like Ethereum, Binance Chain, and Polygon. This allows developers to add confidentiality to their existing dApps. Using bridges like Celer, Sapphire computes the confidential parts, while the target chain handles the rest.

7. Run Your Node

Lastly, I highly encourage you to run a Sapphire client node. This removes dependency on third parties for your dApps and enhances security and reliability.

Documentation

Don’t forget to check out our comprehensive documentation! It’s packed with guides and resources on building dApps, running nodes, and leveraging confidentiality for secure applications.