Do your due diligence

James McCall
LexDAOism
Published in
9 min readMay 20, 2021

How to Use Fancy Math to Token Gate Due Diligence Rooms

This is a cross post that combines my side side project Farmapper, with my side side project LexDAOism. Avid readers remember when we built a due diligence room on Farmapper in the cloud using tax assessor parcel shapes, legal descriptions, USDA Cropscape, document storage to visualize a farm target for a purchase. Similarly the following could apply in any mergers and acquisition project as parties that want to prop up a due diligence room for interested parties.

What if you wanted to form a due diligence room, but grant access to the information in an anonymous manner?

First why the heck would we want to do this? Well, perhaps the buyer wants to be able to perform their due diligence without tipping off the neighbors or the seller. Maybe it is as simple as you don’t want to keep email lists, and contact information. Or maybe the list of investors are accredited investors, and it is a possible securities offering. Maybe it is just a past feud between landowners or DAO’s.

There is also an opportunity of DAO’s merging away from “spinoffs” and merging into other DAO’s. Some of these teams are anonymous, or really don’t even have a developer team. They are just a DAO on chain. An example is where Inverse Finance acquihired Tonic Finance one person development team as executed here. How can they do their due diligence and preserve this pseudo-personal information. In the real world, there can be the onerous process of non-disclosure agreements that often are toothless in case of a breach.

For this article we work as if there is a transaction involving a real world asset “a farm”. If this is your first time hearing about Farmapper.com, it is a web application that allows a user to click on a point on the map and load shapes from a database to overlay over the map interface. These shapes can be saved, have documents saved to them, place icon stickers to mark improvements, and much much more. All of the information and data can be saved to a Farmapper project, that can then be used to generate a public URL or shared with other authenticated Farmapper users.

I Am the Gatekeeper are you the Keymaster?

We start with a gate. And gates need locks and keys. So in our example we have the Farmapper project locked behind a gate. This gate requires a unique NFT to unlock the gate and serve as the Key. A non-fungible token (NFT) is a special type of cryptographic token which represents something unique. So one could say that each photo in your photo album is unique. Slap a serial number on it and digitize it and you have the makings of a NFT.

For this tutorial we will use the following

  1. Farmapper NFT contract to mint cheap NFT’s on the xdai network using cargo.build. These will be our keys
  2. Farmapper application to create a farm project with various documents, parcels, and data to publish a public URL. This is the lock.
  3. Mintgate used to token lock the above Farmapper project URL. This will be our lockmaker.
You open the Gate you Close and Lock the Gate

The target farm for our due diligence is one that there was a very high priced sale between two neighbors. This drove the reported farm sales price up to $18,800 per acre. The rest is just speculation. Imagine that one of the neighbors had a long standing beef with the prospective seller. And on the seller’s death bed, they said don’t sell this guy the farm. Ever!

With this the stage is set. The estate planner wants to have a process that realizes the most value from the real property, but without knowing who any of the interested parties are in the process. This can be accomplished through using encrypted key pair wallets. Without going into the complex math. Blockchain wallets generally work with the only identifiable information being a public address (think of this as a website for money). That is controlled by the owner of the wallet, through a private key. This is the key that enables the owner to move tokens, or make signatures on a blockchain.

We could imagine that interested parties could pseudoanonymously post $1,000 in earnest money in a noncustodial escrow and obtain an NFT token that will serve as the key to the lock.

Let’s mint the NFT

We want to mint our NFT, using the image from a Farmapper project. Here we go to this public project that follows a high sale between two neighbors as per this Twitter conversation. We recreated a proxy for the sale using farmapper.com and published the project to a live URL. We are going to assume that we want to lock the project URL so that it requires an NFT to access. We screen shot the image for the NFT. Farm art is the best.

OpenSea of Corn

With image in hand, we go to cargo.build which is an NFT minting and management platform. We use a different network than Ethereum as it is currently very expensive to mint on mainnet and we just need an NFT, not to secure a billion dollars.

We connect using a metamask account, which uses a browser extension to connect to blockchains. Be careful and make sure everything is official and authenticated and the private keys are kept private. It is the equivalent of having a real life wallet and if you leave it in the open in a bar overnight, it might not have all the stuff that you left in it.

