Link to home
Start Free TrialLog in
Avatar of trevorhartman
trevorhartmanFlag for United States of America

asked on

security policy

Hi,

I'm going thru this msdn articele: http://msdn.microsoft.com/msdnmag/issues/02/10/NETSerialComm/default.aspx on serial communication, and it provides source code and an application for serial comm.  when i click on the settings button to try and setup the port and everything, a window pops up saying:

The application attempted to performa n operation not allowed by the security policy.  The operation required SecurityException.  To grant this app the reuqired permission please contact your system administrator, or use the MS .NET Security policy administration tool.

then some other useless msg

and finally:

Requrest for the permission of type System.Security.Permissions.FileIOPermission, mscorlib, Version=1.0.50000.0, Culture=nuetral, PublicKeyToken=###(some number) failed.

i found the .net security policy administration tool but don't know how to use it. do you?

thanks - Trevor
ASKER CERTIFIED SOLUTION
Avatar of raterus
raterus
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of trevorhartman

ASKER

lol, well i guess you're the #1 candidate for the points, if no one else knows :)
haha, I was wondering what you'd say to that.  Have you tried impersonating a user (like a domain admin) in web.config

<identity impersonate="true" />

This may be a quick fix, but the hard part would be to configure this so the aspnet user has the rights to do this.  This is what I don't know.
oops. i should have asked this in the .NET forum... this isn't even an asp.net question, i'm just so used to asking questions here..

it's a windows forms application..  anyway i sort of figured it out, i just gave FullTrust to all code... probably not the best for security but at least i can test now.
well, enjoy the easy points :)  looks like no one else knows
cool profile btw, i just checked it out :)
Did you ever figure out a solution?  Posting to microsoft.public.dotnet.security will get you in touch with the real experts, and I imagine they will be able to help you more.
well like i said before, it works when i put FullTrust on all code.... i only need it for testing/development, so it shouldn't be a problem.. thanks for the link