New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details
Socket
Book a DemoSign in
Socket

@cfn-modules/lambda-function

Package Overview
Dependencies
Maintainers
1
Versions
37
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@cfn-modules/lambda-function - npm Package Compare versions

Comparing version
0.0.3
to
0.0.5
+18
-12
module.yml

@@ -23,2 +23,6 @@ ---

Default: ''
KmsKeyModule:
Description: 'Optional but recommended stack name of alerting module.'
Type: String
Default: ''
VpcModule:

@@ -28,4 +32,4 @@ Description: 'Optional stack name of vpc module.'

Default: ''
DeadLetterQueueArn: # TODO should be a module reference
Description: 'Optional ARN of a SQS queue for events after the maximum number of retries was reached'
DeadLetterQueueModule:
Description: 'Optional but recommended for async invocations stack name of sqs-queue module where Lambda sends events to after the maximum number of retries was reached'
Type: String

@@ -40,6 +44,2 @@ Default: ''

Type: String
KmsKeyArn: # TODO should be a module reference
Description: 'The Amazon Resource Name (ARN) of an AWS Key Management Service (AWS KMS) key that Lambda uses to encrypt and decrypt environment variable values'
Type: String
Default: ''
MemorySize:

@@ -85,3 +85,4 @@ Description: 'The amount of memory, in MB, that is allocated to your Lambda function'

HasAlertingModule: !Not [!Equals [!Ref AlertingModule, '']]
HasDeadLetterQueueArn: !Not [!Equals [!Ref DeadLetterQueueArn, '']]
HasKmsKeyModule: !Not [!Equals [!Ref KmsKeyModule, '']]
HasDeadLetterQueueModule: !Not [!Equals [!Ref DeadLetterQueueModule, '']]
HasReservedConcurrentExecutions: !Not [!Equals [!Ref ReservedConcurrentExecutions, -1]]

@@ -152,8 +153,9 @@ HasVpcModule: !Not [!Equals [!Ref VpcModule, '']]

Code: '../../../lambdas/'
DeadLetterConfig: !If [HasDeadLetterQueueArn, {TargetArn: !Ref DeadLetterQueueArn}, !Ref 'AWS::NoValue']
DeadLetterConfig: !If [HasDeadLetterQueueModule, {TargetArn: {'Fn::ImportValue': !Sub '${DeadLetterQueueModule}-Arn'}}, !Ref 'AWS::NoValue']
Description: !Ref Description
Environment: {} # TODO how to handle this?
Environment:
Variables: {} # TODO how to handle this? Seems to be impossible...
FunctionName: !Ref 'AWS::StackName'
Handler: !Ref Handler
KmsKeyArn: !Ref KmsKeyArn
KmsKeyArn: !If [HasKmsKeyModule, {'Fn::ImportValue': !Sub '${KmsKeyModule}-Arn'}, !Ref 'AWS::NoValue']
MemorySize: !Ref MemorySize

@@ -165,3 +167,3 @@ ReservedConcurrentExecutions: !If [HasReservedConcurrentExecutions, !Ref ReservedConcurrentExecutions, !Ref 'AWS::NoValue']

TracingConfig:
Mode: PassThrough
Mode: !Ref TracingConfigMode
VpcConfig: !If

@@ -186,2 +188,4 @@ - HasVpcModule

- 'Fn::ImportValue': !Sub '${AlertingModule}-Arn'
OkActions:
- 'Fn::ImportValue': !Sub '${AlertingModule}-Arn'
Dimensions:

@@ -204,2 +208,4 @@ - Name: FunctionName

- 'Fn::ImportValue': !Sub '${AlertingModule}-Arn'
OkActions:
- 'Fn::ImportValue': !Sub '${AlertingModule}-Arn'
Dimensions:

@@ -212,3 +218,3 @@ - Name: FunctionName

ModuleVersion:
Value: '0.0.3'
Value: '0.0.5'
StackName:

@@ -215,0 +221,0 @@ Value: !Ref 'AWS::StackName'

+1
-1
{
"name": "@cfn-modules/lambda-function",
"version": "0.0.3",
"version": "0.0.5",
"description": "AWS Lambda function with automated IAM policy generation, log group and alerting",

@@ -5,0 +5,0 @@ "author": "Michael Wittig <michael@widdix.de>",

+11
-11

@@ -27,7 +27,7 @@ # cfn-modules: AWS Lambda function

AlertingModule: !GetAtt 'Alerting.Outputs.StackName' # optional
KmsKeyModule: !GetAtt 'Key.Outputs.StackName' # optional
VpcModule: !GetAtt 'Vpc.Outputs.StackName' # optional
DeadLetterQueueArn: # optional
DeadLetterQueueModule: !GetAtt 'Queue.Outputs.StackName' # optional
Description: '' # optional
Handler: 'example.handler' # required (file must be in the lambdas folder)
KmsKeyArn: '' # optional
MemorySize: 128 # optional

@@ -66,2 +66,9 @@ ReservedConcurrentExecutions: -1 # optional

<tr>
<td>KmsKeyModule</td>
<td>Stack name of KMS key module</td>
<td></td>
<td>no</td>
<td></td>
</tr>
<tr>
<td>VpcModule</td>

@@ -74,4 +81,4 @@ <td>Stack name of vpc module</td>

<tr>
<td>DeadLetterQueueArn</td>
<td>ARN of a SQS queue for events after the maximum number of retries was reached</td>
<td>DeadLetterQueueModule</td>
<td>Stack name of sqs-queue module where Lambda sends events to after the maximum number of retries was reached</td>
<td></td>

@@ -96,9 +103,2 @@ <td>no</td>

<tr>
<td>KmsKeyArn</td>
<td>The Amazon Resource Name (ARN) of an AWS Key Management Service (AWS KMS) key that Lambda uses to encrypt and decrypt environment variable values</td>
<td></td>
<td>no</td>
<td></td>
</tr>
<tr>
<td>MemorySize</td>

@@ -105,0 +105,0 @@ <td>The amount of memory, in MB, that is allocated to your Lambda function</td>