Severity
Low
Short Description
Uses debug, reflection and dynamic code execution features.
Packages
View packages with this alert.Suggestion
Removing the use of debug will reduce the risk of any reflection and dynamic code execution.
Debugging and dynamic code execution features, such as eval
, Function()
, or reflection APIs, can pose potential risks, including:
While these tools are useful during development or in specific runtime scenarios, their use in production code should be limited or removed entirely to improve security and maintainability.
Review the Package Code:
eval
, Function()
, or similar APIs).Contact the Maintainer:
Consider Alternatives:
Use Secure Build Practices:
Validate Inputs:
eval
) cannot be removed, ensure all inputs are sanitized and validated to mitigate risks of code injection.Document Usage:
Remove if Necessary:
Here is an example of a package flagged for Debug Access due to the use of the vm
module. While the vm
module offers some isolation, it does not fully protect against malicious code or side-channel attacks. It could potentially allow dynamic code execution increases the attack surface, especially if user-provided scripts are not properly validated or sanitized.
Packages are flagged with the Debug Access alert when they use debug, reflection, and dynamic code execution features.