![Oracle Drags Its Feet in the JavaScript Trademark Dispute](https://cdn.sanity.io/images/cgdhsj6q/production/919c3b22c24f93884c548d60cbb338e819ff2435-1024x1024.webp?w=400&fit=max&auto=format)
Security News
Oracle Drags Its Feet in the JavaScript Trademark Dispute
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
@dazn/lambda-powertools-middleware-obfuscater
Advanced tools
Middy middleware to obfuscate the event for logging
A Middy middleware that will enable debug logging for a configurable % of invocations. Defaults is 1%.
Main features:
Install from NPM: npm install @dazn/lambda-powertools-middleware-obfuscater
Alternatively, if you use the template @dazn/lambda-powertools-pattern-obfuscate
then this would be configured for you.
Accepts a configuration object of the following shape:
{
obfuscationFilter: string array formatted like ["object.key.to.obfuscate"]
}
{
Records: [
{ firstName: "personal" secondName: "identifiable" email: "inform@ti.on" },
{ firstName: "second" secondName: "personal" email: "inform@ti.on" }
]
}
// To filter the above object you would pass
const obfuscationFilter = ["Records.*.firstName", "Records.*.secondName", "Records.*.email"]
The output would be...
{
Records: [
{ firstName: "********" secondName: "************" email: "******@**.**" },
{ firstName: "******" secondName: "********" email: "******@**.**" }
]
}
similarly, you can filter entire objects, for instance.
const obfuscationFilter = ["Records.*.personal"]
{
Records: [
{ personal: { firstName: "********" secondName: "************" email: "******@**.**" } }.
{ personal: { firstName: "******" secondName: "********" email: "******@**.**", address: { postcode: "******", street: "* ****** ***", country: "**" }}}
]
}
This will recursively filter every object and subobjects
const middy = require('middy')
const obfuscatedLogging = require('@dazn/lambda-powertools-middleware-obfuscater')
const handler = async (event, context) => {
return 42
}
module.exports = middy(handler)
.use(obfuscatedLogging.obfuscaterMiddleware({ sampleRate: 0.01, obfuscationFilters: ["example.example"] }))
}
This middleware is often used alongside the @dazn/lambda-powertools-middleware-correlation-ids
middleware to implement sample logging. It's recommended that you use the @dazn/lambda-powertools-pattern-obfuscate
which configures both to enable debug logging at 1% of invocations.
FAQs
Middy middleware to obfuscate the event for logging
The npm package @dazn/lambda-powertools-middleware-obfuscater receives a total of 348 weekly downloads. As such, @dazn/lambda-powertools-middleware-obfuscater popularity was classified as not popular.
We found that @dazn/lambda-powertools-middleware-obfuscater demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 7 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.
Security News
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
Security News
The Linux Foundation is warning open source developers that compliance with global sanctions is mandatory, highlighting legal risks and restrictions on contributions.
Security News
Maven Central now validates Sigstore signatures, making it easier for developers to verify the provenance of Java packages.