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

Don't pop excess values from stack #907

Merged
merged 1 commit into from
Oct 30, 2019
Merged

Conversation

mstemm
Copy link
Contributor

@mstemm mstemm commented Oct 30, 2019

The call to rule_loader.load_rules only returns 2 values, so only pop
two values from the stack.

Signed-off-by: Mark Stemm mark.stemm@gmail.com

What type of PR is this?

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

/kind bug

/kind cleanup

/kind design

/kind documentation

/kind failing-test

/kind feature

/kind flaky-test

If contributing rules or changes to rules, please make sure to also uncomment one of the following line:

/kind rule-update

/kind rule-create

Any specific area of the project related to this PR?

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

/area build

/area engine

/area examples

/area rules

/area integrations

/area tests

/area proposals

What this PR does / why we need it:

Which issue(s) this PR fixes:

Fixes #906

Special notes for your reviewer:

Does this PR introduce a user-facing change?:

fix: a crash bug that could result from reading more than ~6 rules files [[#906](https://github.com/falcosecurity/falco/issues/906)]

The call to rule_loader.load_rules only returns 2 values, so only pop
two values from the stack. This fixes #906.

Signed-off-by: Mark Stemm <mark.stemm@gmail.com>
@Kaizhe
Copy link
Contributor

Kaizhe commented Oct 30, 2019

/lgtm

@poiana
Copy link
Contributor

poiana commented Oct 30, 2019

LGTM label has been added.

Git tree hash: 938282bbbc925dee9d2242b5103c9650ad980a2a

@poiana
Copy link
Contributor

poiana commented Oct 30, 2019

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: fntlnz, Kaizhe

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

@fntlnz fntlnz added this to the 0.18.0 milestone Oct 30, 2019
@fntlnz fntlnz mentioned this pull request Oct 30, 2019
@fntlnz fntlnz merged commit 023f510 into dev Oct 30, 2019
@poiana poiana deleted the dont-pop-til-you-cant-stop branch October 30, 2019 07:52
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.

Crash when loading many small rules files
4 participants