CVE-2008-5416
Heap-based buffer overflow in Microsoft SQL Server 2000 SP4, 8.00.2050, 8.00.2039, and earlier; SQL Server 2000 Desktop Engine (MSDE 2000)…
- 9.0HighCVSS base score
- 87.0%Exploitation in 30 daysEPSS · top 0.2% of all CVEs
- NoKnown exploitednot in CISA's KEV catalog
- 5Public exploitsMetasploit, Nuclei and Exploit-DB
Description
Heap-based buffer overflow in Microsoft SQL Server 2000 SP4, 8.00.2050, 8.00.2039, and earlier; SQL Server 2000 Desktop Engine (MSDE 2000) SP4; SQL Server 2005 SP2 and 9.00.1399.06; SQL Server 2000 Desktop Engine (WMSDE) on Windows Server 2003 SP1 and SP2; and Windows Internal Database (WYukon) SP2 allows remote authenticated users to cause a denial of service (access violation exception) or execute arbitrary code by calling the sp_replwritetovarbin extended stored procedure with a set of invalid parameters that trigger memory overwrite, aka "SQL Server sp_replwritetovarbin Limited Memory Overwrite Vulnerability."
Public exploit
An exploit or proof of concept is public: anyone can try it against an unpatched system. The public collections list 2 Metasploit modules and 3 Exploit-DB entries for it. A reference of the record is tagged as an exploit.
Show the exploits6
Metasploit modules2 modules
- MS09-004 Microsoft SQL Server sp_replwritetovarbin Memory Corruption (Metasploit module) (opens in a new tab)
exploit/windows/mssql/ms09_004_sp_replwritetovarbinRank gooddisclosed 9 Dec 2008
- MS09-004 Microsoft SQL Server sp_replwritetovarbin Memory Corruption via SQL Injection (Metasploit module) (opens in a new tab)
exploit/windows/mssql/ms09_004_sp_replwritetovarbin_sqliRank excellentdisclosed 9 Dec 2008
Exploit-DB3 entries
- Microsoft SQL Server - sp_replwritetovarbin Memory Corruption (MS09-004) (via SQL Injection) (Metasploit) (Exploit-DB entry) (opens in a new tab)
EDB-ID 16396remote, windowspublished 8 Feb 2011Verified
- Microsoft SQL Server - sp_replwritetovarbin Memory Corruption (MS09-004) (Metasploit) (Exploit-DB entry) (opens in a new tab)
EDB-ID 16392remote, windowspublished 24 Jan 2011Verified
- Microsoft SQL Server - 'sp_replwritetovarbin()' Heap Overflow (Exploit-DB entry) (opens in a new tab)
EDB-ID 7501local, windowspublished 17 Dec 2008Verified
References tagged exploit1 reference
- 7501 (opens in a new tab)exploitx_refsource_EXPLOIT-DBx_transferred
Modules, templates and exploits as listed by the Metasploit Framework (BSD-3-Clause), ProjectDiscovery's Nuclei templates (MIT) and the Exploit Database (GPLv2), read once a day. Where the data comes from
Timeline
ID reserved
By mitre
Published
- 16 years later
· 16 years later
Record updated
Changes after publication (a new score, a public exploit, EPSS crossing 1, 10 or 50 %, leaving KEV) are kept since November 2026; earlier ones are not known.
Scores
| Scored by | CVSS | Score | Vector |
|---|---|---|---|
| NVDNVD · Modified | 2.0 | High9.0 | AV:N/AC:L/Au:S/C:C/I:C/A:C |
- EPSS (exploitation in 30 days)
- 87.0% · top 0.2% of all CVEs (10 Nov 2026)
The list uses the assigner's score when there is one, then CISA's, then NVD's: High 9.0.
Affected products
n/a
- affected n/a
References
22
- http://www.sec-consult.com/files/20081209_mssql-2000-sp_replwritetovarbin_memwrite.txt (opens in a new tab)x_refsource_MISCx_transferred
- ADV-2008-3380 (opens in a new tab)vdb-entryx_refsource_VUPENx_transferred
- 33034 (opens in a new tab)third-party-advisoryx_refsource_SECUNIAx_transferred
- 50917 (opens in a new tab)vdb-entryx_refsource_OSVDBx_transferred
- 1021363 (opens in a new tab)vdb-entryx_refsource_SECTRACKx_transferred
- 7501 (opens in a new tab)exploitx_refsource_EXPLOIT-DBx_transferred
- 1021490 (opens in a new tab)vdb-entryx_refsource_SECTRACKx_transferred
- mssql-spreplwritetovarbin-bo(47182) (opens in a new tab)vdb-entryx_refsource_XFx_transferred
- VU#696644 (opens in a new tab)third-party-advisoryx_refsource_CERT-VNx_transferred
- 20081209 SEC Consult SA-20081109-0 :: Microsoft SQL Server 2000 sp_replwritetovarbin limited memory overwrite vulnerability (opens in a new tab)mailing-listx_refsource_BUGTRAQx_transferred
- 20081210 Microsoft SQL Server 2005 sp_replwritetovarbin memory overwrite(update to SEC Consult SA-20081209) (opens in a new tab)mailing-listx_refsource_BUGTRAQx_transferred
- MS09-004 (opens in a new tab)vendor-advisoryx_refsource_MSx_transferred
- 4706 (opens in a new tab)third-party-advisoryx_refsource_SREASONx_transferred
- http://www.vmware.com/support/vsphere4/doc/vsp_vc41_u1_rel_notes.html (opens in a new tab)x_refsource_CONFIRMx_transferred
- http://www.microsoft.com/technet/security/advisory/961040.mspx (opens in a new tab)x_refsource_CONFIRMx_transferred
- 32710 (opens in a new tab)vdb-entryx_refsource_BIDx_transferred
- oval:org.mitre.oval:def:6217 (opens in a new tab)vdb-entrysignaturex_refsource_OVALx_transferred
- http://www.vmware.com/security/advisories/VMSA-2011-0003.html (opens in a new tab)x_refsource_CONFIRMx_transferred
- TA09-041A (opens in a new tab)third-party-advisoryx_refsource_CERTx_transferred
- 20081210 Microsoft SQL Server 2005 sp_replwritetovarbin memory overwrite (update to SEC Consult SA-20081209) (opens in a new tab)mailing-listx_refsource_FULLDISCx_transferred
- 20110211 VMSA-2011-0003 Third party component updates for VMware vCenter Server, vCenter Update Manager, ESXi and ESX (opens in a new tab)mailing-listx_refsource_BUGTRAQx_transferred
- http://support.avaya.com/elmodocs2/security/ASA-2009-055.htm (opens in a new tab)x_refsource_CONFIRMx_transferred
Sources
The same CVE in the primary databases and aggregators, to check against.
- CVE.org record (opens in a new tab)
- CVE List JSON (GitHub) (opens in a new tab)
- NVD (opens in a new tab)
- FIRST EPSS (opens in a new tab)
- EUVD EUVD-2008-5393 (opens in a new tab)
- OSV.dev (opens in a new tab)
- GitHub Advisories (opens in a new tab)
- CIRCL Vulnerability-Lookup (opens in a new tab)
Badge for a README or a ticket
[](https://cveledger.app/cve/CVE-2008-5416)Record last updated .