Composer installer error on windows: OpenSSL failed with a 'certificate verify failed' error - ssl

I am setting up lando in my machine.
When I try to install composer, it throwing error as below.
The Composer installer script was not successful [exit code 1].
OpenSSL failed with a 'certificate verify failed' error. This indicates a problem with the Certificate Authority file(s) on your system, which may be out of date.
Certificate location [from SSL_CERT_FILE environment variable]:
C:\projects\cacert.pem
Script Output:
The "https://getcomposer.org/versions" file could not be downloaded: SSL operation failed with code 1. OpenSSL Error messages:
error:1416F086:SSL routines:tls_process_server_certificate:certificate verify failed
Failed to enable crypto
failed to open stream: operation failed
I downloaded the file from https://curl.haxx.se/docs/caextract.html and added file path to my php.ini file.
[curl]
curl.cainfo = "C:\projects\cacert.pem"
[openssl]
openssl.cafile= "C:\projects\cacert.pem"

Related

i am trying to run the command "pacman -Syu" on "msys2" and it doesn't work

I just installed the window64 version of msys2 and I try to update the package database and base packages running the "pacman -Syu" command.
I get this error :
$ pacman -Syu
:: Synchronizing package databases...
mingw32.db failed to download
mingw64.db failed to download
ucrt64.db failed to download
clang32.db failed to download
clang64.db failed to download
error: failed retrieving file 'mingw32.db' from mirror.msys2.org : SSL connection timeout
error: failed retrieving file 'mingw64.db' from mirror.msys2.org : SSL connection timeout
error: failed retrieving file 'ucrt64.db' from mirror.msys2.org : SSL connection timeout
warning: too many errors from mirror.msys2.org, skipping for the remainder of this transaction
error: failed retrieving file 'clang32.db' from mirror.msys2.org : SSL connection timeout
error: failed retrieving file 'clang64.db' from mirror.msys2.org : SSL connection timeout
error: failed retrieving file 'mingw32.db' from repo.msys2.org : SSL connection timeout
if anyone has an idea i would appreciate it.

Hyperledger Fabric error: "TLS: bad certificate server" when installing chaincode

I'm just starting learning HLF, and I have an error while following tutorial from the docs: link
I downloaded fabric-samples using this command (replaced bit.ly link with the destination):
curl -sSL https://raw.githubusercontent.com/hyperledger/fabric/master/scripts/bootstrap.sh | bash -s -- 2.2.2 1.4.9
I run logspout in one terminal and try to execute peer lifecycle chaincode install basic.tar.gz in another one, and this is the result i get
Error: failed to retrieve endorser client for install: endorser client
failed to connect to localhost:7051: failed to create new connection:
context deadline exceeded
Log presented by Logspout:
peer0.org1.example.com|2022-03-15 13:03:24.452 UTC [core.comm]
ServerHandshake -> ERRO 04a Server TLS handshake failed in 2.650245ms
with error remote error: tls: bad certificate server=PeerServer
remoteaddress=172.22.0.1:61126
I set the envs in terminal as instructed in the docs, and I checked that CORE_PEER_TLS_ROOTCERT_FILE variable points to an existing file. The content of the file is the same as on the container.
What I tried to do:
download fabric-samples again and redo all the setup with copy-pasting the commands directly from docs
Do you have any suggestions where I can look for an issue?
I resolved the problem, I was using peer version 2.2.1 from previous experiments, it probably collided with FABRIC_CFG_PATH

REACT-NATÄ°VE - jarsigner error: java.lang.RuntimeException: keystore load: Keystore was tampered with, or password was incorrect

I try to generate android apk for react-native project. However it gives me this error. How can I solve this ?
Execution failed for task ':app:packageReleaseBundle'.
> java.util.concurrent.ExecutionException: java.lang.RuntimeException: jarsigner.exefailed with exit code 1 :
jarsigner error: java.lang.RuntimeException: keystore load: Keystore was tampered with, or password was incorrect
I changed somethigs and now I am getting this error :
1 exception was raised by workers: java.lang.RuntimeException:
java.lang.RuntimeException: jarsigner.exefailed with exit code 1 :
jarsigner: key associated with my-key-alias not a private key
I deleted android/.gradle folder and run the command ./gradlew bundleRelease again. it works for me.
It seems you changed your upload keystore, so before building the bundle launch ./gradlew clean from android project app.

simplehtmldom - SSL operation failed with code 1. OpenSSL Error messages

I'm using http://simplehtmldom.sourceforge.net/ and file_get_contents() in my webApp. The file_get_contents() work fine on localhost. But when upload webApp on server(Windows server 2012 r2) i get this error. How to fix this error?
> Warning: file_get_contents(): SSL operation failed with code 1. OpenSSL Error messages: error:14090086:SSL routines:SSL3_GET_SERVER_CERTIFICATE:certificate verify failed in E:\cfnic.com\includes\class\PHP_Simple_HTML_DOM_Parser.php on line 75
Warning: file_get_contents(): Failed to enable crypto in E:\cfnic.com\includes\class\PHP_Simple_HTML_DOM_Parser.php on line 75
Warning: file_get_contents(https://www.markafoni.com/kadin/): failed to open stream: operation failed in E:\cfnic.com\includes\class\PHP_Simple_HTML_DOM_Parser.php on line 75
Fatal error: Call to a member function find() on boolean in E:\cfnic.com\includes\theme\category.php on line 159
You basically have to set the environment variable SSL_CERT_FILE to the path of the PEM file of the ssl-certificate downloaded from the following link : http://curl.haxx.se/ca/cacert.pem.
It took me a lot of time to figure this out.
For a detailed answer, you can have a look here: https://stackoverflow.com/questions/34590842/cannot-install-composer-on-mac-os-x/34617315

Error enabling SSL while installing cassandra(DataStax Community Edition)on Windows

My System : Windows 7 64-bit. While instaling Datastax Community Edition of cassandra,
As mentioned in the Prerequisites here :
http://www.datastax.com/documentation/gettingstarted/index.html#getting_started/gettingStartedWindows_t.html
I tried enabling SSL using instructions given here
http://www.datastax.com/docs/opscenter/configure/configure_ssl#config-ssl-win
but below is the error I get.
C:\>python "C:\Program Files\DataStax Community\opscenter\bin\setup.py"
File "C:\Program Files\DataStax Community\opscenter\bin\setup.py", line 51
print "Error when creating opscenter SSL files. Error was:\n"
^
SyntaxError: invalid syntax
What's wrong here?
What version of openssl did you install? That error is indicating the openssl command complained about a syntax error. OpsCenter specifically requires openssl 0.9.8 on windows.
http://www.datastax.com/docs/opscenter/configure/configure_ssl#enabling-ssl-windows
Edit the file create-file-pair.bat and set the variable OPENSSL_EXE to the path where your installation of OpenSSL is.