I'm working with private blockchain, and facing some issue with SSL configuration.

The system has two components:

  1. The private blockchain that is configured on the VM.
  2. The web application that initiating transactions.

There is the truffle config file of web app:

development: {
 host: "<serverIPAddress>",
 port: 8545,            
 network_id: "*",       

Provider configuration:

var web3 = require('web3');
web3 = new web3();

var provider = new web3.providers.HttpProvider(
        "http://" + truffleConfig.networks.development.host +
        ":" + truffleConfig.networks.development.port


Web application runs with HTTPS, and hence it gives an error when connection to the blockchain.

this request has been blocked the content must be served over https

If I use "https://" + truffleConfig.networks.development.host +, the error is


Is there any way we can fix this issue?

It is working if we run web app with http, but we need to run web app with ssl only.

  • How about using "https://"? – goodvibration Jul 8 '20 at 9:25
  • @goodvibration, question updated – Div Jul 8 '20 at 9:33

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.