Research
Security News
Quasar RAT Disguised as an npm Package for Detecting Vulnerabilities in Ethereum Smart Contracts
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
@liflig/cdk-lambda-config
Advanced tools
CDK Construct for adding config.json file to a Lambda Function
When using Lambda@Edge, a function cannot use environment variables.
This CDK Construct uses a Custom Resource to inject a config.json
file with user provided values into an existing function, and
publishes a new version that is ready to be used as part of a
CloudFront Distribution.
Inspired by similar mechanism in https://github.com/aws-samples/cloudfront-authorization-at-edge/
npm install @liflig/cdk-lambda-config
Using the construct:
const originalFunction = lambda.Function.fromFunctionArn(...)
const updatedFunction = new LambdaConfig(this, "UpdatedFunction", {
function: originalFunction,
config: {
Key1: "Some value",
Nested: {
Key2: "Other value",
},
},
nonce: "1", // See TSDoc.
})
// Can now retrieve the new version:
updatedFunction.version
Read from within the handler:
const fs = require("fs")
const path = require("path")
const config = JSON.parse(
fs.readFileSync(path.join(__dirname, "config.json"), "utf-8"),
)
FAQs
CDK Construct for adding config.json file to a Lambda Function
The npm package @liflig/cdk-lambda-config receives a total of 44 weekly downloads. As such, @liflig/cdk-lambda-config popularity was classified as not popular.
We found that @liflig/cdk-lambda-config demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Security News
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
Security News
Research
A supply chain attack on Rspack's npm packages injected cryptomining malware, potentially impacting thousands of developers.
Research
Security News
Socket researchers discovered a malware campaign on npm delivering the Skuld infostealer via typosquatted packages, exposing sensitive data.