How do I implement log throttling in WCF?
How do I implement log throttling in WCF?
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
Andrew FensterPosted May 2, 2011, 4:06 PM
maxMessagesToLog
maxSizeOfMessagesToLog
The main point of these settings is to prevent a denial of service attack on your web service. Someone could try to overload your logger with millions of messages or with very large messages.
There's a downside, however. Once you exceed the maxMessagesToLog, your service keeps processing incoming calls, but it stops logging them. So you're guarding against one type of attack but making yourself vulnerable to another type.
See http://wcfsecurity.codeplex.com/wikipage?title=How%20do%20I%20implement%20log%20throttling%20in%20WCF?
Note: Message throttling only matters when you're using WCF Message Logging. For more on message logging, see http://msdn.microsoft.com/en-us/library/ms730064.aspx