Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrading to OSX 10.12.1 breaks the ability to "go get" packages from gopkg.in #47

Closed
gmendel opened this issue Nov 7, 2016 · 15 comments

Comments

@gmendel
Copy link

gmendel commented Nov 7, 2016

Can not get packages like go get gopkg.in/alecthomas/kingpin.v2. It will fail with the following error: Unknown SSL protocol error in connection to gopkg.in:-9838

@aidan-
Copy link

aidan- commented Nov 8, 2016

I am receiving this same error but on a different version of OSX (10.11.6). It looks like this issue is not specific to the go get tool but with git itself.

heylook:temp aidan$ git clone https://gopkg.in/yaml.v2
Cloning into 'yaml.v2'...
fatal: unable to access 'https://gopkg.in/yaml.v2/': Unknown SSL protocol error in connection to gopkg.in:-9838
heylook:temp aidan$ git --version
git version 2.7.4 (Apple Git-66)

EDIT: This looks to be working now?

@liudanking
Copy link

+1

@jedisct1
Copy link

Same here

@niemeyer
Copy link
Owner

Can you please try this:

git config --global http.sslVerify true

@rscottfree
Copy link

@niemeyer
git config --global http.sslVerify true
This worked for me. However, it would be nice if it worked with sslVerify set to false as well.

@niemeyer
Copy link
Owner

I'm probably missing something fundamental about this problem.. why would you like to disable verification?

@adamveld12
Copy link

I had the same issue too:

go get -v gopkg.in/fatih/pool.v2
Fetching https://gopkg.in/fatih/pool.v2?go-get=1
Parsing meta tags from https://gopkg.in/fatih/pool.v2?go-get=1 (status code 200)
get "gopkg.in/fatih/pool.v2": found meta tag main.metaImport{Prefix:"gopkg.in/fatih/pool.v2", VCS:"git", RepoRoot:"https://gopkg.in/fatih/pool.v2"} at https://gopkg.in/fatih/pool.v2?go-get=1
gopkg.in/fatih/pool.v2 (download)
# cd .; git clone https://gopkg.in/fatih/pool.v2 /Users/Adam/projects/go/src/gopkg.in/fatih/pool.v2
Cloning into '/Users/Adam/projects/go/src/gopkg.in/fatih/pool.v2'...
fatal: unable to access 'https://gopkg.in/fatih/pool.v2/': Unknown SSL protocol error in connection to gopkg.in:-9838
package gopkg.in/fatih/pool.v2: exit status 128

Adding the git config line @niemeyer mentioned fixed it for me.

@rscottfree
Copy link

@niemeyer - If I recall correctly, I had to disable ssl verification in order to access some NPM packages on a server using self-signed certificates and for getting around a corporate firewall that rewrote certificates.

@niemeyer
Copy link
Owner

I'm sure this is obvious to most people here, but it must be said: replacing TLS certificates or disabling their verification pretty much kills the point of using TLS. I'd strongly encourage not doing that.

At the same time, I don't understand what the deal is with the TLS library being used by git in your systems. If the certificate is valid when it checks it, how can it possibly break when it's not checking it?

I'm closing this issue, as it doesn't look like a problem on gopkg.in.

@B35T
Copy link

B35T commented Nov 18, 2016

Thank You. @niemeyer
//git config --global http.sslVerify true

@niemeyer
Copy link
Owner

Yes, per notes above, git client on Mac apparently breaks when not validating a valid certificate.

Just enable validation (it's a good idea, btw!) and it works.

@rscottfree
Copy link

That's not accurate. When sslVerify is false I can git clone from an https endpoint on Github without issue. Same for bitbucket. However, I am unable to git clone from https://gopkg.in

git clone https://gopkg.in/fatih/pool.v2 fails
while git clone https://github.com/angular/material.git works.

Perhaps it is the type of ssl certificate in use that the Mac git client struggles with, but it works fine not validating valid certificates other than the gopkg cert.

@niemeyer
Copy link
Owner

Yes, the fact it works with other certificates doesn't say much. Is the certificate valid? Yes. Does it work when that same git client validates it? Yes. Does it work on every other browser and every other git client? Yes. So, all evidence points to a bug on the client.

I'm obviously still open to any information that would say otherwise.

@subbu05
Copy link

subbu05 commented Jan 17, 2017

git config --global http.sslVerify true will resolve SSL errors

@edagarli
Copy link

fantastic

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

10 participants