serilog-sinks-email
serilog-sinks-email copied to clipboard
Initialize NetworkCredentials in EmailConnectionInfo
Fixes #90
@nblumhardt, could you take a look at my PR?
Thanks for the PR! I'm not sure whether this change will prevent the use of default credentials in environments that depend on them - unfortunately I'm short of time to investigate.
Any other maintainers currently following this repo with some bandwidth? :-)
@nblumhardt, thank you for your prompt reply. ~~I did some research into this - and apparently it should not be an issue. Take a look at this: https://stackoverflow.com/a/14130274/7980221~~
If we are talking about the following null check, then you are right. https://github.com/serilog/serilog-sinks-email/blob/5fb82c6be87f40fb69e74fe301e57dac55cc6993/src/Serilog.Sinks.Email/Sinks/Email/EmailSink.cs#L135-L138 I need more time to investigate. I will get back to you as soon as I have the solution.
@nblumhardt,
how about setting the default value for NetworkCredentials to CredentialCache.DefaultNetworkCredentials? Could you take a look at my latest commit (26a2d4e1c0193bf4a237170b6b832f0ad4a86f99)?
Sorry Adrian, I don't have any environment in which to test these things, so this has been sitting on my TODO list for a while. Can you share any details of what testing/investigation you've done? (E.g. why do you think this will preserve the existing behavior?)
Many thanks, Nick
Closing this one as stale, but thanks for sending the PR!