Hi...
I wrote a simple application that creates a work item of type "Bug" and export this item to a specific Team Project in TFS
this application runs fine in the development server but the security problem appears when I try to export the work item using IIS
I have the following error:
Security Exception
Description: The application attempted to perform an operation not allowed by the security policy. To grant this application the required permission please contact your system administrator or change the application's trust level in the configuration file.
Exception Details: System.Security.SecurityException: TF50309: You do not have sufficient permissions to perform this operation.
In the web configuration file, I use the port number of the Team Foundation Server (8080)
<appSettings>
<add key="ServerName" value="http://MyServer:8080/" />
</appSettings>
please help me to solve this problem...
Thanks in advance...

Security Problem when exporting a work item to TFS
Laura Bagnall
BuddyBoy2006
One great way to get down to the root cause, is by opening up SQL Profiler and watching the stored procedures that TFS executes.
However, in general, with permissions, you often need to be apart of the Team Foundation Administrators group to do Event listening and server wide integration. Though I realize you are targeting a particular project and not doing event listening, however the concept still applies.
If you do not fix this, later this evening I can try to repro this and will give you any advice/solutions I have. For now try and make sure you have the needed perms(if you want like I said, use SQL profiler and check for security type stored proecdures, like the following:
exec sp_executesql N'-- prc_security_read_is_member
DECLARE @ismember BIT
EXEC prc_security_read_is_member @sid, @groupsid, @ismember OUTPUT
SELECT @ismember
',N'@sid varchar(46),@groupsid
varchar(59)',@sid='S-1-5-21-1458658638-1311096025-1111419138-1026',@groupsid='S-1-9-1551374245-1204400969-2402986413-2179408616-0-0-0-0-1'
and see if your sid is actually in the group it is attempting to scan for...
Now this may possibly fall even outside of perms of TFS, it may be an IIS issue with reading something like the cache folder, i've seen that before, but i'm not so sure at this point without more information from you.
The main thing to remmeber is this:
For some operations you need perms on the box/domain. But you ALWAYS have to assign perms in TFS, so many people forget that you have to do both. (Also what user is the IIS app running under )
I would suggest using the Team Foundations Administration guide, though it may seem a lot to read at times.
http://www.microsoft.com/downloads/details.aspx familyid=2AED0ECC-1552-49F1-ABE7-4905155E210A&displaylang=en
Thanks,
John