SVN Repository Authentication using SharpSVN

Amila Weerasekara picture Amila Weerasekara · Jun 23, 2010 · Viewed 13.3k times · Source

Can any one tell me how to authenticate users(SVN users) for a repository using SharpSVN Library. That repository should only be committed by those users. Thanks

Answer

Jérémie Bertrand picture Jérémie Bertrand · Mar 2, 2011

Use the Authenticate properties of SVNClient:

client.Authentication.Clear(); // Clear a previous authentication
client.Authentication.DefaultCredentials = new System.Net.NetworkCredential("user", "password");