Rasmus Edvardsen
Rasmus Edvardsen

Reputation: 169

'/.well-known/apple-app-site-association' error in MVC

So we have a site hosted here in Denmark. For the most part, it runs very smoothly.

So I am working on rearranging the logic flow, and I notice that the "path not found" error has a very specific request:

2018-01-12 09:37:01,316 [65] ERROR DAFReturnLabelSite.MvcApplication - App_Error
System.Web.HttpException (0x80004005): The controller for path '/apple-app-site-association' was not found or does not implement IController.
at System.Web.Mvc.DefaultControllerFactory.GetControllerInstance(RequestContext requestContext, Type controllerType)
at System.Web.Mvc.DefaultControllerFactory.CreateController(RequestContext requestContext, String controllerName)
at System.Web.Mvc.MvcHandler.ProcessRequestInit(HttpContextBase httpContext, IController& controller, IControllerFactory& factory)
at System.Web.Mvc.MvcHandler.BeginProcessRequest(HttpContextBase httpContext, AsyncCallback callback, Object state)
at System.Web.Mvc.MvcHandler.BeginProcessRequest(HttpContext httpContext, AsyncCallback callback, Object state)
at System.Web.Mvc.MvcHandler.System.Web.IHttpAsyncHandler.BeginProcessRequest(HttpContext context, AsyncCallback cb, Object extraData)
at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)

It's either the above path that throws an error, or '/.well-known/apple-app-site-association'.

So I look around and find that it's some app security for Apple.

But I don't know where to go from here to make sure this error doesn't occur. How should I handle this event?

Mind you, we've done extensive testing on iPhones and Tablets.

Thanks, Rasmus

Upvotes: 4

Views: 1625

Answers (1)

Heemanshu Bhalla
Heemanshu Bhalla

Reputation: 3765

Its Due to Web Browser–to–Native App Handoff. you can check all details in below link on apple's website -

Web Browser–to–Native App Handoff

The possible reason for coming of these requests are from google-bot or other web spiders. It may rise after you submitted your sitemap and website url to google webmasters. It happens in my case when i submitted sitemap and website url in 'Fetch as Google' tab in google webmaster these requests increased a lot.

These requests are also a problem to your server's bandwidth depending on how many times they are hitting your server.

Solution to them is to add them in robots.txt file that can prevent wastage of bandwidth of your server.

Sample robots.txt file for this problem is below -

Disallow: /.well-known/
Disallow: /apple-app-site-association

Upvotes: 2

Related Questions