Open-source Languages & Tools for z/OS

 View Only
  • 1.  GIT: SSL Certificate Problem: Unable to Get Local Issuer Certificate

    Posted 07-15-2020 04:34

    I am having this error when trying to clone from GitHub.
    One workaround is to add -c http.sslVerify=false to the git command line, but this introduces security problems.

    I have found online that I have to apply this configuration to git:
    git config --system http.sslCAPath /absolute/path/to/git/certificates
    where /absolute/path/to/git/certificates is a path that points to a CA certificate bundle.

    However, when I try to run that command I get this error:
    error: could not lock config file /rsusr/ported/etc/gitconfig: EDC5129I No such file or directory.

    The problem here is that I do NOT have rocket software tools installed into that directory.
    Instead, I have them installed into /bkde/rocket, and all the GIT_* environment variables point there:

    SIGDC@BVLSYSA [~/]$ env |grep -i git   
    GIT_SHELL=/bkde/rocket/bin/bash
    GIT_MAN_PATH=/bkde/rocket/man
    GIT_TEMPLATE_DIR=/bkde/rocket/share/git-core/templates
    GIT_EXEC_PATH=/bkde/rocket/libexec/git-core
    

    So why is git looking into /rsusr/ported/etc/ (which I suppose is the default hard-coded path when GIT_* env vars are not set)??



  • 2.  RE: GIT: SSL Certificate Problem: Unable to Get Local Issuer Certificate

    ROCKETEER
    Posted 07-15-2020 08:49

    Hi Cris70,

    You can try to add GIT_SSL_CAINFO variable.
    Download certificate file from https://curl.haxx.se and export GIT_SSL_CAINFO
    curl -s -k https://curl.haxx.se/ca/cacert.pem -o cacert.pem
    export GIT_SSL_CAINFO=/path/to/your/cacert.pem

    Thanks,
    Alexander



  • 3.  RE: GIT: SSL Certificate Problem: Unable to Get Local Issuer Certificate

    Posted 07-16-2020 03:38

    Thank you @Alex, that solved my issue!
    Though I still think Rocket Software should look into the original issue (i.e. GIT using a hard-coded path).