背景:我以前在全新安装时一切都运行正常:
$ svn co https://domain:443/ test1
Error validating server certificate for 'https://domain:443':
- The certificate is not issued by a trusted authority. Use the
fingerprint to validate the certificate manually!
Certificate information:
- Hostname: **REMOVED**
- Valid: **REMOVED**
- Issuer: **REMOVED**
- Fingerprint: **checked with issuer and REMOVED**
(R)eject, accept (t)emporarily or accept (p)ermanently? p
Authentication realm: <https://domain:443> Subversion repository
Password for 'nicdumz-machine-hostname':
Authentication realm: <https://domain:443> Subversion repository
Username: nicdumz
Password for 'nicdumz':
# proceeds to checkout correctly
$ svn co https://domain:443/ test2
# checkouts nicely, without asking for my password.
有时候我需要使用不同的账户提交内容。所以我这么做了
$ svn ci --username other.user
Authentication realm: <https://domain:443> Subversion repository
Password for 'other.user':
# works fine
但从那时起,每次我想要以“nicdumz”(默认用户,所有存储库都已通过该用户签出)的身份提交时,它都会提示我输入密码:
$ svn ci
Authentication realm: <https://domain:443> Subversion repository
Password for 'nicdumz':
嘿,来吧,为什么:)如果我想要重新结帐,也会发生同样的情况,因为读权限也受到保护。
所以我尝试自己修复这个问题。我读到 ~/.subversion/auth 存储了凭证,所以我从中移除了它:
$ cd ~/.subversion
$ mv auth oldauth
$ mkdir auth
一开始它似乎有效,因为 svn 忘记了证书验证:
$ svn co https://domain:443/ test3
Error validating server certificate for 'https://domain:443':
- The certificate is not issued by a trusted authority. Use the
fingerprint to validate the certificate manually!
Certificate information:
- Hostname: **REMOVED**
- Valid: **REMOVED**
- Issuer: **REMOVED**
- Fingerprint: **checked with issuer and REMOVED**
(R)eject, accept (t)emporarily or accept (p)ermanently? p
Authentication realm: <https://domain:443> Subversion repository
Password for 'nicdumz-machine-hostname':
Authentication realm: <https://domain:443> Subversion repository
Username: nicdumz
Password for 'nicdumz':
# proceeds to checkout correctly
$ svn up
Authentication realm: <https://domain:443> Subversion repository
Password for 'nicdumz':
啥?这是怎么回事?
如果您有建议进一步调查该行为,我非常感兴趣。如果我是对的,没有办法进行详细svn up
或类似操作,所以我不确定是否应该进行调查。哦,不管怎样:
$ svn --version
svn, version 1.6.6 (r40053)
compiled Oct 26 2009, 06:19:08
Copyright (C) 2000-2009 CollabNet.
Subversion is open source software, see http://subversion.tigris.org/
This product includes software developed by CollabNet (http://www.Collab.Net/).
The following repository access (RA) modules are available:
* ra_neon : Module for accessing a repository via WebDAV protocol using Neon.
- handles 'http' scheme
- handles 'https' scheme
* ra_svn : Module for accessing a repository using the svn network protocol.
- with Cyrus SASL authentication
- handles 'svn' scheme
* ra_local : Module for accessing a repository on local disk.
- handles 'file' scheme
* ra_serf : Module for accessing a repository via WebDAV protocol using serf.
- handles 'http' scheme
- handles 'https' scheme
答案1
好吧,我遇到了同样的问题,我删除了 auth 目录。然后我做了:
svn --username xxx update
它要求我输入密码,但仅此而已。我只能说,删除 auth 目录对我有用。您的服务器文件中有正确的选项吗?即(我认为):
store-passwords = yes
store-plaintext-passwords = yes
在[global]
部分中。我不是 100% 确定,但它可能会有所帮助。