Solved it.
There is a configuration file called .hgrc in the user home directory. This contains the password used for access to the remote repository (in clear!). You can edit the file to use the new password instead, and everything works again.
Question
I have been successfully using SmartGit to access a Mercurial repository. My password on the server hosting Mercurial has recently changed. My SmartGit project now fails authentication (Message: "abort: authorization failed" on attempting to Push changes). I can't see any way to register a new password.
(Read access from the repository is working fine. It only fails on push.)
I found advice to go to Preferences>Authentication and remove the existing "Known credentials". However my credentials for this repository aren't listed there. It lists a number of Github repositories that I use, but not this Mercurial repository.
FURTHER INFORMATION 2014-03-04
Opened the keychain application in Applications/utilities. Tried to modify the password for the relevant web domain. No success.
Tried to delete the entry for the relevant web domain. No success.
Tried to clone a new repository from the master, and push from that. No success.
Discovered and upgraded to SmartGit/HG 5.0.7. No success. But it does give more detailed output, reproduced here:
Push
...
url, req, headers)
File "/Library/Python/2.7/site-packages/mercurial/url.py", line 431, in http_error_auth_reqed
self, auth_header, host, req, headers)
File "/var/folders/zf/wthbvqt14q53jh5n3clx1yqw0000gn/T/smartgit550802704160068758tmp/smartgit_http-0.py", line 56, in basic_http_error_auth_reqed
return basic_http_error_auth_reqed.orig(self, authreq, host, req, headers)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 872, in http_error_auth_reqed
response = self.retry_http_basic_auth(host, req, realm)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 885, in retry_http_basic_auth
return self.parent.open(req, timeout=req.timeout)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 410, in open
response = meth(req, response)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 523, in http_response
'http', request, response, code, msg, hdrs)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 442, in error
result = self._call_chain(*args)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 382, in _call_chain
result = func(*args)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 897, in http_error_401
url, req, headers)
File "/Library/Python/2.7/site-packages/mercurial/url.py", line 431, in http_error_auth_reqed
self, auth_header, host, req, headers)
File "/var/folders/zf/wthbvqt14q53jh5n3clx1yqw0000gn/T/smartgit550802704160068758tmp/smartgit_http-0.py", line 56, in basic_http_error_auth_reqed
return basic_http_error_auth_reqed.orig(self, authreq, host, req, headers)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 872, in http_error_auth_reqed
response = self.retry_http_basic_auth(host, req, realm)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 885, in retry_http_basic_auth
return self.parent.open(req, timeout=req.timeout)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 410, in open
response = meth(req, response)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 523, in http_response
'http', request, response, code, msg, hdrs)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 442, in error
result = self._call_chain(*args)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 382, in _call_chain
result = func(*args)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 897, in http_error_401
url, req, headers)
File "/Library/Python/2.7/site-packages/mercurial/url.py", line 431, in http_error_auth_reqed
self, auth_header, host, req, headers)
File "/var/folders/zf/wthbvqt14q53jh5n3clx1yqw0000gn/T/smartgit550802704160068758tmp/smartgit_http-0.py", line 56, in basic_http_error_auth_reqed
return basic_http_error_auth_reqed.orig(self, authreq, host, req, headers)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 872, in http_error_auth_reqed
response = self.retry_http_basic_auth(host, req, realm)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 885, in retry_http_basic_auth
return self.parent.open(req, timeout=req.timeout)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 410, in open
response = meth(req, response)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 523, in http_response
'http', request, response, code, msg, hdrs)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 442, in error
result = self._call_chain(*args)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 382, in _call_chain
result = func(*args)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 897, in http_error_401
url, req, headers)
File "/Library/Python/2.7/site-packages/mercurial/url.py", line 431, in http_error_auth_reqed
self, auth_header, host, req, headers)
File "/var/folders/zf/wthbvqt14q53jh5n3clx1yqw0000gn/T/smartgit550802704160068758tmp/smartgit_http-0.py", line 56, in basic_http_error_auth_reqed
return basic_http_error_auth_reqed.orig(self, authreq, host, req, headers)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 872, in http_error_auth_reqed
response = self.retry_http_basic_auth(host, req, realm)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 885, in retry_http_basic_auth
return self.parent.open(req, timeout=req.timeout)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 410, in open
response = meth(req, response)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 523, in http_response
'http', request, response, code, msg, hdrs)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 442, in error
result = self._call_chain(*args)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 382, in _call_chain
result = func(*args)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 897, in http_error_401
url, req, headers)
File "/Library/Python/2.7/site-packages/mercurial/url.py", line 431, in http_error_auth_reqed
self, auth_header, host, req, headers)
File "/var/folders/zf/wthbvqt14q53jh5n3clx1yqw0000gn/T/smartgit550802704160068758tmp/smartgit_http-0.py", line 56, in basic_http_error_auth_reqed
return basic_http_error_auth_reqed.orig(self, authreq, host, req, headers)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 872, in http_error_auth_reqed
response = self.retry_http_basic_auth(host, req, realm)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 885, in retry_http_basic_auth
return self.parent.open(req, timeout=req.timeout)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 410, in open
response = meth(req, response)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 523, in http_response
'http', request, response, code, msg, hdrs)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 442, in error
result = self._call_chain(*args)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 382, in _call_chain
result = func(*args)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 897, in http_error_401
url, req, headers)
File "/Library/Python/2.7/site-packages/mercurial/url.py", line 431, in http_error_auth_reqed
self, auth_header, host, req, headers)
File "/var/folders/zf/wthbvqt14q53jh5n3clx1yqw0000gn/T/smartgit550802704160068758tmp/smartgit_http-0.py", line 58, in basic_http_error_auth_reqed
call_smartgit("fail", host, self.passwd.ui)
File "/var/folders/zf/wthbvqt14q53jh5n3clx1yqw0000gn/T/smartgit550802704160068758tmp/smartgit_http-0.py", line 38, in call_smartgit
command, authuri])
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/subprocess.py", line 575, in check_output
raise CalledProcessError(retcode, cmd, output=output)
subprocess.CalledProcessError: Command '['/Volumes/SmartGitHg 5.0.7.1/SmartGitHg 5.app/Contents/Resources/Plugins/JRE/Contents/Home/jre/bin/java', '-cp', '/Volumes/SmartGitHg 5.0.7.1/SmartGitHg 5.app/Contents/Resources/Java/log4j.jar:/Volumes/SmartGitHg 5.0.7.1/SmartGitHg 5.app/Contents/Resources/Java/smartgit.jar:/Volumes/SmartGitHg 5.0.7.1/SmartGitHg 5.app/Contents/Resources/Java/trilead.jar', '-Dsmartgit.port=4333', '-Dsmartgit.tempDir=/var/folders/zf/wthbvqt14q53jh5n3clx1yqw0000gn/T/smartgit550802704160068758tmp', '-Dsmartgit.id=7259439108629017519', 'com.syntevo.hgapp.file.state.transport.ShHttpMain', 'fail', 'https://dvcs.w3.org/hg/xslt30-test?cmd=unbundle']' returned non-zero exit status 255
Push: warning: dvcs.w3.org certificate with fingerprint 97:4c:0e:c5:2e:95:74:5e:c7:fa:ed:07:3f:97:ab:ea:80:7a:be:7c not verified (check hostfingerprints or web.cacerts config setting) warning: dvcs.w3.org certificate with fingerprint 97:4c:0e:c5:2e:95:74:5e:c7:fa:ed:07:3f:97:ab:ea:80:7a:be:7c not verified (check hostfingerprints or web.cacerts config setting) warning: dvcs.w3.org certificate with fingerprint 97:4c:0e:c5:2e:95:74:5e:c7:fa:ed:07:3f:97:ab:ea:80:7a:be:7c not verified (check hostfingerprints or web.cacerts config setting) warning: dvcs.w3.org certificate with fingerprint 97:4c:0e:c5:2e:95:74:5e:c7:fa:ed:07:3f:97:ab:ea:80:7a:be:7c not verified (check hostfingerprints or web.cacerts config setting) warning: dvcs.w3.org certificate with fingerprint 97:4c:0e:c5:2e:95:74:5e:c7:fa:ed:07:3f:97:ab:ea:80:7a:be:7c not verified (check hostfingerprints or web.cacerts config setting) warning: dvcs.w3.org certificate with fingerprint 97:4c:0e:c5:2e:95:74:5e:c7:fa:ed:07:3f:97:ab:ea:80:7a:be:7c not verified (check hostfingerprints or web.cacerts config setting) warning: dvcs.w3.org certificate with fingerprint 97:4c:0e:c5:2e:95:74:5e:c7:fa:ed:07:3f:97:ab:ea:80:7a:be:7c not verified (check hostfingerprints or web.cacerts config setting) abort: authorization failed
$ hg push --config extensions.smartgit_http=/var/folders/zf/wthbvqt14q53jh5n3clx1yqw0000gn/T/smartgit550802704160068758tmp/smartgit_http-0.py --config "smartgit.classpath=/Volumes/SmartGitHg 5.0.7.1/SmartGitHg 5.app/Contents/Resources/Java/log4j.jar:/Volumes/SmartGitHg 5.0.7.1/SmartGitHg 5.app/Contents/Resources/Java/smartgit.jar:/Volumes/SmartGitHg 5.0.7.1/SmartGitHg 5.app/Contents/Resources/Java/trilead.jar" --config smartgit.id=882717487546533434 --config "smartgit.java=/Volumes/SmartGitHg 5.0.7.1/SmartGitHg 5.app/Contents/Resources/Plugins/JRE/Contents/Home/jre/bin/java" --config smartgit.mainClass=com.syntevo.hgapp.file.state.transport.ShHttpMain --config smartgit.port=4333 --config smartgit.tempDir=/var/folders/zf/wthbvqt14q53jh5n3clx1yqw0000gn/T/smartgit550802704160068758tmp --config ui.ssh=smartssh.sh --config extensions.color=! --rev 3fd788a6f541d7514e73920288528456b317a5ab default
dvcs.w3.org certificate with fingerprint 97:4c:0e:c5:2e:95:74:5e:c7:fa:ed:07:3f:97:ab:ea:80:7a:be:7c not verified (check hostfingerprints or web.cacerts config setting)
pushing to https://dvcs.w3.org/hg/xslt30-test
searching for changes
dvcs.w3.org certificate with fingerprint 97:4c:0e:c5:2e:95:74:5e:c7:fa:ed:07:3f:97:ab:ea:80:7a:be:7c not verified (check hostfingerprints or web.cacerts config setting)
7 changesets found
dvcs.w3.org certificate with fingerprint 97:4c:0e:c5:2e:95:74:5e:c7:fa:ed:07:3f:97:ab:ea:80:7a:be:7c not verified (check hostfingerprints or web.cacerts config setting)
dvcs.w3.org certificate with fingerprint 97:4c:0e:c5:2e:95:74:5e:c7:fa:ed:07:3f:97:ab:ea:80:7a:be:7c not verified (check hostfingerprints or web.cacerts config setting)
dvcs.w3.org certificate with fingerprint 97:4c:0e:c5:2e:95:74:5e:c7:fa:ed:07:3f:97:ab:ea:80:7a:be:7c not verified (check hostfingerprints or web.cacerts config setting)
dvcs.w3.org certificate with fingerprint 97:4c:0e:c5:2e:95:74:5e:c7:fa:ed:07:3f:97:ab:ea:80:7a:be:7c not verified (check hostfingerprints or web.cacerts config setting)
dvcs.w3.org certificate with fingerprint 97:4c:0e:c5:2e:95:74:5e:c7:fa:ed:07:3f:97:ab:ea:80:7a:be:7c not verified (check hostfingerprints or web.cacerts config setting)
abort: authorization failed
Pas de solution correcte
Autres conseils
Solved it.
There is a configuration file called .hgrc in the user home directory. This contains the password used for access to the remote repository (in clear!). You can edit the file to use the new password instead, and everything works again.