serilog-contrib / Serilog.Enrichers.Sensitive

A Serilog LogEvent enricher that masks sensitive data
MIT License
111 stars 23 forks source link

Feature creditcardmask #2

Closed stoberman37 closed 3 years ago

stoberman37 commented 3 years ago

Hi. I loved your implementation (for the most part, anyway). I needed to add a CreditCard mask. I also tweaked the encrich registration methods to allow others to add their own mask operators as well.

sandermvanvliet commented 3 years ago

Hi @stoberman37 I've finally had time to take a look at the PR, thanks for adding the credit card mask I'm sure many people would find that useful!

I realize that that the README is lacking in the how do I extend this? area and only shows how you can use this as is. That of course leaves everything open to interpretation ;-)

I've added some comments throughout the PR, let me know if they are clear or if I can clarify further.

Also I would suggest to run code cleanup / format document on the code you change before creating the PR. Partially because I'm a bit OCD with alignment and things like that but it also makes things a easier to review as you're not getting triggered by indentation changes in the diffs 😄

Again, thanks for this 👍 I really appreciate it and it's always great to see that this is useful to someone!

stoberman37 commented 3 years ago

I believe that last commit should address all your comments. I included an update to the README.md with a quick explanation of how to extend to additional use cases.