Audit info parameters - WebAPI
See original GitHub issueHi, I have custom WebAPI on the remote server. On every request there is a warning in the log file.
WARN|Abp.Auditing.WebAuditInfoProvider|System.Net.Sockets.SocketException (0x80004005): No such host is known at System.Net.Dns.GetAddrInfo(String name) at System.Net.Dns.InternalGetHostByName(String hostName, Boolean includeIPv6) at System.Net.Dns.GetHostAddresses(String hostNameOrAddress) at Abp.Auditing.WebAuditInfoProvider.GetClientIpAddress(HttpContext httpContext) at Abp.Auditing.WebAuditInfoProvider.Fill(AuditInfo auditInfo)
What’s the problem?
Issue Analytics
- State:
- Created 8 years ago
- Comments:14 (4 by maintainers)
Top Results From Across the Web
Audit.WebApi
Generate Audit Trails for ASP.NET MVC Web API calls. This library provides a configurable infrastructure to log interactions with your Asp.NET (or Asp.NET...
Read more >c# - Web API audit logging
It can record action method calls with caller info, arguments, output, duration, exceptions and more. Take a look at Audit.WebApi.
Read more >How to Audit Your ASP.NET Core WebApi
Firstly, the data gets stored needs to be defined. Different people (because of their roles) can expect different details from an audit log. ......
Read more >How to Audit Your ASP.NET Core WebApi
Add/Remove audit properties Every log is captured in an AuditScope. AuditScope contains some general info about the event as well as the action ......
Read more >Audit Logs Integration Guide - Airtable Web API
The audit log events API is accessible via PAT and OAuth. ... This can be configured using the pageSize parameter and is limited...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I cached exceptions for Dns.GetHostAddresses call. New code is like that:
As you see, I did it virtual. So, you can create a new class inherits from WebAuditInfoProvider and override GetClientIpAddress to change code for your application. Then you can replace IAuditInfoProvider service with your own implementation (https://github.com/aspnetboilerplate/aspnetboilerplate/issues/983#issuecomment-217428154).
Thanks @tamys, this works!