I have have a repository, for example "http://svnserver/repository". Users have different permissions in the folders: "http://svnserver/repository/folder1" or "http://svnserver/folder2". How can I get the permission (read only or read and write) of the user logged in for a specific folder?
Asked
Active
Viewed 691 times
0
-
Do you mean you want to check what permissions you have at a certain level? – Sander Rijken Oct 25 '10 at 13:48
-
I want to check what permissions I have for a specific folder – Arjan Oct 25 '10 at 14:14
2 Answers
3
I don't think you can get this using Subversion, except by trying to commit and seeing if you have write access.
I have seen nothing in the protocol or the commands that shows access rights, except for error messages when you don't have access.
Why do you need this?

Lasse V. Karlsen
- 380,855
- 102
- 628
- 825
-
I have serialized objects in seperate files. The objects can be edited in my program. I want to set a flag when deserializing so my program knows which objects can be edited and which objects can only be read. Is there a clean solution to force committing a file without changing it? – Arjan Oct 26 '10 at 11:36
0
I would suggest trying this:
FileIOPermission f = new FileIOPermission(PermissionState.None);
f.AllLocalFiles = FileIOPermissionAccess.Read;
try
{
f.Demand();
}
catch (SecurityException s)
{
Console.WriteLine(s.Message);
}
As found on:

Michael Eakins
- 4,149
- 3
- 35
- 54
-
2I am using Subversion, and when I create a local working copy, all folders have read and write permissions. – Arjan Oct 26 '10 at 09:37