SVN将不缓存凭据

我使用命令行SVN客户端(版本1.6.12,从Ubuntu的回购协议),我似乎无法得到它的缓存我的用户凭据。 我试图访问HTTPS svn存储库(沿https://subversion.FAKE.com/PROJECT东西线)。 我给这名回购是从我的本地用户名不同。

这里的〜/的.subversion / config中的身份验证部分

[auth] ### Set password stores used by Subversion. They should be ### delimited by spaces or commas. The order of values determines ### the order in which password stores are used. ### Valid password stores: ### gnome-keyring (Unix-like systems) ### kwallet (Unix-like systems) ### keychain (Mac OS X) ### windows-cryptoapi (Windows) # password-stores = gnome-keyring ### ### The rest of this section in this file has been deprecated. ### Both 'store-passwords' and 'store-auth-creds' can now be ### specified in the 'servers' file in your config directory. ### Anything specified in this section is overridden by settings ### specified in the 'servers' file. ### ### Set store-passwords to 'no' to avoid storing passwords in the ### auth/ area of your config directory. It defaults to 'yes', ### but Subversion will never save your password to disk in ### plaintext unless you tell it to (see the 'servers' file). ### Note that this option only prevents saving of *new* passwords; ### it doesn't invalidate existing passwords. (To do that, remove ### the cache files by hand as described in the Subversion book.) store-passwords = yes ### Set store-auth-creds to 'no' to avoid storing any subversion ### credentials in the auth/ area of your config directory. ### It defaults to 'yes'. Note that this option only prevents ### saving of *new* credentials; it doesn't invalidate existing ### caches. (To do that, remove the cache files by hand.) store-auth-creds = yes

而这里的〜/的.subversion /服务器的全局部分

[global] # http-proxy-exceptions = *.exception.com, www.internal-site.org # http-proxy-host = defaultproxy.whatever.com # http-proxy-port = 7000 # http-proxy-username = defaultusername # http-proxy-password = defaultpassword # http-compression = no # http-auth-types = basic;digest;negotiate # No http-timeout, so just use the builtin default. # No neon-debug-mask, so neon debugging is disabled. # ssl-authority-files = /path/to/CAcert.pem;/path/to/CAcert2.pem # # Password / passphrase caching parameters: store-passwords = yes store-plaintext-passwords = no store-auth-creds = yes # store-ssl-client-cert-pp = no # store-ssl-client-cert-pp-plaintext = no

只有我所做的改变是明确设置与存储密码的几个选项。 我试过设置密码商店= GNOME的钥匙圈有没有影响。 此外,我删除〜/的.subversion / AUTH(按照一些其他线程),它仍然没有被svn客户端重新创建。

有什么建议么? 我怎么能强制SVN来存储我的凭据(无论是在〜/的.subversion / AUTH或使用GNOME的钥匙圈,我不在乎)。

--------------解决方案-------------

至少有三种选择

  1. 设置SSH有没有密码(试用此例)
  2. 使用GNOME的钥匙圈(谷歌搜索“svn的GNOME密钥环密码')。 这通常归结为编辑~/.subversion/config filepassword-stores = gnome-keyringstore-passwords = yes )。
  3. 存储明文密码。

要存储明文密码时,先删除你的~/.subversion目录。 这将删除诸如服务器证书你已经接受任何以前缓存密码以前配置的任何物品。 下一次SVN运行它会重建一个“空白”的目录结构。 然后对你的资料库svn命令。 您应该看到类似下面的内容:

$> cd <project directory>
$> svn update
Error validating server certificate for 'https://...':
- The certificate is not issued by a trusted authority. Use the
fingerprint to validate the certificate manually!
Certificate information:
- Hostname: ...
- Valid: ...
- Issuer: ...
- Fingerprint: ...
(R)eject, accept (t)emporarily or accept (p)ermanently? p
Password for 'your username': secret
-----------------------------------------------------------------------
ATTENTION! Your password for authentication realm:

<https://...> ...

can only be stored to disk unencrypted! You are advised to configure
your system so that Subversion can store passwords encrypted, if
possible. See the documentation for details.

You can avoid future appearances of this warning by setting the value
of the 'store-plaintext-passwords' option to either 'yes' or 'no' in
'/home/.../.subversion/servers'.
-----------------------------------------------------------------------
Store password unencrypted (yes/no)? yes

注意!!! 这将节省您的密码以明文(相当不安全的),但它也将缓存您的密码,这样你就不必每次都输入了。 最终,密码存储在明文在~/.subversion/auth/svn.simple/

如果所有提到的设置正确,也许svn客户端无法写入凭据选项文件由于权限。 我发现这个线程遇到了相同的行为,权限是该修补程序。

颠覆配置文件中的用户区域中(你的home目录〜/的.subversion)和系统区域(在/ etc /颠覆),见http://svnbook.red-bean.com/en/1.1/ch07.html#svn -CH-7-教派-1.1。 如果可以从系统文件复制“配置”和“服务器”文件,或直接编辑它们,如果你有管理员权限。

最简单的, 不是安全的 ,解决方法是让颠覆缓存凭据一个纯文本文件。 对于简单的设置store-passwords = yes ,并留下所有其它设置为默认值(注释)。

存储与GNOME的钥匙圈密码可能无法正常工作,因为没有安装工具或gnome-keyring-daemon可能没有运行。

不知道你是否还在寻找这里的答案; 但选择“SSL客户端证书密码”可能是你正在寻找的人。

ssl-client-cert-password=<password>

不知道这是否已经没有解决,但是你尝试过加入

password-stores =

你的'配置'文件?

在您的配置中有一个选项store-plaintext-passwords = no ,这不允许存储在$ HOME /的.subversion密码,除非有一些可用的支持的加密。

要恢复到前1.6的行为可以改变的价值yes ,它允许保存密码。

分类:SVN 时间:2015-03-15 人气:2
本文关键词: SVN,证书
分享到:

相关文章

Copyright (C) 55228885.com, All Rights Reserved.

55228885 版权所有 京ICP备15002868号

processed in 0.296 (s). 10 q(s)