Git-Credential-Manager-for-Windows icon indicating copy to clipboard operation
Git-Credential-Manager-for-Windows copied to clipboard

GCM slow to get credentials over VPN

Open AsWaM opened this issue 4 years ago • 2 comments

Hello!

I was using GCM 1.18.0, and updated to 1.20.0 just to see if it solves the issue. It doesn't.

I set the following flags: GCM_TRACE=1 GIT_TRACE=1

Log GCM 1.18.0 (22 seconds)

18:19:22.874055 run-command.c:637       trace: run_command: 'git credential-manager get'
18:19:44.203789 exec-cmd.c:236          trace: resolved executable dir: C:/Users/samal/AppData/Local/Programs/Git/mingw64/libexec/git-core

Logs GCM 1.20.0 (21seconds)

18:42:58.320135 run-command.c:640       trace: run_command: 'git credential-manager get'
18:43:19.646125 git.c:576               trace: exec: git-credential-manager get

Sometimes it is instant, sometimes it takes 20 seconds...

Only happens when a VPN is active, otherwise no problem in the company network

AsWaM avatar Mar 17 '20 17:03 AsWaM

I can corroborate this. I am having the same problem, with Windows 10 and OpenVPN.

Connected to VPN:

$ GIT_TRACE=1 git push -f
17:50:05.241762 exec-cmd.c:237          trace: resolved executable dir: C:/Program Files/Git/mingw64/bin
17:50:05.244749 git.c:442               trace: built-in: git push -f
17:50:05.246714 run-command.c:663       trace: run_command: GIT_DIR=.git git remote-https origin https://github.com/XXX
17:50:05.274757 exec-cmd.c:237          trace: resolved executable dir: C:/Program Files/Git/mingw64/libexec/git-core
17:50:05.276753 git.c:702               trace: exec: git-remote-https origin https://github.com/XXX
17:50:05.277714 run-command.c:663       trace: run_command: git-remote-https origin https://github.com/XXX
17:50:05.309719 exec-cmd.c:237          trace: resolved executable dir: C:/Program Files/Git/mingw64/libexec/git-core
17:50:05.468741 run-command.c:663       trace: run_command: 'git credential-manager get'
12:50:15.950836 exec-cmd.c:237          trace: resolved executable dir: C:/Program Files/Git/mingw64/libexec/git-core
12:50:15.953826 git.c:702               trace: exec: git-credential-manager get
12:50:15.953826 run-command.c:663       trace: run_command: git-credential-manager get
17:50:16.716866 run-command.c:663       trace: run_command: 'git credential-manager store'
12:50:16.847829 exec-cmd.c:237          trace: resolved executable dir: C:/Program Files/Git/mingw64/libexec/git-core
12:50:16.852830 git.c:702               trace: exec: git-credential-manager store
12:50:16.852830 run-command.c:663       trace: run_command: git-credential-manager store
Everything up-to-date

Disconnected from VPN:

$ GIT_TRACE=1 git push -f
17:54:12.930307 exec-cmd.c:237          trace: resolved executable dir: C:/Program Files/Git/mingw64/bin
17:54:12.933307 git.c:442               trace: built-in: git push -f
17:54:12.935310 run-command.c:663       trace: run_command: GIT_DIR=.git git remote-https origin https://github.com/XXX
17:54:12.962306 exec-cmd.c:237          trace: resolved executable dir: C:/Program Files/Git/mingw64/libexec/git-core
17:54:12.965312 git.c:702               trace: exec: git-remote-https origin https://github.com/XXX
17:54:12.965312 run-command.c:663       trace: run_command: git-remote-https origin https://github.com/XXX
17:54:13.004346 exec-cmd.c:237          trace: resolved executable dir: C:/Program Files/Git/mingw64/libexec/git-core
17:54:13.160308 run-command.c:663       trace: run_command: 'git credential-manager get'
12:54:13.270308 exec-cmd.c:237          trace: resolved executable dir: C:/Program Files/Git/mingw64/libexec/git-core
12:54:13.274306 git.c:702               trace: exec: git-credential-manager get
12:54:13.274306 run-command.c:663       trace: run_command: git-credential-manager get
17:54:13.971492 run-command.c:663       trace: run_command: 'git credential-manager store'
12:54:14.074593 exec-cmd.c:237          trace: resolved executable dir: C:/Program Files/Git/mingw64/libexec/git-core
12:54:14.078592 git.c:702               trace: exec: git-credential-manager store
12:54:14.078592 run-command.c:663       trace: run_command: git-credential-manager store
Everything up-to-date

ghost avatar Jul 29 '20 16:07 ghost

@AsWaM This was resolved for me by upgrading the OpenVPN client I was using.

ghost avatar Sep 28 '20 16:09 ghost