All inbound request port to Azure Linux Webapp is 80, not 443 in logs( in application insights & AppServiceHTTPLogs Table)

Gallatin 21V 206 Reputation points
2025-04-24T01:44:20.5833333+00:00

We made request test to azure linux webapp, find all port is 80, no matter I request http or https.

I configed the Diagnostic logs and application insights, the recored was same as below:

(Made same test in windows webapp, there is no this issue. Please help confirm whether this is a bug or bydisgn?)

Diagnostic logs AppServiceHTTPLogs:
图片

图片

Azure App Service
Azure App Service
Azure App Service is a service used to create and deploy scalable, mission-critical web apps.
8,778 questions
{count} votes

1 answer

Sort by: Most helpful
  1. Bhargavi Naragani 3,820 Reputation points Microsoft External Staff Moderator
    2025-04-28T04:14:55.7766667+00:00

    Hi @Gallatin 21V,

    Since your customer prefers not to modify application code ("no code injection") and is looking for a solution based purely on Azure platform logs (such as Application Insights or Diagnostic Logs). Currently, Azure does not automatically log X-Forwarded-Proto or the original client port into Application Insights or AppServiceHTTPLogs by default, this means without code changes, you cannot get the original protocol (HTTP/HTTPS) purely from Azure’s standard logs at the App Service level.

    If no code changes are allowed but you still need to log the original protocol, as I mentioned in previous response consider using Azure Front Door or Azure Application Gateway, these services sit in front of your App Service, handle TLS termination, and can log client protocol/port into their respective diagnostic logs.

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.