Skip to content

Conversation

@glaslos
Copy link
Member

@glaslos glaslos commented Dec 23, 2020

No description provided.

@glaslos glaslos requested a review from srenfo March 11, 2021 22:56
def __init__(self, host, port, facility, logdevice, logsocket):
logger = logging.getLogger()
self.logger = logging.getLogger("conpot")
handler = logging.StreamHandler()
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This way we're silently swallowing configuration errors (typos mostly). It's also a bit odd to have a "SyslogLogger" print to the console. I'd rather raise an error below.

Alternatively we could make this behavior explicit, like if str(logsocket).lower() == "stderr":, because it should actually be useful to have events printed to the console. At that point we may as well rename "socket" to "mode".

But then we should be able to use /dev/stderr to the same effect - but I haven't tested it.

@glaslos glaslos requested a review from srenfo December 24, 2024 11:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants