QuestionQ190

VerifiedWeb Application Injection Attacks

Which of the following functions can be used to mitigate a command-injection attack?

Each correct answer represents part of the solution.

Choose two
Explanation

escapeshellarg() protects an individual value used as a shell argument, and escapeshellcmd() escapes shell metacharacters in a command string. These functions help prevent attacker-controlled input from being interpreted as additional shell commands. htmlentities() and strip_tags() address HTML markup rather than shell-command interpretation.

Learn more

Community Discussion

No comments yet. Be the first to start the discussion!