Using smart contracts to manage real-world contracts