Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(userspace/falco): accept 'Content-Type' header that contains "application/json", but it is not strictly equal to it #1800

Merged
merged 2 commits into from
Dec 9, 2021

Conversation

FedeDP
Copy link
Contributor

@FedeDP FedeDP commented Nov 19, 2021

Signed-off-by: Federico Di Pierro nierro92@gmail.com

What type of PR is this?

/kind bug

Any specific area of the project related to this PR?

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

/area engine

What this PR does / why we need it:
Do not strictly require "application/json" content-type string in k8s_audit_handler::handlePost(); instead, accept any Content-Type that has "application/json" in it.

Which issue(s) this PR fixes:

Fixes #1702

Special notes for your reviewer:

Does this PR introduce a user-facing change?:

fix(userspace/falco): accept 'Content-Type' header that contains "application/json", but it is not strictly equal to it

…lication/json", but it is not strictly equal to it.

Signed-off-by: Federico Di Pierro <nierro92@gmail.com>
…rts with "application/json" string.

Signed-off-by: Federico Di Pierro <nierro92@gmail.com>

Co-authored-by: Leonardo Grasso <me@leonardograsso.com>
Copy link
Member

@leogr leogr left a comment

Choose a reason for hiding this comment

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

LGTM

/approve

@poiana
Copy link

poiana commented Nov 23, 2021

LGTM label has been added.

Git tree hash: 6075d7e89af99d770fc100ca4cc7bea71c85abaa

@poiana
Copy link

poiana commented Nov 23, 2021

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: FedeDP, leogr

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:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@leogr
Copy link
Member

leogr commented Nov 23, 2021

/milestone 0.31.0

@poiana poiana added this to the 0.31.0 milestone Nov 23, 2021
Copy link
Contributor

@mstemm mstemm left a comment

Choose a reason for hiding this comment

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

I believe this will only detect prefixes, right? So I would suggest updating the release note but if a prefix check is sufficient, then lgtm.

@poiana poiana merged commit bb8b75a into falcosecurity:master Dec 9, 2021
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.

Forwarding audit logs to falco from an AKS cluster using sysdiglabs/aks-audit-log
4 participants