From b3e801eb855cb2d30978bba159a38686296a7c03 Mon Sep 17 00:00:00 2001
From: Mike Hearn <mike@r3cev.com>
Date: Mon, 1 Feb 2016 16:06:52 +0100
Subject: [PATCH] Minor: add an explanatory comment to the two-party trade
 protocol.

---
 src/main/kotlin/contracts/protocols/TwoPartyTradeProtocol.kt | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/src/main/kotlin/contracts/protocols/TwoPartyTradeProtocol.kt b/src/main/kotlin/contracts/protocols/TwoPartyTradeProtocol.kt
index bf0aef213d..c512e0f966 100644
--- a/src/main/kotlin/contracts/protocols/TwoPartyTradeProtocol.kt
+++ b/src/main/kotlin/contracts/protocols/TwoPartyTradeProtocol.kt
@@ -165,7 +165,10 @@ object TwoPartyTradeProtocol {
             val cashSigningPubKeys = Cash().craftSpend(ptx, tradeRequest.price, tradeRequest.sellerOwnerKey, cashStates)
             // Add inputs/outputs/a command for the movement of the asset.
             ptx.addInputState(tradeRequest.assetForSale.ref)
-            // Just pick some new public key for now.
+            // Just pick some new public key for now. This won't be linked with our identity in any way, which is what
+            // we want for privacy reasons: the key is here ONLY to manage and control ownership, it is not intended to
+            // reveal who the owner actually is. The key management service is expected to derive a unique key from some
+            // initial seed in order to provide privacy protection.
             val freshKey = serviceHub.keyManagementService.freshKey()
             val (command, state) = tradeRequest.assetForSale.state.withNewOwner(freshKey.public)
             ptx.addOutputState(state)