Skip to content

Authentication issue on MacOS #3130

Closed
Closed

Description

@dryganets

Some of my co-workers experience a weird authentication issue with git-lfs.

We have a login/password authentication over https.

I've tried to use different store methods:

  1. store
  2. keychain
  3. cache

None is working, while the same setup on the other machine works.
git is able to use the credentials stored while git-lfs is not.

I wonder if there is some kind of verbose mode which could give more inside on what is going on in git-lfs.

Activity

  1. ttaylorr commented on Jul 16, 2018

    @ttaylorr
    Contributor
  2. dryganets commented on Jul 18, 2018

    @dryganets
    Author

    Here is anonymized log for the failed attempt.

    You could see that git passes while git-lfs fails.

    michal-mac:react-dependencies HIDDEN_USER_NAME$ export GIT_TRACE=1
    michal-mac:react-dependencies HIDDEN_USER_NAME$ export GIT_CURL_VERBOSE=1
    michal-mac:react-dependencies HIDDEN_USER_NAME$ 
    michal-mac:react-dependencies HIDDEN_USER_NAME$ 
    michal-mac:react-dependencies HIDDEN_USER_NAME$ 
    michal-mac:react-dependencies HIDDEN_USER_NAME$ 
    michal-mac:react-dependencies HIDDEN_USER_NAME$ 
    michal-mac:react-dependencies HIDDEN_USER_NAME$ git submodule update --init
    13:46:46.317038 git.c:654               trace: exec: git-submodule update --init
    13:46:46.318189 run-command.c:637       trace: run_command: git-submodule update --init
    13:46:46.383488 git.c:654               trace: exec: git-sh-i18n--envsubst --variables 'usage: $dashless $USAGE'
    13:46:46.384806 run-command.c:637       trace: run_command: git-sh-i18n--envsubst --variables 'usage: $dashless $USAGE'
    13:46:46.405298 git.c:654               trace: exec: git-sh-i18n--envsubst 'usage: $dashless $USAGE'
    13:46:46.406455 run-command.c:637       trace: run_command: git-sh-i18n--envsubst 'usage: $dashless $USAGE'
    13:46:46.441055 git.c:415               trace: built-in: git rev-parse --git-dir
    13:46:46.466727 git.c:415               trace: built-in: git rev-parse --git-path objects
    13:46:46.484728 git.c:415               trace: built-in: git rev-parse -q --git-dir
    13:46:46.512591 git.c:415               trace: built-in: git rev-parse --show-prefix
    13:46:46.524551 git.c:415               trace: built-in: git rev-parse --show-toplevel
    13:46:46.549712 git.c:415               trace: built-in: git submodule--helper init
    13:46:46.567705 git.c:415               trace: built-in: git submodule--helper update-clone
    13:46:46.570492 run-command.c:1553      run_processes_parallel: preparing to run up to 1 tasks
    13:46:46.571024 run-command.c:637       trace: run_command: git submodule--helper clone --path v8 --name v8 --url https://skype.visualstudio.com/DefaultCollection/TPS/_git/v8-android-bin
    13:46:46.583078 git.c:415               trace: built-in: git submodule--helper clone --path v8 --name v8 --url https://skype.visualstudio.com/DefaultCollection/TPS/_git/v8-android-bin
    13:46:46.596062 run-command.c:1585      run_processes_parallel: done
    13:46:46.609819 git.c:415               trace: built-in: git submodule--helper name ADAL
    13:46:46.626387 git.c:415               trace: built-in: git config submodule.ADAL.update
    13:46:46.648577 git.c:415               trace: built-in: git submodule--helper relative-path ADAL 
    13:46:46.664460 git.c:415               trace: built-in: git rev-parse --local-env-vars
    13:46:46.676445 git.c:415               trace: built-in: git rev-parse --verify HEAD
    13:46:46.696038 git.c:415               trace: built-in: git submodule--helper name CocoaLumberjack
    13:46:46.708525 git.c:415               trace: built-in: git config submodule.CocoaLumberjack.update
    13:46:46.723592 git.c:415               trace: built-in: git submodule--helper relative-path CocoaLumberjack 
    13:46:46.737161 git.c:415               trace: built-in: git rev-parse --local-env-vars
    13:46:46.748199 git.c:415               trace: built-in: git rev-parse --verify HEAD
    13:46:46.766385 git.c:415               trace: built-in: git submodule--helper name OneAuth
    13:46:46.782099 git.c:415               trace: built-in: git config submodule.OneAuth.update
    13:46:46.795384 git.c:415               trace: built-in: git submodule--helper relative-path OneAuth 
    13:46:46.808773 git.c:415               trace: built-in: git rev-parse --local-env-vars
    13:46:46.824744 git.c:415               trace: built-in: git rev-parse --verify HEAD
    13:46:46.852204 git.c:415               trace: built-in: git submodule--helper name ZipArchive
    13:46:46.867724 git.c:415               trace: built-in: git config submodule.ZipArchive.update
    13:46:46.881662 git.c:415               trace: built-in: git submodule--helper relative-path ZipArchive 
    13:46:46.892888 git.c:415               trace: built-in: git rev-parse --local-env-vars
    13:46:46.904082 git.c:415               trace: built-in: git rev-parse --verify HEAD
    13:46:46.922341 git.c:415               trace: built-in: git submodule--helper name boost_1_63_0
    13:46:46.936858 git.c:415               trace: built-in: git config submodule.boost_1_63_0.update
    13:46:46.951929 git.c:415               trace: built-in: git submodule--helper relative-path boost_1_63_0 
    13:46:46.966105 git.c:415               trace: built-in: git rev-parse --local-env-vars
    13:46:46.977248 git.c:415               trace: built-in: git rev-parse --verify HEAD
    13:46:47.005012 git.c:415               trace: built-in: git submodule--helper name double-conversion-1.1.1
    13:46:47.025990 git.c:415               trace: built-in: git config submodule.double-conversion-1.1.1.update
    13:46:47.039908 git.c:415               trace: built-in: git submodule--helper relative-path double-conversion-1.1.1 
    13:46:47.051814 git.c:415               trace: built-in: git rev-parse --local-env-vars
    13:46:47.062284 git.c:415               trace: built-in: git rev-parse --verify HEAD
    13:46:47.076470 git.c:415               trace: built-in: git submodule--helper name fishhook
    13:46:47.088333 git.c:415               trace: built-in: git config submodule.fishhook.update
    13:46:47.100965 git.c:415               trace: built-in: git submodule--helper relative-path fishhook 
    13:46:47.113024 git.c:415               trace: built-in: git rev-parse --local-env-vars
    13:46:47.125685 git.c:415               trace: built-in: git rev-parse --verify HEAD
    13:46:47.146010 git.c:415               trace: built-in: git submodule--helper name folly-2016.09.26.00
    13:46:47.162898 git.c:415               trace: built-in: git config submodule.folly-2016.09.26.00.update
    13:46:47.178099 git.c:415               trace: built-in: git submodule--helper relative-path folly-2016.09.26.00 
    13:46:47.190038 git.c:415               trace: built-in: git rev-parse --local-env-vars
    13:46:47.200161 git.c:415               trace: built-in: git rev-parse --verify HEAD
    13:46:47.215165 git.c:415               trace: built-in: git submodule--helper name glog-0.3.3
    13:46:47.226666 git.c:415               trace: built-in: git config submodule.glog-0.3.3.update
    13:46:47.239268 git.c:415               trace: built-in: git submodule--helper relative-path glog-0.3.3 
    13:46:47.249814 git.c:415               trace: built-in: git rev-parse --local-env-vars
    13:46:47.258809 git.c:415               trace: built-in: git rev-parse --verify HEAD
    13:46:47.274100 git.c:415               trace: built-in: git submodule--helper name jsc-headers
    13:46:47.286798 git.c:415               trace: built-in: git config submodule.jsc-headers.update
    13:46:47.304116 git.c:415               trace: built-in: git submodule--helper relative-path jsc-headers 
    13:46:47.323464 git.c:415               trace: built-in: git rev-parse --local-env-vars
    13:46:47.338052 git.c:415               trace: built-in: git rev-parse --verify HEAD
    13:46:47.372878 git.c:415               trace: built-in: git submodule--helper name v8
    13:46:47.389149 git.c:415               trace: built-in: git config submodule.v8.update
    13:46:47.407927 git.c:415               trace: built-in: git submodule--helper relative-path v8 
    13:46:47.422997 git.c:415               trace: built-in: git rev-parse --local-env-vars
    13:46:47.467128 git.c:415               trace: built-in: git rev-parse --local-env-vars
    13:46:47.513560 git.c:654               trace: exec: git-sh-i18n--envsubst --variables 'Unable to checkout '\''$sha1'\'' in submodule path '\''$displaypath'\'''
    13:46:47.515136 run-command.c:637       trace: run_command: git-sh-i18n--envsubst --variables 'Unable to checkout '\''$sha1'\'' in submodule path '\''$displaypath'\'''
    13:46:47.541365 git.c:654               trace: exec: git-sh-i18n--envsubst 'Unable to checkout '\''$sha1'\'' in submodule path '\''$displaypath'\'''
    13:46:47.543083 run-command.c:637       trace: run_command: git-sh-i18n--envsubst 'Unable to checkout '\''$sha1'\'' in submodule path '\''$displaypath'\'''
    13:46:47.579640 git.c:654               trace: exec: git-sh-i18n--envsubst --variables 'Submodule path '\''$displaypath'\'': checked out '\''$sha1'\'''
    13:46:47.581316 run-command.c:637       trace: run_command: git-sh-i18n--envsubst --variables 'Submodule path '\''$displaypath'\'': checked out '\''$sha1'\'''
    13:46:47.609095 git.c:654               trace: exec: git-sh-i18n--envsubst 'Submodule path '\''$displaypath'\'': checked out '\''$sha1'\'''
    13:46:47.610904 run-command.c:637       trace: run_command: git-sh-i18n--envsubst 'Submodule path '\''$displaypath'\'': checked out '\''$sha1'\'''
    13:46:47.634953 git.c:415               trace: built-in: git rev-parse --local-env-vars
    13:46:47.652379 git.c:415               trace: built-in: git checkout -f -q 45a78ef44344d18883d1fffff4622f3fe126a137
    13:46:47.705176 run-command.c:637       trace: run_command: 'git-lfs filter-process'
    13:46:47.839774 trace git-lfs: exec: git 'version'
    13:46:47.865921 trace git-lfs: exec: git 'config' '-l'
    13:46:47.883596 trace git-lfs: Install hook: pre-push, force=false, path=/Users/HIDDEN_USER_NAME/Library/Android/react-dependencies/.git/modules/v8/hooks/pre-push, upgrading...
    13:46:47.927483 trace git-lfs: Install hook: post-checkout, force=false, path=/Users/HIDDEN_USER_NAME/Library/Android/react-dependencies/.git/modules/v8/hooks/post-checkout, upgrading...
    13:46:47.931717 trace git-lfs: Install hook: post-commit, force=false, path=/Users/HIDDEN_USER_NAME/Library/Android/react-dependencies/.git/modules/v8/hooks/post-commit, upgrading...
    13:46:47.971670 trace git-lfs: Install hook: post-merge, force=false, path=/Users/HIDDEN_USER_NAME/Library/Android/react-dependencies/.git/modules/v8/hooks/post-merge, upgrading...
    13:46:48.000445 trace git-lfs: Initialize filter-process
    13:46:48.000828 trace git-lfs: exec: git '-c' 'filter.lfs.smudge=' '-c' 'filter.lfs.clean=' '-c' 'filter.lfs.process=' '-c' 'filter.lfs.required=false' 'rev-parse' 'HEAD' '--symbolic-full-name' 'HEAD'
    13:46:48.051083 trace git-lfs: tq: running as batched queue, batch size of 100
    13:46:48.051453 trace git-lfs: filepathfilter: rejecting "armeabi-v7a/libc++_shared.so" via []
    13:46:48.051516 trace git-lfs: filepathfilter: accepting "armeabi-v7a/libc++_shared.so"
    13:46:48.091362 trace git-lfs: filepathfilter: rejecting "armeabi-v7a/libv8.cr.so" via []
    13:46:48.091393 trace git-lfs: filepathfilter: accepting "armeabi-v7a/libv8.cr.so"
    13:46:48.093225 trace git-lfs: filepathfilter: rejecting "armeabi-v7a/libv8_libbase.cr.so" via []
    13:46:48.093256 trace git-lfs: filepathfilter: accepting "armeabi-v7a/libv8_libbase.cr.so"
    13:46:48.095123 trace git-lfs: filepathfilter: rejecting "armeabi-v7a/libv8_libplatform.cr.so" via []
    13:46:48.095149 trace git-lfs: filepathfilter: accepting "armeabi-v7a/libv8_libplatform.cr.so"
    13:46:48.306706 trace git-lfs: filepathfilter: rejecting "x86/libc++_shared.so" via []
    13:46:48.306739 trace git-lfs: filepathfilter: accepting "x86/libc++_shared.so"
    13:46:48.309014 trace git-lfs: filepathfilter: rejecting "x86/libv8.cr.so" via []
    13:46:48.309049 trace git-lfs: filepathfilter: accepting "x86/libv8.cr.so"
    13:46:48.311353 trace git-lfs: filepathfilter: rejecting "x86/libv8_libbase.cr.so" via []
    13:46:48.311388 trace git-lfs: filepathfilter: accepting "x86/libv8_libbase.cr.so"
    13:46:48.313293 trace git-lfs: filepathfilter: rejecting "x86/libv8_libplatform.cr.so" via []
    13:46:48.313321 trace git-lfs: filepathfilter: accepting "x86/libv8_libplatform.cr.so"
    13:46:48.314361 trace git-lfs: tq: sending batch of size 8
    13:46:48.316377 trace git-lfs: api: batch 8 files
    13:46:48.678226 trace git-lfs: HTTP: POST https://skype.visualstudio.com/DefaultCollection/TPS/_git/v8-android-bin.git/info/lfs/objects/batch
    > POST /DefaultCollection/TPS/_git/v8-android-bin.git/info/lfs/objects/batch HTTP/1.1
    > Host: skype.visualstudio.com
    > Accept: application/vnd.git-lfs+json; charset=utf-8
    > Authorization: Basic * * * * *
    > Content-Length: 798
    > Content-Type: application/vnd.git-lfs+json; charset=utf-8
    > User-Agent: git-lfs/2.4.2 (GitHub; darwin amd64; go 1.10.2)
    > 
    {"operation":"download","objects":[{"oid":"725910140df210d0af2cd51ab897b0cd8387b3c4e8a638831278c216d3f69a7c","size":10928064},{"oid":"d452d76357156c57158f052973f8788678eab702c3283313c5588c8bcffaf338","size":8275276},{"oid":"1184f87efdd3d6e27fceb46c44ab2178a0218db00db029469b5daa9083265e63","size":1095276},{"oid":"ff27942fee03c076233782d9cb386387fbe2150d3dfd2bcbadaf23c0f56e325f","size":738760},{"oid":"78e93c5886e6357de0f6f3f73f23979d150370441598149fbf15d966e6c78491","size":109224},{"oid":"90bfd38ac726d7d08d710029e43c5b43cf1829663b78a76df73a0c8249b2f8a0","size":97164},{"oid":"cfd00ccc6994b273cc7aa82c9c9c283d13568f5fefdd754a8935df17fe20a412","size":76368},{"oid":"e593eaf3fc8bc4ce33e93aa43becfc1e43b3091df7ae34cd71f8800db3441ae5","size":55896}],"ref":{"name":"refs/heads/v8-android-bin_6.7.1"}}13:46:50.174279 trace git-lfs: HTTP: 401
    
    < HTTP/1.1 401 Unauthorized
    < Content-Length: 0
    < Activityid: 0ddfa2a6-cb69-4cc3-b6e6-99d667913f9f
    < Date: Wed, 18 Jul 2018 11:46:49 GMT
    < P3p: CP="CAO DSP COR ADMa DEV CONo TELo CUR PSA PSD TAI IVDo OUR SAMi BUS DEM NAV STA UNI COM INT PHY ONL FIN PUR LOC CNT"
    < Strict-Transport-Security: max-age=31536000; includeSubDomains
    < Www-Authenticate: Basic realm="https://tfsprodweu4.visualstudio.com/"
    < X-Content-Type-Options: nosniff
    < X-Frame-Options: SAMEORIGIN
    < X-Msedge-Ref: Ref A: 6CC5BF83D8E744A1A97C9BEA598D93FD Ref B: LON21EDGE1522 Ref C: 2018-07-18T11:46:50Z
    < X-Powered-By: ASP.NET
    < X-Tfs-Processid: 6129d631-c29f-4dac-9148-4ae799692f60
    < X-Tfs-Session: 0ddfa2a6-cb69-4cc3-b6e6-99d667913f9f
    < X-Vss-E2eid: 0ddfa2a6-cb69-4cc3-b6e6-99d667913f9f
    < 
    13:46:50.174723 trace git-lfs: api error: Authentication required: Authorization error: https://skype.visualstudio.com/DefaultCollection/TPS/_git/v8-android-bin.git/info/lfs/objects/batch
    Check that you have proper access to the repository
    13:46:50.175297 trace git-lfs: filepathfilter: rejecting "armeabi-v7a/libc++_shared.so" via []
    13:46:50.175314 trace git-lfs: filepathfilter: accepting "armeabi-v7a/libc++_shared.so"
    Downloading armeabi-v7a/libc++_shared.so (739 KB)
    13:46:50.175529 trace git-lfs: tq: running as batched queue, batch size of 100
    13:46:50.175595 trace git-lfs: tq: sending batch of size 1
    13:46:50.175679 trace git-lfs: api: batch 1 files
    13:46:50.175765 trace git-lfs: HTTP: POST https://skype.visualstudio.com/DefaultCollection/TPS/_git/v8-android-bin.git/info/lfs/objects/batch
    > POST /DefaultCollection/TPS/_git/v8-android-bin.git/info/lfs/objects/batch HTTP/1.1
    > Host: skype.visualstudio.com
    > Accept: application/vnd.git-lfs+json; charset=utf-8
    > Authorization: Basic * * * * *
    > Content-Length: 174
    > Content-Type: application/vnd.git-lfs+json; charset=utf-8
    > User-Agent: git-lfs/2.4.2 (GitHub; darwin amd64; go 1.10.2)
    > 
    {"operation":"download","objects":[{"oid":"ff27942fee03c076233782d9cb386387fbe2150d3dfd2bcbadaf23c0f56e325f","size":738760}],"ref":{"name":"refs/heads/v8-android-bin_6.7.1"}}13:46:50.216596 trace git-lfs: HTTP: 401
    
    < HTTP/1.1 401 Unauthorized
    < Content-Length: 0
    < Activityid: 0ddfa2a5-cb69-4cc3-b6e6-99d667913f9f
    < Date: Wed, 18 Jul 2018 11:46:50 GMT
    < P3p: CP="CAO DSP COR ADMa DEV CONo TELo CUR PSA PSD TAI IVDo OUR SAMi BUS DEM NAV STA UNI COM INT PHY ONL FIN PUR LOC CNT"
    < Strict-Transport-Security: max-age=31536000; includeSubDomains
    < Www-Authenticate: Basic realm="https://tfsprodweu4.visualstudio.com/"
    < X-Content-Type-Options: nosniff
    < X-Frame-Options: SAMEORIGIN
    < X-Msedge-Ref: Ref A: 09C9CCB7A3A44AF09067FF9902C10334 Ref B: LON21EDGE1522 Ref C: 2018-07-18T11:46:50Z
    < X-Powered-By: ASP.NET
    < X-Tfs-Processid: 6129d631-c29f-4dac-9148-4ae799692f60
    < X-Tfs-Session: 0ddfa2a5-cb69-4cc3-b6e6-99d667913f9f
    < X-Vss-E2eid: 0ddfa2a5-cb69-4cc3-b6e6-99d667913f9f
    < 
    13:46:50.216878 trace git-lfs: api error: Authentication required: Authorization error: https://skype.visualstudio.com/DefaultCollection/TPS/_git/v8-android-bin.git/info/lfs/objects/batch
    Check that you have proper access to the repository
    Error downloading object: armeabi-v7a/libc++_shared.so (ff27942): Smudge error: Error downloading armeabi-v7a/libc++_shared.so (ff27942fee03c076233782d9cb386387fbe2150d3dfd2bcbadaf23c0f56e325f): batch response: Authentication required: Authorization error: https://skype.visualstudio.com/DefaultCollection/TPS/_git/v8-android-bin.git/info/lfs/objects/batch
    Check that you have proper access to the repository
    
    Errors logged to /Users/HIDDEN_USER_NAME/Library/Android/react-dependencies/.git/modules/v8/lfs/logs/20180718T134650.217081742.log
    Use `git lfs logs last` to view the log.
    error: external filter 'git-lfs filter-process' failed
    fatal: armeabi-v7a/libc++_shared.so: smudge filter lfs failed
    Unable to checkout '45a78ef44344d18883d1fffff4622f3fe126a137' in submodule path 'v8'
    michal-mac:react-dependencies HIDDEN_USER_NAME$ 
    michal-mac:react-dependencies HIDDEN_USER_NAME$ 
    michal-mac:react-dependencies HIDDEN_USER_NAME$ 
    michal-mac:react-dependencies HIDDEN_USER_NAME$ 
    michal-mac:react-dependencies HIDDEN_USER_NAME$ 
    michal-mac:react-dependencies HIDDEN_USER_NAME$ 
    
    
    
    
    ###### Clone test ######
    
    
    
    
    michal-mac:react-dependencies HIDDEN_USER_NAME$ cd v8
    michal-mac:v8 HIDDEN_USER_NAME$ git remote -v
    13:48:41.917940 git.c:415               trace: built-in: git remote -v
    origin	https://skype.visualstudio.com/DefaultCollection/TPS/_git/v8-android-bin (fetch)
    origin	https://skype.visualstudio.com/DefaultCollection/TPS/_git/v8-android-bin (push)
    michal-mac:v8 HIDDEN_USER_NAME$ cd ..
    michal-mac:react-dependencies HIDDEN_USER_NAME$ 
    michal-mac:react-dependencies HIDDEN_USER_NAME$ 
    michal-mac:react-dependencies HIDDEN_USER_NAME$ 
    michal-mac:react-dependencies HIDDEN_USER_NAME$ 
    michal-mac:react-dependencies HIDDEN_USER_NAME$ 
    michal-mac:react-dependencies HIDDEN_USER_NAME$ git clone https://skype.visualstudio.com/DefaultCollection/TPS/_git/v8-android-bin v8-test
    13:48:58.651532 git.c:415               trace: built-in: git clone https://skype.visualstudio.com/DefaultCollection/TPS/_git/v8-android-bin v8-test
    Cloning into 'v8-test'...
    13:48:59.087315 run-command.c:637       trace: run_command: git-remote-https origin https://skype.visualstudio.com/DefaultCollection/TPS/_git/v8-android-bin
    *   Trying 13.107.6.175...
    * TCP_NODELAY set
    * Connected to skype.visualstudio.com (13.107.6.175) port 443 (#0)
    * ALPN, offering http/1.1
    * Cipher selection: ALL:!EXPORT:!EXPORT40:!EXPORT56:!aNULL:!LOW:!RC4:@STRENGTH
    * successfully set certificate verify locations:
    *   CAfile: /etc/ssl/cert.pem
      CApath: none
    * SSL connection using TLSv1.2 / ECDHE-RSA-AES128-GCM-SHA256
    * ALPN, server accepted to use http/1.1
    * Server certificate:
    *  subject: CN=visualstudio.com
    *  start date: Jun 21 19:43:52 2018 GMT
    *  expire date: Jun 21 19:43:52 2020 GMT
    *  subjectAltName: host "skype.visualstudio.com" matched cert's "*.visualstudio.com"
    *  issuer: C=US; ST=Washington; L=Redmond; O=Microsoft Corporation; OU=Microsoft IT; CN=Microsoft IT TLS CA 2
    *  SSL certificate verify ok.
    > GET /DefaultCollection/TPS/_git/v8-android-bin/info/refs?service=git-upload-pack HTTP/1.1
    Host: skype.visualstudio.com
    User-Agent: git/2.18.0
    Accept: */*
    Accept-Encoding: deflate, gzip
    Pragma: no-cache
    
    < HTTP/1.1 401 Unauthorized
    < Cache-Control: private
    < Content-Length: 8409
    < Content-Type: text/html; charset=utf-8
    < P3P: CP="CAO DSP COR ADMa DEV CONo TELo CUR PSA PSD TAI IVDo OUR SAMi BUS DEM NAV STA UNI COM INT PHY ONL FIN PUR LOC CNT"
    < WWW-Authenticate: Bearer authorization_uri=https://login.microsoftonline.com/72f988bf-86f1-41af-91ab-2d7cd011db47
    < WWW-Authenticate: Basic realm="https://tfsprodweu4.visualstudio.com/"
    < WWW-Authenticate: TFS-Federated
    < X-TFS-ProcessId: 82328673-9ee9-4a83-ac80-c8bf71180183
    < Strict-Transport-Security: max-age=31536000; includeSubDomains
    < ActivityId: eac8da7a-316d-485f-bd15-a2ba2ab6eaf7
    < X-TFS-Session: eac8da7a-316d-485f-bd15-a2ba2ab6eaf7
    < X-VSS-E2EID: eac8da7a-316d-485f-bd15-a2ba2ab6eaf7
    < X-FRAME-OPTIONS: SAMEORIGIN
    < X-TFS-FedAuthRealm: https://tfsprodweu4.visualstudio.com/
    < X-TFS-FedAuthIssuer: https://skype.visualstudio.com/
    < X-VSS-AuthorizationEndpoint: https://skype.vssps.visualstudio.com/
    < X-VSS-ResourceTenant: 72f988bf-86f1-41af-91ab-2d7cd011db47
    < X-AspNet-Version: 4.0.30319
    < X-TFS-SoapException: %3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22utf-8%22%3F%3E%3Csoap%3AEnvelope%20xmlns%3Asoap%3D%22http%3A%2F%2Fwww.w3.org%2F2003%2F05%2Fsoap-envelope%22%3E%3Csoap%3ABody%3E%3Csoap%3AFault%3E%3Csoap%3ACode%3E%3Csoap%3AValue%3Esoap%3AReceiver%3C%2Fsoap%3AValue%3E%3Csoap%3ASubcode%3E%3Csoap%3AValue%3EUnauthorizedRequestException%3C%2Fsoap%3AValue%3E%3C%2Fsoap%3ASubcode%3E%3C%2Fsoap%3ACode%3E%3Csoap%3AReason%3E%3Csoap%3AText%20xml%3Alang%3D%22en%22%3ETF400813%3A%20The%20user%20%27%27%20is%20not%20authorized%20to%20access%20this%20resource.%3C%2Fsoap%3AText%3E%3C%2Fsoap%3AReason%3E%3C%2Fsoap%3AFault%3E%3C%2Fsoap%3ABody%3E%3C%2Fsoap%3AEnvelope%3E
    < X-TFS-ServiceError: TF400813%3A%20The%20user%20%27%27%20is%20not%20authorized%20to%20access%20this%20resource.
    < X-VSS-S2STargetService: 00000002-0000-8888-8000-000000000000/visualstudio.com
    < X-TFS-FedAuthRedirect: https://app.vssps.visualstudio.com/_signin?realm=skype.visualstudio.com&reply_to=https%3A%2F%2Fskype.visualstudio.com%2FTPS%2F_git%2Fv8-android-bin%2Finfo%2Frefs%3Fservice%3Dgit-upload-pack&redirect=1&context=eyJodCI6MiwiaGlkIjoiYjk2MmVkNGYtNjY3MC00YTM3LWFkMjQtOGI5MzgxNTMwZTY3IiwicXMiOnt9LCJyciI6IiIsInZoIjoiIiwiY3YiOiIiLCJjcyI6IiJ90#ctx=eyJTaWduSW5Db29raWVEb21haW5zIjpbImh0dHBzOi8vbG9naW4ubWljcm9zb2Z0b25saW5lLmNvbSIsImh0dHBzOi8vbG9naW4ubWljcm9zb2Z0b25saW5lLmNvbSJdfQ2
    < X-Powered-By: ASP.NET
    < X-Content-Type-Options: nosniff
    < X-MSEdge-Ref: Ref A: 2C5E301BDA1044F8B383F9557B80C696 Ref B: LON21EDGE0521 Ref C: 2018-07-18T11:48:59Z
    < Date: Wed, 18 Jul 2018 11:48:59 GMT
    < 
    * Ignoring the response-body
    * Connection #0 to host skype.visualstudio.com left intact
    * Issue another request to this URL: 'https://skype.visualstudio.com/DefaultCollection/TPS/_git/v8-android-bin/info/refs?service=git-upload-pack'
    * Found bundle for host skype.visualstudio.com: 0x7f89981001c0 [can pipeline]
    * Re-using existing connection! (#0) with host skype.visualstudio.com
    * Connected to skype.visualstudio.com (13.107.6.175) port 443 (#0)
    * Server auth using Basic with user 'HIDDEN_USER_NAME'
    > GET /DefaultCollection/TPS/_git/v8-android-bin/info/refs?service=git-upload-pack HTTP/1.1
    Host: skype.visualstudio.com
    Authorization: Basic --token1--
    User-Agent: git/2.18.0
    Accept: */*
    Accept-Encoding: deflate, gzip
    Pragma: no-cache
    
    < HTTP/1.1 401 Unauthorized
    < P3P: CP="CAO DSP COR ADMa DEV CONo TELo CUR PSA PSD TAI IVDo OUR SAMi BUS DEM NAV STA UNI COM INT PHY ONL FIN PUR LOC CNT"
    * Authentication problem. Ignoring this.
    < WWW-Authenticate: Basic realm="https://tfsprodweu4.visualstudio.com/"
    < X-TFS-ProcessId: 2ee19a44-5f8a-4699-9225-f5a9ea67a53a
    < Strict-Transport-Security: max-age=31536000; includeSubDomains
    < ActivityId: 40930146-e6d1-484d-97e6-36dbc0a19fba
    < X-TFS-Session: 40930146-e6d1-484d-97e6-36dbc0a19fba
    < X-VSS-E2EID: 40930146-e6d1-484d-97e6-36dbc0a19fba
    < X-FRAME-OPTIONS: SAMEORIGIN
    < X-Powered-By: ASP.NET
    < X-Content-Type-Options: nosniff
    < X-MSEdge-Ref: Ref A: 4436E51EFCA04C8E9FAF709A9B7EBBAD Ref B: LON21EDGE0521 Ref C: 2018-07-18T11:48:59Z
    < Date: Wed, 18 Jul 2018 11:48:59 GMT
    < Content-Length: 0
    < 
    * Connection #0 to host skype.visualstudio.com left intact
    13:48:59.673615 run-command.c:637       trace: run_command: 'git credential-osxkeychain get'
    13:48:59.693226 git.c:654               trace: exec: git-credential-osxkeychain get
    13:48:59.694755 run-command.c:637       trace: run_command: git-credential-osxkeychain get
    * Couldn't find host skype.visualstudio.com in the .netrc file; using defaults
    * Found bundle for host skype.visualstudio.com: 0x7f89981001c0 [can pipeline]
    * Re-using existing connection! (#0) with host skype.visualstudio.com
    * Connected to skype.visualstudio.com (13.107.6.175) port 443 (#0)
    * Server auth using Basic with user 'HIDDEN_USER_NAME'
    > GET /DefaultCollection/TPS/_git/v8-android-bin/info/refs?service=git-upload-pack HTTP/1.1
    Host: skype.visualstudio.com
    Authorization: Basic --token2--
    User-Agent: git/2.18.0
    Accept: */*
    Accept-Encoding: deflate, gzip
    Pragma: no-cache
    
    < HTTP/1.1 200 OK
    < Cache-Control: private
    < Content-Length: 394
    < Content-Type: application/x-git-upload-pack-advertisement
    < P3P: CP="CAO DSP COR ADMa DEV CONo TELo CUR PSA PSD TAI IVDo OUR SAMi BUS DEM NAV STA UNI COM INT PHY ONL FIN PUR LOC CNT"
    < X-TFS-ProcessId: ce595db5-b33b-41bf-ad05-b7f2645fb6ba
    < Strict-Transport-Security: max-age=31536000; includeSubDomains
    < ActivityId: e268f3f4-cea9-40b6-b457-9610d604da85
    < X-TFS-Session: e268f3f4-cea9-40b6-b457-9610d604da85
    < X-VSS-E2EID: e268f3f4-cea9-40b6-b457-9610d604da85
    < X-FRAME-OPTIONS: SAMEORIGIN
    < X-VSS-UserData: HIDDEN_AUTH_TOKEN:[email protected]
    < X-AspNet-Version: 4.0.30319
    < X-Powered-By: ASP.NET
    < X-Content-Type-Options: nosniff
    < X-MSEdge-Ref: Ref A: E07131B08BDF4FE5A758F5F791A53C8B Ref B: LON21EDGE0521 Ref C: 2018-07-18T11:48:59Z
    < Date: Wed, 18 Jul 2018 11:48:59 GMT
    < 
    * Connection #0 to host skype.visualstudio.com left intact
    13:48:59.984309 run-command.c:637       trace: run_command: 'git credential-osxkeychain store'
    13:49:00.000908 git.c:654               trace: exec: git-credential-osxkeychain store
    13:49:00.001918 run-command.c:637       trace: run_command: git-credential-osxkeychain store
    13:49:00.145300 run-command.c:637       trace: run_command: git fetch-pack --stateless-rpc --stdin --lock-pack --thin --check-self-contained-and-connected --cloning https://skype.visualstudio.com/DefaultCollection/TPS/_git/v8-android-bin/
    13:49:00.157715 git.c:415               trace: built-in: git fetch-pack --stateless-rpc --stdin --lock-pack --thin --check-self-contained-and-connected --cloning https://skype.visualstudio.com/DefaultCollection/TPS/_git/v8-android-bin/
    * Couldn't find host skype.visualstudio.com in the .netrc file; using defaults
    * Found bundle for host skype.visualstudio.com: 0x7f89981001c0 [can pipeline]
    * Re-using existing connection! (#0) with host skype.visualstudio.com
    * Connected to skype.visualstudio.com (13.107.6.175) port 443 (#0)
    * Server auth using Basic with user 'HIDDEN_USER_NAME'
    > POST /DefaultCollection/TPS/_git/v8-android-bin/git-upload-pack HTTP/1.1
    Host: skype.visualstudio.com
    Authorization: Basic --token2--
    User-Agent: git/2.18.0
    Accept-Encoding: deflate, gzip
    Content-Type: application/x-git-upload-pack-request
    Accept: application/x-git-upload-pack-result
    Content-Length: 164
    
    * upload completely sent off: 164 out of 164 bytes
    < HTTP/1.1 200 OK
    < Cache-Control: private
    < Transfer-Encoding: chunked
    < Content-Type: application/x-git-upload-pack-result
    < P3P: CP="CAO DSP COR ADMa DEV CONo TELo CUR PSA PSD TAI IVDo OUR SAMi BUS DEM NAV STA UNI COM INT PHY ONL FIN PUR LOC CNT"
    < X-TFS-ProcessId: e61c56b7-eb8e-49dd-9fbd-692d8b1b1a22
    < Strict-Transport-Security: max-age=31536000; includeSubDomains
    < ActivityId: 39ae70b7-1f85-49a9-8373-40127888448f
    < X-TFS-Session: 39ae70b7-1f85-49a9-8373-40127888448f
    < X-VSS-E2EID: 39ae70b7-1f85-49a9-8373-40127888448f
    < X-FRAME-OPTIONS: SAMEORIGIN
    < X-VSS-UserData: HIDDEN_AUTH_TOKEN:[email protected]
    < X-AspNet-Version: 4.0.30319
    < X-Powered-By: ASP.NET
    < X-Content-Type-Options: nosniff
    < X-MSEdge-Ref: Ref A: 69AE3478B1C644B98CDE9AAF838DC62F Ref B: LON21EDGE0521 Ref C: 2018-07-18T11:49:00Z
    < Date: Wed, 18 Jul 2018 11:49:00 GMT
    < 
    remote: 
    remote:                    vSTs   
    remote:                  vSTSVSTSv
    remote:                vSTSVSTSVST
    remote: VSTS         vSTSVSTSVSTSV
    remote: VSTSVS     vSTSVSTSV STSVS
    remote: VSTSVSTSvsTSVSTSVS   TSVST
    remote: VS  tSVSTSVSTSv      STSVS
    remote: VS   tSVSTSVST       SVSTS
    remote: VS tSVSTSVSTSVSts    VSTSV
    remote: VSTSVST    SVSTSVSTs VSTSV
    remote: VSTSv        STSVSTSVSTSVS
    remote:                VSTSVSTSVST
    remote:                  VSTSVSTs
    remote:                    VSTs    (TM)
    remote: 
    remote:  Microsoft (R) Visual Studio (R) Team Services
    remote: 
    remote: Found 42 objects to send. (7 ms)
    13:49:00.271196 run-command.c:637       trace: run_command: git unpack-objects --pack_header=2,42
    * Connection #0 to host skype.visualstudio.com left intact
    13:49:00.283944 git.c:415               trace: built-in: git unpack-objects --pack_header=2,42
    Unpacking objects: 100% (42/42), done.
    13:49:00.406139 run-command.c:637       trace: run_command: git rev-list --objects --stdin --not --all --quiet '--progress=Checking connectivity'
    13:49:00.414458 git.c:415               trace: built-in: git rev-list --objects --stdin --not --all --quiet '--progress=Checking connectivity'
    michal-mac:react-dependencies HIDDEN_USER_NAME$ 
    
  3. ttaylorr commented on Jul 19, 2018

    @ttaylorr
    Contributor
  4. PastelMobileSuit commented on Jul 23, 2018

    @PastelMobileSuit
    Contributor

    @ttaylorr I can spend some time looking at this!

  5. PastelMobileSuit commented on Jul 24, 2018

    @PastelMobileSuit
    Contributor

    @dryganets Thanks for the bug report! As @ttaylorr said, it looks like something is going wrong when we receive a 401 response, and we're currently looking into this on our end. A couple of things:

    • Based on the log you gave us it looks like Git LFS is sending credentials to VSTS, and the 401 response is being returned because those credentials are being rejected. Can you check to make sure your credentials are valid?
    • Following on from that, it looks like VSTS is returning a 401 when credentials are rejected, when it should instead be returning a 403. This isn't correct, so they'll need to update their API.
    • Something is definitely going wrong on our end as well when we receive the 401 response. To help us debug this, could you apply this diff and retry the same commands again with GIT_TRACE=1 and GIT_CURL_VERBOSE=1, and providing the same credentials? To apply the diff, you can just download the file and run git apply <filename> && ./script/bootstrap in your Git LFS source directory. You can then link Git LFS into your $PATH by running sudo cp ./bin/git-lfs $(which git-lfs). As before, you'll want to remove your credentials from the output before sharing it here.

    Thanks!

  6. added
    waiting
    on Jul 24, 2018
  7. dryganets commented on Jul 28, 2018

    @dryganets
    Author

    Hmm, the git is able to authenticate, the git-lfs uses wrong auth method for some reason.
    Another thing is that it happens only for some people.

    I ask Michal to try your patch out, sorry for delay in response.

  8. mrousal commented on Jul 30, 2018

    @mrousal

    log with the patch applied:

    michal-mac:react-dependencies$ git submodule update --init
    10:31:01.341384 git.c:654 trace: exec: git-submodule update --init
    10:31:01.342281 run-command.c:637 trace: run_command: git-submodule update --init
    10:31:01.375949 git.c:654 trace: exec: git-sh-i18n--envsubst --variables 'usage: $dashless $USAGE'
    10:31:01.376905 run-command.c:637 trace: run_command: git-sh-i18n--envsubst --variables 'usage: $dashless $USAGE'
    10:31:01.389156 git.c:654 trace: exec: git-sh-i18n--envsubst 'usage: $dashless $USAGE'
    10:31:01.390009 run-command.c:637 trace: run_command: git-sh-i18n--envsubst 'usage: $dashless $USAGE'
    10:31:01.407329 git.c:415 trace: built-in: git rev-parse --git-dir
    10:31:01.417774 git.c:415 trace: built-in: git rev-parse --git-path objects
    10:31:01.429428 git.c:415 trace: built-in: git rev-parse -q --git-dir
    10:31:01.448756 git.c:415 trace: built-in: git rev-parse --show-prefix
    10:31:01.458168 git.c:415 trace: built-in: git rev-parse --show-toplevel
    10:31:01.472948 git.c:415 trace: built-in: git submodule--helper init
    10:31:01.483127 git.c:415 trace: built-in: git submodule--helper update-clone
    10:31:01.486130 run-command.c:1553 run_processes_parallel: preparing to run up to 1 tasks
    10:31:01.486706 run-command.c:637 trace: run_command: git submodule--helper clone --path v8 --name v8 --url https://skype.visualstudio.com/DefaultCollection/TPS/_git/v8-android-bin
    10:31:01.493845 git.c:415 trace: built-in: git submodule--helper clone --path v8 --name v8 --url https://skype.visualstudio.com/DefaultCollection/TPS/_git/v8-android-bin
    10:31:01.502871 run-command.c:1585 run_processes_parallel: done
    10:31:01.509784 git.c:415 trace: built-in: git submodule--helper name ADAL
    10:31:01.517878 git.c:415 trace: built-in: git config submodule.ADAL.update
    10:31:01.527190 git.c:415 trace: built-in: git submodule--helper relative-path ADAL 
    10:31:01.535295 git.c:415 trace: built-in: git rev-parse --local-env-vars
    10:31:01.542473 git.c:415 trace: built-in: git rev-parse --verify HEAD
    10:31:01.554174 git.c:415 trace: built-in: git submodule--helper name CocoaLumberjack
    10:31:01.563630 git.c:415 trace: built-in: git config submodule.CocoaLumberjack.update
    10:31:01.571552 git.c:415 trace: built-in: git submodule--helper relative-path CocoaLumberjack 
    10:31:01.578773 git.c:415 trace: built-in: git rev-parse --local-env-vars
    10:31:01.585891 git.c:415 trace: built-in: git rev-parse --verify HEAD
    10:31:01.596632 git.c:415 trace: built-in: git submodule--helper name OneAuth
    10:31:01.604881 git.c:415 trace: built-in: git config submodule.OneAuth.update
    10:31:01.612837 git.c:415 trace: built-in: git submodule--helper relative-path OneAuth 
    10:31:01.620329 git.c:415 trace: built-in: git rev-parse --local-env-vars
    10:31:01.627910 git.c:415 trace: built-in: git rev-parse --verify HEAD
    10:31:01.639321 git.c:415 trace: built-in: git submodule--helper name ZipArchive
    10:31:01.647352 git.c:415 trace: built-in: git config submodule.ZipArchive.update
    10:31:01.655589 git.c:415 trace: built-in: git submodule--helper relative-path ZipArchive 
    10:31:01.663431 git.c:415 trace: built-in: git rev-parse --local-env-vars
    10:31:01.671930 git.c:415 trace: built-in: git rev-parse --verify HEAD
    10:31:01.682829 git.c:415 trace: built-in: git submodule--helper name boost_1_63_0
    10:31:01.692358 git.c:415 trace: built-in: git config submodule.boost_1_63_0.update
    10:31:01.700162 git.c:415 trace: built-in: git submodule--helper relative-path boost_1_63_0 
    10:31:01.707627 git.c:415 trace: built-in: git rev-parse --local-env-vars
    10:31:01.714672 git.c:415 trace: built-in: git rev-parse --verify HEAD
    10:31:01.726064 git.c:415 trace: built-in: git submodule--helper name double-conversion-1.1.1
    10:31:01.733657 git.c:415 trace: built-in: git config submodule.double-conversion-1.1.1.update
    10:31:01.741884 git.c:415 trace: built-in: git submodule--helper relative-path double-conversion-1.1.1 
    10:31:01.749636 git.c:415 trace: built-in: git rev-parse --local-env-vars
    10:31:01.756933 git.c:415 trace: built-in: git rev-parse --verify HEAD
    10:31:01.768067 git.c:415 trace: built-in: git submodule--helper name fishhook
    10:31:01.776762 git.c:415 trace: built-in: git config submodule.fishhook.update
    10:31:01.785643 git.c:415 trace: built-in: git submodule--helper relative-path fishhook 
    10:31:01.793872 git.c:415 trace: built-in: git rev-parse --local-env-vars
    10:31:01.801429 git.c:415 trace: built-in: git rev-parse --verify HEAD
    10:31:01.813644 git.c:415 trace: built-in: git submodule--helper name folly-2016.09.26.00
    10:31:01.822118 git.c:415 trace: built-in: git config submodule.folly-2016.09.26.00.update
    10:31:01.830086 git.c:415 trace: built-in: git submodule--helper relative-path folly-2016.09.26.00 
    10:31:01.837994 git.c:415 trace: built-in: git rev-parse --local-env-vars
    10:31:01.844914 git.c:415 trace: built-in: git rev-parse --verify HEAD
    10:31:01.855672 git.c:415 trace: built-in: git submodule--helper name glog-0.3.3
    10:31:01.863599 git.c:415 trace: built-in: git config submodule.glog-0.3.3.update
    10:31:01.871745 git.c:415 trace: built-in: git submodule--helper relative-path glog-0.3.3 
    10:31:01.880107 git.c:415 trace: built-in: git rev-parse --local-env-vars
    10:31:01.887525 git.c:415 trace: built-in: git rev-parse --verify HEAD
    10:31:01.898858 git.c:415 trace: built-in: git submodule--helper name jsc-headers
    10:31:01.907687 git.c:415 trace: built-in: git config submodule.jsc-headers.update
    10:31:01.916835 git.c:415 trace: built-in: git submodule--helper relative-path jsc-headers 
    10:31:01.925221 git.c:415 trace: built-in: git rev-parse --local-env-vars
    10:31:01.932192 git.c:415 trace: built-in: git rev-parse --verify HEAD
    10:31:01.944461 git.c:415 trace: built-in: git submodule--helper name v8
    10:31:01.953021 git.c:415 trace: built-in: git config submodule.v8.update
    10:31:01.962142 git.c:415 trace: built-in: git submodule--helper relative-path v8 
    10:31:01.969749 git.c:415 trace: built-in: git rev-parse --local-env-vars
    10:31:01.991112 git.c:415 trace: built-in: git rev-parse --local-env-vars
    10:31:02.015813 git.c:654 trace: exec: git-sh-i18n--envsubst --variables 'Unable to checkout '\''$sha1'\'' in submodule path '\''$displaypath'\'''
    10:31:02.016677 run-command.c:637 trace: run_command: git-sh-i18n--envsubst --variables 'Unable to checkout '\''$sha1'\'' in submodule path '\''$displaypath'\'''
    10:31:02.030507 git.c:654 trace: exec: git-sh-i18n--envsubst 'Unable to checkout '\''$sha1'\'' in submodule path '\''$displaypath'\'''
    10:31:02.031429 run-command.c:637 trace: run_command: git-sh-i18n--envsubst 'Unable to checkout '\''$sha1'\'' in submodule path '\''$displaypath'\'''
    10:31:02.046185 git.c:654 trace: exec: git-sh-i18n--envsubst --variables 'Submodule path '\''$displaypath'\'': checked out '\''$sha1'\'''
    10:31:02.047196 run-command.c:637 trace: run_command: git-sh-i18n--envsubst --variables 'Submodule path '\''$displaypath'\'': checked out '\''$sha1'\'''
    10:31:02.059107 git.c:654 trace: exec: git-sh-i18n--envsubst 'Submodule path '\''$displaypath'\'': checked out '\''$sha1'\'''
    10:31:02.060205 run-command.c:637 trace: run_command: git-sh-i18n--envsubst 'Submodule path '\''$displaypath'\'': checked out '\''$sha1'\'''
    10:31:02.072999 git.c:415 trace: built-in: git rev-parse --local-env-vars
    10:31:02.081861 git.c:415 trace: built-in: git checkout -f -q 45a78ef44344d18883d1fffff4622f3fe126a137
    10:31:02.092412 run-command.c:637 trace: run_command: 'git-lfs filter-process'
    10:31:02.118286 trace git-lfs: exec: git 'version'
    10:31:02.136252 trace git-lfs: exec: git 'config' '-l'
    10:31:02.145638 trace git-lfs: Install hook: pre-push, force=false, path=/Users//Library/Android/react-dependencies/.git/modules/v8/hooks/pre-push, upgrading...
    10:31:02.147229 trace git-lfs: Install hook: post-checkout, force=false, path=/Users//Library/Android/react-dependencies/.git/modules/v8/hooks/post-checkout, upgrading...
    10:31:02.148639 trace git-lfs: Install hook: post-commit, force=false, path=/Users//Library/Android/react-dependencies/.git/modules/v8/hooks/post-commit, upgrading...
    10:31:02.149935 trace git-lfs: Install hook: post-merge, force=false, path=/Users//Library/Android/react-dependencies/.git/modules/v8/hooks/post-merge, upgrading...
    10:31:02.151277 trace git-lfs: Initialize filter-process
    10:31:02.151544 trace git-lfs: exec: git '-c' 'filter.lfs.smudge=' '-c' 'filter.lfs.clean=' '-c' 'filter.lfs.process=' '-c' 'filter.lfs.required=false' 'rev-parse' 'HEAD' '--symbolic-full-name' 'HEAD'
    10:31:02.161946 trace git-lfs: tq: running as batched queue, batch size of 100
    10:31:02.162138 trace git-lfs: filepathfilter: rejecting "armeabi-v7a/libc++_shared.so" via []
    10:31:02.162157 trace git-lfs: filepathfilter: accepting "armeabi-v7a/libc++_shared.so"
    10:31:02.162682 trace git-lfs: filepathfilter: rejecting "armeabi-v7a/libv8.cr.so" via []
    10:31:02.162691 trace git-lfs: filepathfilter: accepting "armeabi-v7a/libv8.cr.so"
    10:31:02.163175 trace git-lfs: filepathfilter: rejecting "armeabi-v7a/libv8_libbase.cr.so" via []
    10:31:02.163192 trace git-lfs: filepathfilter: accepting "armeabi-v7a/libv8_libbase.cr.so"
    10:31:02.163602 trace git-lfs: filepathfilter: rejecting "armeabi-v7a/libv8_libplatform.cr.so" via []
    10:31:02.163612 trace git-lfs: filepathfilter: accepting "armeabi-v7a/libv8_libplatform.cr.so"
    10:31:02.193565 trace git-lfs: filepathfilter: rejecting "x86/libc++_shared.so" via []
    10:31:02.193588 trace git-lfs: filepathfilter: accepting "x86/libc++_shared.so"
    10:31:02.193986 trace git-lfs: filepathfilter: rejecting "x86/libv8.cr.so" via []
    10:31:02.194000 trace git-lfs: filepathfilter: accepting "x86/libv8.cr.so"
    10:31:02.194365 trace git-lfs: filepathfilter: rejecting "x86/libv8_libbase.cr.so" via []
    10:31:02.194378 trace git-lfs: filepathfilter: accepting "x86/libv8_libbase.cr.so"
    10:31:02.194709 trace git-lfs: filepathfilter: rejecting "x86/libv8_libplatform.cr.so" via []
    10:31:02.194720 trace git-lfs: filepathfilter: accepting "x86/libv8_libplatform.cr.so"
    10:31:02.194914 trace git-lfs: tq: sending batch of size 8
    10:31:02.195267 trace git-lfs: api: batch 8 files
    10:31:02.266211 trace git-lfs: HTTP: POST https://skype.visualstudio.com/DefaultCollection/TPS/_git/v8-android-bin.git/info/lfs/objects/batch
    > POST /DefaultCollection/TPS/_git/v8-android-bin.git/info/lfs/objects/batch HTTP/1.1
    > Host: skype.visualstudio.com
    > Accept: application/vnd.git-lfs+json; charset=utf-8
    > Authorization: Basic *
    > Content-Length: 798
    > Content-Type: application/vnd.git-lfs+json; charset=utf-8
    > User-Agent: git-lfs/2.4.2 (GitHub; darwin amd64; go 1.10.3; git 6f4b2e98)
    > 
    {"operation":"download","objects":[{"oid":"725910140df210d0af2cd51ab897b0cd8387b3c4e8a638831278c216d3f69a7c","size":10928064},{"oid":"d452d76357156c57158f052973f8788678eab702c3283313c5588c8bcffaf338","size":8275276},{"oid":"1184f87efdd3d6e27fceb46c44ab2178a0218db00db029469b5daa9083265e63","size":1095276},{"oid":"ff27942fee03c076233782d9cb386387fbe2150d3dfd2bcbadaf23c0f56e325f","size":738760},{"oid":"78e93c5886e6357de0f6f3f73f23979d150370441598149fbf15d966e6c78491","size":109224},{"oid":"90bfd38ac726d7d08d710029e43c5b43cf1829663b78a76df73a0c8249b2f8a0","size":97164},{"oid":"cfd00ccc6994b273cc7aa82c9c9c283d13568f5fefdd754a8935df17fe20a412","size":76368},{"oid":"e593eaf3fc8bc4ce33e93aa43becfc1e43b3091df7ae34cd71f8800db3441ae5","size":55896}],"ref":{"name":"refs/heads/v8-android-bin_6.7.1"}}10:31:02.754190 trace git-lfs: HTTP: 401
    
    < HTTP/1.1 401 Unauthorized
    < Content-Length: 0
    < Activityid: bdb8853f-ffda-4902-925c-723a945819fa
    < Date: Mon, 30 Jul 2018 08:31:02 GMT
    < P3p: CP="CAO DSP COR ADMa DEV CONo TELo CUR PSA PSD TAI IVDo OUR SAMi BUS DEM NAV STA UNI COM INT PHY ONL FIN PUR LOC CNT"
    < Strict-Transport-Security: max-age=31536000; includeSubDomains
    < Www-Authenticate: Basic realm="https://tfsprodweu4.visualstudio.com/"
    < X-Content-Type-Options: nosniff
    < X-Frame-Options: SAMEORIGIN
    < X-Msedge-Ref: Ref A: 97FC121B2D694A2897FEE569D867F4B6 Ref B: LON21EDGE0820 Ref C: 2018-07-30T08:31:02Z
    < X-Powered-By: ASP.NET
    < X-Tfs-Processid: 3f8871d2-0e0a-4bcc-aba4-bea8c0ed9a02
    < X-Tfs-Session: bdb8853f-ffda-4902-925c-723a945819fa
    < X-Vss-E2eid: bdb8853f-ffda-4902-925c-723a945819fa
    < 
    10:31:02.754502 trace git-lfs: creds=map[], access=basic, auth=%!b(bool=true)
    10:31:02.754526 trace git-lfs: api error: Authentication required: Authorization error: https://skype.visualstudio.com/DefaultCollection/TPS/_git/v8-android-bin.git/info/lfs/objects/batch
    Check that you have proper access to the repository
    10:31:02.755138 trace git-lfs: filepathfilter: rejecting "armeabi-v7a/libc++_shared.so" via []
    10:31:02.755173 trace git-lfs: filepathfilter: accepting "armeabi-v7a/libc++_shared.so"
    Downloading armeabi-v7a/libc++_shared.so (739 KB)
    10:31:02.755365 trace git-lfs: tq: running as batched queue, batch size of 100
    10:31:02.755415 trace git-lfs: tq: sending batch of size 1
    10:31:02.755493 trace git-lfs: api: batch 1 files
    10:31:02.755550 trace git-lfs: HTTP: POST https://skype.visualstudio.com/DefaultCollection/TPS/_git/v8-android-bin.git/info/lfs/objects/batch
    > POST /DefaultCollection/TPS/_git/v8-android-bin.git/info/lfs/objects/batch HTTP/1.1
    > Host: skype.visualstudio.com
    > Accept: application/vnd.git-lfs+json; charset=utf-8
    > Authorization: Basic *
    > Content-Length: 174
    > Content-Type: application/vnd.git-lfs+json; charset=utf-8
    > User-Agent: git-lfs/2.4.2 (GitHub; darwin amd64; go 1.10.3; git 6f4b2e98)
    > 
    {"operation":"download","objects":[{"oid":"ff27942fee03c076233782d9cb386387fbe2150d3dfd2bcbadaf23c0f56e325f","size":738760}],"ref":{"name":"refs/heads/v8-android-bin_6.7.1"}}10:31:02.796386 trace git-lfs: HTTP: 401
    
    < HTTP/1.1 401 Unauthorized
    < Content-Length: 0
    < Activityid: 7e6f2c88-3020-4817-8d82-2aacba3aba3a
    < Date: Mon, 30 Jul 2018 08:31:02 GMT
    < P3p: CP="CAO DSP COR ADMa DEV CONo TELo CUR PSA PSD TAI IVDo OUR SAMi BUS DEM NAV STA UNI COM INT PHY ONL FIN PUR LOC CNT"
    < Strict-Transport-Security: max-age=31536000; includeSubDomains
    < Www-Authenticate: Basic realm="https://tfsprodweu4.visualstudio.com/"
    < X-Content-Type-Options: nosniff
    < X-Frame-Options: SAMEORIGIN
    < X-Msedge-Ref: Ref A: D0D5953C412D4F4085A7A4435FD4F720 Ref B: LON21EDGE0820 Ref C: 2018-07-30T08:31:02Z
    < X-Powered-By: ASP.NET
    < X-Tfs-Processid: e5b479e4-b3c8-494e-913a-80cf258318a7
    < X-Tfs-Session: 7e6f2c88-3020-4817-8d82-2aacba3aba3a
    < X-Vss-E2eid: 7e6f2c88-3020-4817-8d82-2aacba3aba3a
    < 
    10:31:02.796610 trace git-lfs: creds=map[], access=basic, auth=%!b(bool=true)
    10:31:02.796625 trace git-lfs: api error: Authentication required: Authorization error: https://skype.visualstudio.com/DefaultCollection/TPS/_git/v8-android-bin.git/info/lfs/objects/batch
    Check that you have proper access to the repository
    Error downloading object: armeabi-v7a/libc++_shared.so (ff27942): Smudge error: Error downloading armeabi-v7a/libc++_shared.so (ff27942fee03c076233782d9cb386387fbe2150d3dfd2bcbadaf23c0f56e325f): batch response: Authentication required: Authorization error: https://skype.visualstudio.com/DefaultCollection/TPS/_git/v8-android-bin.git/info/lfs/objects/batch
    Check that you have proper access to the repository
    
    Errors logged to /Users//Library/Android/react-dependencies/.git/modules/v8/lfs/logs/20180730T103102.796743401.log
    Use `git lfs logs last` to view the log.
    error: external filter 'git-lfs filter-process' failed
    fatal: armeabi-v7a/libc++_shared.so: smudge filter lfs failed
    Unable to checkout '45a78ef44344d18883d1fffff4622f3fe126a137' in submodule path 'v8'
    michal-mac:react-dependencies $ 
    
  9. PastelMobileSuit commented on Jul 31, 2018

    @PastelMobileSuit
    Contributor

    @mrousal @dryganets Thanks so much for the response!

    I've done some digging into the LFS authorization code. In your case, Git LFS should be putting your credentials into the Authorization header for the HTTP request, and it should be formatted as Authorization: Basic username:password.

    The authenticated HTTP requests are appearing in the log, so can you check in your non-anonymized version that the authorization header contains the username and password that you're expecting?

  10. mrousal commented on Aug 2, 2018

    @mrousal

    Hi, I have not anonymized auth headers in git-lfs logs. It is logged exactly as posted: 'Authorization: Basic *'. However I can see correct credentials in git logs, for example in the git clone log above, these were replaced by --token1-- and --token2--.

    Is it possible that git-lfs has problems fetching credentials via credential helper? It should be using credential.helper=osxkeychain which seems to work fine for git.

  11. dryganets commented on Aug 4, 2018

    @dryganets
    Author

    To clarify there is a --token1-- which is incorrect. There is also --token2-- which also doesn't look like correct plaintext token, maybe it is hashed in some way? (Michael told me that the second HTTP request succeeded but token in the logs doesn't match the token in the toolchain.)

    He can't find any trace of the --token1-- on his machine.

    Could you list the possible sources of the tokens/password and clarify how do you choose over a few different auth sources present on the user machine.

    It looks like there is a mismatch between the git order and git-lfs order in some corner case.

    We will be glad to help to find out the source of the mismatch.

  12. PastelMobileSuit commented on Aug 6, 2018

    @PastelMobileSuit
    Contributor

    @dryganets @mrousal I did a little more digging and I think the token will actually be hashed instead of in plaintext, sorry about the misinformation on that! Also, thanks for the additional information on your setup with regards to the credential helper, that's very useful to know.

    In regards to picking credentials, I believe with Basic Authentication, Git LFS should do the following:

    • Use credentials setup in a .netrc file in the user's home directory
    • If those are not present, use credentials provided directly in the remote URL
    • If no credentials are provided in the URL, default to the credential helper configured through Git

    Git LFS prints a trace message if it was successfully able to fill in credentials from the credential helper. I'm not seeing that in the log you posted, which means LFS is either grabbing credentials from somewhere else before it gets to the credential helper, or something went wrong when querying the credential helper.

    I've uploaded another patch file with some more robust debug statements, which I'm hoping will help us pinpoint the source of the issue and get to the bottom of what's happening. Could you apply this new patch file as before, and provide a new log?

  13. mrousal commented on Aug 7, 2018

    @mrousal

    Ok great, this explains it, I had some old password in ~/.netrc which was first git attempt before it went for creds from osxkeychain helper. After deleting entry from ~/.netrc git-lfs started to work.

    So the inconsistency between git and git-lfs is that git goes for another source of creds after 401 failure from ~/.netrc but git-lfs fails.

  14. ttaylorr commented on Aug 7, 2018

    @ttaylorr
    Contributor
  15. PastelMobileSuit commented on Aug 7, 2018

    @PastelMobileSuit
    Contributor

    @ttaylorr It sounds like that's the way Git works, so I'm 👍 for mirroring that behaviour

  16. added and removed
    waiting
    on Aug 8, 2018
  17. PastelMobileSuit commented on Aug 23, 2018

    @PastelMobileSuit
    Contributor

    Working through #3179 has exposed another issue with the way we currently handle .netrc credentials.

    In Git LFS, a request has an 'Access Mode' that indicates how it should be authenticated, with an Access Mode of None indicating an unauthenticated request should be made. The code to retrieve credentials checks this access mode and bails out if it's None to prevent credentials from being added to this request. The sole exception to this is .netrc credentials, which are retrieved and added to the request before the access mode is checked.

    As a result of this, if a host has an entry in the .netrc file, all requests made against that host will contain the .netrc credentials, regardless of whether or not they should be sent. Additionally, this also happens before we check the URL for credentials, meaning .netrc credentials will always take priority over those.

    @ttaylorr and I have decided the best way to handle this is to write a new credential helper for retrieving .netrc credentials. The credential helpers are only queried when the request requires credentials, and this querying only occurs if credentials weren't provided directly in the URL. Additionally, because we support multiple credential helpers, Git LFS will retry a request with new credentials if one set of credentials fails. This should fix all the outstanding issues with .netrc credentials at once.

    This has unfortunately uncovered another latent issue with regards to authentication and the way we track access modes (#3194). That issue will need to be fixed before we can make these .netrc changes.

  18. PastelMobileSuit commented on Oct 9, 2018

    @PastelMobileSuit
    Contributor

    I've just merged in a fix for this issue (#3307)! It should make it into the next release

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions