How do I deal with certificates using cURL while trying to access an HTTPS url? - Stack Overflow (https://cdn.sstatic.net/Sites/stackoverflow/Img/favicon.ico?v=ec617d715196) (https://cdn.sstatic.net/Sites/stackoverflow/Img/apple-touch-icon.png?v=c78bd457575a) (https://cdn.sstatic.net/Sites/stackoverflow/Img/apple-touch-icon.png?v=c78bd457575a) (Stack Overflow) (/opensearch.xml) (https://stackoverflow.com/questions/3160909/how-do-i-deal-with-certificates-using-curl-while-trying-to-access-an-https-url) (https://cdn.sstatic.net/Shared/stacks.css?v=d6a266655a25) (https://cdn.sstatic.net/Sites/stackoverflow/primary.css?v=22fb2cb11723) (Feed for question 'How do I deal with certificates using cURL while trying to access an HTTPS url?') (/feeds/question/3160909) (https://cdn.sstatic.net/Shared/Channels/channels.css?v=5981bb1a5bd7) (https://accounts.google.com/gsi/style) (site logo) Join Stack Overflow By clicking “Sign up”, you agree to our (/legal/terms-of-service/public) terms of service and acknowledge you have read our (/legal/privacy-policy) privacy policy . (59e99b481907aca79504282706e4b1db65c79b5bb11a4cbc1d88997106647265) (1) (2.0) Sign up with Google Sign up with GitHub OR (59e99b481907aca79504282706e4b1db65c79b5bb11a4cbc1d88997106647265) (1) () () () () () () Email Password (8+ characters (at least 1 letter & 1 number)) Sign up Already have an account? (/users/login) Log in (59e99b481907aca79504282706e4b1db65c79b5bb11a4cbc1d88997106647265) () Skip to main content (https://stackoverflow.com) Stack Overflow (https://stackoverflow.co/) About Products (https://stackoverflow.co/teams/ai/?utm_medium=referral&utm_source=stackoverflow-community&utm_campaign=top-nav-bar&utm_content=overflowai) OverflowAI (https://stackoverflow.co/teams/?utm_medium=referral&utm_source=stackoverflow-community&utm_campaign=top-nav&utm_content=stack-overflow-for-teams) Stack Overflow for Teams Where developers & technologists share private knowledge with coworkers (https://stackoverflow.co/advertising/?utm_medium=referral&utm_source=stackoverflow-community&utm_campaign=top-nav&utm_content=stack-overflow-advertising) Advertising & Talent Reach devs & technologists worldwide about your product, service or employer brand (https://stackoverflow.co/teams/ai/?utm_medium=referral&utm_source=stackoverflow-community&utm_campaign=top-nav&utm_content=overflow-ai) OverflowAI GenAI features for Teams (https://stackoverflow.co/api-solutions/?utm_medium=referral&utm_source=stackoverflow-community&utm_campaign=top-nav&utm_content=overflow-api) OverflowAPI Train & fine-tune LLMs (https://stackoverflow.co/labs/?utm_medium=referral&utm_source=stackoverflow-community&utm_campaign=top-nav&utm_content=labs) Labs The future of collective knowledge sharing (https://stackoverflow.co/?utm_medium=referral&utm_source=stackoverflow-community&utm_campaign=top-nav&utm_content=about-the-company) About the company (https://stackoverflow.blog/?utm_medium=referral&utm_source=stackoverflow-community&utm_campaign=top-nav&utm_content=blog) Visit the blog (Search…) () Loading… (https://stackoverflow.com) current community (https://stackoverflow.com) (Stack Overflow) Stack Overflow (https://stackoverflow.com/help) help (https://chat.stackoverflow.com/?tab=site&host=stackoverflow.com) chat (https://meta.stackoverflow.com) (Meta Stack Overflow) Meta Stack Overflow your communities (https://stackoverflow.com/users/signup?ssrc=site_switcher&returnurl=https%3a%2f%2fstackoverflow.com%2fquestions%2f3160909%2fhow-do-i-deal-with-certificates-using-curl-while-trying-to-access-an-https-url) Sign up or (https://stackoverflow.com/users/login?ssrc=site_switcher&returnurl=https%3a%2f%2fstackoverflow.com%2fquestions%2f3160909%2fhow-do-i-deal-with-certificates-using-curl-while-trying-to-access-an-https-url) log in to customize your list. (https://stackexchange.com/sites) more stack exchange communities (https://stackoverflow.blog) company blog (Click to show search) (https://stackoverflow.com/users/login?ssrc=head&returnurl=https%3a%2f%2fstackoverflow.com%2fquestions%2f3160909%2fhow-do-i-deal-with-certificates-using-curl-while-trying-to-access-an-https-url) Log in (https://stackoverflow.com/users/signup?ssrc=head&returnurl=https%3a%2f%2fstackoverflow.com%2fquestions%2f3160909%2fhow-do-i-deal-with-certificates-using-curl-while-trying-to-access-an-https-url) Sign up Let's set up your homepage Select a few topics you're interested in: python javascript c# reactjs java android html flutter c++ node.js typescript css r php angular next.js spring-boot machine-learning sql excel ios azure docker Or search from our full list: (Search) javascript python java c# php android html jquery c++ css ios sql mysql r reactjs node.js arrays c asp.net json python-3.x .net ruby-on-rails sql-server swift django angular objective-c excel pandas angularjs regex typescript ruby linux ajax iphone vba xml laravel spring asp.net-mvc database wordpress string flutter postgresql mongodb wpf windows amazon-web-services xcode bash git oracle-database spring-boot dataframe azure firebase list multithreading docker vb.net react-native eclipse algorithm powershell macos visual-studio numpy image forms scala function vue.js performance twitter-bootstrap selenium winforms kotlin loops express dart hibernate sqlite matlab python-2.7 shell rest apache entity-framework android-studio csv maven api linq qt dictionary unit-testing asp.net-core facebook tensorflow apache-spark file swing class unity-game-engine sorting date authentication go symfony t-sql opencv matplotlib .htaccess google-chrome for-loop datetime codeigniter http perl validation sockets google-maps object uitableview xaml oop if-statement visual-studio-code cordova ubuntu web-services email android-layout github spring-mvc elasticsearch kubernetes selenium-webdriver ms-access user-interface parsing ggplot2 pointers google-sheets machine-learning c++11 security google-apps-script flask ruby-on-rails-3 templates nginx variables exception sql-server-2008 gradle debugging tkinter listview delphi jpa asynchronous pdf web-scraping haskell jsp ssl amazon-s3 google-cloud-platform jenkins testing xamarin wcf npm batch-file generics ionic-framework network-programming unix recursion google-app-engine mongoose visual-studio-2010 .net-core android-fragments assembly animation math next.js session svg hadoop intellij-idea curl django-models join rust winapi laravel-5 url heroku http-redirect tomcat google-cloud-firestore inheritance webpack keras image-processing gcc asp.net-mvc-4 logging dom web swiftui matrix pyspark actionscript-3 button post optimization firebase-realtime-database jquery-ui iis cocoa xpath d3.js javafx firefox internet-explorer xslt caching select asp.net-mvc-3 opengl events asp.net-web-api plot dplyr magento encryption search stored-procedures amazon-ec2 ruby-on-rails-4 memory audio canvas multidimensional-array jsf random vector cookies redux input facebook-graph-api flash xamarin.forms indexing arraylist ipad cocoa-touch data-structures video apache-kafka model-view-controller serialization jdbc woocommerce azure-devops routes razor awk servlets mod-rewrite beautifulsoup docker-compose excel-formula filter iframe aws-lambda design-patterns text django-rest-framework visual-c++ cakephp mobile android-intent react-hooks struct methods groovy mvvm ssh lambda checkbox ecmascript-6 google-chrome-extension time grails installation sharepoint cmake shiny spring-security jakarta-ee android-recyclerview plsql core-data types meteor android-activity sed bootstrap-4 websocket activerecord graph replace scikit-learn file-upload group-by vim junit boost deep-learning import sass memory-management error-handling async-await eloquent dynamic soap silverlight dependency-injection charts layout apache-spark-sql deployment browser gridview svn while-loop google-bigquery vuejs2 ffmpeg dll highcharts view foreach plugins makefile c#-4.0 redis reporting-services jupyter-notebook merge server unicode https reflection google-maps-api-3 twitter oauth-2.0 extjs pytorch axios terminal pip split mysqli cmd encoding django-views automation database-design collections hash netbeans build data-binding ember.js tcp sqlalchemy pdo apache-flex concurrency entity-framework-core command-line spring-data-jpa printing react-redux java-8 jestjs service html-table lua neo4j ansible material-ui parameters module enums visual-studio-2012 flexbox promise outlook webview firebase-authentication web-applications uwp jquery-mobile utf-8 datatable python-requests parallel-processing drop-down-menu colors scroll hive scipy tfs count syntax ms-word twitter-bootstrap-3 ssis google-analytics fonts three.js powerbi rxjs constructor graphql file-io paypal discord cassandra socket.io graphics compiler-errors gwt react-router nlp solr url-rewriting backbone.js memory-leaks datatables oauth terraform datagridview drupal oracle11g zend-framework neural-network knockout.js triggers django-forms interface angular-material google-api casting jmeter linked-list path proxy timer django-templates arduino orm directory visual-studio-2015 parse-platform windows-phone-7 cron push-notification conditional-statements primefaces functional-programming pagination model jar xamarin.android hyperlink uiview gitlab visual-studio-2013 vbscript google-cloud-functions azure-active-directory jwt download swift3 sql-server-2005 configuration process pygame rspec properties combobox callback windows-phone-8 linux-kernel safari permissions scrapy raspberry-pi scripting emacs clojure x86 scope io compilation mongodb-query nhibernate responsive-design expo angularjs-directive azure-functions request bluetooth dns 3d binding reference discord.js architecture playframework pyqt version-control doctrine-orm package get sql-server-2012 rubygems f# autocomplete openssl datepicker kendo-ui tree jackson pycharm controller yii nested grep xamarin.ios static dockerfile statistics transactions datagrid null active-directory uiviewcontroller webforms phpmyadmin discord.py notifications computer-vision sas duplicates mocking youtube nullpointerexception yaml menu sum bitmap blazor asp.net-mvc-5 electron visual-studio-2008 time-series yii2 jsf-2 css-selectors stl android-listview floating-point cryptography ant stream hashmap character-encoding msbuild sdk asp.net-core-mvc google-drive-api selenium-chromedriver jboss joomla cors navigation devise anaconda background camera multiprocessing pyqt5 binary cuda frontend linq-to-sql iterator mariadb onclick plotly ios7 rabbitmq android-jetpack-compose android-asynctask microsoft-graph-api tabs insert laravel-4 uicollectionview environment-variables amazon-dynamodb linker console xsd coldfusion upload continuous-integration ftp textview opengl-es operating-system vuejs3 mockito localization macros formatting xml-parsing json.net kivy type-conversion data.table timestamp calendar integer segmentation-fault android-ndk drag-and-drop prolog char crash jasmine automated-tests dependencies geometry android-gradle-plugin itext firebase-cloud-messaging header fortran sprite-kit mfc attributes nuxt.js nosql format azure-pipelines nestjs odoo db2 jquery-plugins jenkins-pipeline leaflet event-handling flutter-layout julia postman annotations keyboard textbox arm visual-studio-2017 gulp libgdx stripe-payments xampp synchronization crystal-reports timezone dom-events uikit azure-web-app-service android-emulator swagger wso2 sequelize.js namespaces aggregation-framework uiscrollview jvm google-sheets-formula chart.js com subprocess geolocation centos webdriver snowflake-cloud-data-platform html5-canvas garbage-collection widget dialog numbers concatenation sql-update qml set windows-10 tuples mapreduce smtp java-stream ionic2 rotation modal-dialog spring-data android-edittext http-headers nuget doctrine radio-button sonarqube grid lucene xmlhttprequest internationalization listbox initialization switch-statement components google-play apache-camel boolean serial-port ldap ios5 youtube-api return gdb pivot latex eclipse-plugin frameworks tags containers github-actions dataset asp-classic label foreign-keys subquery c++17 copy uinavigationcontroller delegates google-cloud-storage migration struts2 base64 protractor sql-server-2008-r2 find embedded queue uibutton arguments composer-php append jaxb zip stack cucumber autolayout ide entity-framework-6 popup iteration airflow tailwind-css windows-7 r-markdown ssl-certificate vb6 gmail hover jqgrid g++ udp Next You’ll be prompted to create an account to view your personalized homepage. (/) Home (/questions) Questions (/tags) Tags (/beta/discussions) Discussions Labs (https://chat.stackoverflow.com/?tab=all&sort=active) Chat (/users) Users (/jobs?source=so-left-nav) Jobs (https://stackoverflow.com/jobs/companies?so_medium=stackoverflow&so_source=SiteNav) Companies Collectives Communities for your favorite technologies. (/collectives-all) Explore all Collectives Teams () Ask questions, find answers and collaborate at work with Stack Overflow for Teams. (https://stackoverflowteams.com/teams/create/free/?utm_medium=referral&utm_source=stackoverflow-community&utm_campaign=side-bar&utm_content=explore-teams) Try Teams for free (https://stackoverflow.co/teams/?utm_medium=referral&utm_source=stackoverflow-community&utm_campaign=side-bar&utm_content=explore-teams) Explore Teams Teams Ask questions, find answers and collaborate at work with Stack Overflow for Teams. (https://stackoverflow.co/teams/?utm_medium=referral&utm_source=stackoverflow-community&utm_campaign=side-bar&utm_content=explore-teams-compact) Explore Teams Collectives™ on Stack Overflow Find centralized, trusted content and collaborate around the technologies you use most. (/collectives) Learn more about Collectives Teams Q&A for work Connect and share knowledge within a single location that is structured and easy to search. (https://stackoverflow.co/teams/) Learn more about Teams (Illustration of upvote icon after it is clicked) Hang on, you can't downvote just yet. You'll need to complete a few actions and gain 125 reputation points before being able to downvote. Casting downvotes indicate issues with quality, effort, or accuracay of a post. (https://stackoverflow.com/help/whats-reputation) What's reputation and how do I get it? Instead, you can try suggesting an edit to improve the post. Suggest edit No thanks (https://cdn.sstatic.net/Sites/stackoverflow/Img/apple-touch-icon.png?v=c78bd457575a) (/questions/3160909/how-do-i-deal-with-certificates-using-curl-while-trying-to-access-an-https-url) How do I deal with certificates using cURL while trying to access an HTTPS url? (/questions/ask) Ask Question (2010-07-01 19:08:32Z) Asked 14 years, 9 months ago Modified (?lastactivity) (2024-07-24 19:27:46Z) 8 months ago (Viewed 444,444 times) Viewed 444k times This question shows research effort; it is useful and clear (69:3:31e,16:3d374f568e0c9cb5,10:1743964024,16:28f2cbbf87394bd3,7:3160909,dea3d4479839065f0c012135d1223d5e36a2dbd423624a40d46244c35d28e912) 292 (This question does not show any research effort; it is unclear or not useful) (69:3:31e,16:335666a757356925,10:1743964024,16:2379390046a226be,7:3160909,964854f1f8b189726e86300733789ffd3dcf5a6101813641e1fd1b44d631d4e1) Save this question. (/posts/3160909/timeline) Show activity on this post. I am getting the following error using curl: curl: (77) error setting certificate verify locations: CAfile: /etc/ssl/certs/ca-certificates.crt CApath: none How do I set this certificate verify locations? (/questions/tagged/curl) (show questions tagged 'curl') curl (/questions/tagged/https) (show questions tagged 'https') https (/q/3160909) (Short permalink to this question) Share Share a link to this question Copy link (https://creativecommons.org/licenses/by-sa/4.0/) (The current license for this post: CC BY-SA 4.0) CC BY-SA 4.0 (/posts/3160909/edit) () Improve this question Follow (69:3:31e,16:7c77147329adb4cc,10:1743964024,16:b8e99abbb331f07d,7:3160909,5afc39e98baf04ca1731781385a81d8844e2d8926b15eb393bb290b3e04df6c8) Follow this question to receive notifications (/posts/3160909/revisions) (show all edits to this post) edited (2021-11-02 07:41:18Z) Nov 2, 2021 at 7:41 (/users/12892553/nimantha) (Nimantha's user avatar) (/users/12892553/nimantha) Nimantha (reputation score) 6,484 (6 gold badges) 6 6 gold badges (31 silver badges) 31 31 silver badges (76 bronze badges) 76 76 bronze badges asked (2010-07-01 19:08:32Z) Jul 1, 2010 at 19:08 (/users/439619/moorecats) (moorecats's user avatar) (/users/439619/moorecats) moorecats moorecats (reputation score) 3,492 (4 gold badges) 4 4 gold badges (22 silver badges) 22 22 silver badges (23 bronze badges) 23 23 bronze badges 6 (number of 'useful comment' votes received) 2 What OS/distro are you on? You should install the ca-certificates package (that's what it's called on debian/ubuntu). – (/users/289985/igorw) (28,289 reputation) igorw Commented (2010-07-01 19:34:52Z, License: CC BY-SA 2.5) Jul 1, 2010 at 19:34 (number of 'useful comment' votes received) 50 For future reference, I had already ca-certificates installed but the error persisted. The problem was that my certificates were located in /etc/ssl/certs/ca-certificates.crt instead of /etc/pki/tls/certs/ca-bundle.crt , so I just had to set the environmental variable CURL_CA_BUNDLE to the correct path. – (/users/460147/r-31415) (8,982 reputation) r_31415 Commented (2014-12-11 04:28:33Z, License: CC BY-SA 3.0) Dec 11, 2014 at 4:28 (this comment was edited 1 time) (number of 'useful comment' votes received) 17 Cool! It works for me when I set export CURL_CA_BUNDLE=/etc/ssl/certs/ca-certificates.crt . – (/users/988709/tidy) (5,097 reputation) tidy Commented (2016-03-18 07:06:56Z, License: CC BY-SA 3.0) Mar 18, 2016 at 7:06 (this comment was edited 1 time) and where do you change this variable? In what file? – (/users/322537/john-jones) (7,780 reputation) john-jones Commented (2023-11-29 10:46:05Z, License: CC BY-SA 4.0) Nov 29, 2023 at 10:46 hit this when pycurl==7.45.3 was released in pypi in debian bullseye (docker image python:3.8-slim-bullseye) with ca-certificates installed – (/users/925125/bigbear3001) (544 reputation) bigbear3001 Commented (2024-02-26 08:23:38Z, License: CC BY-SA 4.0) Feb 26, 2024 at 8:23 (Use comments to ask for more information or suggest improvements. Avoid answering questions in comments.) | (Expand to show all comments on this post) Show 1 more comment 26 Answers 26 Sorted by: (/questions/3160909/how-do-i-deal-with-certificates-using-curl-while-trying-to-access-an-https-url?answertab=scoredesc#tab-top) Reset to default (scoredesc) Highest score (default) (trending) Trending (recent votes count more) (modifieddesc) Date modified (newest first) (createdasc) Date created (oldest first) This answer is useful (70:3:31e,16:c6c6204ec4871896,10:1743964024,16:27eb0a985c19c7fb,8:30154802,dbbb4752c9ef6bda3279ee84142c33c2ad9ae38a474f389cb095019984713d06) 173 (This answer is not useful) (70:3:31e,16:e058f260821836d9,10:1743964024,16:528354b26b6ba7ef,8:30154802,982dbc5210d84cc2f86f9d426722fa6e0df0bfce1985b9706de3719ffbee755d) Save this answer. (Loading when this answer was accepted…) (/posts/30154802/timeline) Show activity on this post. I also had the newest version of ca-certificates installed but was still getting the error: curl: (77) error setting certificate verify locations: CAfile: /etc/pki/tls/certs/ca-bundle.crt CApath: none The issue was that curl expected the certificate to be at the path /etc/pki/tls/certs/ca-bundle.crt but could not find it because it was at the path /etc/ssl/certs/ca-certificates.crt . Copying my certificate to the expected destination by running sudo cp /etc/ssl/certs/ca-certificates.crt /etc/pki/tls/certs/ca-bundle.crt worked for me. You will need to create folders for the target destination if they do not exist by running sudo mkdir -p /etc/pki/tls/certs If needed, modify the above command to make the destination file name match the path expected by curl, i.e. replace /etc/pki/tls/certs/ca-bundle.crt with the path following "CAfile:" in your error message. (/a/30154802) (Short permalink to this answer) Share Share a link to this answer Copy link (https://creativecommons.org/licenses/by-sa/3.0/) (The current license for this post: CC BY-SA 3.0) CC BY-SA 3.0 (/posts/30154802/edit) () Improve this answer Follow (70:3:31e,16:11fd242e3771466e,10:1743964024,16:78d543c08df8c89b,8:30154802,c775151dacbbae65b3daf1ea5ffc6d43e1056abec049c5aa2f41c4bc3732929c) Follow this answer to receive notifications (/posts/30154802/revisions) (show all edits to this post) edited (2015-05-20 13:53:32Z) May 20, 2015 at 13:53 (/users/1712419/nicolas-ivanov) (Nicolas Ivanov's user avatar) (/users/1712419/nicolas-ivanov) Nicolas Ivanov (reputation score) 838 (10 silver badges) 10 10 silver badges (15 bronze badges) 15 15 bronze badges answered (2015-05-10 18:02:29Z) May 10, 2015 at 18:02 (/users/3025865/scott-emmons) (Scott Emmons's user avatar) (/users/3025865/scott-emmons) Scott Emmons Scott Emmons (reputation score) 1,891 (3 gold badges) 3 3 gold badges (13 silver badges) 13 13 silver badges (9 bronze badges) 9 9 bronze badges 3 (number of 'useful comment' votes received) 41 You could also create a symbolic link with ln -s if don't want to re-copy it every time you update it. – (/users/1460422/starbeamrainbowlabs) (6,166 reputation) starbeamrainbowlabs Commented (2015-08-28 08:41:37Z, License: CC BY-SA 3.0) Aug 28, 2015 at 8:41 (number of 'useful comment' votes received) 4 Had same problem for rescuetime app on Fedora 25. sudo ln -s /etc/pki/tls/certs/ca-bundle.crt /etc/pki/tls/certs/ca-certificates.crt solved the problem. (CURL_CA_BUNDLE env var didn't work) – (/users/1092815/gableroux) (18,003 reputation) GabLeRoux Commented (2017-02-14 03:33:45Z, License: CC BY-SA 3.0) Feb 14, 2017 at 3:33 On my ubuntu this fixed the issue: sudo ln -s /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/ca-certificates.pem . I was actually getting The repository ... does not have a Release file which was caused by missing certificate ( Could not load certificates from ... ). – (/users/1555615/marinos-an) (10,970 reputation) Marinos An Commented (2019-10-01 10:02:20Z, License: CC BY-SA 4.0) Oct 1, 2019 at 10:02 (Use comments to ask for more information or suggest improvements. Avoid comments like “+1” or “thanks”.) Add a comment | (Expand to show all comments on this post) This answer is useful (70:3:31e,16:eaed9f4c285315a6,10:1743964024,16:5a0e7a40062ef930,8:13400988,5149856b2456c5ef112e53771a1b8baeaeb6fc91d62bc56dbf26894a0b961151) 161 (This answer is not useful) (70:3:31e,16:975bcca3fdf7e2b8,10:1743964024,16:be7236cdf64a4b28,8:13400988,4de126559b44f20b549e68418f6d25abbf313da3e22b3b8cdb30ae37ad03b0b4) Save this answer. (Loading when this answer was accepted…) (/posts/13400988/timeline) Show activity on this post. This error is related to a missing package : ca-certificates . Install it. In Ubuntu Linux (and similar distro): # apt-get install ca-certificates In CygWin via (https://github.com/cfg/apt-cyg) Apt-Cyg # apt-cyg install ca-certificates In Arch Linux (Raspberry Pi) # pacman -S ca-certificates The documentation tells: This package includes PEM files of CA certificates to allow SSL-based applications to check for the authenticity of SSL connections. As seen at: (http://packages.debian.org/squeeze/ca-certificates) Debian -- Details of package ca-certificates in squeeze (/a/13400988) (Short permalink to this answer) Share Share a link to this answer Copy link (https://creativecommons.org/licenses/by-sa/3.0/) (The current license for this post: CC BY-SA 3.0) CC BY-SA 3.0 (/posts/13400988/edit) () Improve this answer Follow (70:3:31e,16:8e6394de2b4e927b,10:1743964024,16:dd82720f2b45dee6,8:13400988,2a853f29de5bf8895e42f23e0e78888d0701e87dfcbee976d1ab5e1422496229) Follow this answer to receive notifications (/posts/13400988/revisions) (show all edits to this post) edited (2017-02-14 18:09:21Z) Feb 14, 2017 at 18:09 (/users/1420197/ionic%c4%83-biz%c4%83u) (Ionică Bizău's user avatar) (/users/1420197/ionic%c4%83-biz%c4%83u) Ionică Bizău (reputation score 113,699) 114k (94 gold badges) 94 94 gold badges (310 silver badges) 310 310 silver badges (487 bronze badges) 487 487 bronze badges answered (2012-11-15 15:41:59Z) Nov 15, 2012 at 15:41 (/users/439427/rubens-mariuzzo) (Rubens Mariuzzo's user avatar) (/users/439427/rubens-mariuzzo) Rubens Mariuzzo Rubens Mariuzzo (reputation score 29,261) 29.3k (27 gold badges) 27 27 gold badges (123 silver badges) 123 123 silver badges (149 bronze badges) 149 149 bronze badges 12 (number of 'useful comment' votes received) 128 ca-certificates is already the newest version, yet I'm still getting the error – (/users/1053335/pastor-bones) (7,381 reputation) Pastor Bones Commented (2013-01-10 17:09:59Z, License: CC BY-SA 3.0) Jan 10, 2013 at 17:09 (number of 'useful comment' votes received) 2 Of course, you'll get this same error if you try to install apt-cyg via the recommended method using curl and (https://raw.github.com) raw.github.com . – (/users/1678427/10gistic) (565 reputation) 10gistic Commented (2013-06-23 22:26:09Z, License: CC BY-SA 3.0) Jun 23, 2013 at 22:26 (number of 'useful comment' votes received) 11 On Arch Linux, you might also need pacman -S ca-certificates-utils . I did. – (/users/13233/mark-grimes) (567 reputation) Mark Grimes Commented (2016-09-08 20:23:25Z, License: CC BY-SA 3.0) Sep 8, 2016 at 20:23 (number of 'useful comment' votes received) 14 This package is already installed. This answer is not helpful. – (/users/1708543/jimmyjames-supports-canada) (1,463 reputation) JimmyJames supports Canada Commented (2017-06-09 20:12:39Z, License: CC BY-SA 3.0) Jun 9, 2017 at 20:12 (number of 'useful comment' votes received) 30 @PastorBones I had the same issue that the package was already latest, I think it had however been corrupted so a sudo apt install --reinstall ca-certificates reinstalled the package and resolved the errors I was seeing – (/users/803976/will) (1,573 reputation) Will Commented (2018-08-05 09:40:32Z, License: CC BY-SA 4.0) Aug 5, 2018 at 9:40 (Use comments to ask for more information or suggest improvements. Avoid comments like “+1” or “thanks”.) | (Expand to show all comments on this post) Show 7 more comments This answer is useful (70:3:31e,16:4835957f71f2c4a5,10:1743964024,16:7b6bdaeeb73f71e0,8:31060428,3e8109ca1e7bb996c61a43bc3224d7396c48c4d09f1d134dfc876710c9637dc7) 114 (This answer is not useful) (70:3:31e,16:859c2cf6b99eba4b,10:1743964024,16:0695bdb9839dda16,8:31060428,ac00b4b3799a2e7f1fbddcb16c3b5710f618af2bea9be25a3936713f5a1caa17) Save this answer. (Loading when this answer was accepted…) (/posts/31060428/timeline) Show activity on this post. Put this into your .bashrc # fix CURL certificates path export CURL_CA_BUNDLE=/etc/ssl/certs/ca-certificates.crt (see comment from Robert) (/a/31060428) (Short permalink to this answer) Share Share a link to this answer Copy link (https://creativecommons.org/licenses/by-sa/3.0/) (The current license for this post: CC BY-SA 3.0) CC BY-SA 3.0 (/posts/31060428/edit) () Improve this answer Follow (70:3:31e,16:f2b09fd3d1b8bfcd,10:1743964024,16:36b61dd4e14f0856,8:31060428,f2707fc8800ba7a498cab5e95d80bed96924bfa77bcae536d6dc470e0c9caab6) Follow this answer to receive notifications answered (2015-06-25 20:43:20Z) Jun 25, 2015 at 20:43 (/users/544463/yauhen-yakimovich) (Yauhen Yakimovich's user avatar) (/users/544463/yauhen-yakimovich) Yauhen Yakimovich Yauhen Yakimovich (reputation score 14,241) 14.2k (8 gold badges) 8 8 gold badges (62 silver badges) 62 62 silver badges (68 bronze badges) 68 68 bronze badges 6 (number of 'useful comment' votes received) 12 Thank you for providing a method that doesn't require me to muck up system files by hand, but still keeps the security of using certificates! – (/users/5063/stephen-johnson) (467 reputation) Stephen Johnson Commented (2015-08-07 20:44:23Z, License: CC BY-SA 3.0) Aug 7, 2015 at 20:44 Thank you. This solved my similar problem with pyenv & curl. I was using Ubuntu 14.04 and already had ca-certificates installed. – (/users/143397/davida) (13,724 reputation) davidA Commented (2016-07-12 00:18:40Z, License: CC BY-SA 3.0) Jul 12, 2016 at 0:18 This approach also works with xonsh (add $CURL_CA_BUNDLE = "/etc/ssl/certs/ca-certificates.crt" to the .xonshrc ). – (/users/2862719/m00am) (6,298 reputation) m00am Commented (2017-11-27 08:45:21Z, License: CC BY-SA 3.0) Nov 27, 2017 at 8:45 (number of 'useful comment' votes received) 1 Just in case: The one liner version of this: CURL_CA_BUNDLE=/path/to/bundle.crt curl http://example.com – (/users/730326/jmathew) (1,566 reputation) jmathew Commented (2018-01-09 04:29:44Z, License: CC BY-SA 3.0) Jan 9, 2018 at 4:29 This was a life-saver. Curl kept looking for certificates at a path that didn't exist on my system - specifically {USER}/Desktop/src/master/cert.ca. I have no idea where it got that from. This single export solved everything. – (/users/8480863/brugia) (483 reputation) brugia Commented (2024-02-24 13:37:17Z, License: CC BY-SA 4.0) Feb 24, 2024 at 13:37 (Use comments to ask for more information or suggest improvements. Avoid comments like “+1” or “thanks”.) | (Expand to show all comments on this post) Show 1 more comment This answer is useful (70:3:31e,16:647b57b55065b6c8,10:1743964024,16:eee877c62b83d7d2,8:31424970,add321ac941d855836b1ffb5f520fdc559fa2f0e9375bb37fd3cadcd581c9561) 38 (This answer is not useful) (70:3:31e,16:f26ca04069f9c562,10:1743964024,16:b993ecda53deb1f7,8:31424970,bdc95b35c52a509cc6dc759d238e6f28878a24de050228e28fe37c8a958c5e5a) Save this answer. (Loading when this answer was accepted…) (/posts/31424970/timeline) Show activity on this post. Create a file ~/.curlrc with the following content cacert=/etc/ssl/certs/ca-certificates.crt as follows echo "cacert=/etc/ssl/certs/ca-certificates.crt" >> ~/.curlrc (/a/31424970) (Short permalink to this answer) Share Share a link to this answer Copy link (https://creativecommons.org/licenses/by-sa/4.0/) (The current license for this post: CC BY-SA 4.0) CC BY-SA 4.0 (/posts/31424970/edit) () Improve this answer Follow (70:3:31e,16:878318e60bc01a7c,10:1743964024,16:792ff756ef3cbf34,8:31424970,a383bb916538ce6edf1eebdc0949356308319d20cfc48bc9346e788f6ff747d1) Follow this answer to receive notifications (/posts/31424970/revisions) (show all edits to this post) edited (2020-11-02 18:57:46Z) Nov 2, 2020 at 18:57 (/users/9213345/henke-%d0%9d%d0%b0%d0%b2%d0%b0%cc%81%d0%bb%d1%8c%d0%bd%d1%8b%d0%b9-%d0%9f-%d1%81-%d0%bc) (Henke - Нава́льный П с м's user avatar) (/users/9213345/henke-%d0%9d%d0%b0%d0%b2%d0%b0%cc%81%d0%bb%d1%8c%d0%bd%d1%8b%d0%b9-%d0%9f-%d1%81-%d0%bc) Henke - Нава́льный П с м (reputation score) 5,827 (6 gold badges) 6 6 gold badges (41 silver badges) 41 41 silver badges (51 bronze badges) 51 51 bronze badges answered (2015-07-15 08:13:43Z) Jul 15, 2015 at 8:13 (/users/2717021/prabeesh) (prabeesh's user avatar) (/users/2717021/prabeesh) prabeesh prabeesh (reputation score) 945 (9 silver badges) 9 9 silver badges (11 bronze badges) 11 11 bronze badges 4 (number of 'useful comment' votes received) 2 the best answer, this worked for me on Linux Mint 17 – (/users/1378746/santiago) (236 reputation) Santiago Commented (2018-05-23 14:15:11Z, License: CC BY-SA 4.0) May 23, 2018 at 14:15 (number of 'useful comment' votes received) 1 On Mac, it worked with following in ~/.curlrc cacert=/etc/openssl/cert.pem – (/users/10674324/amirathi) (536 reputation) amirathi Commented (2020-03-03 10:37:21Z, License: CC BY-SA 4.0) Mar 3, 2020 at 10:37 (this comment was edited 1 time) did not work for me / ubuntu 18 – (/users/1621800/pascal-sautot) (405 reputation) pascal sautot Commented (2021-09-20 14:37:42Z, License: CC BY-SA 4.0) Sep 20, 2021 at 14:37 @pascalsautot Were you able to solve it ? – (/users/7589751/zuha-karim) (279 reputation) Zuha Karim Commented (2022-04-22 01:20:36Z, License: CC BY-SA 4.0) Apr 22, 2022 at 1:20 (Use comments to ask for more information or suggest improvements. Avoid comments like “+1” or “thanks”.) Add a comment | (Expand to show all comments on this post) This answer is useful (70:3:31e,16:448dae006a10a5e2,10:1743964024,16:59d149b54f4564a6,8:17265929,ec028fd00374973c82c6add97cb1151ceb94d814f5a4be95278f44affae314ce) 24 (This answer is not useful) (70:3:31e,16:ee970a42ed64bd27,10:1743964024,16:3253282d9921505d,8:17265929,a8d62407b0594a9d3a223511764ba1c828c1da898168ce3a82058764ed567e37) Save this answer. (Loading when this answer was accepted…) (/posts/17265929/timeline) Show activity on this post. The quickest way to get around the error is add on the -k option somewhere in your curl request. That option "allows connections to SSL cites without certs." (from curl --help) Be aware that this may mean that you're not talking to the endpoint you think you are, as they are presenting a certificate not signed by a CA you trust. For example: $ curl -o /usr/bin/apt-cyg https://raw.github.com/cfg/apt-cyg/master/apt-cyg gave me the following error response: curl: (77) error setting certificate verify locations: CAfile: /usr/ssl/certs/ca-bundle.crt CApath: none I added on -k: curl -o /usr/bin/apt-cyg https://raw.github.com/cfg/apt-cyg/master/apt-cyg -k and no error message. As a bonus, now I have apt-cyg installed. And ca-certificates. (/a/17265929) (Short permalink to this answer) Share Share a link to this answer Copy link (https://creativecommons.org/licenses/by-sa/3.0/) (The current license for this post: CC BY-SA 3.0) CC BY-SA 3.0 (/posts/17265929/edit) () Improve this answer Follow (70:3:31e,16:9bede2bca9f3aee1,10:1743964024,16:79886595e6a306e8,8:17265929,0cdb54b0a035db66cfb33eac9875d6899899a8eb2db2e15894477b9fe7eb3e6a) Follow this answer to receive notifications (/posts/17265929/revisions) (show all edits to this post) edited (2015-07-14 18:15:48Z) Jul 14, 2015 at 18:15 answered (2013-06-23 22:32:41Z) Jun 23, 2013 at 22:32 (/users/1678427/10gistic) (10gistic's user avatar) (/users/1678427/10gistic) 10gistic 10gistic (reputation score) 565 (3 silver badges) 3 3 silver badges (13 bronze badges) 13 13 bronze badges 7 (number of 'useful comment' votes received) 14 That might get around the error, but it also makes the "secure" connection become insecure. – (/users/180606/tim) (963 reputation) Tim Commented (2013-07-10 18:18:52Z, License: CC BY-SA 3.0) Jul 10, 2013 at 18:18 (number of 'useful comment' votes received) 2 Not really. As far as I know, you can't just bypass the encryption of a secure connection, so it's still encrypted and going to only one endpoint. Somebody correct me if I'm wrong, but the only risk you run is that you could fall prey to a man-in-the-middle attack. Still not likely a risk if you're using curl. – (/users/1678427/10gistic) (565 reputation) 10gistic Commented (2013-07-29 16:46:25Z, License: CC BY-SA 3.0) Jul 29, 2013 at 16:46 (number of 'useful comment' votes received) 26 Yes, really. The "-k" option is shorthand for "--insecure". If you have man-in-the-middle what do you think he's doing with your data ? Spoiler alert: he's decrypting it, stealing it, and possibly modifying it and injecting back into the insecure stream. Straight from the man page : "-k, --insecure (SSL) This option explicitly allows curl to perform "insecure" SSL connections and transfers. All SSL connections are attempted to be made secure by using the CA certificate bundle installed by default. This makes all connections considered "insecure" fail unless -k, --insecure is used." – (/users/180606/tim) (963 reputation) Tim Commented (2013-08-03 10:59:47Z, License: CC BY-SA 3.0) Aug 3, 2013 at 10:59 (number of 'useful comment' votes received) 2 If you need SSL you need privacy and verification — the -k flag means you're losing verification. Depending on your needs this may be acceptable. MITM are non-trivial attacks if you assume your network and the server you're communicating with are secured from interlopers (can you make that assumption?). The risk increases depending on the type of you data (sourcecode and certs are riskier than images). You can verify the integrity of the data after the transfer (checksums etc.) but now you're shifting your trust onto that checksum channel. In the end -k gives you quite a bit more work. – (/users/934195/mark-fox) (8,924 reputation) Mark Fox Commented (2014-03-04 20:12:18Z, License: CC BY-SA 3.0) Mar 4, 2014 at 20:12 So does it mean that if i am using a Self signed certificate. I should be using the option -k. As it may not be possible to verify the Self signed certificate ? – (/users/2139708/linus) (950 reputation) Linus Commented (2014-07-25 10:04:55Z, License: CC BY-SA 3.0) Jul 25, 2014 at 10:04 (Use comments to ask for more information or suggest improvements. Avoid comments like “+1” or “thanks”.) | (Expand to show all comments on this post) Show 2 more comments This answer is useful (69:3:31e,16:f64febae1070b703,10:1743964024,16:98fa13523fc60beb,7:9925923,bbed16de6201b0dbfe7d1b3d209668ffbf93dc908d6c6a426163974e9d22db0a) 17 (This answer is not useful) (69:3:31e,16:b92665159b7092f5,10:1743964024,16:321d11c4a726bf3d,7:9925923,f0a3e163518613b222e38577693d22ce76c2c4bc4a40a4d3fb408d0d20fbd581) Save this answer. (Loading when this answer was accepted…) (/posts/9925923/timeline) Show activity on this post. From $ man curl : --cert-type (SSL) Tells curl what certificate type the provided certificate is in. PEM, DER and ENG are recognized types. If not specified, PEM is assumed. If this option is used several times, the last one will be used. --cacert (SSL) Tells curl to use the specified certificate file to verify the peer. The file may contain multiple CA certificates. The certificate(s) must be in PEM format. Normally curl is built to use a default file for this, so this option is typically used to alter that default file. (/a/9925923) (Short permalink to this answer) Share Share a link to this answer Copy link (https://creativecommons.org/licenses/by-sa/3.0/) (The current license for this post: CC BY-SA 3.0) CC BY-SA 3.0 (/posts/9925923/edit) () Improve this answer Follow (69:3:31e,16:0b45b793e9f5d761,10:1743964024,16:6d79a720663faf12,7:9925923,28433b85eeb06c1245f49d453a645a10a16de3aeee7d3a567c6e60bf9da968a5) Follow this answer to receive notifications (/posts/9925923/revisions) (show all edits to this post) edited (2014-03-04 19:54:27Z) Mar 4, 2014 at 19:54 (/users/934195/mark-fox) (Mark Fox's user avatar) (/users/934195/mark-fox) Mark Fox (reputation score) 8,924 (9 gold badges) 9 9 gold badges (56 silver badges) 56 56 silver badges (77 bronze badges) 77 77 bronze badges answered (2012-03-29 13:03:41Z) Mar 29, 2012 at 13:03 (/users/821480/purnachandar-rao-voleti) (Purnachandar Rao Voleti's user avatar) (/users/821480/purnachandar-rao-voleti) Purnachandar Rao Voleti Purnachandar Rao Voleti (reputation score) 586 (4 silver badges) 4 4 silver badges (12 bronze badges) 12 12 bronze badges (Use comments to ask for more information or suggest improvements. Avoid comments like “+1” or “thanks”.) Add a comment | (Expand to show all comments on this post) This answer is useful (70:3:31e,16:ad322cc38de208fe,10:1743964024,16:9dd8015ab0564146,8:37804716,6ccb02d5cae1a239bf53c52f4b5a0a6aa119b1440e622de800b0c560b6ce51bf) 16 (This answer is not useful) (70:3:31e,16:0635413595c7ff15,10:1743964024,16:320c1dedb44ec84d,8:37804716,e37c35844743e3bf83b8b8ece6ede3488148530d94211c088ac63d201ab105c2) Save this answer. (Loading when this answer was accepted…) (/posts/37804716/timeline) Show activity on this post. @roens is correct. This affects all Anaconda users, with below errorcurl: (77) error setting certificate verify locations: CAfile: /etc/pki/tls/certs/ca-bundle.crt CApath: none The workaround is to use the default system curl and avoid messing with the prepended Anaconda PATH variable. You can either Rename the Anaconda curl binary :)mv /path/to/anaconda/bin/curl /path/to/anaconda/bin/curl_anaconda OR remove Anaconda curlconda remove curl $ which curl /usr/bin/curl [0] Anaconda Ubuntu curl Github issue (https://github.com/conda/conda-recipes/issues/352) https://github.com/conda/conda-recipes/issues/352 (/a/37804716) (Short permalink to this answer) Share Share a link to this answer Copy link (https://creativecommons.org/licenses/by-sa/3.0/) (The current license for this post: CC BY-SA 3.0) CC BY-SA 3.0 (/posts/37804716/edit) () Improve this answer Follow (70:3:31e,16:a4876684633605cd,10:1743964024,16:7181ae5962bd91d0,8:37804716,3194c0fc1a716827d3f51599e2905c743cd4e11cc247364fc334e420afb4fa5e) Follow this answer to receive notifications (/posts/37804716/revisions) (show all edits to this post) edited (2016-06-14 06:56:01Z) Jun 14, 2016 at 6:56 answered (2016-06-14 06:41:57Z) Jun 14, 2016 at 6:41 (/users/5061477/harsha-manjunath) (Harsha Manjunath's user avatar) (/users/5061477/harsha-manjunath) Harsha Manjunath Harsha Manjunath (reputation score) 599 (6 silver badges) 6 6 silver badges (12 bronze badges) 12 12 bronze badges 1 Good find, I didn't realize Anaconda was stealing my path precedence. It worked once I replaced curl with the full path /usr/bin/curl – (/users/1330381/jxramos) (8,306 reputation) jxramos Commented (2018-11-19 01:22:34Z, License: CC BY-SA 4.0) Nov 19, 2018 at 1:22 (this comment was edited 1 time) (Use comments to ask for more information or suggest improvements. Avoid comments like “+1” or “thanks”.) Add a comment | (Expand to show all comments on this post) This answer is useful (70:3:31e,16:4207b6374866a5e4,10:1743964024,16:356275091aef1259,8:59023110,e265882476d6bd5222bd4347ad142ef41666dbb4cb5d7a095ce31a8ccf05f51e) 13 (This answer is not useful) (70:3:31e,16:9d9457f53e19939b,10:1743964024,16:1124b0ebe8e809a5,8:59023110,bd2e3205f47e8519186bf5c29f6926de7852aeeadefa9aad60fc8be923aa2357) Save this answer. (Loading when this answer was accepted…) (/posts/59023110/timeline) Show activity on this post. If anyone is still having trouble, try this, it worked for me. Delete the files in your /etc/ssl/certs/ directory then reinstall ca-certificates: sudo apt install ca-certificates --reinstall Did this when I tried installing Linuxbrew. (/a/59023110) (Short permalink to this answer) Share Share a link to this answer Copy link (https://creativecommons.org/licenses/by-sa/4.0/) (The current license for this post: CC BY-SA 4.0) CC BY-SA 4.0 (/posts/59023110/edit) () Improve this answer Follow (70:3:31e,16:ecb8f92c48fe9b4b,10:1743964024,16:ea9ca6b9a20313f1,8:59023110,4678267d57f1715b09893ac688511a4e40e37af7af0e13b072f2e83ee416468a) Follow this answer to receive notifications (/posts/59023110/revisions) (show all edits to this post) edited (2020-01-20 00:56:22Z) Jan 20, 2020 at 0:56 (/users/2766176/brian-d-foy) (brian d foy's user avatar) (/users/2766176/brian-d-foy) brian d foy (reputation score 133,003) 133k (31 gold badges) 31 31 gold badges (212 silver badges) 212 212 silver badges (605 bronze badges) 605 605 bronze badges answered (2019-11-24 22:36:08Z) Nov 24, 2019 at 22:36 (/users/5743426/michael-enitan) (Michael Enitan's user avatar) (/users/5743426/michael-enitan) Michael Enitan Michael Enitan (reputation score) 562 (6 silver badges) 6 6 silver badges (10 bronze badges) 10 10 bronze badges 2 (number of 'useful comment' votes received) 2 This helped me but I didn't delete the files on my machine. Just ran the simple command and curl started working. – (/users/4249323/josefhu15) (83 reputation) Josefhu15 Commented (2020-05-17 18:50:34Z, License: CC BY-SA 4.0) May 17, 2020 at 18:50 This was the solution for me 👍 – (/users/1918407/ime) (413 reputation) iMe Commented (2021-11-27 13:23:05Z, License: CC BY-SA 4.0) Nov 27, 2021 at 13:23 (Use comments to ask for more information or suggest improvements. Avoid comments like “+1” or “thanks”.) Add a comment | (Expand to show all comments on this post) This answer is useful (70:3:31e,16:9854829a11d3ebe1,10:1743964024,16:ca5e8de2d2505dd5,8:31969626,964ae763cf106747f9faae06b69cf5d63d23168c9e7d6984356ce59bf57e9a01) 10 (This answer is not useful) (70:3:31e,16:0dd8ebc3b4d19037,10:1743964024,16:76b9f0b2acfc8931,8:31969626,12e0c90fb56c605af622d84567d87ce29c3965efd16886edfae307c78b9464e1) Save this answer. (Loading when this answer was accepted…) (/posts/31969626/timeline) Show activity on this post. Another alternative to fix this problem is to disable the certificate validation: echo insecure >> ~/.curlrc (/a/31969626) (Short permalink to this answer) Share Share a link to this answer Copy link (https://creativecommons.org/licenses/by-sa/3.0/) (The current license for this post: CC BY-SA 3.0) CC BY-SA 3.0 (/posts/31969626/edit) () Improve this answer Follow (70:3:31e,16:deadff974ba3ba2e,10:1743964024,16:ffa12cad84d9509f,8:31969626,84227230954a746c920bcf08b8d80e2da7c5b39a71ad9f69e29815e2a71184e9) Follow this answer to receive notifications answered (2015-08-12 15:31:28Z) Aug 12, 2015 at 15:31 (/users/3114469/pablo-r-mier) (Pablo R. Mier's user avatar) (/users/3114469/pablo-r-mier) Pablo R. Mier Pablo R. Mier (reputation score) 757 (1 gold badge) 1 1 gold badge (8 silver badges) 8 8 silver badges (14 bronze badges) 14 14 bronze badges 1 (number of 'useful comment' votes received) 2 Workaround, but it helps me after too much time with curl certificates. Thanks. – (/users/5991749/k-gol) (1,636 reputation) K. Gol Commented (2018-04-12 11:06:14Z, License: CC BY-SA 3.0) Apr 12, 2018 at 11:06 (Use comments to ask for more information or suggest improvements. Avoid comments like “+1” or “thanks”.) Add a comment | (Expand to show all comments on this post) This answer is useful (70:3:31e,16:c8b8bc9deb1ec4d4,10:1743964024,16:eaa0bf176c58f276,8:41264375,9e3710f84acbbccbad37ea0b38f13e6a8052952ded467d734bdb27bbc38917cf) 9 (This answer is not useful) (70:3:31e,16:80a71aa0a104831b,10:1743964024,16:82d941f8c2d5613f,8:41264375,d0e0939aa3ec1632ffaa5a39494d88af99de91536db6c7d208fdea3015e47caa) Save this answer. (Loading when this answer was accepted…) (/posts/41264375/timeline) Show activity on this post. I had the exact same problem. As it turns out, my /etc/ssl/certs/ca-certificates.crt file was malformed. The last entry showed something like this: -----BEGIN CERTIFICATE----- MIIEDTCCAvWgAwIBAgIJAN..lots of certificate text....AwIBAgIJAN-----END CERTIFICATE----- After adding a newline before -----END CERTIFICATE----- , curl was able handle the certificates file. This was very annoying to find out since my update-ca-certificates command did not give me any warning. This may or may not be a version specific problem of curl, so here is my version, just for completeness: curl --version # curl 7.51.0 (x86_64-alpine-linux-musl) libcurl/7.51.0 OpenSSL/1.0.2j zlib/1.2.8 libssh2/1.7.0 # Protocols: dict file ftp ftps gopher http https imap imaps pop3 pop3s rtsp scp sftp smb smbs smtp smtps telnet tftp # Features: IPv6 Largefile NTLM NTLM_WB SSL libz TLS-SRP UnixSockets (/a/41264375) (Short permalink to this answer) Share Share a link to this answer Copy link (https://creativecommons.org/licenses/by-sa/3.0/) (The current license for this post: CC BY-SA 3.0) CC BY-SA 3.0 (/posts/41264375/edit) () Improve this answer Follow (70:3:31e,16:fb48c79ed86e6047,10:1743964024,16:6c4d599f245f2f2d,8:41264375,000dafb9de1cdb0d912bba24e1352adbe9c2dc21987f5e742a8518729b4a80fc) Follow this answer to receive notifications answered (2016-12-21 13:51:49Z) Dec 21, 2016 at 13:51 (/users/3788261/shrimpphaser) (ShrimpPhaser's user avatar) (/users/3788261/shrimpphaser) ShrimpPhaser ShrimpPhaser (reputation score) 3,507 (1 gold badge) 1 1 gold badge (24 silver badges) 24 24 silver badges (22 bronze badges) 22 22 bronze badges 0 (Use comments to ask for more information or suggest improvements. Avoid comments like “+1” or “thanks”.) Add a comment | (Expand to show all comments on this post) This answer is useful (70:3:31e,16:7216f1c698cba9ad,10:1743964024,16:8fd64afd71c51008,8:35956375,384efd200209debc4d63e1f397d691ebe261aa7c4c77fc1e92d75ed96eef788b) 7 (This answer is not useful) (70:3:31e,16:de51ae3b70927a26,10:1743964024,16:ea25c26bb9c8588f,8:35956375,f1360c8ea3b8db6ac190294a2777b032e31051d0b296173758910f8c30bbdda5) Save this answer. (Loading when this answer was accepted…) (/posts/35956375/timeline) Show activity on this post. For PHP code running on XAMPP on Windows I found I needed to edit php.ini to include the below [curl] ; A default value for the CURLOPT_CAINFO option. This is required to be an ; absolute path. curl.cainfo = curl-ca-bundle.crt and then copy to a file (https://curl.haxx.se/ca/cacert.pem) https://curl.haxx.se/ca/cacert.pem and rename to curl-ca-bundle.crt and place it under \xampp path (I couldn't get curl.capath to work). I also found the CAbundle on the cURL site wasn't enough for the remote site I was connecting to, so used one that is listed with a pre-compiled Windows version of curl 7.47.1 at (http://winampplugins.co.uk/curl/) http://winampplugins.co.uk/curl/ (/a/35956375) (Short permalink to this answer) Share Share a link to this answer Copy link (https://creativecommons.org/licenses/by-sa/3.0/) (The current license for this post: CC BY-SA 3.0) CC BY-SA 3.0 (/posts/35956375/edit) () Improve this answer Follow (70:3:31e,16:8ef46c24a89de497,10:1743964024,16:43a213e5162f2b40,8:35956375,5cbb74271eeb9077bbc42a1959d2b096508ce4f8dfd578d3a5fd16bc4011791e) Follow this answer to receive notifications answered (2016-03-12 10:18:53Z) Mar 12, 2016 at 10:18 (/users/977566/ljt) (LJT's user avatar) (/users/977566/ljt) LJT LJT (reputation score) 1,289 (3 gold badges) 3 3 gold badges (20 silver badges) 20 20 silver badges (25 bronze badges) 25 25 bronze badges 1 On windows you can also just add "xampp" before php like so: curl.cainfo = "C:\xampp\php\extras\cacert.pem" – (/users/4121165/ryan-steyn) (69 reputation) Ryan Steyn Commented (2016-10-28 06:55:17Z, License: CC BY-SA 3.0) Oct 28, 2016 at 6:55 (this comment was edited 3 times) (Use comments to ask for more information or suggest improvements. Avoid comments like “+1” or “thanks”.) Add a comment | (Expand to show all comments on this post) This answer is useful (70:3:31e,16:b0df372ac89506c4,10:1743964024,16:4216d331287ee6e5,8:29077304,c5ca4774ceae20cbb226c37c2f1c5057dcbd265b7afde1e994312f7b0a0d35b4) 5 (This answer is not useful) (70:3:31e,16:09ac5625a1ed9051,10:1743964024,16:9ad26128bfe37f19,8:29077304,6c81d0faf9e29fe167f8ae426e4b76787a45fee8380953413ed6f45c78662536) Save this answer. (Loading when this answer was accepted…) (/posts/29077304/timeline) Show activity on this post. This worked for me sudo apt-get install ca-certificates then go into the certificates folder at sudo cd /etc/ssl/certs then you copy the ca-certificates.crt file into the /etc/pki/tls/certs sudo cp ca-certificates.crt /etc/pki/tls/certs if there is no tls/certs folder: create one and change permissions using chmod 777 -R folderNAME (/a/29077304) (Short permalink to this answer) Share Share a link to this answer Copy link (https://creativecommons.org/licenses/by-sa/3.0/) (The current license for this post: CC BY-SA 3.0) CC BY-SA 3.0 (/posts/29077304/edit) () Improve this answer Follow (70:3:31e,16:1d21d987609dc3bc,10:1743964024,16:be92624798e67d54,8:29077304,dbabd189ea9c7ddbd8e2329996368f55050a6bf0cd4c5dc69c5edf4fce502f3a) Follow this answer to receive notifications (/posts/29077304/revisions) (show all edits to this post) edited (2015-03-16 13:12:55Z) Mar 16, 2015 at 13:12 (/users/542270/opal) (Opal's user avatar) (/users/542270/opal) Opal (reputation score 85,024) 85k (29 gold badges) 29 29 gold badges (200 silver badges) 200 200 silver badges (218 bronze badges) 218 218 bronze badges answered (2015-03-16 12:52:38Z) Mar 16, 2015 at 12:52 (/users/3965400/kwame-yeboah) (Kwame Yeboah's user avatar) (/users/3965400/kwame-yeboah) Kwame Yeboah Kwame Yeboah (reputation score) 79 (1 silver badge) 1 1 silver badge (1 bronze badge) 1 1 bronze badge 2 (number of 'useful comment' votes received) 2 I tried this but this didn't work for me and I still get the same error. Any ideas ? – (/users/2123548/anirudh) (385 reputation) Anirudh Commented (2015-03-21 11:34:00Z, License: CC BY-SA 3.0) Mar 21, 2015 at 11:34 (number of 'useful comment' votes received) 2 chmod 777 is very insecure (anyone - any process - on that box can change the certs and MitM attack you) - chmod 755 is much better – (/users/903280/gedge) (315 reputation) Gedge Commented (2021-05-11 08:36:32Z, License: CC BY-SA 4.0) May 11, 2021 at 8:36 (this comment was edited 1 time) (Use comments to ask for more information or suggest improvements. Avoid comments like “+1” or “thanks”.) Add a comment | (Expand to show all comments on this post) This answer is useful (70:3:31e,16:ed17f464802aa329,10:1743964024,16:b9762b39cadce672,8:26260710,2977e51f6c51c900f83232e47cc62a0601c6ea51ae0d960074cf0d78ba69f20f) 5 (This answer is not useful) (70:3:31e,16:9cfe7f9fcf05f9ba,10:1743964024,16:e248616a6130af06,8:26260710,cc62bbb20b7a59af0dfe4863a4b78a0453b565b6e8006317f3b2528801a64675) Save this answer. (Loading when this answer was accepted…) (/posts/26260710/timeline) Show activity on this post. curl performs SSL certificate verification by default, using a "bundle" of Certificate Authority (CA) public keys (CA certs). The default bundle is named curl-ca-bundle.crt; you can specify an alternate file using the --cacert option. If this HTTPS server uses a certificate signed by a CA represented in the bundle, the certificate verification probably failed due to a problem with the certificate (it might be expired, or the name might not match the domain name in the URL). If you'd like to turn off curl's verification of the certificate, use the -k (or --insecure ) option. for example curl --insecure http://........ (/a/26260710) (Short permalink to this answer) Share Share a link to this answer Copy link (https://creativecommons.org/licenses/by-sa/3.0/) (The current license for this post: CC BY-SA 3.0) CC BY-SA 3.0 (/posts/26260710/edit) () Improve this answer Follow (70:3:31e,16:e643d735d432238d,10:1743964024,16:5d7c9852cd08a930,8:26260710,fcfa9bb18713bfd9f7f38294fb246be439e17a92910ae74015aa762b3d6b738e) Follow this answer to receive notifications (/posts/26260710/revisions) (show all edits to this post) edited (2015-10-21 01:38:26Z) Oct 21, 2015 at 1:38 answered (2014-10-08 15:27:37Z) Oct 8, 2014 at 15:27 (/users/1880431/meda) (meda's user avatar) (/users/1880431/meda) meda meda (reputation score 45,490) 45.5k (14 gold badges) 14 14 gold badges (95 silver badges) 95 95 silver badges (123 bronze badges) 123 123 bronze badges 1 (number of 'useful comment' votes received) 3 Just an aside that "trusting the source" is pretty irrelevant here, since without properly validating the cert against a CA, you have no idea who "the source" is. – (/users/1133019/jeff-allen) (17,565 reputation) Jeff Allen Commented (2015-05-30 23:06:19Z, License: CC BY-SA 3.0) May 30, 2015 at 23:06 (Use comments to ask for more information or suggest improvements. Avoid comments like “+1” or “thanks”.) Add a comment | (Expand to show all comments on this post) This answer is useful (69:3:31e,16:f6aae4c70f25f97d,10:1743964024,16:119d018ec92419cd,7:3161949,7f5fa83fa453d1c22ba0ce18146d6e9cab053e35bc45dd44a45e9b752ef05266) 4 (This answer is not useful) (69:3:31e,16:6e64a90e0eff7e76,10:1743964024,16:cdf1a89159bcc436,7:3161949,3ab57814bd8ceb1418788eed84751866bc5dadc6e9229ab6e011ba0940075d96) Save this answer. (Loading when this answer was accepted…) (/posts/3161949/timeline) Show activity on this post. It seems your curl points to a non-existing file with CA certs or similar. For the primary reference on CA certs with curl, see: (https://curl.se/docs/sslcerts.html) https://curl.se/docs/sslcerts.html (/a/3161949) (Short permalink to this answer) Share Share a link to this answer Copy link (https://creativecommons.org/licenses/by-sa/4.0/) (The current license for this post: CC BY-SA 4.0) CC BY-SA 4.0 (/posts/3161949/edit) () Improve this answer Follow (69:3:31e,16:3656274a40dcf25a,10:1743964024,16:c86ee4756dba7fa4,7:3161949,ad176f3e55056f148f57b714734486676f7d430649ea810803c97d855858be5b) Follow this answer to receive notifications (/posts/3161949/revisions) (show all edits to this post) edited (2023-11-30 08:40:03Z) Nov 30, 2023 at 8:40 answered (2010-07-01 21:52:24Z) Jul 1, 2010 at 21:52 (/users/93747/daniel-stenberg) (Daniel Stenberg's user avatar) (/users/93747/daniel-stenberg) Daniel Stenberg Daniel Stenberg (reputation score 58,374) 58.4k (19 gold badges) 19 19 gold badges (159 silver badges) 159 159 silver badges (232 bronze badges) 232 232 bronze badges (Use comments to ask for more information or suggest improvements. Avoid comments like “+1” or “thanks”.) Add a comment | (Expand to show all comments on this post) This answer is useful (70:3:31e,16:38ef8944c9de02f9,10:1743964024,16:68eca492a03ac81a,8:55215998,4319a0aef9e2703d2f43d79acf0510402c3c0f9b502c925462014ee40974f7d6) 3 (This answer is not useful) (70:3:31e,16:2c81123948f5ae62,10:1743964024,16:9a96448d6d35b120,8:55215998,54a14e0443433b225456578fe4c3f20cc652f1d197effeb7f8a3326369cfc845) Save this answer. (Loading when this answer was accepted…) (/posts/55215998/timeline) Show activity on this post. Just create the folders, which is missing in your system.. /etc/pki/tls/certs/ and create the file using the following command, sudo apt-get install ca-certificates and then copy and paste the certificate to the destination folder, which is showing in your error.. mine was " with message 'error setting certificate verify locations: CAfile: /etc/pki/tls/certs/ca-bundle.crt CApath: none' in " make sure you paste the file to the exact location mentioned in the error. Use the following command to copy paste.. sudo cp /etc/ssl/certs/ca-certificates.crt /etc/pki/tls/certs/ca-bundle.crt Fixed. (/a/55215998) (Short permalink to this answer) Share Share a link to this answer Copy link (https://creativecommons.org/licenses/by-sa/4.0/) (The current license for this post: CC BY-SA 4.0) CC BY-SA 4.0 (/posts/55215998/edit) () Improve this answer Follow (70:3:31e,16:d8ac1d5b90d4dfa3,10:1743964024,16:84341614652a5dcf,8:55215998,a185af9e297ce6b583f9392304880de3e77ba45d971cc71f53d60cba7cf59447) Follow this answer to receive notifications answered (2019-03-18 06:56:24Z) Mar 18, 2019 at 6:56 (/users/2890344/manu-r-s) (Manu R S's user avatar) (/users/2890344/manu-r-s) Manu R S Manu R S (reputation score) 980 (9 silver badges) 9 9 silver badges (6 bronze badges) 6 6 bronze badges 1 (number of 'useful comment' votes received) 1 None of the top answers worked for me but this did! – (/users/10671246/prachiti-prakash-prabhu) (684 reputation) Prachiti Prakash Prabhu Commented (2020-02-28 20:46:32Z, License: CC BY-SA 4.0) Feb 28, 2020 at 20:46 (Use comments to ask for more information or suggest improvements. Avoid comments like “+1” or “thanks”.) Add a comment | (Expand to show all comments on this post) This answer is useful (70:3:31e,16:04d61152ca3f4f92,10:1743964024,16:0663e781e40935db,8:70688820,cd16259d3d214843dc6867551b523cf8365691ace74578655e6d41ec48c1d68e) 3 (This answer is not useful) (70:3:31e,16:def70e282c6742d7,10:1743964024,16:454aeee5000e210d,8:70688820,6940508b6cd0b53aa5f452f05022e1cdb4705e881831bc033c85dcfd9e53a674) Save this answer. (Loading when this answer was accepted…) (/posts/70688820/timeline) Show activity on this post. For windows :- Download the certificate from (https://curl.se/docs/caextract.html) https://curl.se/docs/caextract.html Rename cacert.pem to curl-ca-bundle.crt Add the file to any of the below locations (https://i.sstatic.net/SWPmb.png) (enter image description here) Check this for details (https://curl.se/docs/sslcerts.html) https://curl.se/docs/sslcerts.html (/a/70688820) (Short permalink to this answer) Share Share a link to this answer Copy link (https://creativecommons.org/licenses/by-sa/4.0/) (The current license for this post: CC BY-SA 4.0) CC BY-SA 4.0 (/posts/70688820/edit) () Improve this answer Follow (70:3:31e,16:97e404afaa641f1f,10:1743964024,16:527e9189e6c996e3,8:70688820,502567ca29e0704604e75aed3ac70b21cebb1c5df490c035b18308293d468bdd) Follow this answer to receive notifications answered (2022-01-12 21:44:17Z) Jan 12, 2022 at 21:44 (/users/1251376/ssilas777) (ssilas777's user avatar) (/users/1251376/ssilas777) ssilas777 ssilas777 (reputation score) 9,762 (4 gold badges) 4 4 gold badges (47 silver badges) 47 47 silver badges (69 bronze badges) 69 69 bronze badges 1 I did curl https://curl.se/ca/cacert.pem -o /etc/ssl/certs/ca-certificates.crt -k to get a copy of the root certificate curl needs. I am building linux from scratch. – (/users/1968972/exebook) (34,080 reputation) exebook Commented (2023-03-04 14:46:08Z, License: CC BY-SA 4.0) Mar 4, 2023 at 14:46 (this comment was edited 1 time) (Use comments to ask for more information or suggest improvements. Avoid comments like “+1” or “thanks”.) Add a comment | (Expand to show all comments on this post) This answer is useful (70:3:31e,16:4aa55b1107179b55,10:1743964024,16:7db0aa05cf51acc2,8:72534237,b63ad70c3f3e65935804b586b620e930db4b6ceb1845837cad7678e79107115b) 3 (This answer is not useful) (70:3:31e,16:91a36709291c11b9,10:1743964024,16:683848ca2c4178d0,8:72534237,91d909f847725c616165afad9249716624952f660a9358d8ac483a8fbccc5757) Save this answer. (Loading when this answer was accepted…) (/posts/72534237/timeline) Show activity on this post. I came across this curl 77 problem while was trying to access elasticsearch running in docker container on Ubuntu 20.04 localhost. Afrer container was started: Check curl without ssl: curl --cacert http_ca.crt -u elastic https://localhost:9200 -k lowercase -k for insecure connection. Check curl configs: curl-config --configure , noticed what is ca-bundle: --with-ca-bundle=/etc/ssl/certs/ca-certificates.crt . Copy http_ca.crt file from container to:/usr/local/share/ca-certificates/ , original command is (https://www.elastic.co/guide/en/elasticsearch/reference/8.2/docker.html) here . Run update on ca-certificates: sudo update-ca-certificates . Run curl: curl -u elastic: https://localhost:9201 .Finally got response with "tagline" : "You Know, for Search" . Change to the one that was generated when Docker Image was run.Also notice that on my machine elastic was started on port 9201 (don't know why: sudo ss -tlpn | grep 9200 gives me nothing), I have found the port with: sudo netstat -ntlp and Programm name was docker-proxy. (/a/72534237) (Short permalink to this answer) Share Share a link to this answer Copy link (https://creativecommons.org/licenses/by-sa/4.0/) (The current license for this post: CC BY-SA 4.0) CC BY-SA 4.0 (/posts/72534237/edit) () Improve this answer Follow (70:3:31e,16:1dd9c7217d5311c4,10:1743964024,16:3ca51e226da3bdf4,8:72534237,0fdd74f27b4ee62fe9e1d40a836adeeb7021e2911a5153df15b575ed32b0a31b) Follow this answer to receive notifications answered (2022-06-07 15:53:18Z) Jun 7, 2022 at 15:53 (/users/6813176/dobhareach) (dobhareach's user avatar) (/users/6813176/dobhareach) dobhareach dobhareach (reputation score) 344 (5 silver badges) 5 5 silver badges (7 bronze badges) 7 7 bronze badges (Use comments to ask for more information or suggest improvements. Avoid comments like “+1” or “thanks”.) Add a comment | (Expand to show all comments on this post) This answer is useful (70:3:31e,16:23e95204fee6ae16,10:1743964024,16:6d410fc054dd21ff,8:58931930,52922e0a2157ff97187aebb34241999ebc90a15aea416243967d3c67071618be) 3 (This answer is not useful) (70:3:31e,16:d725ca2586c08be8,10:1743964024,16:cd87640be838f2ac,8:58931930,fba94b5fbbef9eac91cd22f3a7b8a0a66d0f540b07aa1c9177cd5dff72346418) Save this answer. (Loading when this answer was accepted…) (/posts/58931930/timeline) Show activity on this post. I've got the same problem : I'm building an alpine based docker image, and when I want to curl to a website of my organisation, this error appears. To solve it, I have to get the CA cert of my company, then, I have to add it to the CA certs of my image. Get the CA certificate Use OpenSSL to get the certificates related to the website : openssl s_client -showcerts -servername my.company.website.org -connect my.company.website.org:443 This will output something like : CONNECTED(00000005) depth=2 CN = UbisoftRootCA verify error:num=19:self signed certificate in certificate chain ... -----BEGIN CERTIFICATE----- ... -----END CERTIFICATE----- -----BEGIN CERTIFICATE----- ... -----END CERTIFICATE----- ... Get the last certificate (the content between the -----BEGIN CERTIFICATE----- and the-----END CERTIFICATE----- markups included) and save it into a file (mycompanyRootCA.crt for example) Build your image Then, when you'll build your docker image from alpine, do the following : FROM alpine RUN apk add ca-certificates curl COPY mycompanyRootCA.crt /usr/local/share/ca-certificates/mycompanyRootCA.crt RUN update-ca-certificates Your image will now work properly! (/a/58931930) (Short permalink to this answer) Share Share a link to this answer Copy link (https://creativecommons.org/licenses/by-sa/4.0/) (The current license for this post: CC BY-SA 4.0) CC BY-SA 4.0 (/posts/58931930/edit) () Improve this answer Follow (70:3:31e,16:8c498188d1766e51,10:1743964024,16:f77bb851fd18c459,8:58931930,ec5d706ac51660c1b7a56ba6161d4d000960314a827b1787330b57aa3b22d606) Follow this answer to receive notifications (/posts/58931930/revisions) (show all edits to this post) edited (2024-02-26 22:14:04Z) Feb 26, 2024 at 22:14 (/users/1007939/cdspace) (CDspace's user avatar) (/users/1007939/cdspace) CDspace (reputation score) 2,689 (19 gold badges) 19 19 gold badges (32 silver badges) 32 32 silver badges (39 bronze badges) 39 39 bronze badges answered (2019-11-19 10:32:06Z) Nov 19, 2019 at 10:32 (/users/1517814/alphayax) (alphayax's user avatar) (/users/1517814/alphayax) alphayax alphayax (reputation score) 3,110 (2 gold badges) 2 2 gold badges (26 silver badges) 26 26 silver badges (28 bronze badges) 28 28 bronze badges (Use comments to ask for more information or suggest improvements. Avoid comments like “+1” or “thanks”.) Add a comment | (Expand to show all comments on this post) This answer is useful (70:3:31e,16:e3084d31d76db720,10:1743964024,16:602c9bb1b4cde85f,8:76092661,cf8cf66c758ca83d56d107d223eea6d5f71b7503c3974424655dee2a22ee30b8) 2 (This answer is not useful) (70:3:31e,16:e8efff384ead8e57,10:1743964024,16:e1a5fb779faaf8ea,8:76092661,029c8cc30406ae10af5889571f44b0444500b0d0b93362f617c10ba451cb93f3) Save this answer. (Loading when this answer was accepted…) (/posts/76092661/timeline) Show activity on this post. I used to get this error when run composer update And I tried all the commands to reinstall the cert file, but the problem was not solved. I realized that the error is due to permission So the problem was solved with this command cd /etc/ssl sudo chmod 755 -R certs/ (/a/76092661) (Short permalink to this answer) Share Share a link to this answer Copy link (https://creativecommons.org/licenses/by-sa/4.0/) (The current license for this post: CC BY-SA 4.0) CC BY-SA 4.0 (/posts/76092661/edit) () Improve this answer Follow (70:3:31e,16:2c3eefb1c93a387b,10:1743964024,16:3256e1694a1e8145,8:76092661,0602f6f42a01e876522c45c1db5ef525e01644cd70e8cd5bb4ad37fdee278d23) Follow this answer to receive notifications answered (2023-04-24 13:54:08Z) Apr 24, 2023 at 13:54 (/users/6310309/fatemeh-sadeghi) (fatemeh sadeghi's user avatar) (/users/6310309/fatemeh-sadeghi) fatemeh sadeghi fatemeh sadeghi (reputation score) 2,623 (1 gold badge) 1 1 gold badge (15 silver badges) 15 15 silver badges (15 bronze badges) 15 15 bronze badges (Use comments to ask for more information or suggest improvements. Avoid comments like “+1” or “thanks”.) Add a comment | (Expand to show all comments on this post) This answer is useful (70:3:31e,16:1098876d41841ee9,10:1743964024,16:2daafec68fc34d57,8:34210478,f32aa92b79b35af993d0f9cacc5dd4b646df79c8e3c5ce761222657049a3c97e) 1 (This answer is not useful) (70:3:31e,16:709af70b3730d3d9,10:1743964024,16:57b25109eda9ee96,8:34210478,e85b05091bee98312e73b81a9f3e04fda32727a07ebc16df277f5741b7558374) Save this answer. (Loading when this answer was accepted…) (/posts/34210478/timeline) Show activity on this post. For what it's worth, checking which curl is being run is significant too. A user on a shared machine I maintain had been getting this error. But the cause turned out to be because they'd installed Anaconda ((http://continuum.io) http://continuum.io ). Doing so put Anaconda's binary path before the standard $PATH , and it comes with its own curl binary, which had trouble finding the default certs that were installed on this Ubuntu machine. (/a/34210478) (Short permalink to this answer) Share Share a link to this answer Copy link (https://creativecommons.org/licenses/by-sa/3.0/) (The current license for this post: CC BY-SA 3.0) CC BY-SA 3.0 (/posts/34210478/edit) () Improve this answer Follow (70:3:31e,16:2547005940a8fca0,10:1743964024,16:0494d9939bb5603b,8:34210478,d8877e5a464962b55fae1ae52b4dd104eaf9639c3ae5d92535f17e1a320ba9cf) Follow this answer to receive notifications (/posts/34210478/revisions) (show all edits to this post) edited (2016-03-17 19:17:50Z) Mar 17, 2016 at 19:17 answered (2015-12-10 19:47:56Z) Dec 10, 2015 at 19:47 (/users/925987/roens) (roens's user avatar) (/users/925987/roens) roens roens (reputation score) 352 (2 silver badges) 2 2 silver badges (9 bronze badges) 9 9 bronze badges 1 (number of 'useful comment' votes received) 1 I recommend checking which -a curl to see everything available, and of course noting which one comes on top. – (/users/1330381/jxramos) (8,306 reputation) jxramos Commented (2018-11-19 01:23:36Z, License: CC BY-SA 4.0) Nov 19, 2018 at 1:23 (Use comments to ask for more information or suggest improvements. Avoid comments like “+1” or “thanks”.) Add a comment | (Expand to show all comments on this post) This answer is useful (70:3:31e,16:159af74f43d857a7,10:1743964024,16:e9655f86f08ce62f,8:61264216,774b05d76365f8d3f6718424fd95792cc8106eb3349a380251aa9fe4b8dd9c06) 1 (This answer is not useful) (70:3:31e,16:98cdea255c6f5345,10:1743964024,16:4f67eeec0e25fb24,8:61264216,aa04d969340293293bcb33f4ad3c5842f56374fb19e4d2d26c0afeb05d9a4393) Save this answer. (Loading when this answer was accepted…) (/posts/61264216/timeline) Show activity on this post. Just find this solution works perfectly for me. echo 'cacert=/etc/ssl/certs/ca-certificates.crt' > ~/.curlrc I found this solution from (https://youremindmeofmymother.com/2016/03/28/curl-77-error-setting-certificate-verify-locations/) here (/a/61264216) (Short permalink to this answer) Share Share a link to this answer Copy link (https://creativecommons.org/licenses/by-sa/4.0/) (The current license for this post: CC BY-SA 4.0) CC BY-SA 4.0 (/posts/61264216/edit) () Improve this answer Follow (70:3:31e,16:a97f116f7e5b2a4c,10:1743964024,16:90882bf7bfae0bf0,8:61264216,4d15f034346f3c8a3414b5e5181c23de0b2b53e6365543b51a9c3d775a91ae72) Follow this answer to receive notifications answered (2020-04-17 04:32:17Z) Apr 17, 2020 at 4:32 (/users/8055979/daniel) (Daniel's user avatar) (/users/8055979/daniel) Daniel Daniel (reputation score) 385 (4 silver badges) 4 4 silver badges (13 bronze badges) 13 13 bronze badges (Use comments to ask for more information or suggest improvements. Avoid comments like “+1” or “thanks”.) Add a comment | (Expand to show all comments on this post) This answer is useful (70:3:31e,16:5d344eadca6940cb,10:1743964024,16:4ca3f35dc3488a8b,8:44637479,b434182578cdedd42bd06b6e6ffdf8705936b9953568eeaf92f01f4c9aacfae8) 0 (This answer is not useful) (70:3:31e,16:429b29f2e6b914d6,10:1743964024,16:94a691c2b55414f1,8:44637479,a44bdae35ac76eb1ed6a794cbd619b98adb14e4b93e595634401a9efd4105e52) Save this answer. (Loading when this answer was accepted…) (/posts/44637479/timeline) Show activity on this post. Run following command in git bash that works fine for me git config --global http.sslverify "false" (/a/44637479) (Short permalink to this answer) Share Share a link to this answer Copy link (https://creativecommons.org/licenses/by-sa/3.0/) (The current license for this post: CC BY-SA 3.0) CC BY-SA 3.0 (/posts/44637479/edit) () Improve this answer Follow (70:3:31e,16:0d70cb44262265cf,10:1743964024,16:575817980df05605,8:44637479,46a9bae8c8588dec2578fc9b67f12b4a3aad5eeb49b9d510029899086a42c3cb) Follow this answer to receive notifications answered (2017-06-19 18:25:16Z) Jun 19, 2017 at 18:25 (/users/1933675/nivir) (Nivir's user avatar) (/users/1933675/nivir) Nivir Nivir (reputation score 31,238) 31.2k (9 gold badges) 9 9 gold badges (45 silver badges) 45 45 silver badges (56 bronze badges) 56 56 bronze badges 0 (Use comments to ask for more information or suggest improvements. Avoid comments like “+1” or “thanks”.) Add a comment | (Expand to show all comments on this post) This answer is useful (70:3:31e,16:9c64add25d8f66a5,10:1743964024,16:1c504a6d0f3cce19,8:67675659,5be332d9742fa309be1cce33857fc164640f773d4aaccf900c5b2061b26bf78f) 0 (This answer is not useful) (70:3:31e,16:1fd19a78a51ed668,10:1743964024,16:3b2fc6e1edc04972,8:67675659,72e59d552f1d2a3681f3e87e11e31d20e1cc76be559458b5ca1833b9a0a9a0ee) Save this answer. (Loading when this answer was accepted…) (/posts/67675659/timeline) Show activity on this post. I use MobaXterm which intern uses Cygwin so even after installing ca-certificates using apt-cyg install ca-certificates problem didn't resolve. I was still getting the following error: curl: (77) error setting certificate verify locations: CAfile: /etc/ssl/certs/ca-certificates.crt CApath: none Then I tried listing the file /etc/ssl/certs/ca-certificates.crt and I couldn't find it. However I could find /usr/ssl/certs/ca-bundle.crt with all standard CA certificates so I copied the file /usr/ssl/certs/ca-bundle.crt as /etc/ssl/certs/ca-certificates.crt and problem got resolved. (/a/67675659) (Short permalink to this answer) Share Share a link to this answer Copy link (https://creativecommons.org/licenses/by-sa/4.0/) (The current license for this post: CC BY-SA 4.0) CC BY-SA 4.0 (/posts/67675659/edit) () Improve this answer Follow (70:3:31e,16:e888e3065024532e,10:1743964024,16:c4824dc0d0792f73,8:67675659,b2bf920dc31a8bdc50508875be942cba82ae65fa58ca5ac8420ab8f2e57aa062) Follow this answer to receive notifications answered (2021-05-24 16:26:18Z) May 24, 2021 at 16:26 (/users/4226815/bharat-balothia) (Bharat Balothia's user avatar) (/users/4226815/bharat-balothia) Bharat Balothia Bharat Balothia (reputation score) 5 (3 bronze badges) 3 3 bronze badges (Use comments to ask for more information or suggest improvements. Avoid comments like “+1” or “thanks”.) Add a comment | (Expand to show all comments on this post) This answer is useful (70:3:31e,16:26627a2e5fe30aee,10:1743964024,16:59c8a867895e1ffd,8:64530868,bb676bfadb6c8c5d0e6b5317c5021e71f3cfa1844bad3509d63eb18fccdb3357) 0 (This answer is not useful) (70:3:31e,16:5aec01bce0ef24a3,10:1743964024,16:01d3e76fab33d329,8:64530868,f2b9f381eea0ed9c8641bd64924922e075506042ba58c93cc890f8a4409cdd0e) Save this answer. (Loading when this answer was accepted…) (/posts/64530868/timeline) Show activity on this post. I had this problem as well. My issue was this file: /usr/ssl/certs/ca-bundle.crt is by default just an empty file. So even if it exists, you'll still get the error as it doesn't contain any certificates. You can generate them like this: p11-kit extract --overwrite --format pem-bundle /usr/ssl/certs/ca-bundle.crt (https://github.com/msys2/MSYS2-packages/blob/master/ca-certificates/ca-certificates.install) https://github.com/msys2/MSYS2-packages/blob/master/ca-certificates/ca-certificates.install (/a/64530868) (Short permalink to this answer) Share Share a link to this answer Copy link (https://creativecommons.org/licenses/by-sa/4.0/) (The current license for this post: CC BY-SA 4.0) CC BY-SA 4.0 (/posts/64530868/edit) () Improve this answer Follow (70:3:31e,16:98fd37e801362639,10:1743964024,16:d6519bc26b66d620,8:64530868,69f06094dd0ede15e946b50ed9f3d081c28dff7d974f4ce93d0809a0d6f186df) Follow this answer to receive notifications (/posts/64530868/revisions) (show all edits to this post) edited (2021-11-02 07:40:42Z) Nov 2, 2021 at 7:40 (/users/12892553/nimantha) (Nimantha's user avatar) (/users/12892553/nimantha) Nimantha (reputation score) 6,484 (6 gold badges) 6 6 gold badges (31 silver badges) 31 31 silver badges (76 bronze badges) 76 76 bronze badges answered (2020-10-26 02:38:47Z) Oct 26, 2020 at 2:38 (/users/1002260/zombo) (Zombo's user avatar) (/users/1002260/zombo) Zombo Zombo (reputation score) 1 (Use comments to ask for more information or suggest improvements. Avoid comments like “+1” or “thanks”.) Add a comment | (Expand to show all comments on this post) This answer is useful (70:3:31e,16:1b4b902af66f45a0,10:1743964024,16:06f1fd5b62943231,8:78790238,43783cff915479ff8cc92249d0128162faebac0fd0c6eb19d0cddd90f74a8494) 0 (This answer is not useful) (70:3:31e,16:d2e72500ebe402ba,10:1743964024,16:14fb5b9ff4624b40,8:78790238,ff9f18d56feec8277f0aab777aeab1a159a91be06ff5579c7dfeff9340250fd4) Save this answer. (Loading when this answer was accepted…) (/posts/78790238/timeline) Show activity on this post. In my case (on Mac) I had a /etc/ssl/cert_new.pem instead of the default cert filename /etc/ssl/cert.pem . So I run sudo cp cert_new.pem cert.pem and all the ssl issues fixed. (/a/78790238) (Short permalink to this answer) Share Share a link to this answer Copy link (https://creativecommons.org/licenses/by-sa/4.0/) (The current license for this post: CC BY-SA 4.0) CC BY-SA 4.0 (/posts/78790238/edit) () Improve this answer Follow (70:3:31e,16:b88576c890ab972c,10:1743964024,16:5d5ab0da93076759,8:78790238,37a9d5ba254a21f53d6047eb5ad149c64663c74a447355bd0dc19d7736ea15f0) Follow this answer to receive notifications answered (2024-07-24 19:27:46Z) Jul 24, 2024 at 19:27 (/users/3074131/menepet) (menepet's user avatar) (/users/3074131/menepet) menepet menepet (reputation score) 882 (15 silver badges) 15 15 silver badges (19 bronze badges) 19 19 bronze badges (Use comments to ask for more information or suggest improvements. Avoid comments like “+1” or “thanks”.) Add a comment | (Expand to show all comments on this post) This answer is useful (70:3:31e,16:70cadae76826e19d,10:1743964024,16:bed686e13842cc51,8:75589825,b644bcba9bd79fe4beea1f9f57b22ae5ba56e4bb2aa54a40901591fd63b3231c) -3 (This answer is not useful) (70:3:31e,16:e9f56091a7384c4d,10:1743964024,16:2dc51c8f2b3bc53e,8:75589825,3dbca22ece21e44b2e1bbb8d80948fe966eb7463078c37c72476edec94929abd) Save this answer. (Loading when this answer was accepted…) (/posts/75589825/timeline) Show activity on this post. In my case, it was a permission issue try sudo curl ..... (/a/75589825) (Short permalink to this answer) Share Share a link to this answer Copy link (https://creativecommons.org/licenses/by-sa/4.0/) (The current license for this post: CC BY-SA 4.0) CC BY-SA 4.0 (/posts/75589825/edit) () Improve this answer Follow (70:3:31e,16:d420d799ac1e1902,10:1743964024,16:f770fedcd6979385,8:75589825,aaebd318535284c9bc71ea6704578d1a2fffdc432d2da125f4c5b4bcbbe17dee) Follow this answer to receive notifications answered (2023-02-28 08:59:43Z) Feb 28, 2023 at 8:59 (/users/391232/maverick) (Maverick's user avatar) (/users/391232/maverick) Maverick Maverick (reputation score) 1,187 (16 silver badges) 16 16 silver badges (44 bronze badges) 44 44 bronze badges (Use comments to ask for more information or suggest improvements. Avoid comments like “+1” or “thanks”.) Add a comment | (Expand to show all comments on this post) (/help/privileges/protect-questions) Highly active question . Earn 10 reputation (not counting the (https://meta.stackexchange.com/questions/141648/what-is-the-association-bonus-and-how-does-it-work) association bonus ) in order to answer this question. The reputation requirement helps protect this question from spam and non-answer activity. Start asking to get answers Find the answer to your question by asking. (/questions/ask) Ask question Explore related questions (/questions/tagged/curl) (show questions tagged 'curl') curl (/questions/tagged/https) (show questions tagged 'https') https See similar questions with these tags. The Overflow Blog (https://stackoverflow.blog/2025/04/03/from-training-to-inference-the-new-role-of-web-data-in-llms/?cb=1) From training to inference: The new role of web data in LLMs (https://stackoverflow.blog/2025/04/04/is-ai-a-bubble-or-a-revolution-the-answer-is-yes/?cb=1) Is AI a bubble or a revolution? The answer is yes. Featured on Meta (Meta Stack Exchange) (https://meta.stackexchange.com/questions/407927/changes-to-reporting-for-the-status-review-escalation-process?cb=1) Changes to reporting for the [status-review] escalation process (Meta Stack Overflow) (https://meta.stackoverflow.com/questions/421831/policy-generative-ai-e-g-chatgpt-is-banned?cb=1) Policy: Generative AI (e.g., ChatGPT) is banned (Meta Stack Overflow) (https://meta.stackoverflow.com/questions/433466/a-discussion-about-closed-and-potentially-useful-posts-on-stack-overflow?cb=1) A discussion about closed (and potentially useful) posts on Stack Overflow Linked (https://stackoverflow.com/q/46163537?lq=1) (Question score (upvotes - downvotes)) 1 (https://stackoverflow.com/questions/46163537/facebook-sdk-returned-an-error-error-setting-certificate-verify-locations?noredirect=1&lq=1) Facebook SDK returned an error: error setting certificate verify locations (https://stackoverflow.com/q/26476744?lq=1) (Question score (upvotes - downvotes)) 107 (https://stackoverflow.com/questions/26476744/nvm-ls-remote-command-results-in-n-a?noredirect=1&lq=1) nvm ls-remote command results in "N/A" (https://stackoverflow.com/q/24832972?lq=1) (Question score (upvotes - downvotes)) 57 (https://stackoverflow.com/questions/24832972/docker-apt-get-update-fails?noredirect=1&lq=1) Docker apt-get update fails (https://stackoverflow.com/q/37227854?lq=1) (Question score (upvotes - downvotes)) 28 (https://stackoverflow.com/questions/37227854/pyenv-build-failed-ubuntu-15-04-using-python-build-20160509?noredirect=1&lq=1) pyenv: BUILD FAILED (Ubuntu 15.04 using python-build 20160509) (https://stackoverflow.com/q/31643036?lq=1) (Question score (upvotes - downvotes)) 14 (https://stackoverflow.com/questions/31643036/devtoolsinstall-github-fails-with-ca-cert-error?noredirect=1&lq=1) devtools::install_github fails with CA cert error (https://stackoverflow.com/q/64761861?lq=1) (Question score (upvotes - downvotes)) 5 (https://stackoverflow.com/questions/64761861/how-to-fix-cert-location-of-curl?noredirect=1&lq=1) how to fix cert location of curl (https://stackoverflow.com/q/30737794?lq=1) (Question score (upvotes - downvotes)) 4 (https://stackoverflow.com/questions/30737794/curl-error-77-error-setting-certificate-verify-locations?noredirect=1&lq=1) cURL error: [77] error setting certificate verify locations (https://stackoverflow.com/q/34356814?lq=1) (Question score (upvotes - downvotes)) 5 (https://stackoverflow.com/questions/34356814/error-setting-certificate-verify-locations-cafile-ca-bundle-crt-capath-none?noredirect=1&lq=1) error setting certificate verify locations: CAfile ca-bundle.crt CApath: none (https://stackoverflow.com/q/72608643?lq=1) (Question score (upvotes - downvotes)) 3 (https://stackoverflow.com/questions/72608643/ubuntu-22-04-lts-and-composer-curl-error-60-ssl-certificate-problem-unable-to?noredirect=1&lq=1) Ubuntu 22.04 LTS and Composer curl error 60 - SSL certificate problem: unable to get local issuer certificate (https://stackoverflow.com/q/33498093?lq=1) (Question score (upvotes - downvotes)) 2 (https://stackoverflow.com/questions/33498093/php-curl-error-unable-to-use-client-certificate-no-key-found-or-wrong-pass-phr?noredirect=1&lq=1) PHP CURL error: unable to use client certificate (no key found or wrong pass phrase?) (https://stackoverflow.com/questions/linked/3160909?lq=1) See more linked questions Related (https://stackoverflow.com/q/8939616?rq=3) (Question score (upvotes - downvotes)) 0 (https://stackoverflow.com/questions/8939616/using-curl-to-read-from-https-response?rq=3) Using cURL to read from https response (https://stackoverflow.com/q/10079707?rq=3) (Question score (upvotes - downvotes)) 215 (https://stackoverflow.com/questions/10079707/https-connection-using-curl-from-command-line?rq=3) https connection using CURL from command line (https://stackoverflow.com/q/14448815?rq=3) (Question score (upvotes - downvotes)) 4 (https://stackoverflow.com/questions/14448815/how-to-make-an-https-request-using-curl?rq=3) How to make an HTTPS request using cURL? (https://stackoverflow.com/q/19351052?rq=3) (Question score (upvotes - downvotes)) 8 (https://stackoverflow.com/questions/19351052/ssl-certificate-error?rq=3) SSL certificate error (https://stackoverflow.com/q/28767117?rq=3) (Question score (upvotes - downvotes)) 9 (https://stackoverflow.com/questions/28767117/using-curl-with-certificate-that-has-no-password?rq=3) Using curl with certificate that has no password (https://stackoverflow.com/q/36431179?rq=3) (Question score (upvotes - downvotes)) 17 (https://stackoverflow.com/questions/36431179/using-curl-with-cert?rq=3) Using curl with --cert (https://stackoverflow.com/q/49258708?rq=3) (Question score (upvotes - downvotes)) 1 (https://stackoverflow.com/questions/49258708/curl-not-validating-certifcate?rq=3) CURL not validating certifcate (https://stackoverflow.com/q/50148785?rq=3) (Question score (upvotes - downvotes)) 0 (https://stackoverflow.com/questions/50148785/curl-certificate-verification-failed?rq=3) Curl certificate verification failed (https://stackoverflow.com/q/57331315?rq=3) (Question score (upvotes - downvotes)) 1 (https://stackoverflow.com/questions/57331315/unable-to-connect-curl-on-https?rq=3) Unable to connect curl on HTTPS (https://stackoverflow.com/q/71527663?rq=3) (Question score (upvotes - downvotes)) 3 (https://stackoverflow.com/questions/71527663/ssl-certificate-problem-with-curl-sslcerts?rq=3) SSL certificate problem with cURL - sslcerts (https://stackexchange.com/questions?tab=hot) Hot Network Questions (Home Improvement Stack Exchange) (https://diy.stackexchange.com/questions/316658/how-to-fix-lawn-where-car-drives-over) How to fix lawn where car drives over (Physics Stack Exchange) (https://physics.stackexchange.com/questions/846849/contrasting-results-about-time-intervals-measured-by-stationary-and-moving-obser) Contrasting results about time intervals measured by stationary and moving observers: why? (German Language Stack Exchange) (https://german.stackexchange.com/questions/79042/contracting-the-first-person-singular-pr%c3%a4teritum) Contracting the First-Person Singular Präteritum (Physics Stack Exchange) (https://physics.stackexchange.com/questions/847007/intuition-for-maupertuis-action-and-the-principle-of-least-action) Intuition for Maupertuis' action and the principle of least action (French Language Stack Exchange) (https://french.stackexchange.com/questions/55713/pronunciation-of-par-hasard) Pronunciation of "par hasard" (Code Golf Stack Exchange) (https://codegolf.stackexchange.com/questions/279050/efficiently-navigate-a-6-sided-die) Efficiently navigate a 6 sided die (Puzzling Stack Exchange) (https://puzzling.stackexchange.com/questions/131286/an-excellent-description) An excellent description (The Workplace Stack Exchange) (https://workplace.stackexchange.com/questions/200666/how-can-i-assert-myself-and-earn-respect-in-a-new-team-where-the-tech-lead-and-a) How can I assert myself and earn respect in a new team where the tech lead and architect dominate discussions and dismiss my input? (Mathematica Stack Exchange) (https://mathematica.stackexchange.com/questions/312023/unwanted-vector-in-vectorplot) Unwanted vector in VectorPlot (Arqade) (https://gaming.stackexchange.com/questions/411753/will-switch-2-also-support-original-switch-joy-cons) Will Switch 2 also support original Switch Joy-Cons? (Bicycles Stack Exchange) (https://bicycles.stackexchange.com/questions/96481/do-hydraulic-disc-brakes-have-an-expiry-date) Do hydraulic disc brakes have an expiry date (Retrocomputing Stack Exchange) (https://retrocomputing.stackexchange.com/questions/31545/what-is-the-origin-of-corruption-in-rom-memories) What is the origin of corruption in ROM memories? (Electrical Engineering Stack Exchange) (https://electronics.stackexchange.com/questions/743185/kicad-added-footprints-only-addable-in-pcb-editor) KiCad added footprints only addable in PCB Editor (Puzzling Stack Exchange) (https://puzzling.stackexchange.com/questions/131293/two-circles-and-a-pentagon) Two circles and a pentagon (Science Fiction & Fantasy Stack Exchange) (https://scifi.stackexchange.com/questions/295870/a-melted-plastic-container-results-in-a-room-temperature-super-conductor) A melted plastic container results in a room-temperature super-conductor (History of Science and Mathematics Stack Exchange) (https://hsm.stackexchange.com/questions/18457/who-first-showed-the-famous-best-worst-case-complexity-on-sorting-algorithms) Who first showed the famous best worst case complexity on sorting algorithms? (Stack Overflow) (https://stackoverflow.com/questions/79555310/implicit-declaration-of-standard-function-in-c) Implicit declaration of standard function in C (Economics Stack Exchange) (https://economics.stackexchange.com/questions/60216/doesnt-a-negative-compensating-variation-cv-mean-the-change-is-good-while-po) Doesn't a negative compensating variation (CV) mean the change is good (while positive means it's bad)? (Electrical Engineering Stack Exchange) (https://electronics.stackexchange.com/questions/743097/is-an-8-bit-oscilloscope-for-fpga-signal-measurement-sufficient) Is an 8 bit oscilloscope for FPGA signal measurement sufficient? (Signal Processing Stack Exchange) (https://dsp.stackexchange.com/questions/96494/should-we-call-mp3-mpeg-mp4-etc-are-a-kind-of-source-coding-in-telecommunica) Should we call .mp3, mpeg, mp4, etc are a kind of source coding in telecommunications? (Movies & TV Stack Exchange) (https://movies.stackexchange.com/questions/125017/what-language-is-captain-america-speaking-when-talking-to-batroc-in-winter-soldi) What language is Captain America speaking when talking to Batroc in Winter Soldier? (Worldbuilding Stack Exchange) (https://worldbuilding.stackexchange.com/questions/265722/drawbacks-of-stem-cell-regeneration-with-magic) Drawbacks of stem cell regeneration with magic? (Japanese Language Stack Exchange) (https://japanese.stackexchange.com/questions/107404/what-does-the-verb-%e3%81%b6%e3%81%a3%e3%81%a1%e3%82%83%e3%81%a3%e3%81%a6-here-mean) What does the verb ぶっちゃって here mean? (Home Improvement Stack Exchange) (https://diy.stackexchange.com/questions/316584/are-these-concrete-steps-fixable) Are these concrete steps fixable? (/feeds/question/3160909) (Feed of this question and its answers) Question feed Subscribe to RSS Question feed To subscribe to this RSS feed, copy and paste this URL into your RSS reader. (https://stackoverflow.com/feeds/question/3160909) () (https://stackoverflow.com) (https://stackoverflow.com) Stack Overflow (/questions) Questions (/help) Help (https://chat.stackoverflow.com/?tab=site&host=stackoverflow.com) Chat (https://stackoverflow.co/) Products (https://stackoverflow.co/teams/?utm_medium=referral&utm_source=stackoverflow-community&utm_campaign=footer&utm_content=teams) Teams (https://stackoverflow.co/advertising/?utm_medium=referral&utm_source=stackoverflow-community&utm_campaign=footer&utm_content=advertising) Advertising (https://stackoverflow.co/advertising/employer-branding/?utm_medium=referral&utm_source=stackoverflow-community&utm_campaign=footer&utm_content=talent) Talent (https://stackoverflow.co/) Company (https://stackoverflow.co/) About (https://stackoverflow.co/company/press/) Press (https://stackoverflow.co/company/work-here/) Work Here (https://stackoverflow.com/legal) Legal (https://stackoverflow.com/legal/privacy-policy) Privacy Policy (https://stackoverflow.com/legal/terms-of-service/public) Terms of Service (/contact) Contact Us Your Privacy Choices (https://stackoverflow.com/legal/cookie-policy) Cookie Policy (https://stackexchange.com) Stack Exchange Network (https://stackexchange.com/sites#technology) Technology (https://stackexchange.com/sites#culturerecreation) Culture & recreation (https://stackexchange.com/sites#lifearts) Life & arts (https://stackexchange.com/sites#science) Science (https://stackexchange.com/sites#professional) Professional (https://stackexchange.com/sites#business) Business (https://api.stackexchange.com/) API (https://data.stackexchange.com/) Data (https://stackoverflow.blog?blb=1) Blog (https://www.facebook.com/officialstackoverflow/) Facebook (https://twitter.com/stackoverflow) Twitter (https://linkedin.com/company/stack-overflow) LinkedIn (https://www.instagram.com/thestackoverflow) Instagram Site design / logo © 2025 Stack Exchange Inc; user contributions licensed under (https://stackoverflow.com/help/licensing) CC BY-SA . rev 2025.4.4.24803 By clicking “Accept all cookies”, you agree Stack Exchange can store cookies on your device and disclose information in accordance with our (https://stackoverflow.com/legal/cookie-policy) Cookie Policy . Accept all cookies Necessary cookies only Customize settings