🛍️ Merchant Identity

In Perpetual3, each merchant is uniquely identified by a combination of their crypto wallet and two cryptographic key pairs - an ed25519 key pair and a x25519 key pair.

💼 Crypto Wallet

The merchant's crypto wallet is the primary identifier. This not only associates the merchant with their transactions, but it also serves as the primary access point for interacting with the Perpetual3 platform. The crypto wallet is link publicly linked merchant's two key pairs - ed25519 and x25519 - using public keys, ensuring a comprehensive and robust identity framework.

🔑 ed25519 key pair

The ed25519 key pair plays a crucial role in ensuring the integrity and authenticity of a merchant's transactions on the Perpetual3 platform. The merchant uses their ed25519 private key to sign all significant data related to their store, such as product listings, accepted payment methods, terms of service, on chain collections, and more.

These signed data pieces become an integral part of the transaction process. When customers place orders, the corresponding smart contracts validate the order parameters against the merchant's signed data, effectively verifying that the order details match the terms set by the merchant. As a result, merchants receive only orders with valid parameters, safeguarding them against tampered data.

Moreover, the use of ed25519 signatures also protects customers by ensuring a non-repudiation from merchant with proof of the commerce terms, as the signature confirms that the merchant has indeed agreed to these terms.

We use an additional key pair for data signing instead of native crypto wallet because users need to perform a lot of sign operations and we believe that asking each time the user to sign data with their crypto wallet could significantly impact the user experience.

🛡️ x25519 Key pair

The x25519 key pair plays a pivotal role in ensuring private and secure communications. This key pair, leveraging the Elliptic Curve Diffie-Hellman (ECDH) key exchange protocol, allows any party, such as customers, to establish an end-to-end encrypted communication channel with the merchant. This approach negates the need to trust intermediaries with sensitive information, reinforcing the platform's privacy and data protection principles.

Once the shared key is established, it is used to encrypt all messages in the communication channel. Perpetual3 uses the ChaCha20-Poly1305 encryption algorithm due to its efficiency and robust security attributes. This ensures that the encrypted data remains confidential and tamper-proof throughout the transmission.

The x25519 key pair, therefore, plays a crucial role in ensuring the privacy of merchant-customer interactions, fostering trust, and encouraging secure and open communication.

We may change ed25519 key pair to ECDSA key pair for better cross chain interoperability.

Last updated