amavic / bmerode-generator Goto Github PK
View Code? Open in Web Editor NEWGenerate Hyperledger Fabric chaincode automatically from conceptual models.
Home Page: https://merode.econ.kuleuven.be/Research.html
License: Other
Generate Hyperledger Fabric chaincode automatically from conceptual models.
Home Page: https://merode.econ.kuleuven.be/Research.html
License: Other
Add a transaction that allows to retrieve the history of a given business object based on its ID
Handling authorization check for collaboration setup
When generating the code for the Participant Business Object Types, a public key attribute must be added (in attributes, constructors, etc.)
When executing an ending method that is triggered because of an ending method in a dependent object,
the top method rejects the event execution because of existing "living dependents" (that will, actually be removed in the end)
The code generator does not generate the CollaborationSetup lastIds structure for all business object types.
In the XSD File (1.6): an element of type MetaMPCKind is expected but not added in the generated XSD Files.
As a temporary fix: put minOccurs = "0" in the XSD for that element
To be implemented
When users try to perform operations that are not allowed, the operation is well denied.
However, the reason why is not clearly displayed (mess with Exceptions).
Compared to the proposition in the original paper, instance access rules can be simplified.
We only consider instance access rules for event execution: conditions specifying whether a particular instance of a participant is allowed to execute a given business event.
For instance:
To do for implementation:
Implement a JSON Validator allowing to make sure any JSON Strings provided as parameters are valid for a given call
To be implemented
The version of the org.hyperledger.fabric-chaincode-java:fabric-chaincode-shim library is not fixed in build.gradle, which causes issues with the generated chaincode.
Fix: org.hyperledger.fabric-chaincode-java:fabric-chaincode-shim:2.5.0
The gradlew shell script is not copied from the base chaincode structure into the generated chaincode directory.
Manual Testing of the Key Components to prepare for Case Studies: All Successfull (after a couple of committed adjustments)
Model Files used as Input: BMerode-Solution-Testing-Models.zip
Testing Scenarios and Results: BMerode-Solution-Testing-Scenarios.txt
The different participants are handled in the scope of the collaboration being supported, distinctively from HLF's identity system. Indeed, access control lists and policies that can be defined on HLF are independent from the chaincode. It does support the assignation of attributes to different identities, which can be used to encode permissions. The chosen solution makes it easier to handle participants as regular business object types and allow organizations to use B-Merode without needing to affect user identities on their blockchain networks.
In this context, each participant BOT has a public key (which can be retrieved when it submits a transaction).
When users send transaction proposals to the network peers, these proposals must be cryptographically signed, and HLF verifies the correctness and validity of the signature. Therefore, having a mapping (public key --> role --> permissions) is sufficient to verify, at chaincode level, whether a given user has the right to perform a given transaction.
While the Event-Participant Table defines which participant (type) is allowed to fire business events, and thereby, among others create, modify or end participants, we still need a way to handle this when the collaboration is not running yet. Indeed, if participants of a given type are allowed to create other participants, the former must well be added by someone.
Thereby, we introduce two elements:
This is consistent with the general idea that even if organizations collaborate in a trustless and decentralized manner, one needs to make the initial setup (c.f. HLF docs).
This has a number of implications:
Current solution does generate all required files, but does not include in the package the files that do not depend upon the model and need to be added to the solution "as-is"
Develop JSON Converter:
Defines which Business Event can be fired by which Business Object (Participant) Type.
Default: not allowed.
Business Object Type | Business Event | Allowed |
---|---|---|
BOT1 | EVT1 | true |
BOT1 | EVT2 | false |
BOT2 | EVT1 | false |
BOT2 | EVT2 | true |
Once the setup of the collaboration is ready (required participants (BO) have been added), the ParticipantsHandler can specify it using this transaction.
Upon reception of a request to handle a Business Event, the following checks must be performed:
To be Implemented
Potentially same issue as getBO / getBOHistory (that are fixed)
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.