osquery / osquery-python

Python bindings for osquery's Thrift API
Other
295 stars 51 forks source link

Fix for double-JSON-encoding of table generation contexts (#77) #78

Closed nickovs closed 3 years ago

nickovs commented 3 years ago

As described in issue #77, the context information passed to a table plugin's generate() method is (a) inconveniently double-encoded and (b) inconsistent in its data type (since it can either be a double-encoded string or an empty dictionary). This PR fixes this to always pass a dictionary, which will contain the unpacked context information if it was provided in the call.

linux-foundation-easycla[bot] commented 3 years ago

CLA Signed

The committers are authorized under a signed CLA.

nickovs commented 3 years ago

@theopolis Thank you for the swift response. Any chance that someone can push an updated version to PyPI so that the fix is more widely available?