jfrog / jfrog-cli

JFrog CLI is a client that provides a simple interface that automates access to the JFrog products.
https://www.jfrog.com/confluence/display/CLI/JFrog+CLI
Apache License 2.0
534 stars 234 forks source link

how to configure cli trust store #277

Open torstenstach opened 5 years ago

torstenstach commented 5 years ago

>jfrog rt ping --url=https://artprod.issh.de/artifactory [Error] Get https://artprod.issh.de/artifactory/api/system/ping: x509: certificate signed by unknown authority how to configure the jfrog-cli trust store?

eyalbe4 commented 5 years ago

@torstenstach, Here's you add your self signed certificates. Disabling the use of SSL certificates is currently not supported, but we're considering add it. Let us know if this helps.

torstenstach commented 5 years ago

No this does not help. under windows cli is unable to check the whole certificate chain. WORKAROUND: install the sub-ca certificate also as Trusted Root Certificate

Can you fix this?

image

eyalbe4 commented 5 years ago

@torstenstach, Are you using the latest JFrog CLI version? (currently the latest version is 1.22.0). I'm asking because you may be affected by https://github.com/golang/go/issues/18609. The latest JFrog CLI release is built with Go 1.11, which should include this fix.

torstenstach commented 5 years ago

I have the same problem with version 1.22.0

eyalbe4 commented 5 years ago

@torstenstach, Actually, we need to wait for this issue to be fixed - https://github.com/golang/go/issues/16736 I'm not sure there's anything we can do before it is fixed by go... We have tried to fix this in the past by adding https://github.com/jfrog/jfrog-client-go/blob/master/artifactory/auth/cert/sslutils_windows.go (runs for Windows only), but there's a chance this code is not perfect. I see no other option but waiting for the above issue to be fixed.

moeHaydar commented 5 years ago

I have the same problem, any news about this ?

vdsbenoit commented 4 years ago

+1

kenden commented 4 years ago

About: "is there a way to disable the check?" The option --insecure-tls was added recently: https://github.com/jfrog/jfrog-cli/blob/master/RELEASE.md#1351-mar-18-2020

kenyon commented 1 year ago

This link from https://github.com/jfrog/jfrog-cli/issues/277#issuecomment-440280090 is now broken and I'm really having a hard time finding the current location of documentation on using JFrog CLI with internal certificate authorities: https://www.jfrog.com/confluence/display/CLI/CLI+for+JFrog+Artifactory#CLIforJFrogArtifactory-UsingSelf-signedSSLCertificates

emveee commented 1 year ago

This link from #277 (comment) is now broken and I'm really having a hard time finding the current location of documentation on using JFrog CLI with internal certificate authorities: https://www.jfrog.com/confluence/display/CLI/CLI+for+JFrog+Artifactory#CLIforJFrogArtifactory-UsingSelf-signedSSLCertificates

https://web.archive.org/web/20191007071125/https://www.jfrog.com/confluence/display/CLI/CLI+for+JFrog+Artifactory

larkoie commented 9 months ago

FYI the issue is still existing in jfrog cli 2.52.9 (latest at the time of my comment). The bug https://github.com/golang/go/issues/16736 looks fixed (closed completed in november 2021)

Can somebody take a look at this now? Thanks

mathieugouin commented 3 weeks ago

I have version 2.71.0 of the cli.

I have exactly the same problem. To add more info, SSL works with curl -UseBasicParsing "https://artifactory.example.com/artifactory/api/system/ping" but not with jfrog rt ping.

I have installed my root CA certificate in my Docker image using:

Any other clue?