Skip to content

Conversation

@zwass
Copy link
Member

@zwass zwass commented Apr 12, 2022

This resolves an issue where the extension does not shut down if osquery
goes away unexpectedly (without sending a shutdown signal via Thrift).

The scenario could be reliably reproduced by running osqueryi,
connecting an extension, and then sending a SIGKILL to osqueryi. The
exception thrown in the start_watcher function would be of type
thrift.transport.TTransport.TTransportException, and would cause the
watcher thread to exit without exiting the rest of the program.

This is a possible fix for issues that users have experienced with
extensions reconnecting after the Watchdog kills osquery.

This resolves an issue where the extension does not shut down if osquery
goes away unexpectedly (without sending a shutdown signal via Thrift).

The scenario could be reliably reproduced by running `osqueryi`,
connecting an extension, and then sending a `SIGKILL` to `osqueryi`. The
exception thrown in the `start_watcher` function would be of type
`thrift.transport.TTransport.TTransportException`, and would cause the
watcher thread to exit without exiting the rest of the program.

This is a possible fix for issues that users have experienced with
extensions reconnecting after the Watchdog kills osquery.
Copy link
Member

@sharvilshah sharvilshah left a comment

Choose a reason for hiding this comment

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

I think we will need to update the version in https://github.com/osquery/osquery-python/blob/master/osquery/__init__.py#L7 too?

@zwass
Copy link
Member Author

zwass commented Apr 15, 2022

I'd prefer to keep those version updates in a separate PR (#84). @sharvilshah does that work for you?

@sharvilshah
Copy link
Member

That works!

@zwass zwass merged commit 4cbe297 into osquery:master Apr 15, 2022
@zwass zwass deleted the fix-unexpected-shutdown branch April 15, 2022 15:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants