I need to disable git credential assistant for OS X: git-credential-osxkeychain
I am using git as installed by Xcode Command Line Utilities 4.6.2 on OS X Mountain Lion 10.8.3.
In this installation, the default behavior of git pull or git push is that the password is remembered, thereby freeing the user from having to enter it again.
Although convenient, it is a security risk in my situation. I need to disable the credential assistant so that every pull , push or fetch needed .
git installed with Xcode does not use git config to install this function. Here are my settings:
# git --version =>
git version 1.7.12.4 (Apple Git-37)
# git config --global --list =>
user.name=User Name user.email=user@home color.diff=auto color.status=auto color.branch=auto color.interactive=auto color.ui=auto alias.lol=log --pretty=oneline --abbrev-commit --graph --decorate alias.co=checkout alias.ci=commit alias.st=status alias.br=branch alias.hist=log --pretty=format:'%h %ad | %s%d [%an]' --graph --date=short alias.type=cat-file -t alias.dump=cat-file -p core.autocrlf=input core.safecrlf=true core.editor=/usr/bin/vim
# git config --local --list =>
core.repositoryformatversion=0 core.filemode=true core.bare=false core.logallrefupdates=true core.ignorecase=true remote.origin.fetch=+refs/heads/*:refs/remotes/origin/* remote.origin.url=https:// XXXXXXX@bitbucket.org /YYYYYYYY/ZZZ.git branch.master.remote=origin branch.master.merge=refs/heads/master
# git config --system --list =>
fatal: unable to read config file '/usr/etc/gitconfig': No such file or directory
[Note: there is no system configuration file for my installation. ]
I did a thorough search in Qaru and Google, but couldn't find a solution to disable the credential assistant in this installation.
I suspect there is a .plist file or similar configuration file somewhere in the Xcode hierarchy that has a flag to disable, but could not find mention of this in git or Xcode docs.
A quick and dirty solution would be for the chmod binary file Applications/Xcode.app/Contents/Developer/usr/libexec/git-core/git-credential-osxkeychain , but it is not very elegant and most likely will break with any Xcode updates.
Do any Xcode experts have any ideas where Apple sets the flag to disable this git feature?