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

feat: implement rego from dataflow #123

Merged
merged 16 commits into from
Nov 15, 2022
Merged

Conversation

vjerci
Copy link
Contributor

@vjerci vjerci commented Nov 15, 2022

Description

This pr adds boilerplate for policies and implements first logger leaks policy.

Example output:

- level: warning
  locations:
    - filename: logging.rb
      line_number: "15"
    - filename: logging.rb
      line_number: "21"
    - filename: logging.rb
      line_number: "23"

Checklist

  • I've added test coverage that shows my fix or feature works as expected.
  • I've updated or added documentation if required.
  • I've included usage information in the description if CLI behavior was updated or added.
  • PR title follows Conventional Commits format

@swarmia
Copy link

swarmia bot commented Nov 15, 2022

✅  Linked to AMA-3179 · Implement rego from dataflow
➡️  Part of AMA-2947 · OSS - Curio CLI

@vjerci vjerci requested review from cfabianski and removed request for cfabianski November 15, 2022 12:21
@vjerci vjerci requested review from elsapet, cfabianski and gotbadger and removed request for elsapet November 15, 2022 12:21
pkg/classification/dependencies/dependencies.go Outdated Show resolved Hide resolved
pkg/flag/report_flags.go Outdated Show resolved Hide resolved
pkg/report/output/output.go Outdated Show resolved Hide resolved
pkg/report/output/output.go Outdated Show resolved Hide resolved
pkg/report/output/output.go Outdated Show resolved Hide resolved
Copy link
Contributor

@elsapet elsapet left a comment

Choose a reason for hiding this comment

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

Does it make sense to add some tests at this point, or is this for a later stage?

vjerci and others added 3 commits November 15, 2022 14:06
Co-authored-by: Cédric Fabianski <cedric@bearer.sh>
Co-authored-by: Cédric Fabianski <cedric@bearer.sh>
@vjerci
Copy link
Contributor Author

vjerci commented Nov 15, 2022

Does it make sense to add some tests at this point, or is this for a later stage?

in my opinion it is too early.

@vjerci vjerci changed the title Feat: implement rego from dataflow feat: implement rego from dataflow Nov 15, 2022
@vjerci vjerci added echoes/effort: L enhancement New feature or request labels Nov 15, 2022
@vjerci vjerci merged commit 8be0e07 into main Nov 15, 2022
@vjerci vjerci deleted the AMA-3179-implement-rego-from-dataflow branch November 15, 2022 16:17
@cfabianski
Copy link
Collaborator

- detector_id: logger_leak
  level: warning
  data_types:
    - name: Email
      locations:
       - filename: logging.rb
         line_number: "15"
       - filename: logging.rb
         line_number: "21"
       - filename: logging.rb
         line_number: "23"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants