Conversation
|
|
||
| def beacon_gate_options_string(bgo: BeaconGateOptions) -> list[str]: | ||
| """Return the enabled BeaconGate WinAPI's as a list of strings""" | ||
| options = {k for k, v in bgo._values.items() if v} |
There was a problem hiding this comment.
does cstruct provide a better or a public api for accessing the values? If not, that might be a nice contract/feature to add so it doesn't break in a future cstruct update :)
There was a problem hiding this comment.
Yeah so although __values__ has a lot of underscores, that is mostly to avoid collisions with user defined fields; it is considered part of the public interface.
Alternative would be to loop over the field names and get the attributes, I think this is slightly cleaner.
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #81 +/- ##
=======================================
Coverage 76.40% 76.40%
=======================================
Files 12 12
Lines 2729 2729
=======================================
Hits 2085 2085
Misses 644 644
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
In which version of cstruct did this API change? |
The change will be part of 4.6 https://github.com/fox-it/dissect.cstruct/blob/main/CHANGELOG.md |
Make cobaltstrike compatible with changes to the struct API.
Note: After cstruct is released, update the dependency