Network and updates
Certificates (TLS)
6 min read
Every HTTPS server presents a certificate, and git checks that certificate before sending or receiving anything. On corporate networks, this usually fails for three reasons:
- the company's certificate authority isn't in the list git uses;
- the authority's revocation service (CRL/OCSP) doesn't respond from inside the network;
- a proxy or firewall intercepts the connection.
Versora recognizes these errors in git's output, explains each one in the interface language and, when there's a safe fix, offers the button that applies it. The fix is always shown first, with the exact command, and can be removed later.
Tip
Versora's calls to GitLab and GitHub (merge requests, pipelines, issues) already use the Windows certificates, including the company's root certificate. This page is about Git commands: clone, fetch, pull and push over HTTPS.
Caution
Versora never turns off certificate verification (http.sslVerify). Turning off verification leaves the connection open to interception and isn't offered anywhere in the app.
The Certificates (TLS) group shows which certificate list git is using and the certificate settings that exist in your global git configuration.
- Menu: Preferences › Network › Certificates (TLS)
- Palette (Ctrl+P): "Preferences: Network"
- Open Preferences › Network and scroll down to Certificates (TLS).
- Read the line "Git checks certificates with: …". The possible values are:
- Git's default (not configured);
- Windows certificates (schannel);
- Git's own list (OpenSSL).
- If the value comes from a specific place, the next line says "Set in Git's … configuration scope."
- Below are the settings already written, one per line:
- All servers or the server's address;
- "Check certificates with: …", "No certificate revocation check" or "Revocation check: …";
- each one's Remove… button.
IT usually installs the company's root certificate in the Windows certificate store. The browser and Versora already trust it. Git, however, may be using its own list (OpenSSL), which doesn't know that certificate. This setting makes git check certificates through Windows (schannel). Verification stays on.
- In the error notice of a fetch, pull, push or clone: Use Windows certificates… button
- Menu: Preferences › Network › Certificates (TLS) › Use Windows certificates… (for all servers)
- A push to
https://gitlab.empresa.com.br/time/app.gitfails. The notice explains: "Git didn't recognize the server's certificate: it's using its own certificate list (OpenSSL), which doesn't include your company's certificate authority…" - Click Use Windows certificates….
- In the Use Windows certificates window, choose under Where to apply:
- Only for gitlab.empresa.com.br: "Other servers stay as they are."
- For all servers: "Applies to any HTTPS remote."
- Check the command under "This will be written to Git's global configuration (…):".
- Click Save.
- The notice confirms, for example: "Git now uses the Windows certificates for gitlab.empresa.com.br. Repeat the operation."
- Repeat the push.
When opened from Preferences, the window writes for all servers.
| Option | What it does | Default |
|---|---|---|
| Only for ‹server› | Writes the setting only for that address. | Yes, when the window comes from an error |
| For all servers | Writes the setting for any HTTPS remote. | Yes, when the window comes from Preferences |
# Only for one server
git config --global http.https://gitlab.empresa.com.br.sslBackend schannel
# For all servers
git config --global http.sslBackend schannel
The setting stays in your global git configuration. It also applies outside Versora: in the terminal, in the editor and in any other tool that uses the same git.
Ctrl+Z doesn't undo this setting. In Preferences › Network › Certificates (TLS), click Remove… on the setting's line. The Remove the certificate setting? window shows the command:
git config --global --unset-all http.https://gitlab.empresa.com.br.sslBackend
Confirm with Remove. "The option is removed and Git's default applies (or the system configuration's, if any)."
- "Replaces the current value (…). Removing the setting later deletes the option: the previous value doesn't come back by itself.": appears when the key already had a value. Note down the old value if you want to go back to it.
- "Git already uses the Windows certificates for all servers.": the Preferences button is disabled, because there's nothing to change.
- "Not even Windows trusts the server's certificate: the authority that issued it isn't in "Trusted Root Certification Authorities". Ask IT for the company's root certificate (or to install it) and try again. Turning off certificate verification isn't a safe fix.": the problem isn't git's. The root certificate needs to be installed in Windows.
There's no policy key for this setting: it belongs to each person's git configuration.
For IT
The cleanest way to solve it for everyone is to install the company's root certificate in Windows' "Trusted Root Certification Authorities" through GPO. With git using schannel, there's no need to distribute certificate files.
With the Windows certificates, git asks the certificate authority whether the certificate was revoked (canceled). On internal networks, the service that answers this (CRL/OCSP) is often not reachable, and git fails even with a good certificate. This setting skips that lookup for one server only. The certificate's validity, name and chain are still checked.
- In the error notice of a fetch, pull, push or clone: Skip revocation check for ‹server›… button
It doesn't exist in Preferences: the setting is only offered from a real error, for a known server.
- A fetch fails. The notice explains: "Windows couldn't check whether the server's certificate was revoked: the certificate authority's revocation service (CRL/OCSP) doesn't respond from this network — common on internal networks. You can skip this check for this server only."
- Click Skip revocation check for gitlab.empresa.com.br….
- Read the Skip the certificate revocation check for gitlab.empresa.com.br window, including the warning: "The revocation check catches canceled certificates (for example, after a leak). Use this only for an internal company server you know."
- Click Save for gitlab.empresa.com.br.
- The notice confirms: "Revocation is no longer required for gitlab.empresa.com.br's certificate. Repeat the operation."
git config --global http.https://gitlab.empresa.com.br.schannelCheckRevoke false
Versora doesn't offer turning off revocation for all servers. If the window is called that way, it refuses: "Versora doesn't offer this certificate setting."
In Preferences › Network › Certificates (TLS), the server's line shows "No certificate revocation check". Click Remove… and confirm with Remove.
git config --global --unset-all http.https://gitlab.empresa.com.br.schannelCheckRevoke
- "Invalid server address for the certificate setting: …": the remote's address isn't a recognizable HTTPS server.
- If the error message doesn't include the server's address, the notice explains the problem, but doesn't show the button.
The notices below appear in place of git's raw message. Versora recognizes the error by the Windows
codes (SEC_E_…, CRYPT_E_…, 0x8009…), which don't depend on the system language.
| Notice | What it means | What to do |
|---|---|---|
| "Git didn't recognize the server's certificate: it's using its own certificate list (OpenSSL)…" | The company's authority isn't in git's list. | Use Windows certificates… |
| "Not even Windows trusts the server's certificate…" | The root certificate is missing from Windows. | Ask IT to install the root certificate. |
| "Windows couldn't check whether the server's certificate was revoked…" | The revocation service doesn't respond from this network. | Skip revocation check for ‹server›… |
| "The server's certificate was revoked by the authority that issued it…" | The certificate was canceled. | Tell the server's administrator and don't use the address. |
| "The server's certificate has expired — or this computer's date and time are wrong…" | Expired certificate or wrong clock. | Check the Windows clock; if it's right, tell the server's administrator. |
| "The certificate presented isn't for this address…" | The remote URL uses another name (or the IP), or something intercepts the connection. | Use the server's official address in the remote. |
| "The secure connection (TLS) failed before the certificate was checked…" | Usually, a proxy or firewall intercepting. | Check the proxy in Proxy. |
- Proxy
- Support diagnostics: the report shows the
http.sslBackendin effect. - git config in the git documentation (opens another site)