DL Research Content

Nekodex: Simplifying DeFi with Account and Chain Abstraction

Nekodex: Simplifying DeFi with Account and Chain Abstraction
Illustration: Andrés Tapia; Source: Nekodex
Overview - Nekodex: DeFi Without Hassle
  • Nekodex is a crypto app designed to simplify user interaction with decentralized exchanges (DEX) in the DeFi space. It eliminates the need for complex processes like managing seed phrases, gas fees, or multiple blockchain networks.
  • By integrating technologies such as passkeys, smart contract wallets, and cross-chain swaps, Nekodex offers a user-friendly platform accessible to a broader audience.

The Power of Abstraction

Entering the DeFi ecosystem often requires navigating multiple steps, including wallet setup, gas token acquisition, phishing risks, bridging, and token approvals — each of which can lead to errors or confusion.

Nekodex addresses these challenges by condensing the process into straightforward steps. Users can install an app, deposit funds (e.g., USDC), search for desired assets or interest accounts, make a selection, and confirm via a simplified summary.

Backend processes such as wallet creation, network fees, and bridging are automated. Additionally, curated lists of coins and interest accounts aim to provide users with reliable options.

Key Concepts to Understand

To better grasp how Nekodex operates, here are a few foundational concepts:

  • Smart Contract Wallet: A blockchain-based wallet powered by smart contracts — self-executing code that facilitates secure and automated transactions while ensuring users retain control of their funds.
  • Account Abstraction (AA): A method that simplifies wallet interactions by handling technical details like gas fees on behalf of the user.
  • Multi-Chain Ecosystem: Cryptocurrency and smart contract platforms now span multiple blockchains, each offering unique features and scalability. While this provides flexibility, it can also make navigation challenging. In this article, the terms network, chain, and blockchain are used interchangeably.

Next, we’ll explore how these concepts apply to:

  • Account and Wallet Creation
  • Cross-Chain Trading
  • Withdrawals

Account & Wallet Creation

Nekodex streamlines wallet creation and management using passkeys, a secure authentication method designed for ease of use and enhanced security.

What is a Passkey?

A passkey functions as a highly secure password, eliminating the need for memorisation and safeguarding against exposure to malicious parties.

Join the community to get our latest stories and updates

It is stored on your device (e.g., phone or computer) and backed up in encrypted form via iCloud or Google accounts.

Nekodex graph.

How Passkeys Work

When setting up a passkey for your Nekodex account, the process involves:

1. Challenge Generation: The server sends a randomised request (a “challenge”) to your device.

Nekodex graph.

2. Key Pair Creation: Your device generates two cryptographic keys — one public and one private. The private key remains securely stored on your device.

Nekodex graph.

3. Public Key Linking: The public key is sent to Nekodex’s server and linked to your account for future logins.

Nekodex graph.

(Referenced from https://www.passkeys.io/technical-details)

Passkeys are stored locally on your device and encrypted in your Apple or Google account. They are app-specific, preventing use on fake or malicious platforms, and adding a layer of protection to your Nekodex account.

How Nekodex Uses Passkeys to Sign Transactions

Passkeys are used to authorise critical actions on Nekodex, such as logging in, making withdrawals, or upgrading accounts. These actions require your passkey to confirm your identity and ensure the transaction is legitimate.

To enable this functionality, Nekodex integrates tooling from ZeroDev, ensuring secure and efficient transaction signing.

What is ZeroDev?

Smart Wallets with Passkeys

Nekodex accounts are built on ZeroDev, a smart contract wallet solution that uses passkeys to simplify wallet creation and management. ZeroDev enables secure transaction signing and account management through its innovative wallet architecture.

ZeroDev’s system comprises two main components:

  1. Kernel: The smart contract wallet serving as the core of the system.
  2. Plugins: Add-on features that enhance the Kernel wallet’s functionality. Nekodex uses a Passkey Validator plugin, allowing transactions to be securely signed with your passkey.

This setup simplifies complex cryptocurrency transactions, providing a user-friendly alternative to traditional wallet tools.

Session Keys: Simplifying Trades

While logging in with a passkey is straightforward, manually signing every transaction can become tedious during frequent trading.

Session keys address this issue by enabling automated transaction signing under controlled conditions.

What Are Session Keys?

Session keys allow your Nekodex account to sign transactions automatically, with safeguards in place to ensure security. These safeguards include:

  • Who: Defining whether you or the session key can perform an action.
  • When: Restricting actions to specific times or conditions, such as transaction limits.
  • What: Specifying allowed actions, like trading a particular token.

With session keys, users can execute trades quickly by tapping a button, without needing to approve each transaction individually.

However, session keys are not used for critical functions such as logins, withdrawals, or account upgrades, which require passkey authorisation.

(Reference: https://docs.zerodev.app/sdk/permissions/intro#permissions-session-keys)

Cross-Chain Trading

Chain Abstraction Made Simple

Nekodex simplifies trading by managing the complexities of blockchain interaction behind the scenes.

Users don’t need to handle bridging, gas fees, token approvals, or other technical details. Instead, users simply specify the token they want to trade, and Nekodex manages the process seamlessly.

Intent-Based Trading with Across Protocol

Nekodex supports token trading across multiple blockchains using a cross-chain settlement network from Across Protocol. When a user initiates a trade, Nekodex generates an intent-based order based on the provided quote.

The order is signed by the user’s smart contract wallet using the EIP-1271 standard, with its structure adhering to the ERC-7683 specification for cross-chain trading.

How Trading Works

  • Same-Chain Trading: For trades on Nekodex’s native network (Optimism Mainnet), transactions occur in a single step with the help of a filler network—automated bots that process orders.
  • Cross-Chain Trading: For trades between different blockchains, Nekodex uses cross-chain messaging from Across Protocol. Relayers request fillers on the appropriate blockchain to execute the order and transfer the token to the user’s destination wallet.

Relayers and Filler Bots

Automated filler bots in an open network process user orders in exchange for payments and small fees. These bots ensure quick and reliable trade execution.

Here’s the general workflow for a standard cross-chain buy order:

Nekodex graph.

Withdrawals

Withdrawing Funds Using a Passkey

Currently, Nekodex supports USDC deposits and withdrawals. The process is straightforward:

  1. Enter the recipient address for your funds.
  2. Authorise the transaction using your passkey.
  3. The transaction is sent to the blockchain, and your tokens are transferred.

Fund Recovery

If users lose access to their passkey, Nekodex offers a fund recovery process. This allows funds to be moved to a recovery address predefined by the user. The recovery address can be linked to a trusted individual’s Nekodex account or a traditional web3 wallet.

Fund recovery is initiated via the email associated with the Nekodex account. The recovery process is managed by a third-party provider, ensuring that users do not need to rely solely on Nekodex for fund access.

What’s Coming Next?

Nekodex is focused on ongoing improvements, with plans to introduce:

  • Support for additional coins, DeFi products, and blockchains.
  • Withdrawal options for all coins held by users.
  • More decentralised features, such as third-party relayers for trade facilitation.
  • Faster and more cost-efficient transactions.

By leveraging technologies like account abstraction, passkeys, and chain abstraction, Nekodex aims to reduce traditional barriers in DeFi, striving to make the ecosystem more accessible, secure, and user-friendly.