-
Notifications
You must be signed in to change notification settings - Fork 138
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
SSL_CACERT Error: Peer certificate cannot be authenticated with known CA certificates #155
Comments
ProblemRunning the command Reproductionrequire 'net/http'
require 'pp'
require 'ethon'
file_remote_url = "https://wtfismyip.com/text"
puts "trying with net/http:"
puts Net::HTTP.get(URI(file_remote_url))
puts "trying with Ethon:"
easy = Ethon::Easy.new(url: file_remote_url)
if easy.perform == :ok
puts easy.response_body
else
pp easy
end Output
Versions
InvestigationIt appears that
Notably, using SolutionIt seems sudo rm /usr/local/lib/libcurl*
brew install curl |
ssl_cacert error
I get
ssl_cacert
error -> Peer certificate cannot be authenticated with known CA certificatesSteps to Reproduce
Ruby: 2.6.0
Rails: 5.2.2
Windows 10 [Version 10.0.17134.590]
rails new myapp
hello
controller usingrails g controller hello
and added contentindex.html.erb
file inviews
with contentWhat I also tried
Tried the same with Faraday and did not get any errors: See the commented code in the controller. I had to change
@response.response_body
to@response.body
in the views. Linkedin page was rendered.But with
ethon
, I getssl_cacert
.The text was updated successfully, but these errors were encountered: