Skip to main content

🤝 Share Encrypted Files

Once you've uploaded an encrypted file to Walrus, you can share access with other SUI addresses by adding them to the file's allowlist.

Sharing an Encrypted File​

Follow these steps from the Lighthouse Files Dapp:


Step 1: Locate Your Encrypted File​

From your files dashboard, find the encrypted file you want to share. Encrypted files are marked with a lock icon.

Encrypted File

Click on the file to open its details view.


Step 2: Open the Share Panel​

In the file details view, click the Share button. This opens the share panel where you can manage who has access to your encrypted file.

Share Button


Step 3: Add a Wallet Address​

Enter the Sui wallet address of the person you want to share the file with. This is the address that will be granted permission to decrypt the file.

Add Wallet Address

The address must be a valid Sui wallet address. Lighthouse will validate the format before proceeding.


Step 4: Sign the Transaction​

After entering the wallet address, your Sui wallet will prompt you to sign a transaction. This transaction:

  • Calls the add_user function on the file's FileAllowlist object
  • Adds the specified wallet address to the allowlist
  • Updates the on-chain access control for the encrypted file

Sign Share Transaction


Step 5: Confirmation​

Once the transaction is confirmed on-chain, the recipient's wallet address is added to the allowlist. They can now:

  • View the encrypted file in their own dashboard (if they have the CID)
  • Prove ownership and decrypt the file using SEAL
  • Access the file contents on their device

The shared wallet will appear in your file's access list, confirming the share was successful.

Share Confirmed

Sharing Multiple Files

You can repeat this process to share the file with multiple wallet addresses. Each address is added independently to the allowlist.