0

Technical Stack

  • Imperva WAF
  • Angular 7
  • Azure WebApp

We are planning to deploy Angular 7 build in Azure WebApp and will add custom domain to it which will be behind Imperva WAF. WAF will make sure that only whitelisted IPs can access site. WebApp gets WAF IPs instead of client IPs.

In this case, we are not able to trace usage reports for given client IPs. So as per suggestion, we want to add these data into App Insights to make sure we have all to get the usage reports.

How to implement this? Do we have anything to write custom code to implement this?

Manish Joisar
  • 1,256
  • 3
  • 23
  • 47

1 Answers1

0

Please correct me if I misunderstand you.

There is application insights sdk, you can take use of it like use methods trackTrace / trackEvent to add your custom log.

You can also search by google, there're lots of examples of using application insights for logging with code.

Hope it helps.

Ivan Glasenberg
  • 29,865
  • 2
  • 44
  • 60
  • Hello Ivan, thanks for quick reply. When you are saying sdk, that means we have to implement this within our angular application to add custom log, right ? do we need to create custom fields within AppInsights or it create with new field name? It manages all other default parameters on its own ? i.e. WebApp Name, Operation details, URL etc. ? and we need to just pass custom log details ? – Manish Joisar Jun 18 '19 at 12:15
  • 1
    @ManishJoisar, yes, you need to add code for custom logs. App insights will automactially add some fields, but it's ok to use the property filed(when use methods like trackTrace etc.) to add any filed you need. – Ivan Glasenberg Jun 19 '19 at 02:02