不允许用户保存TFS凭

不允许用户保存TFS凭

本文介绍了不允许用户保存TFS凭证的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

限时删除!!

这是该问题的后续问题:

This is a follow up question to this question:

如何加载Visual Studio时,可以更改用于连接到Visual Studio Online的默认凭据吗(TFSPreview)?

我遇到的问题是,如果用户选中了记住我的凭据"复选框,则需要以与链接的问题中给出的答案相同的方式删除凭据.

The problem I got is that if the user has check the box of "Remember my credentials", I need to delete the credentials in a way like in the answers given in the question I linked.

如何使用户每次连接时都输入其凭据,而又无法保存其凭据?

How can I make the user enter his credentials every time he connects without the possibility of saving his credentials?

这是我用于VS2010的东西,但不适用于VS2013:

This is something I used which worked for VS2010 but it doesn't work for VS2013:

控制面板->管理工具->本地安全策略->本地策略->安全选项将网络访问:不允许存储用于网络身份验证的密码和凭据"更改为启用

Control Panel -> Administrative Tools -> Local Security Policy -> Local Policies -> Security Options Change "Network access: Do not allow storage of passwords and credentials for network authentication" to state Enable

欢迎更改某些Windows设置甚至使用代码的答案.

Answers of changing some windows settings or even using code are both welcomed.

推荐答案

您必须编写一些代码才能做到这一点.

You'll have to write some code to do this.

从此处开始: http://msdn.microsoft.com/zh-CN/library/windows/desktop/ee207401(v = vs.85).aspx

基本上,您需要利用凭据管理API来删除存储的凭据.您无法停止初始存储,但是可以设置一个在启动时执行的程序来为您执行此操作.

Essentially you need to leverage the Credential Management API to remove stored credentials. You cant stop the initial storage, but you could have a program set to execute on startup that does this for you.

除此以外,我还看到了另外两个可能的选择.

Beyond that I see two other potential options.

第一个方法是进入服务并将服务标记为已禁用",以完全禁用凭据管理器. https://superuser.com/questions/346745/how-can-我禁用Windows凭据管理器

The first is to completely disable the Credential Manager by going into services and marking the service as Disabled. https://superuser.com/questions/346745/how-can-i-disable-the-windows-credential-manager

第二个是使用正确的GPO.具体来说,网络访问:不允许存储用于网络身份验证的凭据或.NET Passport.

The second would be to use the correct GPO. Specifically, Network Access: Do not allow storage of credentials or .NET Passports for network authentication.

http ://www.itworld.com/article/2779749/windows/how-to-disable-credential-caching-on-client-computers.html

请注意,这样做可能会带来其他意想不到的后果.

note that doing this might have other unintended consequences.

这篇关于不允许用户保存TFS凭证的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

1403页,肝出来的..

09-06 09:16