CVE-2021-42258 in bqe billquick web suite
LogPulse has a published detection rule for this CVE: it raises a notable when someone tries to exploit it.
What the vulnerability is
BQE BillQuick Web Suite 2018 through 2021 before 22.0.9.1 allows SQL injection for unauthenticated remote code execution, as exploited in the wild in October 2021 for ransomware installation. SQL injection can, for example, use the txtID (aka username) parameter. Successful exploitation can include the ability to execute arbitrary code as MSSQLSERVER$ via xp_cmdshell.
Affected software: bqe billquick web suite
Scores
- CVSS: 9.8 (critical)
- EPSS: 76.44% chance of exploitation in the next 30 days
- CISA KEV: Known exploited, listed 2021-11-03, used in ransomware
- Published: 2021-10-22
What LogPulse has for it
- Detection rule: Yes, published
- Agent check (vulnerable version): Yes, published
- Mitigation: Yes, see below
How to mitigate it
Upgrade BQE BillQuick Web Suite to 22.0.9.1 or later and stop SQL Server command execution
Patch or upgrade. Upgrading BillQuick Web Suite to WebSuite 2021 version 22.0.9.1 or later removes the unauthenticated SQL injection in the login form. Disabling xp_cmdshell and moving the application off the sa login stops a SQL injection from turning into code execution on the server.
Applies to: BQE BillQuick Web Suite 2018 through 2021 before version 22.0.9.1, installed on-premises on Windows/IIS with Microsoft SQL Server.
- Find every server that runs BQE BillQuick Web Suite (2018, 2019, 2020 or 2021) and note its version in Programs and Features.
- Until patched, take the BillQuick web site off the internet: allow it only from the office network or VPN in the firewall or IIS IP restrictions.
- Download BillQuick WebSuite 2021 version 22.0.9.1 or later from BQE and install it on the web server; older suites (2018-2020) have no fix and must be upgraded.
- In SQL Server Management Studio run: EXEC sp_configure 'show advanced options',1; RECONFIGURE; EXEC sp_configure 'xp_cmdshell',0; RECONFIGURE;
- Change the BillQuick database connection to a dedicated SQL login with rights only on the BillQuick database instead of sa, and give sa a new strong password.
- Check for compromise: review the IIS logs for repeated POST requests to the BillQuick login page from foreign addresses, and process creation logs for cmd.exe or powershell.exe started by sqlservr.exe.
- Confirm the installed version shows 22.0.9.1 or later.
Sources:
Source data: NIST NVD, CISA KEV and FIRST EPSS. LogPulse processes new CVEs every hour.
We build every detection with great care, but no two environments are the same. Log sources, parsing and configuration differ, so test a detection in your own environment before you rely on it.