Search code examples
.netazureazure-application-insightstelemetry

How can I hide Client IP address in Application Insights?


I've tried to add the following TelemetryInitializer:

TelemetryConfiguration.Active.TelemetryInitializers.Add(new HiddenIpsTelemetryInitializer());

public class HiddenIpsTelemetryInitializer : ITelemetryInitializer
{
    public void Initialize(ITelemetry telemetry)
    {
        telemetry.Context.Properties["Client IP address"] = "Hidden";
    }
}

But it doesn't do what I want. It adds a new property to "Custom Data" section, and what I want is to hide the "Client IP address" in "Request Properties" section.


Solution

  • There was a service announcement recently on AI Service blog informing that IP will be zeroed out after AI has extracted Geo location information from it.

    This is done to make sure the privacy concerns of AI customers are addressed in light of upcoming GDPR law in EU.

    So, you do not need to hide it anymore.