File tree Expand file tree Collapse file tree 4 files changed +13
-5
lines changed
main/java/org/fisco/bcos/sdk/v3/config/model Expand file tree Collapse file tree 4 files changed +13
-5
lines changed Original file line number Diff line number Diff line change @@ -52,11 +52,19 @@ public CryptoMaterialConfig(ConfigProperty configProperty) throws ConfigExceptio
5252
5353 Map <String , Object > cryptoMaterialProperty = configProperty .getCryptoMaterial ();
5454 String useSMCrypto = (String ) cryptoMaterialProperty .get ("useSMCrypto" );
55- String disableSsl = (String ) cryptoMaterialProperty .get ("disableSsl" );
55+ Object disableSsl = cryptoMaterialProperty .get ("disableSsl" );
56+ Object enableSsl = cryptoMaterialProperty .get ("enableSsl" );
5657 String enableHsm = (String ) cryptoMaterialProperty .get ("enableHsm" );
5758
5859 this .useSmCrypto = Boolean .valueOf (useSMCrypto );
59- this .disableSsl = Boolean .valueOf (disableSsl );
60+ if (disableSsl != null ) {
61+ this .disableSsl = Boolean .parseBoolean ((String ) disableSsl );
62+ }
63+ if (enableSsl != null ) {
64+ // if enableSsl is set, disableSsl will be ignored
65+ this .disableSsl = !Boolean .parseBoolean ((String ) enableSsl );
66+ }
67+
6068 this .enableHsm = Boolean .valueOf (enableHsm );
6169
6270 if (this .enableHsm ) {
Original file line number Diff line number Diff line change 99 <map >
1010 <entry key =" certPath" value =" conf" />
1111 <entry key =" useSMCrypto" value =" false" />
12- <entry key =" disableSsl " value =" false " />
12+ <entry key =" enableSsl " value =" true " />
1313 <!-- SSL certificate configuration -->
1414 <!-- entry key="caCert" value="conf/ca.crt" /-->
1515 <!-- entry key="sslCert" value="conf/sdk.crt" /-->
Original file line number Diff line number Diff line change 22
33certPath = " conf" # The certification path
44useSMCrypto = " false"
5- disableSsl = " false " # Communication with nodes without SSL
5+ enableSsl = " true " # Communication with nodes without SSL
66
77# The following configurations take the certPath by default if commented
88# caCert = "conf/ca.crt" # CA cert file path
Original file line number Diff line number Diff line change 22
33certPath = " conf" # The certification path
44useSMCrypto = " false"
5- disableSsl = " false " # Communication with nodes without SSL
5+ enableSsl = " true " # Communication with nodes without SSL
66
77# The following configurations take the certPath by default if commented
88# caCert = "conf/ca.crt" # CA cert file path
You can’t perform that action at this time.
0 commit comments