{"id":15448473,"url":"https://github.com/vasa-develop/quorum-cluster-peer-1","last_synced_at":"2025-07-04T12:04:27.924Z","repository":{"id":99739296,"uuid":"132578889","full_name":"vasa-develop/quorum-cluster-peer-1","owner":"vasa-develop","description":null,"archived":false,"fork":false,"pushed_at":"2018-05-08T17:43:35.000Z","size":55,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-06-01T03:58:12.059Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/vasa-develop.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2018-05-08T08:32:07.000Z","updated_at":"2018-05-08T17:43:36.000Z","dependencies_parsed_at":"2023-07-31T18:45:56.967Z","dependency_job_id":null,"html_url":"https://github.com/vasa-develop/quorum-cluster-peer-1","commit_stats":{"total_commits":18,"total_committers":3,"mean_commits":6.0,"dds":0.2777777777777778,"last_synced_commit":"3f3108dcda0e9c07228087e13bf38548733cf665"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/vasa-develop/quorum-cluster-peer-1","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vasa-develop%2Fquorum-cluster-peer-1","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vasa-develop%2Fquorum-cluster-peer-1/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vasa-develop%2Fquorum-cluster-peer-1/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vasa-develop%2Fquorum-cluster-peer-1/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/vasa-develop","download_url":"https://codeload.github.com/vasa-develop/quorum-cluster-peer-1/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vasa-develop%2Fquorum-cluster-peer-1/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":263507812,"owners_count":23477401,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-01T20:26:36.654Z","updated_at":"2025-07-04T12:04:27.874Z","avatar_url":"https://github.com/vasa-develop.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# 7 nodes\n\nThis example configures 7 nodes, each with their own PrivateTransactionManager. Usage:\n\n  - `raft-init.sh`: Initialize accounts and keystores\n  - `raft-start.sh`: Launch `constellation` and `geth` nodes, then send a private transaction\n  - `stop.sh`: Stop all `constellation` and `geth` nodes\n\nThere are corresponding commands for running in Istanbul BFT mode (`stop.sh` stays the same).\n\n  - `istanbul-init.sh`\n  - `istanbul-start.sh`\n\nAll logs and temporary data will be written to the `qdata` folder.\n\n## Testing Privacy\nYou can run the 7node example to test the privacy features of Quorum. As described in the Quick Start section of the [README](https://github.com/jpmorganchase/quorum), the final step of the 7node `start.sh` script was the sending of a private transaction to generate a (private) smart contract (SimpleStorage) sent from node 1 \"for\" node 7 (denoted by the public key passed via privateFor: [\"ROAZBWtSacxXQrOe3FGAqJDyJjFePR5ce4TSIzmJ0Bc=\"] in the sendTransaction call). We'll begin by demonstrating only nodes 1 and 7 are able to view the initial state of the contract. Next we have node 1 update the state of this contract and again verify only nodes 1 and 7 are able to see the updated state of the contract after the block containing the update transaction is validated by the network.\n\nFor this test it is recommended to use separate terminal windows running geth JavaScript console attached to node 1, node 7, and any node 2-6 (in our example we'll choose node 4).\n\nIn each terminal, ensure you are in the 7nodes dir before running the below.\n\n* If you aren't already running the 7nodes example, in terminal 1 run ``$ ./init.sh `` followed by ``$ ./start.sh ``\n* In terminal 1 run ``$ geth attach ipc:qdata/dd1/geth.ipc``\n* In terminal 2 run ``$ geth attach ipc:qdata/dd4/geth.ipc``\n* In terminal 3 run ``$ geth attach ipc:qdata/dd7/geth.ipc``\n\nFor each of the 3 nodes we'll use the built-in JavaScript by setting the variable ```address``` assigned to the simpleStorage contract address created by the node 1. The address can be found in the node 1's log file 7nodes/qdata/logs/1.log, or alternatively by reading the `contractAddress` param after calling `eth.getTransactionReceipt(txHash)` ([Ethereum API documentation](https://github.com/ethereum/wiki/wiki/JavaScript-API#web3ethgettransactionreceipt)), passing in the transaction hash that was logged in the console that you ran the 7nodes example in. Replace the address below with the address value found in the 1.log file:\n```\n\u003e var address = \"0x1932c48b2bf8102ba33b4a6b545c32236e342f34\";\n```\nNext we'll use ```eth.contract``` to define a contract class with the simpleStorage ABI definition as follows:\n```\n\u003e var abi = [{\"constant\":true,\"inputs\":[],\"name\":\"storedData\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"x\",\"type\":\"uint256\"}],\"name\":\"set\",\"outputs\":[],\"payable\":false,\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"get\",\"outputs\":[{\"name\":\"retVal\",\"type\":\"uint256\"}],\"payable\":false,\"type\":\"function\"},{\"inputs\":[{\"name\":\"initVal\",\"type\":\"uint256\"}],\"type\":\"constructor\"}];\n\u003e var private = eth.contract(abi).at(address)\n```\nThe function calls are now available on the contract instance and you can call those methods on the contract. Let's start by examining the initial value of the contract to make sure that only nodes 1 and 7 can see the initialized value.\n* In terminal window 1 (node 1)\n```\n\u003e private.get()\n42\n```\n* In terminal window 2 (node 4)\n```\n\u003e private.get()\n0\n```\n* In terminal window 3 (node 7)\n```\n\u003e private.get()\n42\n```\n\nSo we now see nodes 1 and 7 are able to read the state of the private contract and it's initial value is 42. Node 4 is unable to read the state. Next we'll have node 1 set the state to the value `4` and verify only nodes 1 and 7 are able to view the new state.\n\nIn terminal window 1 (node 1)\n```\n\u003e private.set(4,{from:eth.coinbase,privateFor:[\"ROAZBWtSacxXQrOe3FGAqJDyJjFePR5ce4TSIzmJ0Bc=\"]});\n\"0xacf293b491cccd1b99d0cfb08464a68791cc7b5bc14a9b6e4ff44b46889a8f70\"\n```\nYou can check the log files in ~7nodes/qdata/logs directory to see each node validating the block with this new private transaction. Once the block containing the transaction has been validated we can once again check the state from each node 1, 4, and 7.\n* In terminal window 1 (node 1)\n```\n\u003e private.get()\n4\n```\n* In terminal window 2 (node 4)\n```\n\u003e private.get()\n0\n```\n* In terminal window 3 (node 7)\n```\n\u003e private.get()\n4\n```\nAnd there you have it. All 7 nodes are validating the same blockchain of transactions, the private transactions carrying nothing other than a 512 bit hash, and only parties to private transactions are able to view and update the state of private contracts.\n\n## Permissions\n\nNode Permissioning is a feature in Quorum that allows only a pre-defined set of nodes (as identified by their remotekey/enodes) to connect to the permissioned network.\n\nThis example demonstrates the following:\n* Sets up a network with a combination of permissioned and non-permissioned nodes in the cluster.\n* Details of permissioned-nodes.json file.\n* Demonstrate that only the nodes that are specified in permissioned-nodes.json can connect to the network.\n\n### Verify only permissioned nodes are connected to the network.\n\nAttach to the individual nodes via\n\t`geth attach path/to/geth.ipc` and use `admin.peers` to check the connected nodes.\n\n```\n❯ geth attach qdata/dd1/geth.ipc\nWelcome to the Geth JavaScript console!\n\ninstance: Geth/v1.7.2-stable/darwin-amd64/go1.9.2\ncoinbase: 0xed9d02e382b34818e88b88a309c7fe71e65f419d\nat block: 1 (Mon, 29 Oct 47909665359 22:09:51 EST)\n datadir: /Users/joel/jpm/quorum-examples/examples/7nodes/qdata/dd1\n modules: admin:1.0 debug:1.0 eth:1.0 miner:1.0 net:1.0 personal:1.0 raft:1.0 rpc:1.0 txpool:1.0 web3:1.0\n\n\u003e admin.peers\n[{\n    caps: [\"eth/63\"],\n    id: \"0ba6b9f606a43a95edc6247cdb1c1e105145817be7bcafd6b2c0ba15d58145f0dc1a194f70ba73cd6f4cdd6864edc7687f311254c7555cc32e4d45aeb1b80416\",\n    name: \"Geth/v1.7.2-stable/darwin-amd64/go1.9.2\",\n    network: {\n      localAddress: \"127.0.0.1:65188\",\n      remoteAddress: \"127.0.0.1:21001\"\n    },\n    protocols: {\n      eth: {\n        difficulty: 0,\n        head: \"0xc23b4ebccc79e2636d66939924d46e618269ca1beac5cf1ec83cc862b88b1b71\",\n        version: 63\n      }\n    }\n},\n...\n]\n```\n\nYou can also inspect the log files under `qdata/logs/*.log` for further diagnostics messages around incoming / outgoing connection requests. Grep for `ALLOWED-BY` or `DENIED-BY`. Please be sure to enable verobsity for p2p module.\n\n### Permissioning configuration\n\nPermissioning is granted based on the remote key of the geth node. The remote keys are specified in the permissioned-nodes.json and is placed under individual nodes \u003cdatadir\u003e.\n\nThe below sample permissioned-nodes.json provides a list of nodes permissioned to join the network ( node ids truncated for clarity)\n\n```\n[\n   \"enode://8475a01f22a1f48116dc1f0d22ecaaaf77e@127.0.0.1:30301\",\n   \"enode://b5660501f496e60e59ded734a889c97b7da@127.0.0.1:30302\",\n   \"enode://54bd7ff4bd971fb80493cf4706455395917@127.0.0.1:30303\"\n]\n```\n\n### Enabling/Disabling permissions\n\nAn individual node can enable/disable permissioning by passing the `-permissioned` command line flag. If enabled, then only the nodes that are in the `\u003cdatadir\u003e/permissioned-nodes.json` can connect to it. Further, these are the only nodes that this node can make outbound connections to as well.\n\n```\nMISCELLANEOUS OPTIONS:\n--permissioned          If enabled, the node will allow only a defined list of nodes to connect\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvasa-develop%2Fquorum-cluster-peer-1","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fvasa-develop%2Fquorum-cluster-peer-1","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvasa-develop%2Fquorum-cluster-peer-1/lists"}