UNPKG

@hclsoftware/secagent

Version:

IAST agent

23 lines (19 loc) 840 B
//IASTIGNORE /* * **************************************************** * Licensed Materials - Property of HCL. * (c) Copyright HCL Technologies Ltd. 2017, 2025. * Note to U.S. Government Users *Restricted Rights. * **************************************************** */ const HookRule = require('./HookRule') const TaintTracker = require('../../TaintTracker') const StackInfo = require('../../StackInfo') class SinkRule extends HookRule { doHook (hookValues) { const param = HookRule.getActualParam(this.data.from, hookValues) const parameters = StackInfo.getParamsStringArrayPostHook(hookValues.that, hookValues.simpleThat, hookValues.methodName, hookValues.simpleArgs, hookValues.simpleRet) TaintTracker.sinkTrigger(param, this.data.vulnerability, parameters) } } module.exports = SinkRule