Skip to content

Commit

Permalink
Nag suppression should be on iam role
Browse files Browse the repository at this point in the history
  • Loading branch information
alexiswl committed Nov 1, 2024
1 parent 19f3ce5 commit 4be4062
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ import * as dynamodb from 'aws-cdk-lib/aws-dynamodb';
import path from 'path';
import { NagSuppressions } from 'cdk-nag';
import * as sfn from 'aws-cdk-lib/aws-stepfunctions';
import * as iam from 'aws-cdk-lib/aws-iam';
import * as ssm from 'aws-cdk-lib/aws-ssm';
import * as secretsManager from 'aws-cdk-lib/aws-secretsmanager';
import * as events from 'aws-cdk-lib/aws-events';
Expand Down Expand Up @@ -163,7 +164,7 @@ export class Cttsov2CompleteToPieriandxConstruct extends Construct {
Handle lambda permissions
*/
// FIXME - cannot get the 'current' version of an IFunction object
NagSuppressions.addResourceSuppressions(getDataFromRedCapPyLambdaObj, [
NagSuppressions.addResourceSuppressions(<iam.Role>getDataFromRedCapPyLambdaObj.role, [
{
id: 'AwsSolutions-IAM5',
reason: 'Cannot get latest version of redcap lambda function ($LATEST) will not work',
Expand Down

0 comments on commit 4be4062

Please sign in to comment.