Skip to Main Content

ODP.NET

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

managed ODP.NET beta security permission failure - demands unmanagedcode

thsisntjaredApr 1 2013
I thought this was particularly amusing because of the irony at first, but short of also adding a wrapper that asserts the unmanagedcode securitypermission, I am not out of options and am no longer amused. This is in the context of a web app with AllowPartiallyTrustedCallers and SecurityRules(SecurityRuleSet.Level2). Obviously, the application cannot be permitted to run in full trust, but the ODP.NET library may.

Exception Information
System.Security.SecurityException: Request for the permission of type 'System.Security.Permissions.SecurityPermission, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' failed.
at System.StubHelpers.StubHelpers.DemandPermission(IntPtr pNMD)
at Microsoft.Win32.NativeMethods.GetCurrentProcessId()
at System.Diagnostics.Process.GetCurrentProcess()
at OracleInternal.Common.ProviderConfig..cctor()

The action that failed was:
Demand
The type of the first permission that failed was:
System.Security.Permissions.SecurityPermission
The first permission that failed was:
<IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"
version="1"
Flags="UnmanagedCode"/>

Are others coming across this? are there intentions of asserting the SecurityPermission for UnmanagedCode prior to requesting the current process when this is out of beta??
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Apr 29 2013
Added on Apr 1 2013
0 comments
485 views