ASP.NET single page application or MVC app and 404.15 - http-status-code-404

I created a ASP.NET single page application. When I run it I get the following 404.15 error. I see the same error with an MVC application without a Web API in it also.
I commented out the ConfigureAuth code as below:
public partial class Startup
{
public void Configuration(IAppBuilder app)
{
//ConfigureAuth(app);
}
}
Now I get another error which is below:
I tried to duplicate this on a different laptop, and I don't see a problem there.
Is this a directory level permission issue on this particular laptop where I created the app? Appreciate anyone can shed some light on this to fix this.
UPDATE 11/9/2014
I did some further debugging and found that the applications works fine with no authentication and Windows Authentication. When the authentication is forms, I see this problem happening. As you see in the IntelliTrace, the GET request is looping back to Account/Login multiple times and finally give with a 404.15 error. I added a authorization section in the web.config to allow all users to access the resources with , I still see the errors.
I see a major difference between how my laptop and the surface pro 2 behaving with the same application. In my surface pro 2, the home page is displayed and the redirect to account/login never happens. But in the laptop the redirection is happening to account/login.
There are tables in the surface pro 2 created by the asp.net identity. But in my laptop there are no tables. I believe when the application starts, there is no requirement for the tables and the control should go to the home page.
I hope anyone can provide an answer with my additional info.

At first sight looking at the requestedUrl it may be the case that you are always redirecting to the same page (the login page) which creates an infinite redirect loop until the request url becomes too long: Since there is no code I can't be sure about it but I would suggest you to check your redirect url. The authentication appears just because you outcommented the ConfigureAuth method but I don't think it will solve the problem.

Related

Webview missing from Chrome

We have an embedded microApp that is setup on a thirdparty website (Saba) that is designed to pass a session token to our Application. We are initiating a User login by presenting them an embedded browser session using WebView2 in our wpf application. Then after a successful login the microApp on the Saba homepage passes back a session token. This appears to be where the application is hanging, waiting for the valid session token to be returned.
This had been working great up until the last 24 hrs, when we are experience hangs on logging in. It appears that trying to access webview via the console/inspector from Edge doesn't work either. "window.chrome.webview" shows undefined.
We are actively scouring any reference we can find to see if there is information about webview support being deprecated or moved but we haven't yet. If anyone has any ideas or resources of where we may be able to find some answer that would be much appreciated.

Angular App getting Access Denied from IE11 when going through Intranet

This is a weird problem and I apologize beforehand that I may not give enough details:
We have a pretty standard Angular app that needs to access an API on a different (sub-)domain, using CORS. Everything works perfectly fine on Chrome and Firefox. We also got it working on IE >=9.
Unfortunately, some of our customers need to access our public website from within their company intranet. In this case, using IE, only a couple API requests go through. Chrome and Firefox cause no problems.
They can create a sessionThey get the result of a second GET requestBut the third request fails
In the console, we see an Access Denied message caused by a GET request.
**AND**: When they reload the page, the third request goes through. One customer could bypass his intranet and access our website directly. Then, everything worked like a charm.
Please note that we are only aware of issues with IE 11.
Any help is really appreciated.

Silverlight webapplication white screen of death

I'm having an white screen of death when trying to debug my silverlight application. The problem is that I don't know what causes it and I don't get any type of information from either Visual Studio or the browser itself (IE9). Breakpoints won't be hit as App() in the App.xml.cs doesn't get fired either.
The application works fine on my own laptop, but I'm trying to make final adjustments to it on the server which will host the application once it's done. The problem occures on this server.
Would there be any way to get information about what's causing it or did someone experience simulair issues?
hit F12 in IE and go to network and start capturing. You should see your error there if something went wrong downloading and also if there was a problem with the Silverlight plugin (check Console or Script tag).
There could be a number of reasons for this including problems with database connectivity, WCF services, and many other factors. One thing that might help you get some information is a product called Fiddler. If you are able to download and install that on your development machine, you can have it running when you try and access your application on the server. It will give you messages for every step of your application initialization, including database authentication, service authentication, the xap file transfer, etc.
My problem was related to init params not loading up from the web project's .aspx page, try having a look at this if you are having "white death screen" issues.

cakephp auth login problem, only white screen after login

I’ve created a small cakePHP application that uses the auth component to manage an admin section for changes.
The problem I’m having ‘only in the production environment’ is that after I login all I can see is a blank white screen. I should be redirected to a ‘dashboard’ view. This blank screen is also what I get with all other ‘admin’ prefixed views that require a logged in user, thus the auth component.
What is strange about this are two things, (1) this works fine in the local host and (2) this application is a copy of one that works fine in both the local host and production.
What I’ve done to try and resolve this is:
-Checked the previous application copy; nothing different found
-Checked that the passwords were hashed
-Checked that the .htaccess file was uploaded in ASCII format (suggested by the host)
Any help with this is appreciated.
Ideally I’d like to understand how to trouble shoot this type of problem.
Thanks, Paul
Clear out your tmp cache files anytime you move a cakephp project to a new server or folder. They are located in /app/tmp/cache/

CakePHP's Auth->Login not working in production, but works in test

I have a CakePHP website that's been working great.
I just developed a new functionality that at one point auto-logs the user in, and redirects him to a page that's behind the login wall.
This works perfectly well in my dev machine, but in production, the user gets redirected to the login page.
Relevant code: (not much)
$objCustomer = $this->Customer->findById($customerId);
$this->Auth->login($objCustomer);
$this->redirect("/customers/signup");
Customer is the Model that's used for authentication.
In the server, I see that I AM getting redirected to /customers/signup, and that redirects me to /customers/login
The thing that confuses me the most is that this works perfectly in my machine.
I dumped the return value of Auth->Login in the server, and it returns 1, so in theory everything is fine and the user should've been logged in.
Some things I can think of that are different between my machine and the server:
Dev machine is Windows, Server is Linux. This sometimes introduces case-sensitivity issues, but the signup method i'm redirecting to is all lowercase, I don't see where there could be such a problem here.
Dev machine is IIS, Server is LiteSpeed. Maybe Litespeed is screwing with something? This would be the first time in over a year running this site in production that i'd find something different because of LiteSpeed
Production site is over SSL, dev is not. I don't see how this could be a problem.
Any ideas are infinitely welcome!
Thank you!
I had problems too with authentication working fine on my machine in development mode, but not working on the server in production mode. Surprisingly, when I changed the server to development mode it started working correctly. Then I changed back to production, and it was still working. Perhaps it was some cache issue.
After a LOOOONG process of trying different weird things, it turns out it all boils down to this:
ini_set('session.referer_check', $this->host);
That's part of CakePHP's standard security features... It sets that INI setting.
If the request made to the action that'll call Auth->login is coming from another host (domain/subdomain/whatever), PHP will consider the session invalid, which effectively kills the auto-login attempt.

Resources