newrelic
Version:
New Relic agent
24 lines (21 loc) • 467 B
JavaScript
module.exports = initialize
function initialize(agent, crypto, moduleName, shim) {
shim.record(
crypto,
[
'pbkdf2',
'randomBytes',
'pseudoRandomBytes',
'randomFill',
'scrypt'
],
function recordCryptoMethod(shim, fn, name) {
return {
name: 'crypto.' + name,
callback: shim.LAST,
callbackRequired: true // sync version used too heavily - too much overhead
}
}
)
}