This site is currently in read-only mode during migration to a new platform.
You cannot post questions, answers or comments, as they would be lost during the migration otherwise.
+4 votes

I'm trying to do an HTTPRequest to a url that uses SLL. I've read over this: http://docs.godotengine.org/en/3.0/tutorials/networking/ssl_certificates.html

I'm not really understanding where to acquire the certificate it needs, I thought I exported it from the browser and added, but it still does not seem to work, reporting RESULT_CONNECTION_ERROR = 4 — Request failed due to connection(read/write) error.

If anyone has information or a more detailed explanation on the proper methods for acquiring and applying SSL certs that is compatible with a Godot project, please let me know. Thanks. X)

in Engine by (5,286 points)

1 Answer

+5 votes
Best answer

The certificate bundle is currently not automatically included when exporting – this may change in a future release.

To enable support for SSL verification after exporting, you can save ca-certificates.crt from the Godot Git repository, place it somewhere in your project, specify its path in Project Settings → Network → Ssl → Certificates then export the project.

Note that the certificate bundle is never used when exporting to HTML5; the browser will handle SSL verification instead (since it relies on XMLHttpRequest to perform HTTP requests). There are a few other restrictions in this case as well.

Update: Starting from Godot 3.1, SSL certificates will be included in export templates.

by (12,908 points)
edited by

Awesome, big thanks for that answer Calinou. Problem resolved. X)

I'm just starting to explore this stuff, and had no idea it was a bundle of certificates stored in the repo. Is making more sense now though.

Welcome to Godot Engine Q&A, where you can ask questions and receive answers from other members of the community.

Please make sure to read Frequently asked questions and How to use this Q&A? before posting your first questions.
Social login is currently unavailable. If you've previously logged in with a Facebook or GitHub account, use the I forgot my password link in the login box to set a password for your account. If you still can't access your account, send an email to [email protected] with your username.