git clone to clone an item on GitHub or gitee, the following error is reported:
error setting certificate verify locations:
CAfile: E:/Git/mingw64/ssl/certs/ca-bundle. crt
According to the error prompt, there is an error in setting the certificate verification location, that is, the certificate file path is wrong.
When cloning a remote project, the security certificate will be verified first. If the local security certificate file cannot be found, an error will be reported.
This is why this error will not be reported when cloning projects on gitlab, because gitlab is generally built on the intranet and does not need to verify the security certificate.
Path errors often occur because the local Git is installed green, that is, it is directly extracted and used.
In this way, the path of the certificate file is still the path on the original machine. If the path of the new machine is inconsistent, the path error will be caused.
For the above analysis, there are two solutions:
- Modify certificate file path (recommended)
- Turn off certificate verification
Turning off certificate verification may cause security problems. It is recommended to modify the certificate file path.
Modify certificate file path
There are two ways:
- Execute the configuration command (recommended)
- Modify the configuration file
The essence of these two methods is to modify the configuration file. However, some misoperations may occur when modifying the file, and the operation is more cumbersome. It is recommended to execute the configuration command.
Execute configuration command
git config --system http.sslcainfo "Git安装路径/mingw64/ssl/certs/ca-bundle.crt"
Git’s system configuration files are located at:
git installation path \etc\gitconfig
Modify the path in the file as shown in the figure to
git installation path /mingw64/ssl/certs/ca-bundle.crt save again.
Turn off certificate verification
git config --system http.sslverify false
This method may cause git security problems and is not recommended.
- git submodule add Error: SSL certificate problem unable to get local issuer certificate
- [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed [Solved]
- Repo init Error: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed
- [Solved] Git Clone Error: The TLS connection was non-properly terminated.
- [Solved] Git Clone Error: error:1407742E:SSL routines:SSL23_GET_SERVER_HELLO:tlsv1 alert protocol version
- git clone,pod install error: RPC failed; curl 56 LibreSSL SSL_read: SSL_ERROR_SYSCALL, errno 54
- [Solved] svn Error: E230001: Server SSL certificate verification failed: certificate issued
- SVN Error:svn: E230001: Server SSL certificate verification failed: certificate issued
- [vite] http proxy error: Error: self signed certificate in certificate chain vite
- Gitlab Clone Error: next InitializeSecurityContext failed
- Mac IDEA Connect SVN Error: E230001: Server SSL certificate verification failed: certificate issued
- [Solved] fatal: not in a git directory Error: Command failed with exit 128: git
- Github Clone Error: RPC failed; result=56, HTTP code=200
- [Solved] pip is configured with locations that require TLS/SSL, however the ssl module in Python is not available
- Git pull and Git pull origin master Warning: Pulling without specifying how to reconcile divergent branches
- How to Solve pod Error: “Authentication token is invalid or unverified. Either verify it with the email that…”
- How to Solve Error: homebrew-core is a shallow clone.
- How to Fix Error Cannot find command ‘git‘ – do you have ‘git‘ installed and in your PATH?
- [Solved] Error response from daemon: Get “*“: x509: certificate signed by unknown authority
- [Solved] Android HTTPS request resource or interface error: server certificate