Not able to deploy IdentityServer 4 code on Azure App service - azure
I have used dotnetcore 3.0 to develop the IdentityServer in empty Asp.net Web Application hosting.
App Service I created is dotnetcore 3.0, Windows platform.
In my dotnet core solution I created the publish output using 'dotnet publish'
It worked fine on localhost url as I consumed that url in my client application. I have only TokenPoint and from UI application I pass username/ password
Below is the logs on App service:
2020-04-02 17:41:09 NEWIDPSERVER GET / X-ARR-LOG-ID=e83b7b1e-6f40-4f67-9f0d-0f4f474e2309 443 - 112.196.168.73 Mozilla/5.0+(Windows+NT+10.0;+Win64;+x64)+AppleWebKit/537.36+(KHTML,+like+Gecko)+Chrome/80.0.3987.149+Safari/537.36 ARRAffinity=c450828deae8ef5774d6b51f85ad7bb411cc76cec811344524a352e00ebf3ca1 - newidpserver.azurewebsites.net 500 30 574 2913 1374 6437
2020-04-02 17:41:19 ~1NEWIDPSERVER GET /detectors type=tools&name=eventviewer&X-ARR-LOG-ID=ec15da12-ce7e-44ae-83fe-7f8f4c9c62cc 443 - 112.196.168.73 Mozilla/5.0+(Windows+NT+10.0;+Win64;+x64)+AppleWebKit/537.36+(KHTML,+like+Gecko)+Chrome/80.0.3987.149+Safari/537.36 ARRAffinity=c450828deae8ef5774d6b51f85ad7bb411cc76cec811344524a352e00ebf3ca1 https://newidpserver.azurewebsites.net/ newidpserver.scm.azurewebsites.net 302 0 0 1047 1590 1062
IIS Detailed Error - 500.30 - Internal Server Error
HTTP Error 500.30 - Internal Server ErrorThe page cannot be displayed because an internal server error has occurred.Most likely causes: IIS received the request; however, an internal error occurred during the processing of the request. The root cause of this error depends on which module handles the request and what was happening in the worker process when this error occurred. IIS was not able to access the web.config file for the Web site or application. This can occur if the NTFS permissions are set incorrectly. IIS was not able to process configuration for the Web site or application. The authenticated user does not have permission to use this DLL. The request is mapped to a managed handler but the .NET Extensibility Feature is not installed. Things you can try: Ensure that the NTFS permissions for the web.config file are correct and allow access to the Web server's machine account. Check the event logs to see if any additional information was logged. Verify the permissions for the DLL. Install the .NET Extensibility feature if the request is mapped to a managed handler. Create a tracing rule to track failed requests for this HTTP status code. For more information about creating a tracing rule for failed requests, click here.
Detailed Error Information:Module AspNetCoreModuleV2Notification ExecuteRequestHandlerHandler aspNetCoreError Code 0x8007023e
Requested URL https://newidpserver:80/.well-known/openid-configurationPhysical Path D:\home\site\wwwroot\.well-known\openid-configurationLogon Method AnonymousLogon User Anonymous
More Information:This error means that there was a problem while processing the request. The request was received by the Web server, but during processing a fatal error occurred, causing the 500 error.View more information »Microsoft Knowledge Base Articles:
2020-04-02 17:42:35 NEWIDPSERVER GET /.well-known/openid-configuration X-ARR-LOG-ID=3273401b-d59d-4e79-ba95-207ca2a8273f 443 - 112.196.168.73 - - - newidpserver.azurewebsites.net 500 30 574 2923 892 0
2020-04-02T17:44:45 No new trace in the past 1 min(s).
2020-04-02T17:45:45 No new trace in the past 2 min(s).
2020-04-02T17:46:45 No new trace in the past 3 min(s).
2020-04-02T17:47:36 Welcome, you are now connected to log-streaming service. The default timeout is 2 hours. Change the timeout with the App Setting SCM_LOGSTREAM_TIMEOUT (in seconds).
2020-04-02T17:48:36 No new trace in the past 1 min(s).
2020-04-02T17:49:07
System.ApplicationException: The trace listener AzureBlobTraceListener is disabled. ---> System.InvalidOperationException: The SAS URL for the cloud storage account is not specified. Use the environment variable 'DIAGNOSTICS_AZUREBLOBCONTAINERSASURL' to define it.at Microsoft.WindowsAzure.WebSites.Diagnostics.AzureBlobTraceListener.RefreshConfig()--- End of inner exception stack trace ---
2020-04-02T17:49:07 PID[6956] Information Loading modules from D:\Program Files (x86)\MiddlewareModules\1.2.4\Microsoft.Azure.AppService.Middleware.Modules.dll
2020-04-02T17:49:08 PID[6956] Verbose Detected application setting 'WEBSITE_AUTH_LOGOUT_PATH' = '/.auth/logout'
2020-04-02T17:49:08 PID[6956] Verbose Detected application setting 'WEBSITE_AUTH_ENABLED' = 'False'
2020-04-02T17:49:08 PID[6956] Verbose Detected application setting 'EASY_AUTH_CONFIG_CONTENTS' = '{"preserveUrlFragmentsForLogins":false,"endpointPath":{"apiPrefix":"/.auth","logoutPath":"/.auth/logout","LogoutCompletionPath":"/.auth/logout/complete","mobileCompatibilityEnabled":false},"allowedExternalRedirectUri":{"allowedExternalRedirectUrls":null,"AllowedExternalRedirectUriCollection":[]},"nonce":{"validateNonce":true,"nonceExpirationInterval":"00:05:00"},"token":{"stateDirectory":"D:\home\data\.auth","TokenStorePath":"D:\home\data\.auth\tokens","tokenStoreEnabled":false,"tokenStoreContainerSasUrlSettingName":null,"tokenRefreshExtensionHours":72.0},"isAuthEnabled":false,"requireHttps":true,"defaultProvider":null,"unauthenticatedClientAction":0,"authConfigDirectory":null,"hideDeprecatedSecurityIds":false,"AppTracingLevel":31,"useLegacyClaims":true,"warmupPath":null,"forwardingHeader":null,"functionsExtensionVersion":null,"cookieExpirationTime":"08:00:00","azureActiveDirectory":{"openIdIssuer":null,"clientId":null,"clientSecretSettingName":null,"clientSecretCertificateThumbprint":null,"allowedAudiences":null,"loginParameters":null,"aadBypassSingleTenancyCheck":false,"activeDirectoryAcl":null,"disableWwwAuthenticateResponse":false,"OpenIdIssuerValue":null,"OpenIdConfigurationUrl":null},"facebook":{"facebookAppId":null,"facebookAppSecretSettingName":null,"facebookScope":null,"facebookGraphApiVersion":"v3.3"},"gitHub":{"gitHubAppId":null,"gitHubAppSecretSettingName":null,"gitHubScope":null},"twitter":{"twitterConsumerKey":null,"twitterConsumerSecretSettingName":null},"google":{"googleClientId":null,"googleClientSecretSettingName":null,"googleScope":null,"allowedAudiences":null},"openIdConnectProviders":null}'
2020-04-02T17:49:08 PID[6956] Verbose Detected application setting 'WEBSITE_CORS_ALLOWED_ORIGINS' = ''
2020-04-02T17:49:08 PID[6956] Verbose Detected application setting 'WEBSITE_CORS_SUPPORT_CREDENTIALS' = 'False'
2020-04-02T17:49:08 PID[6956] Verbose Detected application setting 'WEBSITE_AUTH_LOGOUT_PATH' = '/.auth/logout'
2020-04-02T17:49:08 PID[6956] Verbose Detected application setting 'WEBSITE_AUTH_ENABLED' = 'False'
2020-04-02T17:49:08 PID[6956] Verbose Detected application setting 'EASY_AUTH_CONFIG_CONTENTS' = '{"preserveUrlFragmentsForLogins":false,"endpointPath":{"apiPrefix":"/.auth","logoutPath":"/.auth/logout","LogoutCompletionPath":"/.auth/logout/complete","mobileCompatibilityEnabled":false},"allowedExternalRedirectUri":{"allowedExternalRedirectUrls":null,"AllowedExternalRedirectUriCollection":[]},"nonce":{"validateNonce":true,"nonceExpirationInterval":"00:05:00"},"token":{"stateDirectory":"D:\home\data\.auth","TokenStorePath":"D:\home\data\.auth\tokens","tokenStoreEnabled":false,"tokenStoreContainerSasUrlSettingName":null,"tokenRefreshExtensionHours":72.0},"isAuthEnabled":false,"requireHttps":true,"defaultProvider":null,"unauthenticatedClientAction":0,"authConfigDirectory":null,"hideDeprecatedSecurityIds":false,"AppTracingLevel":31,"useLegacyClaims":true,"warmupPath":null,"forwardingHeader":null,"functionsExtensionVersion":null,"cookieExpirationTime":"08:00:00","azureActiveDirectory":{"openIdIssuer":null,"clientId":null,"clientSecretSettingName":null,"clientSecretCertificateThumbprint":null,"allowedAudiences":null,"loginParameters":null,"aadBypassSingleTenancyCheck":false,"activeDirectoryAcl":null,"disableWwwAuthenticateResponse":false,"OpenIdIssuerValue":null,"OpenIdConfigurationUrl":null},"facebook":{"facebookAppId":null,"facebookAppSecretSettingName":null,"facebookScope":null,"facebookGraphApiVersion":"v3.3"},"gitHub":{"gitHubAppId":null,"gitHubAppSecretSettingName":null,"gitHubScope":null},"twitter":{"twitterConsumerKey":null,"twitterConsumerSecretSettingName":null},"google":{"googleClientId":null,"googleClientSecretSettingName":null,"googleScope":null,"allowedAudiences":null},"openIdConnectProviders":null}'
2020-04-02T17:49:08 PID[6956] Verbose Detected application setting 'WEBSITE_CORS_ALLOWED_ORIGINS' = ''
2020-04-02T17:49:08 PID[6956] Verbose Detected application setting 'WEBSITE_CORS_SUPPORT_CREDENTIALS' = 'False'
2020-04-02T17:49:08 PID[6956] Verbose Detected application setting 'WEBSITE_AUTH_SIGNING_KEY' = '0F****'
2020-04-02T17:49:08 PID[6956] Verbose Detected application setting 'WEBSITE_AUTH_ENCRYPTION_KEY' = 'CE****'
IIS Detailed Error - 500.0 - Internal Server Error
HTTP Error 500.0 - Internal Server ErrorThe page cannot be displayed because an internal server error has occurred.Most likely causes: IIS received the request; however, an internal error occurred during the processing of the request. The root cause of this error depends on which module handles the request and what was happening in the worker process when this error occurred. IIS was not able to access the web.config file for the Web site or application. This can occur if the NTFS permissions are set incorrectly. IIS was not able to process configuration for the Web site or application. The authenticated user does not have permission to use this DLL. The request is mapped to a managed handler but the .NET Extensibility Feature is not installed. Things you can try: Ensure that the NTFS permissions for the web.config file are correct and allow access to the Web server's machine account. Check the event logs to see if any additional information was logged. Verify the permissions for the DLL. Install the .NET Extensibility feature if the request is mapped to a managed handler. Create a tracing rule to track failed requests for this HTTP status code. For more information about creating a tracing rule for failed requests, click here.
Detailed Error Information:Module AspNetCoreModuleV2Notification ExecuteRequestHandlerHandler aspNetCoreError Code 0x00000000
Requested URL https://newidpserver:80/.well-known/openid-configurationPhysical Path D:\home\site\wwwroot\.well-known\openid-configurationLogon Method AnonymousLogon User Anonymous
More Information:This error means that there was a problem while processing the request. The request was received by the Web server, but during processing a fatal error occurred, causing the 500 error.View more information »Microsoft Knowledge Base Articles:
2:
https://i.stack.imgur.com/zeALq.png
Token on my local:
ack.imgur.com/X6Ch3.png
You can publish you webapps by vscode, if you has something with your visual studio.
Add Extensions about azure, and open your project which created by visual studio. Run it in local make sure you can open the site.
Then you can deploy you apps follow the document about publish app by vscode .I suggest you deploy apps by visual studio. I think it's easy publishing with Visual Studio.
Related
HTTP Error 500.30 - ANCM In-Process Start Failure with newly created app service
we are created new development environment so I cloned a current working app service into a new one and changed the configurations and deployed same code but the new app service is returning HTTP Error 500.30 - ANCM In-Process Start Failure after trying the console for more details that's what I get, I don't think its related to runtime identifier because same code runs on different exact app services
The dreaded 500.3x ACNM error can mean different things, so I'm going to assist you in pinpointing those things. My recommendation: Go to Azure Portal > Your App Service > development tools Open console. Screen should look like this: Console Screen Azure Type in (YourWebAppName).exe What this will do, is show error messages that are relevant to your startup issue. Also, some information regarding errors can be seen here: https://learn.microsoft.com/en-us/aspnet/core/test/troubleshoot-azure-iis?view=aspnetcore-3.1#app-startup-errors
Azure backend return 500 in PATCH operation
I am desperately trying to debug an error 500 only when I try to update an object from my xamarin.Forms offline DB to Azure. I am using Azure Mobile Client. I set all the logging to ON in azure, then I downloaded the log. I can see the generic error, but nothing useful. <failedRequest url="https://MASKED:80/tables/Appel/9A3342A2-0598-4126-B0F6-2999B524B4AE" siteId="Masked" appPoolId="Masked" processId="6096" verb="PATCH" remoteUserName="" userName="" tokenUserName="IIS APPPOOL\Masked" authenticationType="anonymous" activityId="{80000063-0000-EA00-B63F-84710C7967BB}" failureReason="STATUS_CODE" statusCode="500" triggerStatusCode="500" timeTaken="625" xmlns:freb="http://schemas.microsoft.com/win/2006/06/iis/freb" > The table that failed is the only one I extend with some virtual runtime calculated field of navigation field. But I add the [JsonIgnore] to stop AzureService to create field in the local DB (that work) or send it on the wire to the server. But I always got the 500 error, not exception when debugging the c# Azure backend too. How I can find the stack trace or the "deep" reason for this 500 error in my backend?
For C# Mobile App backend, you could add the following code in the ConfigureMobileApp method of your Startup.MobileApp.cs file for including error details and return to your client side. config.IncludeErrorDetailPolicy = IncludeErrorDetailPolicy.Always; You could just capture the exception in your mobile application or leverage fiddler to capture the network traces when invoking the PATCH operation to retrieve the detailed error message. Moreover, you are viewing the Failed Request Traces log, you need to check the Application logs. Details you could follow Enable diagnostics logging for web apps in Azure App Service.
pre flight HTTP OPTIONS call timesout with 500 Error sporadically
I have a C# based webAPI hosted on Azure WebApp. Sporadically, the HTTP OPTIONS call fails with a 500 error. The OPTIONS call is not handled by our code. So I assume the server handles it by itself. I tried enabling logs but both event log and web server logs does not print anything other than that it failed with a 500 error. Any ideas why this would happen?. Update: I see only the below error messages in the web server logs. No details Additionally I added code in my webAPI to handle options call, but the code does not go there. Not sure if I need to enable/disable something in web.confi. 2017-08-31 11:49:39 xxx.mywebsite.com OPTIONS /api/apiname StartDate=2017-08-25&EndDate=2017-08-31&X-ARR-LOG-ID=d86ffe7f-32c9-410b-8116-65833d5af7b9 443 - xxx.xxx.xxx.xxx Mozilla/5.0+(Windows+NT+6.1;+Win64;+x64)+AppleWebKit/537.36+(KHTML,+like+Gecko)+Chrome/60.0.3112.113+Safari/537.36 - www.website.com 500 121 0 636 1612 230013
how to debug error 500 Internal Server Error on an Azure App?
I got an "500 Internal Server Error - An error occurred while starting the application" after deploying my application: https://iidapp.azurewebsites.net/ I keep finding the following error message but I am unable to find out on msdn websites any information describing how I can specify the SAS URL INFO: The app was working for a long period and I didn't have to set the SAS URL; I wonder why suddenly Azure is generating exceptions INFO2: the app works perfectly on my local machine Any help is welcomed as I couldn't find any solution by reading the related topics on stackoverflow 2017-04-05T18:51:32 System.ApplicationException: The trace listener AzureBlobTraceListener is disabled. ---> System.InvalidOperationException: The SAS URL for the cloud storage account is not specified. Use the environment variable 'DIAGNOSTICS_AZUREBLOBCONTAINERSASURL' to define it. at Microsoft.WindowsAzure.WebSites.Diagnostics.AzureBlobTraceListener.RefreshConfig() --- End of inner exception stack trace ---
An error was triggered by W3SVC-WP : {app name}02000780 I found out on eventid that the code 02000780 meant that a file was missing I eventually found out that it was possible to log further information by enabling the stdoulog inside the web.config. Read When a .NET Core Azure App Service won’t start: 502.5 Process Failure I opened the debug console and found out that a directory wasn't found https://{app_id}.scm.azurewebsites.net/DebugConsole Voilà! I corrected the code and the app is up and running!
HTTP Error 500.19
I moved previously published application from IIS-6 to IIS-8 on new windows server 2012R2 new application is giving me below error. Server Error in Application "application name" HTTP Error 500.19 – Internal Server Error HRESULT: 0x8007000d Description of HRESULT The requested page cannot be accessed because the related configuration data for the page is invalid. can anyone guide me how to resolve this error.
I resolved this issue by changing application pool CLR version to 2.* from 4.*, as it was written in previous version of the .net framework.