System.Security.SecurityException: Request for the permission of type 'System.Net.WebPermission, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' failed. at System.Security.CodeAccessSecurityEngine.Check(Object demand, StackCrawlMark& stackMark, Boolean isPermSet) at System.Security.CodeAccessPermission.Demand() at System.Net.HttpWebRequest..ctor(Uri uri, ServicePoint servicePoint) at System.Net.HttpRequestCreator.Create(Uri Uri) at System.Net.WebRequest.Create(Uri requestUri, Boolean useUriBase) at System.Net.WebRequest.Create(Uri requestUri) at IntelliSoftware.Common.HTTPConnection.HTTPRequest(String sMethod, String sUrl, String sContentType, String sFormData) at IntelliSoftware.Common.HTTPConnection.HTTPPost(String sURL, String sPostData, String ContentType) at IntelliSoftware.Internal.SMSGatewayService.MakeHTTPRequest(String sURL, SMSGatewayRequestData objSMSGatewayRequestData, String sReturnCodePrefix, String& sRawResponse, ResultCodes& ResultCode, Exception& InternalException) The action that failed was: Demand The type of the first permission that failed was: System.Net.WebPermission The first permission that failed was: <IPermission class="System.Net.WebPermission, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1"> <ConnectAccess> <URI uri="https://www\.intellisoftware2\.co\.uk/smsgateway/default\.aspx"/> </ConnectAccess> </IPermission> The demand was for: <IPermission class="System.Net.WebPermission, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1"> <ConnectAccess> <URI uri="https://www\.intellisoftware2\.co\.uk/smsgateway/default\.aspx"/> </ConnectAccess> </IPermission> The granted set of the failing assembly was: <PermissionSet class="System.Security.PermissionSet" version="1"> <IPermission class="System.Security.Permissions.EnvironmentPermission, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Read="USERNAME"/> <IPermission class="System.Security.Permissions.FileDialogPermission, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Unrestricted="true"/> <IPermission class="System.Security.Permissions.FileIOPermission, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Read="Y:\Visual Studio 2008\Projects\SMS\bin\" PathDiscovery="Y:\Visual Studio 2008\Projects\SMS\bin\"/> <IPermission class="System.Security.Permissions.IsolatedStorageFilePermission, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Allowed="AssemblyIsolationByUser" UserQuota="9223372036854775807" Expiry="9223372036854775807" Permanent="True"/> <IPermission class="System.Security.Permissions.ReflectionPermission, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="ReflectionEmit"/> <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Assertion, Execution, BindingRedirects"/> <IPermission class="System.Security.Permissions.UIPermission, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Unrestricted="true"/> <IPermission class="System.Security.Permissions.StrongNameIdentityPermission, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" PublicKeyBlob="002400000480000094000000060200000024000052534131000400000100010083B1457F4199018A8D8B8C626704A48401A9932C8A08CBDF5C6F38BE0103EA1D3177C7769D6A342E7DE9D4EABAAB826AF6D2CBCF2DF8CCD02929ABAE81AB71FF9F549047FBC54DEE2DE059DC5F3D2D51600F2A3FAAC71219E18C7C4B633B2F3E7FC1C9347E61173C3515B948C268FE6E8FFA3710FEBE93FD406E769D2E5EB7BA" Name="IntelliSMSDotNet" AssemblyVersion="4.5.0.0"/> <IPermission class="System.Security.Permissions.UrlIdentityPermission, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Url="file:///y:/Visual Studio 2008/Projects/SMS/bin/IntelliSMSDotNet.DLL"/> <IPermission class="System.Security.Permissions.ZoneIdentityPermission, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Zone="Intranet"/> <IPermission class="System.Net.DnsPermission, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Unrestricted="true"/> <IPermission class="System.Drawing.Printing.PrintingPermission, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" version="1" Level="DefaultPrinting"/> </PermissionSet> The assembly or AppDomain that failed was: IntelliSMSDotNet, Version=4.5.0.0, Culture=neutral, PublicKeyToken=500d2211a5cfb13e The method that caused the failure was: System.String HTTPRequest(System.String, System.String, System.String, System.String) The Zone of the assembly that failed was: Intranet The Url of the assembly that failed was: file:///y:/Visual Studio 2008/Projects/SMS/bin/IntelliSMSDotNet.DLL