Giter VIP home page Giter VIP logo

fabricnetwork-2.x's Introduction

fabricnetwork-2.x's People

Contributors

adhavpavan avatar adityajoshi12 avatar priyatham-sai-chand avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

fabricnetwork-2.x's Issues

Privacy leakage in fabcar.go

The "CreatePrivateDataImplicitForOrg1" function in artifacts/src/github.com/fabcar/go/fabcar.go gets the private data directly via function parameters, which will be included in the transaction and all peers can access. The private data should be passed in the function via "GetTranscient" API.

Error happen when I run create-artifacts.sh

rm: cannot remove ‘genesis.block’: Is a directory
rm: cannot remove ‘mychannel.tx’: No such file or directory
mychannel
2021-02-24 21:49:40.435 CST [common.tools.configtxgen] main -> INFO 001 Loading configuration
2021-02-24 21:49:40.468 CST [common.tools.configtxgen.localconfig] completeInitialization -> INFO 002 orderer type: etcdraft
2021-02-24 21:49:40.469 CST [common.tools.configtxgen.localconfig] completeInitialization -> INFO 003 Orderer.EtcdRaft.Options unset, setting to tick_interval:"500ms" election_tick:10 heartbeat_tick:1 max_inflight_blocks:5 snapshot_interval_size:16777216
2021-02-24 21:49:40.469 CST [common.tools.configtxgen.localconfig] Load -> INFO 004 Loaded configuration: /home/cshiru/Fabric_Network/FabricNetwork-2.x/artifacts/channel/configtx.yaml
2021-02-24 21:49:40.469 CST [common.tools.configtxgen] main -> FATA 005 Error on outputBlock: could not create bootstrapper: could not create channel group: could not create orderer group: cannot marshal metadata for orderer type etcdraft: cannot load client cert for consenter orderer.example.com:7050: open /home/cshiru/Fabric_Network/FabricNetwork-2.x/artifacts/channel/crypto-config/ordererOrganizations/example.com/orderers/orderer.example.com/tls/server.crt: no such file or directory

Error in orderer2 step_1

Hy,

First of all, this is very good guide! Thanks a lot!
I try to make this based on your repository, but when i try to fetch config to update orderer2 certificate, i can't fetch it.
I got an TLS handsake error.

root@hlf-workstation:~/FabricNetwork-2.x/artifacts/channel/create-certificate-with-ca/rotate-certs/step_1/orderer2$ ./add_tls_o2_sys_channel.sh 
2022-03-02 23:37:56.447 UTC 0001 ERRO [comm.tls] ClientHandshake -> Client TLS handshake failed after 1.570332ms with error: x509: certificate has expired or is not yet valid: current time 2022-01-28T15:37:56Z is before 2022-03-02T22:47:00Z remoteaddress=127.0.0.1:7050
2022-03-02 23:37:57.451 UTC 0002 ERRO [comm.tls] ClientHandshake -> Client TLS handshake failed after 1.509486ms with error: x509: certificate has expired or is not yet valid: current time 2022-01-28T15:37:57Z is before 2022-03-02T22:47:00Z remoteaddress=127.0.0.1:7050
2022-03-02 23:37:59.054 UTC 0003 ERRO [comm.tls] ClientHandshake -> Client TLS handshake failed after 1.11307ms with error: x509: certificate has expired or is not yet valid: current time 2022-01-28T15:37:59Z is before 2022-03-02T22:47:00Z remoteaddress=127.0.0.1:7050
Error: failed to create deliver client for orderer: orderer client failed to connect to localhost:7050: failed to create new connection: context deadline exceeded
## Encode Orderer2
....
----------------------------
root@hlf-workstation:~/FabricNetwork-2.x/artifacts/channel/create-certificate-with-ca/rotate-certs/step_1/orderer2$ date
Wed Mar  2 23:38:00 UTC 2022

The steps what i did:

  • turn off the ntp and set the date to 2022.01.05
  • create ca's
  • change configurations (720h)
  • Create Network participant certificates using CA
  • Create Channel Artifacts
  • Run all peer services(Persist data for each service)
  • Create Channel & Deploy Chaincode
  • Start API Server & invoke tx

Everythings is good, and then:

  • turn on the ntp
  • wait for the time sync
  • edit docker-compose for env variables (ORDERER_GENERAL_TLS_TLSHANDSHAKETIMESHIFT, ORDERER_GENERAL_CLUSTER_TLSHANDSHAKETIMESHIFT, ORDERER_GENERAL_AUTHENTICATION_NOEXPIRATIONCHECKS)
  • restart orderers
  • remove old msp directories from orderers and peers
  • copy new msp directories from new-certs to crypto-config (yes only the msp directories)
  • restart services
  • i can update the first orderer with the new tls certificate and can commit to sys-channel
  • i can update the application channel with first orderer certificate

All the changes what i do in your config is change 200h to 800h because this is an older date.

Error while creating channel

Hi! I am learning hlf by following your youtube videos. But I am getting error while creating channel. Steps to reproduce.

  1. git clone https://github.com/adhavpavan/FabricNetwork-2.x.git
  2. cd artifacts/channel/
  3. vi crypto-config.yaml
  4. Add the following at end of the file.
  - Name: Org3
    Domain: org3.example.com
    EnableNodeOUs: true

    Template:
      Count: 2
      # Start: 5
      # Hostname: {{.Prefix}}{{.Index}} # default
      SANS:
        - "localhost"

    Users:
      Count: 1
  1. ./create-artifacts.sh
  2. cd ..
  3. docker-compose -f docker-compose.yaml up -d
  4. cd ../..
  5. ./createChannel.sh
Getting the following error.
➜  FabricNetwork-2.x git:(main) ✗ ./createChannel.sh
2021-03-23 10:52:42.129 IST [channelCmd] InitCmdFactory -> INFO 001 Endorser and orderer connections initialized
Error: got unexpected status: BAD_REQUEST -- error validating channel creation transaction for new channel 'mychannel', could not successfully apply update to template configuration: error authorizing update: error validating DeltaSet: policy for [Group]  /Channel/Application not satisfied: implicit policy evaluation failed - 0 sub-
policies were satisfied, but this policy requires 1 of the 'Admins' sub-policies to be satisfied
2021-03-23 10:52:42.193 IST [channelCmd] InitCmdFactory -> INFO 001 Endorser and orderer connections initialized
Error: genesis block file not found open ./channel-artifacts/mychannel.block: no such file or directory
2021-03-23 10:52:42.238 IST [channelCmd] InitCmdFactory -> INFO 001 Endorser and orderer connections initialized
Error: genesis block file not found open ./channel-artifacts/mychannel.block: no such file or directory
2021-03-23 10:52:42.289 IST [channelCmd] InitCmdFactory -> INFO 001 Endorser and orderer connections initialized
Error: genesis block file not found open ./channel-artifacts/mychannel.block: no such file or directory
2021-03-23 10:52:42.331 IST [channelCmd] InitCmdFactory -> INFO 001 Endorser and orderer connections initialized
Error: got unexpected status: BAD_REQUEST -- Consortium config value missing
2021-03-23 10:52:42.381 IST [channelCmd] InitCmdFactory -> INFO 001 Endorser and orderer connections initialized
Error: got unexpected status: BAD_REQUEST -- Consortium config value missing
2021-03-23 10:52:42.432 IST [channelCmd] InitCmdFactory -> INFO 001 Endorser and orderer connections initialized
Error: got unexpected status: BAD_REQUEST -- Consortium config value missing
➜  FabricNetwork-2.x git:(main) ✗

Help me to fix this issue.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.