A stateful inspection firewall monitors the state and context of active connections but is generally more focused on network and transport layer traffic, such as IP addresses, ports, and connection state, rather than application-specific threats like buffer overflow attacks.
A Web Application Firewall (WAF) would best address the risk of buffer overflow attacks on Priyanka’s new web application. A WAF specifically monitors and filters HTTP traffic to and from a web application, identifying and blocking potentially harmful requests that could exploit vulnerabilities such as buffer overflows. The real fix for a buffer overflow is input validation and bounds checking in the application’s code. Of the options here, though, the WAF is the only one that inspects the web traffic carrying the attack.
Database activity monitoring is aimed at tracking and analyzing database activities, which helps protect against threats to the database but does not address web application vulnerabilities directly.
A Hardware Security Module (HSM) is used for managing digital keys and providing cryptographic processing. While it enhances security for encryption and key management, it does not directly mitigate the risk of buffer overflow attacks in web applications.