(I'm new to .Net and the Microsoft world in general, coming from a Java and Tomcat background, so please bear that in mind.) I'm working on my first .Net application, using Visual Studio 2013, C#, .Net 4.5, MVC 5, and EF 6. It's a fairly simple web-based application, using Windows [...] read more
I have created a website which compiles successfully when I log-in using administrator but when I log-in using any other user, following error occurs. > Could not load file or assembly 'Microsoft.CSharp, Version=4.0.0.0, > Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. > Either a required impersonation level was not provided, [...] read more
I have an MVC4 web application deployed on a Windows 2012 R2 server with IIS 8.5. I configured the Application Pool to run with a custom domain account because the web application needs to call another webservice on the network with Windows authentication enabled. When i try to reach the [...] read more
I have a very simple site with only static files in IIS 7 on Windows Server 2008 SP2. When I try to access any static file I get a 500 error. If I rename an html file to have an aspx extension it works fine. The site also works fine [...] read more
I have a WCF service, hosted in IIS 7.0 that needs to run database queries. In order to get the right permissions to do this I am impersonating within the service as follows: CODE [OperationBehavior(Impersonation = ImpersonationOption.Allowed)] public void MyOperation(int arg) CONFIGURATION <behavior name="ReceivingServiceBehavior"> <!-- Other behaviors --> <serviceAuthorization impersonateCallerForAllOperations="true" [...] read more
I have tried to setup an website in a new server and I get this error for all static files html/css/js, etc. HTTP Error 500.0 - Internal Server Error The page cannot be displayed because an internal server error has occurred. enter image description here [https://i.stack.imgur.com/Tkzb5.png] AuthenticateRequest is happening for [...] read more
Impersonation example I can check is user domain administrator with next lines of code: using (Impersonation im = new Impersonation(UserName, Domain, Password)) { System.Security.Principal.WindowsIdentity identity = System.Security.Principal.WindowsIdentity.GetCurrent(); bool isDomainAdmin = identity.IsDomainAdmin(Domain, UserName, Password); if (!isDomainAdmin) { //deny access, for example } } where IsDomainAdmin - is extension method public static [...] read more
I have my dll hosted at IIS with wsHttpBinding. I have this weird error happened intermediate. Well, everything will be restored back normal again when I reset the IIS (iisreset). I also read this one http://msdn.microsoft.com/en-us/library/ee517280.aspx. But I am not sure it has to do with this. Please guide me [...] read more
I am dealing with a nasty issue that has me ready to tear my hair out. I have a C# console application that uses Microsoft's HttpListener class to listen for web requests. The idea is that the console application runs in the background as UserAccountA (low priv). UserAccountB (Administrator, etc) [...] read more
We have a particular SQL Server which we need to access from a thick (.Net 4.0 WPF) client, and the only credentials available to us for that connection is a 'service' account which is effectively an Active Directory account with permission on the SQL Server. I am using Entity Framework, [...] read more
I developed a wcf service. Since it will also be called by non-.net clients, I used basichttpbinding. Some of the methods need Impersonation. This is forced by decorating the webmethods with: [OperationBehavior(Impersonation = ImpersonationOption.Required)] After I deployed the service on our test server, I get a strange error when I [...] read more
I am using Excel 2013 PowerQuery addin to connect to SQL Server database. I have Excel open with my user account (domain/Sherlock); which does not have read access to the database (myServer/myDB). I have the credentials for another Windows user account (domain/Sherlock_2), which does have read access. Objective: I would [...] read more
We are attempting to use Basic Authentication in a project, which generally works fine in our integration and QA environment or even running locally with IIS 7.5. But running locally in IIS Express we get some very strange issues -- any static requests result in cryptic HTTP 500 errors telling [...] read more
So, I have developed a web application in VS 2010 using ASP.net with VB.net code-behind. This web app is hosted on the company server. I use impersonation in IIS to be able to access network files in my web app, but for some reason I have run in to problems. [...] read more
This may have been asked previously a slightly different way, but I have not yet satisfied myself completely. With Visual Studio 2013, Windows 7, and a small C#/.NET 4.0 project, I am using an HttpListener to build a tiny web server in order to host some simple services and pages. [...] read more
Guys I'm out of ideas... Info : * WPF aplication (C#, .net Framework 4.5) * EntityFramework 6.1 * Recreated whole model (even merged from 3 models to 1) * Uninstalled/installed EntityFramework (console and nuget) few times :) Everything works fine if I run it from VS, but when I run [...] read more
I have an external drive most of my work is on, and I use it at a work PC running Windows 7 Enterprise with limited permissions (small research team in a big organization). I want to make sure that the 1-2TB data on my main external drive (my 'expansion' drive) [...] read more
I have this code running on 8 servers. Now I'm standing up the next 4. I've reproduced this issue on all 4 servers. At first, I get: > System.InvalidOperationException: The view 'Index' or its master was not found > or no view engine supports the searched locations. and it lists [...] read more
I'm trying to implement authentication into my website. I have managed to be correctly redirected to a login page when I try to access the secured website and I can login. However, the problem is that after login I can't access static files (such as .html, .css, .js, etc.), but [...] read more
I just tried this morning to switch an old ASP.NET site's app pool to one that use an AD account for SQL access, upon doing so most of the static content on the site was unavailable (i.e. some images and the CSS file) with a nice 500. After activating failed [...] read more
My website hosted on two environment. Both environment has similar server configuration (Azure VM, Windows server 2016, IIS 10) and same version of code deployed. It was working fine since last one months on both servers but after new release its giving below errors on test02 environment server while in [...] read more
I have an issue with all computers in AD: I'm getting this error after creating VBScriptEngine with debugging flag: either a required impersonation level was not provided, or the provided impersonation level is invalid. (Exception from HRESULT: 0x80070542) The problem is around this line: processDebugManager.AddApplication(debugApplication, out debugApplicationCookie)) where processDebugManager is [...] read more
I have a web app that calls the SharePoint 2007 Lists.asmx service using a WCF endpoint. In an all day attempt to determine why it was receiving a 500 response when calling the GetListItems method, I discovered that it starts succeeding after I execute a query in U2U Caml Query [...] read more
I am getting error 0x80070542 whenever I try to access a static file (such as .html). If I try to access a page like Default.aspx, everything works fine with no errors. Is there any reasonable solution to this problem? I have already seen this answer, however, I don't want to [...] read more
My ASP.NET MVC 3 website was working fine, and then this afternoon I started getting a 500 error, although the only thing I changed was to enable 32-bit applications. I changed that back but the error remains. I've even deleted my app pool and web site and recreated them in [...] read more
I'm attempting to write a couple of NAnt tasks for interacting with Microsoft Virtual Server 2005 R2 SP1, and I've lifted the code found on "Virtual PC Guy's WebLog", in the "Controlling Virtual Server through PowerShell" post. It doesn't work: I always get a failure when calling CreateVirtualMachine: System.Runtime.InteropServices.COMException (0x80070542): [...] read more
I need some help about WCF and authorization. Currently I have a client which calls as .NET remoting object hosted in a windows service and which is calling a WCF service (with wshttpbinding). The WCF service is using windows authentication with message based security. The windows service is running with [...] read more
I am experiencing a weird issue while testing an Asp.Net Webforms application with Windows authentication & IIS Express. Here is the context information: OS: OS Name Microsoft Windows Server 2016 Standard Version 10.0.14393 Build 14393 Visual Studio 2019: Microsoft Visual Studio Enterprise 2019 Version 16.4.6 VisualStudio.16.Release/16.4.6+29905.134 Microsoft .NET Framework Version [...] read more
While migrating from mq dot client 1.0 to mq 8.0.0.4, receiving following error when call mq manager is made. call is made from a script task from ssis 2012 package. call to mq manager works when called from a windows service. Inner Exception : System.IO.FileLoadException: Could not load file or [...] read more
I had a Python Flask website that ran fine when I ran the app pool as my own account. When I tried changing this to a service account (which should have permissions), I get the following error > HTTP Error 500.0 - Internal Server Error > > The page cannot [...] read more
In my project, I've a JS file that I've included in the index file at the top of the page. The file contains collection of common jquery functions for events, e.g.: $('#student').click(function () { var url = "../Layout/EditStudent?StdID=" + $(this).attr('data-sid') + '&crsID=' + $(this).attr('data-crsID'); console.info(url); window.location.href = url; }); When [...] read more
I have a web app that is calling a WCF Method with Impersonation set as required. In this method, I need to call another web service (ASMX) that returns security groups. The problem is, with the Impersonation set as Required, I get an error when I try to create an [...] read more
I'm currently facing an issue I've never seen Before. I have a static .wsdl file set in the site directory and if I navigate to the .svc file it shows up just fine, but as soon as I navigate to http://www.foo.bar/service.wsdl to download the WSDL it throws up an Error [...] read more
I am having windows 8.1 and I upgrade it 2 days a go. After upgrading, When I open my visual studio and debug any of my project so I got the error that you can see in last that I have provided. I had also re-installed visual studio 13 but [...] read more
I have WCF 3.5 service written by other company but I have source code. I have two clients, first is Silverlight (written by the same company) and second ASP page created by me. I have following error on WCF site: using(((WindowsIdentity)HttpContext.Current.User.Identity).Impersonate()) { SomeClass.SomeMethod(); } The Identity is almost the same. [...] read more
I am using visual studio 2020 to do the web application development,and our application require high authenciation,so we add the user identified information in the web.config like this: <identity userName="username" password="pass" impersonate="true"/> However,after add these words,I found that I can not go to the debug model. When I hit the [...] read more
I have a solution in which a Silverlight application calls a WCF service (self-hosted in console application) which we'll call A, which calls another WCF service (hosted in IIS) which we'll call B. WCF service A contains two standard methods and one methods which uses impersonation and calls WCF service [...] read more
I have a frustrating problem trying to use the System.DirectoryServices.DirectoryEntry.Invoke() method to recycle app pools on a remote IIS server. The basic context is two client machines and an IIS 7.0 server machine (Windows 2008 Server), myServer, all in the same Windows domain. I want to run code on the [...] read more
Near the bottom of this article (MSDN) in a section entitled "The following code example demonstrates how to use delegation." where MSDN shows an example of how to perform delegation. I have tried to take this example and apply it to my code. In my situation, I have a client [...] read more