100$ at bar and rounds for my friends

Farmapper has executed a transaction on app.cargo.build that launches a smart contract that enables us to mint our own NFT’s on the xdai network. We want to mint another NFT for our “key” to the lock.

Farm art requires catchy descriptions

Basically, we add information including the name, a description, the number of tokens “keys” to mint, the image from our project, and we can even lock in files into the NFT. I am going to drop in a .kml file that is a Google Earth friendly version of our project shapes. There are even options for dropping in videos, audio or make 3D NFT’s. Yes the future is weird.

Next we mint, which basically prints the NFT token on the blockchain and relates the data that we stored to the token. Picture an NFT as a token that points to other data. In our case, it will point to other information. Here you can see that it points to my screenshot as an image, and to cargo to host the token in their marketplace.

Here is token #17

As the owner of the NFT, I can “unlock” the kml file that I buried in it. I can transfer it to anyone else or I can even list it for sale on their marketplace. Plus I can even include royalties every time that the NFT sells in the secondary market. But I won’t do that here.

I did transfer an NFT to another account so that it can be used as the key.

Using Mintgate to make the Lock

Now we want to “lock” some content that can be opened with the NFT as the key. We go to mintgate and authenticate with Twitter. I want to add the public URL to token lock it. Astute followers will know that the public url is still public, but for the general public it would not be available without the link. Though it is still public and crawlable to anyone or anybot with the url to view the project.

Insert URL to Lock here

Insert the URL for what we want locked behind the gate.

I now select the xdai network, the contract address that was used to mint the NFT’s and the token identification number #19. This should create an “unlockable link” that looks like this. Try it out.

Now, if I go to this link with a wallet that holds the NFT, I should be able to sign an encrypted signature proving that the wallet holds the NFT and access the link.

If not, I just get a message that I don’t hold the token. So I transferred the NFT earlier, and click on the Mintgate link and after the signature verified the NFT key in my metamask wallet.

After the NFT key fits the lock, the link propagates and we see the due diligence room appear, with the farm project, the stickers, the documents, etc all available for the holder of the NFT.

Bootiful patterns

Share Open Information with Anyone

Once again, in our example, the attorney was able to put together information in a due diligence room and allow the exchange between parties without the other knowing exactly who is accessing the information. All done using fancy cryptography to ensure that from the point of the blockchain it sees only the NFT owned by the wallet which gives the owner certain permissions.

In the future we hope that the NFT won’t just unlock due diligence rooms, but perhaps even easements, or leasehold rights, or camping sites, chat rooms, or whatever use case can be dreamed up. All without the either party needing to share precious information that can be subject to data breaches, future mail spam, etc.

Special thanks to Nick Rishwain for providing comments.

About Farmapper

We are on a mission at farmapper.com to bring agriculture together on the map. We want farmers to own and control their data and be able to use technology to remove friction costs. Please give us a clap or two and let us know what we should write the next series on.

Follow us on Twitter: @farmapper

Visit our Website: www.farmapper.com

Checkout our Facebook: https://www.facebook.com/farmapper/

About LexDAO

LexDAO is a non-profit association of legal engineering professionals that brings the traditional legal settlement layer to code, and coded agreements to the masses. We believe that everyone deserves access to justice provided in a quick and efficient manner. If legal services were easier to use, verify, and enforce, we could live in a fairer world. Blockchain technology offers solutions to many problems in the legal space. Our mission is to research, develop and evangelize first-class legal methods and blockchain protocols that secure rules and promises with code rather than trust. We do this by training LexDAO certified legal engineers and building LexDAO certified blockchain applications. We strive to balance new deterministic tools with the equitable considerations of law to better serve our clients, allies, and ultimately citizens.

All links provided are for informational purposes only and not meant as recommendations of the people or products. Nothing herein is legal or financial advice and should not be relied upon without reaching out to your own personal attorney. The linked ABA disclaimer is appended to the blog.

Follow us on Twitter @lexDAO

Join our Discord lexdao.chat

Peruse our Github https://github.com/lexDAO

--

--

James McCall
LexDAOism

Love agriculture, finance, and law Not legal advice. DAO things w/ @lex_dao ; @farmapper working wit @realdao ; views are mine and relatively scenic