Reputation: 11
I have 5 nodes each representing partyA, partyB, partyC, partyD, partyE. I need to make a transaction with need as described below...
only 'write user' from partyA should be able to 'create' or initiate flow with a state which has 20 fields, with parties as partyA,B, C,D,E.
any other user (including 'read user' from partyA) should be able to only view output state details (but do not have ability to modify/consume it).
partyA, partyB should get to see all 20 fields.
Can some one suggest best approach to achieve field level read write access control for output states in corda3.x please.
Thanks in advance.
Upvotes: 1
Views: 72
Reputation: 141
I am afraid there is no privacy control down to a field level of states.
For your example, the best is to create 3 kinds of states to share with those parties, say a FullState, HalvedState, QuarteredState.
In your contracts, you can make sure the initiator/initial signer of the transaction is partyA's identity. Because only the initiator is able to make changes which matches your #1 requirement.
Then implement 2 flows that will be triggered after the FullState is created/modified and clone it to a HalvedState and share with the corresponding nodes.
Upvotes: 1