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(stepfunctions): add stepfunctions service and check stepfunctions_statemachine_logging_enabled #5466

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

AdriiiPRodri
Copy link
Contributor

Context

To cover the checks for the Step Functions service, in this PR we have added that service and have also included the logging enabled check: [StepFunctions.1] Step Functions state machines should have logging turned on

Description

This PR adds:

  • Step Functions service.
  • Step Functions client.
  • stepfunctions_statemachine_logging_enabled check.
  • Unittest for service, check and config.
  • Config file parameter to check log level (the check will only pass if the state machine has the specified logging level enabled).

Checklist

License

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

@AdriiiPRodri AdriiiPRodri added the provider/aws Issues/PRs related with the AWS provider label Oct 18, 2024
@AdriiiPRodri AdriiiPRodri self-assigned this Oct 18, 2024
@AdriiiPRodri AdriiiPRodri requested review from a team as code owners October 18, 2024 14:00
Copy link
Contributor

You can check the documentation for this PR here -> Prowler Documentation

@AdriiiPRodri AdriiiPRodri force-pushed the PRWLR-4469-Ensure-Step-Functions-State-Machines-Have-Logging-Enabled branch from fcf088e to 6636b62 Compare October 18, 2024 16:12
Copy link
Contributor

You can check the documentation for this PR here -> Prowler Documentation

Copy link

codecov bot commented Oct 18, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 89.69%. Comparing base (ffa29f2) to head (a588c17).

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #5466      +/-   ##
==========================================
+ Coverage   89.58%   89.69%   +0.10%     
==========================================
  Files        1073     1076       +3     
  Lines       33237    33385     +148     
==========================================
+ Hits        29777    29946     +169     
+ Misses       3460     3439      -21     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@AdriiiPRodri AdriiiPRodri force-pushed the PRWLR-4469-Ensure-Step-Functions-State-Machines-Have-Logging-Enabled branch from 6636b62 to 4999bf0 Compare October 20, 2024 21:51
Copy link
Contributor

You can check the documentation for this PR here -> Prowler Documentation

Copy link
Contributor

You can check the documentation for this PR here -> Prowler Documentation

"Code": {
"CLI": "aws stepfunctions update-state-machine --state-machine-arn <state-machine-arn> --logging-configuration file://logging-config.json",
"NativeIaC": "",
"Other": "https://docs.aws.amazon.com/step-functions/latest/dg/logging.html",
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
"Other": "https://docs.aws.amazon.com/step-functions/latest/dg/logging.html",
"Other": "https://docs.aws.amazon.com/securityhub/latest/userguide/stepfunctions-controls.html#stepfunctions-1",

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation provider/aws Issues/PRs related with the AWS provider
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants