Help us shape the future of Go! Take the 2026 Go Developer Survey

osxcrossfix

package module
v0.0.0-...-f5e6179 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 7, 2014 License: MIT Imports: 0 Imported by: 0

README

Package osxcrossfix solves the common problem of not being able to access the system's root certificates when cross-compiling for darwin. The error usually encountered when trying this is

x509: failed to load system roots and no roots provided

This problem is solved by bundling the most common signing authiorities' certificates into the binary and injecting them into the http.DefaultClient.

The package has a build constraint and will be completely empty unless compiling for darwin while cgo is disabled. An underscore import

import _ "github.com/voxelbrain/osxcrossfix"

is therefore always safe to do.

Documentation

Overview

Package osxcrossfix solves the common problem of not being able to access the system's root certificates when cross-compiling for darwin. The error usually encountered when trying this is

x509: failed to load system roots and no roots provided

This problem is solved by bundling the most common signing authiorities' certificates into the binary and injecting them into the http.DefaultClient.

The package has a build constraint and will be completely empty unless compiling for darwin while cgo is disabled. An underscore import

import _ "github.com/voxelbrain/osxcrossfix"

is therefore always safe to do.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL