falcosecurity / plugins

Falco plugins registry
Apache License 2.0
78 stars 71 forks source link

plugins(k8saudit-gke): export ConvertLogEntry method #490

Closed SKosier closed 2 months ago

SKosier commented 2 months ago

What type of PR is this?

Uncomment one (or more) /kind <> lines:

/kind feature

Any specific area of the project related to this PR?

Uncomment one (or more) /area <> lines:

/area plugins

What this PR does / why we need it:

For the project I have we are ingesting gke events in other way and we would like to leverage already existing OSS code for converting gke events to k8s_audit ones, due to maintainability reasons.

Which issue(s) this PR fixes:

Fixes #

Special notes for your reviewer:

jasondellaluce commented 2 months ago

@sboschman @leogr what's your take here? I think the conversion method genuinely offers a valuable piece of functionality useful to other projects and that perhaps we could export as part of the plugin's package. LGTM.

github-actions[bot] commented 2 months ago

Rules files suggestions

rules

Comparing 9455f9022d5278e8a8a437557a6ec67b046434c8 with latest tag plugins/k8saudit-gke/v0.1.1

Major changes:

Minor changes:

sboschman commented 2 months ago

I don't mind exposing the conversion method as part of the plugin sdk. Seems a bit strange to just expose a random internal function b/c it might be useful without any method signature guarantee or being documented as part of the sdk.

As sdk changes are a bit of work, the method can be made public for the time being. Just add a comment indicating that it is an internal method without any signature guarantees. So use at your own risk.

SKosier commented 2 months ago

I don't mind exposing the conversion method as part of the plugin sdk. Seems a bit strange to just expose a random internal function b/c it might be useful without any method signature guarantee or being documented as part of the sdk.

As sdk changes are a bit of work, the method can be made public for the time being. Just add a comment indicating that it is an internal method without any signature guarantees. So use at your own risk.

Thank you @sboschman for the review. I applied the feedback and added the comment above the method signature.

github-actions[bot] commented 2 months ago

Rules files suggestions

rules

Comparing 1781880ca70c766c0f063a84bea3b7ee865a68e7 with latest tag plugins/k8saudit-gke/v0.1.1

Major changes:

Minor changes:

poiana commented 2 months ago

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: sboschman, SKosier

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files: - ~~[plugins/k8saudit-gke/OWNERS](https://github.com/falcosecurity/plugins/blob/main/plugins/k8saudit-gke/OWNERS)~~ [sboschman] Approvers can indicate their approval by writing `/approve` in a comment Approvers can cancel approval by writing `/approve cancel` in a comment
poiana commented 2 months ago

LGTM label has been added.

Git tree hash: f5d521ed765e078181739e59145800f311345c9e