Dataset Viewer
Auto-converted to Parquet Duplicate
func
string
target
int64
cwe
list
project
string
commit_id
string
hash
float64
size
int64
message
string
is_vulnerable
string
cwe_id_extracted
string
cwe_details
string
static boolean ReadICCProfile(j_decompress_ptr jpeg_info) { char magick[12]; ErrorManager *error_manager; ExceptionInfo *exception; Image *image; MagickBooleanType status; register ssize_t i; register unsigned char *p; size_t length; StringInfo *icc_profile,...
1
[ "CWE-416" ]
ImageMagick
39f226a9c137f547e12afde972eeba7551124493
162,374,092,337,400,400,000,000,000,000,000,000,000
111
https://github.com/ImageMagick/ImageMagick/issues/1641
Vulnerable
416
{"cwe_id": "CWE-416", "vulnerability_type": "Use After Free", "description": "The product reuses or references memory after it has been freed. At some point afterward, the memory may be allocated again and saved in another pointer, while the original pointer references a location somewhere within the new allocation. An...
__export struct rad_dict_attr_t *rad_dict_find_attr_id(struct rad_dict_vendor_t *vendor, int id) { struct rad_dict_attr_t *attr; struct list_head *items = vendor ? &vendor->items : &dict->items; list_for_each_entry(attr, items, entry) if (attr->id == id) return attr; return NULL; }
0
[ "CWE-787" ]
accel-ppp
d4cb89721cc8e5b3dd3fbefaf173eb77ecb85615
123,560,801,128,212,490,000,000,000,000,000,000,000
11
fix buffer overflow when receive radius packet This patch fixes buffer overflow if radius packet contains invalid atribute length and attrubute type from the following list: ipv4addr, ipv6addr, ipv6prefix or ifid Reported-by: Chloe Ong Reported-by: Eugene Lim <spaceraccoon@users.noreply.github.com> Reported-by: Kar We...
Safe
787
{"cwe_id": "CWE-787", "vulnerability_type": "Out-of-bounds Write", "description": "The product writes data past the end, or before the beginning, of the intended buffer.", "severity": "High", "category": "Memory Corruption", "impact": ["Modify Memory", "Execute Unauthorized Code or Commands", "DoS: Crash, Exit, or Rest...
void set_user_nice(struct task_struct *p, long nice) { int old_prio, delta, on_rq; unsigned long flags; struct rq *rq; if (TASK_NICE(p) == nice || nice < -20 || nice > 19) return; /* * We have to be careful, if called from sys_setpriority(), * the task might be in the middle of scheduling on another CPU. ...
0
[]
linux-2.6
8f1bc385cfbab474db6c27b5af1e439614f3025c
80,653,397,182,524,560,000,000,000,000,000,000,000
46
sched: fair: weight calculations In order to level the hierarchy, we need to calculate load based on the root view. That is, each task's load is in the same unit. A / \ B 1 / \ 2 3 To compute 1's load we do: weight(1) -------------- rq_weight(A) To ...
Safe
null
null
GetNumWrongData(const byte * curPtr, const int maxnum) { int count = 0; if (1 == maxnum) { return (1); } while (maxnum > count+1 && *(curPtr + count) != *(curPtr + count + 1)) { count++; } return (count); }
0
[ "CWE-787" ]
ghostpdl
9f39ed4a92578a020ae10459643e1fe72573d134
62,986,818,176,178,330,000,000,000,000,000,000,000
13
Bug 701792: Avoid going beyond buffer in GetNumSameData() and GetNumWrongData(). GetNumSameData() compared buffer contents before checking that we are still within bounds of buffer, which caused the bug. Have made similar fix to GetNumWrongData() because it has similar error. Fixes address sanitizer error in: ./...
Safe
787
{"cwe_id": "CWE-787", "vulnerability_type": "Out-of-bounds Write", "description": "The product writes data past the end, or before the beginning, of the intended buffer.", "severity": "High", "category": "Memory Corruption", "impact": ["Modify Memory", "Execute Unauthorized Code or Commands", "DoS: Crash, Exit, or Rest...
int btrfs_check_dir_item_collision(struct btrfs_root *root, u64 dir, const char *name, int name_len) { int ret; struct btrfs_key key; struct btrfs_dir_item *di; int data_size; struct extent_buffer *leaf; int slot; struct btrfs_path *path; path = btrfs_alloc_path(); if (!path) return -ENOMEM; key.o...
0
[ "CWE-310" ]
linux-2.6
9c52057c698fb96f8f07e7a4bcf4801a092bda89
248,982,828,227,266,640,000,000,000,000,000,000,000
58
Btrfs: fix hash overflow handling The handling for directory crc hash overflows was fairly obscure, split_leaf returns EOVERFLOW when we try to extend the item and that is supposed to bubble up to userland. For a while it did so, but along the way we added better handling of errors and forced the FS readonly if we hi...
Safe
310
null
static int rsi_mac80211_resume(struct ieee80211_hw *hw) { u16 rx_filter_word = 0; struct rsi_hw *adapter = hw->priv; struct rsi_common *common = adapter->priv; common->wow_flags = 0; rsi_dbg(INFO_ZONE, "%s: mac80211 resume\n", __func__); if (common->hibernate_resume) return 0; mutex_lock(&common->mutex); ...
0
[ "CWE-416" ]
linux
abd39c6ded9db53aa44c2540092bdd5fb6590fa8
60,472,285,856,768,470,000,000,000,000,000,000,000
23
rsi: add fix for crash during assertions Observed crash in some scenarios when assertion has occurred, this is because hw structure is freed and is tried to get accessed in some functions where null check is already present. So, avoided the crash by making the hw to NULL after freeing. Signed-off-by: Sanjay Konduri <...
Safe
416
{"cwe_id": "CWE-416", "vulnerability_type": "Use After Free", "description": "The product reuses or references memory after it has been freed. At some point afterward, the memory may be allocated again and saved in another pointer, while the original pointer references a location somewhere within the new allocation. An...
MagickExport MagickBooleanType SetImageProperty(Image *image, const char *property,const char *value,ExceptionInfo *exception) { MagickBooleanType status; MagickStatusType flags; assert(image != (Image *) NULL); assert(image->signature == MagickCoreSignature); if (image->debug != MagickFalse) ...
0
[ "CWE-476" ]
ImageMagick
b61d35eaccc0a7ddeff8a1c3abfcd0a43ccf210b
229,196,161,740,944,960,000,000,000,000,000,000,000
459
https://github.com/ImageMagick/ImageMagick/issues/298
Safe
476
{"cwe_id": "CWE-476", "vulnerability_type": "NULL Pointer Dereference", "description": "The product dereferences a pointer that it expects to be valid but is NULL.", "severity": "Medium", "category": "NPD", "impact": ["DoS: Crash, Exit, or Restart", "Execute Unauthorized Code or Commands", "Read Memory", "Modify Memory...
proto_tree_add_item_ret_boolean(proto_tree *tree, int hfindex, tvbuff_t *tvb, const gint start, gint length, const guint encoding, gboolean *retval) { header_field_info *hfinfo = proto_registrar_get_nth(hfindex); field_info *new_fi; guint64 value,...
0
[ "CWE-401" ]
wireshark
a9fc769d7bb4b491efb61c699d57c9f35269d871
257,882,672,430,912,520,000,000,000,000,000,000,000
48
epan: Fix a memory leak. Make sure _proto_tree_add_bits_ret_val allocates a bits array using the packet scope, otherwise we leak memory. Fixes #17032.
Safe
401
{"cwe_id": "CWE-401", "vulnerability_type": "Missing Release of Memory after Effective Lifetime", "description": "The product does not sufficiently track and release allocated memory after it has been used, making the memory unavailable for reallocation and reuse.", "severity": "Medium", "category": "Memory Leak", "imp...
auth_update_component(struct sc_card *card, struct auth_update_component_info *args) { struct sc_apdu apdu; unsigned char sbuf[SC_MAX_APDU_BUFFER_SIZE + 0x10]; unsigned char ins, p1, p2; int rv, len; LOG_FUNC_CALLED(card->ctx); if (args->len > sizeof(sbuf) || args->len > 0x100) LOG_FUNC_RETURN(card->ctx, SC_ER...
0
[ "CWE-125" ]
OpenSC
8fe377e93b4b56060e5bbfb6f3142ceaeca744fa
262,522,697,236,003,360,000,000,000,000,000,000,000
89
fixed out of bounds reads Thanks to Eric Sesterhenn from X41 D-SEC GmbH for reporting and suggesting security fixes.
Safe
125
{"cwe_id": "CWE-125", "vulnerability_type": "Out-of-bounds Read", "description": "The product reads data past the end, or before the beginning, of the intended buffer.", "severity": null, "category": "OOB read", "impact": ["Read Memory", "Bypass Protection Mechanism", "DoS: Crash, Exit, or Restart", "Varies by Context"...
static s32 brcmf_set_auth_type(struct net_device *ndev, struct cfg80211_connect_params *sme) { struct brcmf_cfg80211_profile *profile = ndev_to_prof(ndev); struct brcmf_cfg80211_security *sec; s32 val = 0; s32 err = 0; switch (sme->auth_type) { case NL80211_AUTHTYPE_OPEN_SYSTEM: val = 0; brcmf_dbg(...
0
[ "CWE-119", "CWE-787" ]
linux
8f44c9a41386729fea410e688959ddaa9d51be7c
275,196,499,693,108,930,000,000,000,000,000,000,000
32
brcmfmac: fix possible buffer overflow in brcmf_cfg80211_mgmt_tx() The lower level nl80211 code in cfg80211 ensures that "len" is between 25 and NL80211_ATTR_FRAME (2304). We subtract DOT11_MGMT_HDR_LEN (24) from "len" so thats's max of 2280. However, the action_frame->data[] buffer is only BRCMF_FIL_ACTION_FRAME_SI...
Safe
119
{"cwe_id": "CWE-119", "vulnerability_type": "Improper Restriction of Operations within the Bounds of a Memory Buffer", "description": "The product performs operations on a memory buffer, but it reads from or writes to a memory location outside the buffer's intended boundary. This may result in read or write operations ...
CImg<T>& blur_box(const float boxsize_x, const float boxsize_y, const float boxsize_z, const unsigned int boundary_conditions=1, const unsigned int nb_iter=1) { if (is_empty()) return *this; if (_width>1) boxfilter(boxsize_x,0,'x',boundary_conditions,nb_iter);...
0
[ "CWE-770" ]
cimg
619cb58dd90b4e03ac68286c70ed98acbefd1c90
340,143,946,313,479,640,000,000,000,000,000,000,000
9
CImg<>::load_bmp() and CImg<>::load_pandore(): Check that dimensions encoded in file does not exceed file size.
Safe
770
{"cwe_id": "CWE-770", "vulnerability_type": "Allocation of Resources Without Limits or Throttling", "description": "The product allocates a reusable resource or group of resources on behalf of an actor without imposing any intended restrictions on the size or number of resources that can be allocated.", "severity": "Hi...
static int network_flush(cdtime_t timeout, __attribute__((unused)) const char *identifier, __attribute__((unused)) user_data_t *user_data) { pthread_mutex_lock(&send_buffer_lock); if (send_buffer_fill > 0) { if (timeout > 0) { cdtime_t now = cdtime(); ...
0
[ "CWE-835" ]
collectd
f6be4f9b49b949b379326c3d7002476e6ce4f211
256,471,210,509,380,000,000,000,000,000,000,000,000
19
network plugin: Fix endless loop DOS in parse_packet() When correct 'Signature part' is received by Collectd, configured without AuthFile option, condition for endless loop occurs due to missing increase of pointer to next unprocessed part. This is a forward-port of #2233. Fixes: CVE-2017-7401 Closes: #2174 Signed-o...
Safe
835
{"cwe_id": "CWE-835", "vulnerability_type": "Loop with Unreachable Exit Condition ('Infinite Loop')", "description": "The product contains an iteration or loop with an exit condition that cannot be reached, i.e., an infinite loop.", "severity": null, "category": null, "impact": ["DoS: Resource Consumption (CPU)", "DoS:...
static void test_bug9643() { MYSQL_STMT *stmt; MYSQL_BIND my_bind[1]; int32 a; int rc; const char *stmt_text; int num_rows= 0; ulong type; ulong prefetch_rows= 5; myheader("test_bug9643"); mysql_query(mysql, "drop table if exists t1"); mysql_query(mysql, "create table t1 (id integer not null pri...
0
[ "CWE-416" ]
server
eef21014898d61e77890359d6546d4985d829ef6
257,412,792,354,208,870,000,000,000,000,000,000,000
56
MDEV-11933 Wrong usage of linked list in mysql_prune_stmt_list mysql_prune_stmt_list() was walking the list following element->next pointers, but inside the loop it was invoking list_add(element) that modified element->next. So, mysql_prune_stmt_list() failed to visit and reset all elements, and some of them were left...
Safe
416
{"cwe_id": "CWE-416", "vulnerability_type": "Use After Free", "description": "The product reuses or references memory after it has been freed. At some point afterward, the memory may be allocated again and saved in another pointer, while the original pointer references a location somewhere within the new allocation. An...
zzip_mem_disk_load(ZZIP_MEM_DISK* dir, ZZIP_DISK* disk) { if (dir->list) zzip_mem_disk_unload(dir); ___ struct zzip_disk_entry* entry = zzip_disk_findfirst(disk); for (; entry ; entry = zzip_disk_findnext(disk, entry)) { ZZIP_MEM_DISK_ENTRY* item = zzip_mem_disk_entry_new(disk, entry); if (dir->last) { di...
1
[ "CWE-119" ]
zziplib
596d9dfce2624e849417d4301e8d67935608aa5e
219,475,429,227,882,320,000,000,000,000,000,000,000
12
memdisk (.)
Vulnerable
119
{"cwe_id": "CWE-119", "vulnerability_type": "Improper Restriction of Operations within the Bounds of a Memory Buffer", "description": "The product performs operations on a memory buffer, but it reads from or writes to a memory location outside the buffer's intended boundary. This may result in read or write operations ...
int rsa_pkcs1_decrypt( rsa_context *ctx, int mode, size_t *olen, const unsigned char *input, unsigned char *output, size_t output_max_len) { switch( ctx->padding ) { case RSA_PKCS_V15: return rsa_rsae...
1
[ "CWE-310" ]
polarssl
43f9799ce61c6392a014d0a2ea136b4b3a9ee194
103,061,960,944,602,730,000,000,000,000,000,000,000
22
RSA blinding on CRT operations to counter timing attacks
Vulnerable
310
null
void subtime(struct timeval *a, struct timeval *b) { timersub(a, b, b); }
0
[ "CWE-20", "CWE-703" ]
sgminer
910c36089940e81fb85c65b8e63dcd2fac71470c
228,197,706,535,211,000,000,000,000,000,000,000,000
4
stratum: parse_notify(): Don't die on malformed bbversion/prev_hash/nbit/ntime. Might have introduced a memory leak, don't have time to check. :( Should the other hex2bin()'s be checked? Thanks to Mick Ayzenberg <mick.dejavusecurity.com> for finding this.
Safe
20
{"cwe_id": "CWE-20", "vulnerability_type": "Improper Input Validation", "description": "The product receives input or data, but it does\n not validate or incorrectly validates that the input has the\n properties that are required to process the data safely and\n correctly.", "severity": "High", "ca...
bool Item::cleanup_processor(void *arg) { if (fixed) cleanup(); return FALSE; }
0
[ "CWE-416" ]
server
c02ebf3510850ba78a106be9974c94c3b97d8585
250,276,211,036,235,450,000,000,000,000,000,000,000
6
MDEV-24176 Preparations 1. moved fix_vcol_exprs() call to open_table() mysql_alter_table() doesn't do lock_tables() so it cannot win from fix_vcol_exprs() from there. Tests affected: main.default_session 2. Vanilla cleanups and comments.
Safe
416
{"cwe_id": "CWE-416", "vulnerability_type": "Use After Free", "description": "The product reuses or references memory after it has been freed. At some point afterward, the memory may be allocated again and saved in another pointer, while the original pointer references a location somewhere within the new allocation. An...
static struct sb_uart_state *uart_get(struct uart_driver *drv, int line) { struct sb_uart_state *state; MP_MUTEX_LOCK(mp_mutex); state = drv->state + line; if (mutex_lock_interruptible(&state->mutex)) { state = ERR_PTR(-ERESTARTSYS); goto out; } state->count++; if (!state->port) { state->count--; MP_STA...
0
[ "CWE-200" ]
linux
a8b33654b1e3b0c74d4a1fed041c9aae50b3c427
313,685,609,041,585,120,000,000,000,000,000,000,000
40
Staging: sb105x: info leak in mp_get_count() The icount.reserved[] array isn't initialized so it leaks stack information to userspace. Reported-by: Nico Golde <nico@ngolde.de> Reported-by: Fabian Yamaguchi <fabs@goesec.de> Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Cc: stable@kernel.org Signed-off-by: Li...
Safe
200
{"cwe_id": "CWE-200", "vulnerability_type": "Exposure of Sensitive Information to an Unauthorized Actor", "description": "The product exposes sensitive information to an actor that is not explicitly authorized to have access to that information.", "severity": "High", "category": "Information Disclosure", "impact": ["Re...
grapheme_extract_charcount_iter(UBreakIterator *bi, int32_t csize, unsigned char *pstr, int32_t str_len) { int pos = 0, prev_pos = 0; int ret_pos = 0, prev_ret_pos = 0; while ( 1 ) { pos = ubrk_next(bi); if ( UBRK_DONE == pos ) { break; } /* if we are beyond our limit, then the loop is done */ if ( p...
0
[]
php-src
16d0b9c836b793f9338c5a6296fba1b272bbae06
29,138,782,675,523,820,000,000,000,000,000,000,000
33
Fix bug #72061 - Out-of-bounds reads in zif_grapheme_stripos with negative offset
Safe
null
null
static void regulator_bulk_enable_async(void *data, async_cookie_t cookie) { struct regulator_bulk_data *bulk = data; bulk->ret = regulator_enable(bulk->consumer); }
0
[ "CWE-416" ]
linux
60a2362f769cf549dc466134efe71c8bf9fbaaba
53,491,484,475,638,870,000,000,000,000,000,000,000
6
regulator: core: Fix regualtor_ena_gpio_free not to access pin after freeing After freeing pin from regulator_ena_gpio_free, loop can access the pin. So this patch fixes not to access pin after freeing. Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com> Signed-off-by: Mark Brown <broonie@kernel.org>
Safe
416
{"cwe_id": "CWE-416", "vulnerability_type": "Use After Free", "description": "The product reuses or references memory after it has been freed. At some point afterward, the memory may be allocated again and saved in another pointer, while the original pointer references a location somewhere within the new allocation. An...
static void free_pgpaths(struct list_head *pgpaths, struct dm_target *ti) { struct pgpath *pgpath, *tmp; struct multipath *m = ti->private; list_for_each_entry_safe(pgpath, tmp, pgpaths, list) { list_del(&pgpath->list); if (m->hw_handler_name) scsi_dh_detach(bdev_get_queue(pgpath->path.dev->bdev)); dm_put_...
0
[ "CWE-284", "CWE-264" ]
linux
ec8013beddd717d1740cfefb1a9b900deef85462
249,918,762,209,933,000,000,000,000,000,000,000,000
13
dm: do not forward ioctls from logical volumes to the underlying device A logical volume can map to just part of underlying physical volume. In this case, it must be treated like a partition. Based on a patch from Alasdair G Kergon. Cc: Alasdair G Kergon <agk@redhat.com> Cc: dm-devel@redhat.com Signed-off-by: Paolo ...
Safe
284
{"cwe_id": "CWE-284", "vulnerability_type": "Improper Access Control", "description": "The product does not restrict or incorrectly restricts access to a resource from an unauthorized actor.", "severity": null, "category": "Authorization", "impact": ["Varies by Context"], "languages": [null], "example": "Example not ex...
bgp_attr_origin (struct bgp_attr_parser_args *args) { struct peer *const peer = args->peer; struct attr *const attr = args->attr; const bgp_size_t length = args->length; /* If any recognized attribute has Attribute Length that conflicts with the expected length (based on the attribute type code), then ...
0
[]
quagga
8794e8d229dc9fe29ea31424883433d4880ef408
155,420,048,715,899,980,000,000,000,000,000,000,000
42
bgpd: Fix regression in args consolidation, total should be inited from args * bgp_attr.c: (bgp_attr_unknown) total should be initialised from the args.
Safe
null
null
bool ParticipantImpl::removeSubscriber( Subscriber* sub) { for (auto sit = m_subscribers.begin(); sit != m_subscribers.end(); ++sit) { if (sit->second->getGuid() == sub->getGuid()) { delete(sit->second); m_subscribers.erase(sit); return true; }...
0
[ "CWE-284" ]
Fast-DDS
d2aeab37eb4fad4376b68ea4dfbbf285a2926384
172,398,974,772,747,200,000,000,000,000,000,000,000
14
check remote permissions (#1387) * Refs 5346. Blackbox test Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 5346. one-way string compare Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 5346. Do not add partition separator on last partition Signed-off-by: Iker Luengo <ikerluengo@e...
Safe
284
{"cwe_id": "CWE-284", "vulnerability_type": "Improper Access Control", "description": "The product does not restrict or incorrectly restricts access to a resource from an unauthorized actor.", "severity": null, "category": "Authorization", "impact": ["Varies by Context"], "languages": [null], "example": "Example not ex...
void virDomainInputDefFree(virDomainInputDefPtr def) { if (!def) return; virDomainDeviceInfoClear(&def->info); VIR_FREE(def->source.evdev); VIR_FREE(def->virtio); VIR_FREE(def); }
0
[ "CWE-212" ]
libvirt
a5b064bf4b17a9884d7d361733737fb614ad8979
237,339,978,112,959,250,000,000,000,000,000,000,000
10
conf: Don't format http cookies unless VIR_DOMAIN_DEF_FORMAT_SECURE is used Starting with 3b076391befc3fe72deb0c244ac6c2b4c100b410 (v6.1.0-122-g3b076391be) we support http cookies. Since they may contain somewhat sensitive information we should not format them into the XML unless VIR_DOMAIN_DEF_FORMAT_SECURE is assert...
Safe
212
{"cwe_id": "CWE-212", "vulnerability_type": "Improper Removal of Sensitive Information Before Storage or Transfer", "description": "The product stores, transfers, or shares a resource that contains sensitive information, but it does not properly remove that information before the product makes the resource available to...
static ssize_t tlbflush_read_file(struct file *file, char __user *user_buf, size_t count, loff_t *ppos) { char buf[32]; unsigned int len; len = sprintf(buf, "%ld\n", tlb_single_page_flush_ceiling); return simple_read_from_buffer(user_buf, count, ppos, buf, len); }
0
[ "CWE-362" ]
linux
71b3c126e61177eb693423f2e18a1914205b165e
23,801,901,871,415,734,000,000,000,000,000,000,000
9
x86/mm: Add barriers and document switch_mm()-vs-flush synchronization When switch_mm() activates a new PGD, it also sets a bit that tells other CPUs that the PGD is in use so that TLB flush IPIs will be sent. In order for that to work correctly, the bit needs to be visible prior to loading the PGD and therefore star...
Safe
362
{"cwe_id": "CWE-362", "vulnerability_type": "Concurrent Execution using Shared Resource with Improper Synchronization ('Race Condition')", "description": "The product contains a concurrent code sequence that requires temporary, exclusive access to a shared resource, but a timing window exists in which the shared resour...
bool CSteamNetworkConnectionUDP::BBeginAccept( CSteamNetworkListenSocketDirectUDP *pParent, const netadr_t &adrFrom, CSharedSocket *pSharedSock, const SteamNetworkingIdentity &identityRemote, uint32 unConnectionIDRemote, const CMsgSteamDatagramCertificateSigned &msgCert, const CMsgSteamDatagramSessionCryptInfoSi...
0
[ "CWE-703" ]
GameNetworkingSockets
d944a10808891d202bb1d5e1998de6e0423af678
224,142,327,983,614,340,000,000,000,000,000,000,000
51
Tweak pointer math to avoid possible integer overflow
Safe
703
{"cwe_id": "CWE-703", "vulnerability_type": "Improper Check or Handling of Exceptional Conditions", "description": "The product does not properly anticipate or handle exceptional conditions that rarely occur during normal operation of the product.", "severity": null, "category": null, "impact": ["Read Application Data"...
static void fwnet_remove(struct fw_unit *unit) { struct fwnet_peer *peer = dev_get_drvdata(&unit->device); struct fwnet_device *dev = peer->dev; struct net_device *net; int i; mutex_lock(&fwnet_device_mutex); net = dev->netdev; fwnet_remove_peer(peer, dev); if (list_empty(&dev->peer_list)) { unregister_ne...
0
[ "CWE-119", "CWE-284", "CWE-787" ]
linux
667121ace9dbafb368618dbabcf07901c962ddac
183,275,235,350,997,300,000,000,000,000,000,000,000
28
firewire: net: guard against rx buffer overflows The IP-over-1394 driver firewire-net lacked input validation when handling incoming fragmented datagrams. A maliciously formed fragment with a respectively large datagram_offset would cause a memcpy past the datagram buffer. So, drop any packets carrying a fragment wi...
Safe
119
{"cwe_id": "CWE-119", "vulnerability_type": "Improper Restriction of Operations within the Bounds of a Memory Buffer", "description": "The product performs operations on a memory buffer, but it reads from or writes to a memory location outside the buffer's intended boundary. This may result in read or write operations ...
static inline void smb2_sg_set_buf(struct scatterlist *sg, const void *buf, unsigned int buflen) { void *addr; /* * VMAP_STACK (at least) puts stack into the vmalloc address space */ if (is_vmalloc_addr(buf)) addr = vmalloc_to_page(buf); else addr = virt_to_page(buf); sg_set_page(sg, addr, buflen, o...
0
[ "CWE-476" ]
linux
d6f5e358452479fa8a773b5c6ccc9e4ec5a20880
3,494,783,149,816,233,000,000,000,000,000,000,000
13
cifs: fix NULL ptr dereference in smb2_ioctl_query_info() When calling smb2_ioctl_query_info() with invalid smb_query_info::flags, a NULL ptr dereference is triggered when trying to kfree() uninitialised rqst[n].rq_iov array. This also fixes leaked paths that are created in SMB2_open_init() which required SMB2_open_f...
Safe
476
{"cwe_id": "CWE-476", "vulnerability_type": "NULL Pointer Dereference", "description": "The product dereferences a pointer that it expects to be valid but is NULL.", "severity": "Medium", "category": "NPD", "impact": ["DoS: Crash, Exit, or Restart", "Execute Unauthorized Code or Commands", "Read Memory", "Modify Memory...
TEST_F(ExpressionNaryTest, GroupingOptimizationOnAssociativeOnlyNotExecuteOnSingleConstantsBack) { BSONArray spec = BSON_ARRAY("$path" << 55); addOperandArrayToExpr(_associativeOnly, spec); assertContents(_associativeOnly, spec); intrusive_ptr<Expression> optimized = _associativeOnly->optimize(); AS...
0
[ "CWE-835" ]
mongo
0a076417d1d7fba3632b73349a1fd29a83e68816
336,184,152,400,771,970,000,000,000,000,000,000,000
8
SERVER-38070 fix infinite loop in agg expression
Safe
835
{"cwe_id": "CWE-835", "vulnerability_type": "Loop with Unreachable Exit Condition ('Infinite Loop')", "description": "The product contains an iteration or loop with an exit condition that cannot be reached, i.e., an infinite loop.", "severity": null, "category": null, "impact": ["DoS: Resource Consumption (CPU)", "DoS:...
int security_vm_enough_memory_mm(struct mm_struct *mm, long pages) { WARN_ON(mm == NULL); return security_ops->vm_enough_memory(mm, pages); }
0
[]
linux-2.6
ee18d64c1f632043a02e6f5ba5e045bb26a5465f
263,465,344,747,992,300,000,000,000,000,000,000,000
5
KEYS: Add a keyctl to install a process's session keyring on its parent [try #6] Add a keyctl to install a process's session keyring onto its parent. This replaces the parent's session keyring. Because the COW credential code does not permit one process to change another process's credentials directly, the change is...
Safe
null
null
congestion_control_init(congestion_control_t *cc, const circuit_params_t *params, cc_path_t path) { cc->sendme_pending_timestamps = smartlist_new(); cc->sendme_arrival_timestamps = smartlist_new(); cc->in_slow_start = 1; congestion_control_init_params(cc, params,...
0
[]
tor
b0496d40197dd5b4fb7b694c1410082d4e34dda6
113,303,769,819,035,550,000,000,000,000,000,000,000
12
Fix for RTT calculation hang during congestion control. Only cache RTT on explicit stalls; Only use this cache for the RTT decrease case. Otherwise use only local circuit RTT state for clock jump checks.
Safe
null
null
kssl_tgt_is_available(KSSL_CTX *kssl_ctx) { krb5_error_code krb5rc = KRB5KRB_ERR_GENERIC; krb5_context krb5context = NULL; krb5_ccache krb5ccdef = NULL; krb5_creds krb5creds, *krb5credsp = NULL; int rc = 0; memset((char *)&krb5creds, 0, s...
0
[ "CWE-20" ]
openssl
cca1cd9a3447dd067503e4a85ebd1679ee78a48e
26,146,682,338,263,900,000,000,000,000,000,000,000
48
Submitted by: Tomas Hoger <thoger@redhat.com> Fix for CVE-2010-0433 where some kerberos enabled versions of OpenSSL could be crashed if the relevant tables were not present (e.g. chrooted).
Safe
20
{"cwe_id": "CWE-20", "vulnerability_type": "Improper Input Validation", "description": "The product receives input or data, but it does\n not validate or incorrectly validates that the input has the\n properties that are required to process the data safely and\n correctly.", "severity": "High", "ca...
struct dentry *ovl_entry_real(struct ovl_entry *oe, bool *is_upper) { struct dentry *realdentry; realdentry = ovl_upperdentry_dereference(oe); if (realdentry) { *is_upper = true; } else { realdentry = oe->lowerdentry; *is_upper = false; } return realdentry; }
0
[ "CWE-284", "CWE-264" ]
linux
69c433ed2ecd2d3264efd7afec4439524b319121
61,750,705,353,684,010,000,000,000,000,000,000,000
13
fs: limit filesystem stacking depth Add a simple read-only counter to super_block that indicates how deep this is in the stack of filesystems. Previously ecryptfs was the only stackable filesystem and it explicitly disallowed multiple layers of itself. Overlayfs, however, can be stacked recursively and also may be s...
Safe
284
{"cwe_id": "CWE-284", "vulnerability_type": "Improper Access Control", "description": "The product does not restrict or incorrectly restricts access to a resource from an unauthorized actor.", "severity": null, "category": "Authorization", "impact": ["Varies by Context"], "languages": [null], "example": "Example not ex...
static String* Pe_r_bin_pe_parse_string(struct PE_(r_bin_pe_obj_t)* bin, PE_DWord* curAddr) { String* string = calloc (1, sizeof(*string)); PE_DWord begAddr = *curAddr; int len_value = 0; int i = 0; if (!string) { bprintf ("Warning: calloc (String)\n"); return NULL; } if (begAddr > bin->size || begAddr + siz...
0
[ "CWE-125" ]
radare2
4e1cf0d3e6f6fe2552a269def0af1cd2403e266c
234,554,764,011,263,940,000,000,000,000,000,000,000
81
Fix crash in pe
Safe
125
{"cwe_id": "CWE-125", "vulnerability_type": "Out-of-bounds Read", "description": "The product reads data past the end, or before the beginning, of the intended buffer.", "severity": null, "category": "OOB read", "impact": ["Read Memory", "Bypass Protection Mechanism", "DoS: Crash, Exit, or Restart", "Varies by Context"...
glob_func_error(VALUE val) { struct glob_error_args *arg = (struct glob_error_args *)val; VALUE path = rb_enc_str_new_cstr(arg->path, arg->enc); rb_syserr_fail_str(arg->error, path); return Qnil; }
0
[ "CWE-22" ]
ruby
bd5661a3cbb38a8c3a3ea10cd76c88bbef7871b8
164,057,602,225,359,800,000,000,000,000,000,000,000
7
dir.c: check NUL bytes * dir.c (GlobPathValue): should be used in rb_push_glob only. other methods should use FilePathValue. https://hackerone.com/reports/302338 * dir.c (rb_push_glob): expand GlobPathValue git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62989 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Safe
22
{"cwe_id": "CWE-22", "vulnerability_type": "Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal')", "description": "The product uses external input to construct a pathname that is intended to identify a file or directory that is located underneath a restricted parent directory, but the product ...
int ipmi_set_my_LUN(struct ipmi_user *user, unsigned int channel, unsigned char LUN) { int index, rv = 0; user = acquire_ipmi_user(user, &index); if (!user) return -ENODEV; if (channel >= IPMI_MAX_CHANNELS) { rv = -EINVAL; } else { channel = array_index_nospec(channel, IPMI_MAX_CHANNELS); us...
0
[ "CWE-416", "CWE-284" ]
linux
77f8269606bf95fcb232ee86f6da80886f1dfae8
166,266,362,563,834,550,000,000,000,000,000,000,000
20
ipmi: fix use-after-free of user->release_barrier.rda When we do the following test, we got oops in ipmi_msghandler driver while((1)) do service ipmievd restart & service ipmievd restart done --------------------------------------------------------------- [ 294.230186] Unable to handle kernel paging request at virt...
Safe
416
{"cwe_id": "CWE-416", "vulnerability_type": "Use After Free", "description": "The product reuses or references memory after it has been freed. At some point afterward, the memory may be allocated again and saved in another pointer, while the original pointer references a location somewhere within the new allocation. An...
irc_server_set_host (struct t_irc_server *server, const char *host) { struct t_irc_channel *ptr_channel; /* if host is the same, just return */ if ((!server->host && !host) || (server->host && host && strcmp (server->host, host) == 0)) { return; } /* update the nick host in ser...
0
[ "CWE-120", "CWE-787" ]
weechat
40ccacb4330a64802b1f1e28ed9a6b6d3ca9197f
282,281,645,955,468,200,000,000,000,000,000,000,000
28
irc: fix crash when a new message 005 is received with longer nick prefixes Thanks to Stuart Nevans Locke for reporting the issue.
Safe
120
{"cwe_id": "CWE-120", "vulnerability_type": "Buffer Copy without Checking Size of Input ('Classic Buffer Overflow')", "description": "The product copies an input buffer to an output buffer without verifying that the size of the input buffer is less than the size of the output buffer.", "severity": "High", "category": "...
static int crypto_pcomp_init(struct crypto_tfm *tfm, u32 type, u32 mask) { return 0; }
0
[ "CWE-310" ]
linux
9a5467bf7b6e9e02ec9c3da4e23747c05faeaac6
147,664,987,213,752,340,000,000,000,000,000,000,000
4
crypto: user - fix info leaks in report API Three errors resulting in kernel memory disclosure: 1/ The structures used for the netlink based crypto algorithm report API are located on the stack. As snprintf() does not fill the remainder of the buffer with null bytes, those stack bytes will be disclosed to users of th...
Safe
310
null
**/ CImgList():
0
[ "CWE-125" ]
CImg
10af1e8c1ad2a58a0a3342a856bae63e8f257abb
148,572,735,456,648,060,000,000,000,000,000,000,000
2
Fix other issues in 'CImg<T>::load_bmp()'.
Safe
125
{"cwe_id": "CWE-125", "vulnerability_type": "Out-of-bounds Read", "description": "The product reads data past the end, or before the beginning, of the intended buffer.", "severity": null, "category": "OOB read", "impact": ["Read Memory", "Bypass Protection Mechanism", "DoS: Crash, Exit, or Restart", "Varies by Context"...
unsigned int iucv_sock_poll(struct file *file, struct socket *sock, poll_table *wait) { struct sock *sk = sock->sk; unsigned int mask = 0; sock_poll_wait(file, sk_sleep(sk), wait); if (sk->sk_state == IUCV_LISTEN) return iucv_accept_poll(sk); if (sk->sk_err || !skb_queue_empty(&sk->sk_error_queue)) m...
0
[ "CWE-20", "CWE-269" ]
linux
f3d3342602f8bcbf37d7c46641cb9bca7618eb1c
266,043,790,386,285,540,000,000,000,000,000,000,000
38
net: rework recvmsg handler msg_name and msg_namelen logic This patch now always passes msg->msg_namelen as 0. recvmsg handlers must set msg_namelen to the proper size <= sizeof(struct sockaddr_storage) to return msg_name to the user. This prevents numerous uninitialized memory leaks we had in the recvmsg handlers an...
Safe
20
{"cwe_id": "CWE-20", "vulnerability_type": "Improper Input Validation", "description": "The product receives input or data, but it does\n not validate or incorrectly validates that the input has the\n properties that are required to process the data safely and\n correctly.", "severity": "High", "ca...
xfrm_state_lookup(struct net *net, u32 mark, const xfrm_address_t *daddr, __be32 spi, u8 proto, unsigned short family) { struct xfrm_state *x; rcu_read_lock(); x = __xfrm_state_lookup(net, mark, daddr, spi, proto, family); rcu_read_unlock(); return x; }
0
[ "CWE-416" ]
linux
dbb2483b2a46fbaf833cfb5deb5ed9cace9c7399
106,215,368,509,155,800,000,000,000,000,000,000,000
10
xfrm: clean up xfrm protocol checks In commit 6a53b7593233 ("xfrm: check id proto in validate_tmpl()") I introduced a check for xfrm protocol, but according to Herbert IPSEC_PROTO_ANY should only be used as a wildcard for lookup, so it should be removed from validate_tmpl(). And, IPSEC_PROTO_ANY is expected to only m...
Safe
416
{"cwe_id": "CWE-416", "vulnerability_type": "Use After Free", "description": "The product reuses or references memory after it has been freed. At some point afterward, the memory may be allocated again and saved in another pointer, while the original pointer references a location somewhere within the new allocation. An...
int security_syslog(int type) { return security_ops->syslog(type); }
0
[]
linux-2.6
ee18d64c1f632043a02e6f5ba5e045bb26a5465f
207,415,667,638,984,660,000,000,000,000,000,000,000
4
KEYS: Add a keyctl to install a process's session keyring on its parent [try #6] Add a keyctl to install a process's session keyring onto its parent. This replaces the parent's session keyring. Because the COW credential code does not permit one process to change another process's credentials directly, the change is...
Safe
null
null
bool ha_partition::initialize_partition(MEM_ROOT *mem_root) { handler **file_array, *file; ulonglong check_table_flags; DBUG_ENTER("ha_partition::initialize_partition"); if (m_create_handler) { m_tot_parts= m_part_info->get_tot_partitions(); DBUG_ASSERT(m_tot_parts > 0); if (new_handlers_from_par...
0
[]
server
f305a7ce4bccbd56520d874e1d81a4f29bc17a96
169,860,518,244,737,900,000,000,000,000,000,000,000
53
bugfix: long partition names
Safe
null
null
init_write_reg( int name, yankreg_T **old_y_previous, yankreg_T **old_y_current, int must_append, int *yank_type UNUSED) { if (!valid_yank_reg(name, TRUE)) // check for valid reg name { emsg_invreg(name); return FAIL; } // Don't want to change the current (unnamed) register...
0
[ "CWE-122", "CWE-787" ]
vim
d25f003342aca9889067f2e839963dfeccf1fe05
299,550,476,032,393,100,000,000,000,000,000,000,000
22
patch 9.0.0011: reading beyond the end of the line with put command Problem: Reading beyond the end of the line with put command. Solution: Adjust the end mark position.
Safe
122
{"cwe_id": "CWE-122", "vulnerability_type": "Heap-based Buffer Overflow", "description": "A heap overflow condition is a buffer overflow, where the buffer that can be overwritten is allocated in the heap portion of memory, generally meaning that the buffer was allocated using a routine such as malloc().", "severity": "...
static json_t *json_object_deep_copy(const json_t *object) { json_t *result; void *iter; result = json_object(); if(!result) return NULL; /* Cannot use json_object_foreach because object has to be cast non-const */ iter = json_object_iter((json_t *)object); while(iter) { ...
0
[ "CWE-310" ]
jansson
8f80c2d83808150724d31793e6ade92749b1faa4
198,512,818,646,698,080,000,000,000,000,000,000,000
24
CVE-2013-6401: Change hash function, randomize hashes Thanks to Florian Weimer and Eric Sesterhenn for reporting, reviewing and testing.
Safe
310
null
static int mmap_ureg(struct vm_area_struct *vma, struct qib_devdata *dd, u64 ureg) { unsigned long phys; unsigned long sz; int ret; /* * This is real hardware, so use io_remap. This is the mechanism * for the user process to update the head registers for their ctxt * in the chip. */ sz = dd->flags...
0
[ "CWE-284", "CWE-264" ]
linux
e6bd18f57aad1a2d1ef40e646d03ed0f2515c9e3
325,892,051,447,840,600,000,000,000,000,000,000,000
30
IB/security: Restrict use of the write() interface The drivers/infiniband stack uses write() as a replacement for bi-directional ioctl(). This is not safe. There are ways to trigger write calls that result in the return structure that is normally written to user space being shunted off to user specified kernel memory...
Safe
284
{"cwe_id": "CWE-284", "vulnerability_type": "Improper Access Control", "description": "The product does not restrict or incorrectly restricts access to a resource from an unauthorized actor.", "severity": null, "category": "Authorization", "impact": ["Varies by Context"], "languages": [null], "example": "Example not ex...
xmlHashAddEntry(xmlHashTablePtr table, const xmlChar *name, void *userdata) { return(xmlHashAddEntry3(table, name, NULL, NULL, userdata)); }
0
[ "CWE-399" ]
libxml2
8973d58b7498fa5100a876815476b81fd1a2412a
148,906,882,834,292,230,000,000,000,000,000,000,000
3
Add hash randomization to hash and dict structures Following http://www.ocert.org/advisories/ocert-2011-003.html it seems that having hash randomization might be a good idea when using XML with untrusted data * configure.in: lookup for rand, srand and time * dict.c: add randomization to dictionaries hash tables * hash...
Safe
399
null
static struct bsg_command *bsg_alloc_command(struct bsg_device *bd) { struct bsg_command *bc = ERR_PTR(-EINVAL); spin_lock_irq(&bd->lock); if (bd->queued_cmds >= bd->max_queue) goto out; bd->queued_cmds++; spin_unlock_irq(&bd->lock); bc = kmem_cache_zalloc(bsg_cmd_cachep, GFP_KERNEL); if (unlikely(!bc)) { ...
0
[ "CWE-399" ]
linux-2.6
f2f1fa78a155524b849edf359e42a3001ea652c0
83,903,343,827,894,920,000,000,000,000,000,000,000
28
Enforce a minimum SG_IO timeout There's no point in having too short SG_IO timeouts, since if the command does end up timing out, we'll end up through the reset sequence that is several seconds long in order to abort the command that timed out. As a result, shorter timeouts than a few seconds simply do not make sense...
Safe
399
null
static inline struct sk_buff *validate_xmit_xfrm(struct sk_buff *skb, netdev_features_t features, bool *again) { return skb; }
0
[ "CWE-416" ]
linux
dbb2483b2a46fbaf833cfb5deb5ed9cace9c7399
60,852,953,061,237,295,000,000,000,000,000,000,000
4
xfrm: clean up xfrm protocol checks In commit 6a53b7593233 ("xfrm: check id proto in validate_tmpl()") I introduced a check for xfrm protocol, but according to Herbert IPSEC_PROTO_ANY should only be used as a wildcard for lookup, so it should be removed from validate_tmpl(). And, IPSEC_PROTO_ANY is expected to only m...
Safe
416
{"cwe_id": "CWE-416", "vulnerability_type": "Use After Free", "description": "The product reuses or references memory after it has been freed. At some point afterward, the memory may be allocated again and saved in another pointer, while the original pointer references a location somewhere within the new allocation. An...
static int shmem_remount_fs(struct super_block *sb, int *flags, char *data) { struct shmem_sb_info *sbinfo = SHMEM_SB(sb); struct shmem_sb_info config = *sbinfo; unsigned long blocks; unsigned long inodes; int error = -EINVAL; if (shmem_parse_options(data, &config, true)) return error; spin_lock(&sbinfo->sta...
0
[ "CWE-400" ]
linux-2.6
14fcc23fdc78e9d32372553ccf21758a9bd56fa1
85,681,055,874,180,990,000,000,000,000,000,000,000
41
tmpfs: fix kernel BUG in shmem_delete_inode SuSE's insserve initscript ordering program hits kernel BUG at mm/shmem.c:814 on 2.6.26. It's using posix_fadvise on directories, and the shmem_readpage method added in 2.6.23 is letting POSIX_FADV_WILLNEED allocate useless pages to a tmpfs directory, incrementing i_blocks ...
Safe
400
{"cwe_id": "CWE-400", "vulnerability_type": "Uncontrolled Resource Consumption", "description": "The product does not properly control the allocation and maintenance of a limited resource.", "severity": "High", "category": "Resource Exhaustion", "impact": ["DoS: Crash, Exit, or Restart", "DoS: Resource Consumption (CPU...
static errno_t sssctl_restore(bool force_start, bool force_restart) { errno_t ret; if (!sssctl_start_sssd(force_start)) { return ERR_SSSD_NOT_RUNNING; } if (sssctl_backup_file_exists(SSS_BACKUP_USER_OVERRIDES)) { ret = sssctl_run_command((const char *[]){"sss_override", "user-import", ...
0
[ "CWE-78" ]
sssd
7ab83f97e1cbefb78ece17232185bdd2985f0bbe
154,674,701,828,439,540,000,000,000,000,000,000,000
32
TOOLS: replace system() with execvp() to avoid execution of user supplied command :relnote: A flaw was found in SSSD, where the sssctl command was vulnerable to shell command injection via the logs-fetch and cache-expire subcommands. This flaw allows an attacker to trick the root user into running a specially crafted ...
Safe
78
{"cwe_id": "CWE-78", "vulnerability_type": "Improper Neutralization of Special Elements used in an OS Command ('OS Command Injection')", "description": "The product constructs all or part of an OS command using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes...
thread_specific_data(void *private_data) { xmlDocPtr myDoc; const char *filename = (const char *) private_data; int okay = 1; if (!strcmp(filename, "test/threads/invalid.xml")) { xmlDoValidityCheckingDefaultValue = 0; xmlGenericErrorContext = stdout; } else { xmlDoValidityCh...
0
[ "CWE-125" ]
libxml2
a820dbeac29d330bae4be05d9ecd939ad6b4aa33
44,216,203,358,287,320,000,000,000,000,000,000,000
43
Bug 758605: Heap-based buffer overread in xmlDictAddString <https://bugzilla.gnome.org/show_bug.cgi?id=758605> Reviewed by David Kilzer. * HTMLparser.c: (htmlParseName): Add bounds check. (htmlParseNameComplex): Ditto. * result/HTML/758605.html: Added. * result/HTML/758605.html.err: Added. * result/HTML/758605.html.s...
Safe
125
{"cwe_id": "CWE-125", "vulnerability_type": "Out-of-bounds Read", "description": "The product reads data past the end, or before the beginning, of the intended buffer.", "severity": null, "category": "OOB read", "impact": ["Read Memory", "Bypass Protection Mechanism", "DoS: Crash, Exit, or Restart", "Varies by Context"...
void fsck_set_msg_types(struct fsck_options *options, const char *values) { char *buf = xstrdup(values), *to_free = buf; int done = 0; while (!done) { int len = strcspn(buf, " ,|"), equal; done = !buf[len]; if (!len) { buf++; continue; } buf[len] = '\0'; for (equal = 0; equal < len && buf...
0
[ "CWE-20", "CWE-88", "CWE-522" ]
git
a124133e1e6ab5c7a9fef6d0e6bcb084e3455b46
130,448,972,128,989,900,000,000,000,000,000,000,000
37
fsck: detect submodule urls starting with dash Urls with leading dashes can cause mischief on older versions of Git. We should detect them so that they can be rejected by receive.fsckObjects, preventing modern versions of git from being a vector by which attacks can spread. Signed-off-by: Jeff King <peff@peff.net> Si...
Safe
20
{"cwe_id": "CWE-20", "vulnerability_type": "Improper Input Validation", "description": "The product receives input or data, but it does\n not validate or incorrectly validates that the input has the\n properties that are required to process the data safely and\n correctly.", "severity": "High", "ca...
static void *m_start(struct seq_file *m, loff_t *pos) { struct proc_mounts *p = proc_mounts(m); down_read(&namespace_sem); return seq_list_start(&p->ns->list, *pos); }
0
[ "CWE-284", "CWE-264" ]
linux
3151527ee007b73a0ebd296010f1c0454a919c7d
308,368,640,005,441,440,000,000,000,000,000,000,000
7
userns: Don't allow creation if the user is chrooted Guarantee that the policy of which files may be access that is established by setting the root directory will not be violated by user namespaces by verifying that the root directory points to the root of the mount namespace at the time of user namespace creation. ...
Safe
284
{"cwe_id": "CWE-284", "vulnerability_type": "Improper Access Control", "description": "The product does not restrict or incorrectly restricts access to a resource from an unauthorized actor.", "severity": null, "category": "Authorization", "impact": ["Varies by Context"], "languages": [null], "example": "Example not ex...
static int ehci_process_itd(EHCIState *ehci, EHCIitd *itd, uint32_t addr) { USBDevice *dev; USBEndpoint *ep; uint32_t i, len, pid, dir, devaddr, endp; uint32_t pg, off, ptr1, ptr2, max, mult; ehci->periodic_sched_active = PERIODIC_ACTIVE; ...
1
[ "CWE-617" ]
qemu
2fdb42d840400d58f2e706ecca82c142b97bcbd6
177,780,597,048,296,830,000,000,000,000,000,000,000
107
hw: ehci: check return value of 'usb_packet_map' If 'usb_packet_map' fails, we should stop to process the usb request. Signed-off-by: Li Qiang <liq3ea@163.com> Message-Id: <20200812161727.29412-1-liq3ea@163.com> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Vulnerable
617
{"cwe_id": "CWE-617", "vulnerability_type": "Reachable Assertion", "description": "The product contains an assert() or similar statement that can be triggered by an attacker, which leads to an application exit or other behavior that is more severe than necessary.", "severity": null, "category": "assertion failure", "im...
int free_embedded_options(char ** options_list, int options_count) { int i; for (i= 0; i < options_count; i++) { if (options_list[i]) free(options_list[i]); } free(options_list); return 1; }
0
[ "CWE-416" ]
DBD-mysql
a56ae87a4c1c1fead7d09c3653905841ccccf1cc
12,008,645,177,397,620,000,000,000,000,000,000,000
13
fix use-after-free crash in RT #97625
Safe
416
{"cwe_id": "CWE-416", "vulnerability_type": "Use After Free", "description": "The product reuses or references memory after it has been freed. At some point afterward, the memory may be allocated again and saved in another pointer, while the original pointer references a location somewhere within the new allocation. An...
static bool reg_type_mismatch_ok(enum bpf_reg_type type) { switch (base_type(type)) { case PTR_TO_CTX: case PTR_TO_SOCKET: case PTR_TO_SOCK_COMMON: case PTR_TO_TCP_SOCK: case PTR_TO_XDP_SOCK: case PTR_TO_BTF_ID: return false; default: return true; } }
0
[ "CWE-787" ]
linux
64620e0a1e712a778095bd35cbb277dc2259281f
202,620,438,503,806,000,000,000,000,000,000,000,000
14
bpf: Fix out of bounds access for ringbuf helpers Both bpf_ringbuf_submit() and bpf_ringbuf_discard() have ARG_PTR_TO_ALLOC_MEM in their bpf_func_proto definition as their first argument. They both expect the result from a prior bpf_ringbuf_reserve() call which has a return type of RET_PTR_TO_ALLOC_MEM_OR_NULL. Meani...
Safe
787
{"cwe_id": "CWE-787", "vulnerability_type": "Out-of-bounds Write", "description": "The product writes data past the end, or before the beginning, of the intended buffer.", "severity": "High", "category": "Memory Corruption", "impact": ["Modify Memory", "Execute Unauthorized Code or Commands", "DoS: Crash, Exit, or Rest...
GF_Filter *gf_fs_load_filter(GF_FilterSession *fsess, const char *name, GF_Err *err_code) { const char *args=NULL; const char *sep, *file_ext; u32 i, len, count = gf_list_count(fsess->registry); Bool quiet = (err_code && (*err_code == GF_EOS)) ? GF_TRUE : GF_FALSE; assert(fsess); assert(name); if (err_code) *er...
1
[ "CWE-476" ]
gpac
44fdc3d972c31c56efe73e1a3b63438d46087652
220,232,041,198,906,980,000,000,000,000,000,000,000
97
fixed #1906
Vulnerable
476
{"cwe_id": "CWE-476", "vulnerability_type": "NULL Pointer Dereference", "description": "The product dereferences a pointer that it expects to be valid but is NULL.", "severity": "Medium", "category": "NPD", "impact": ["DoS: Crash, Exit, or Restart", "Execute Unauthorized Code or Commands", "Read Memory", "Modify Memory...
TEST_F(HttpHealthCheckerImplTest, GoAwayProbeInProgress) { setupHCHttp2(); EXPECT_CALL(runtime_.snapshot_, featureEnabled("health_check.verify_cluster", 100)) .WillRepeatedly(Return(false)); cluster_->prioritySet().getMockHostSet(0)->hosts_ = { makeTestHost(cluster_->info_, "tcp://127.0.0.1:80", simTi...
0
[ "CWE-476" ]
envoy
9b1c3962172a972bc0359398af6daa3790bb59db
215,775,242,690,504,880,000,000,000,000,000,000,000
31
healthcheck: fix grpc inline removal crashes (#749) Signed-off-by: Matt Klein <mklein@lyft.com> Signed-off-by: Pradeep Rao <pcrao@google.com>
Safe
476
{"cwe_id": "CWE-476", "vulnerability_type": "NULL Pointer Dereference", "description": "The product dereferences a pointer that it expects to be valid but is NULL.", "severity": "Medium", "category": "NPD", "impact": ["DoS: Crash, Exit, or Restart", "Execute Unauthorized Code or Commands", "Read Memory", "Modify Memory...
Error Box_auxC::write(StreamWriter& writer) const { size_t box_start = reserve_box_header_space(writer); writer.write(m_aux_type); for (uint8_t subtype : m_aux_subtypes) { writer.write8(subtype); } prepend_header(writer, box_start); return Error::Ok; }
0
[ "CWE-703" ]
libheif
2710c930918609caaf0a664e9c7bc3dce05d5b58
241,889,598,447,862,300,000,000,000,000,000,000,000
14
force fraction to a limited resolution to finally solve those pesky numerical edge cases
Safe
703
{"cwe_id": "CWE-703", "vulnerability_type": "Improper Check or Handling of Exceptional Conditions", "description": "The product does not properly anticipate or handle exceptional conditions that rarely occur during normal operation of the product.", "severity": null, "category": null, "impact": ["Read Application Data"...
static void cmd_capabilities(char *keyword __attribute__((unused))) { const char *mechlist; int mechcount = 0; prot_printf(nntp_out, "101 Capability list follows:\r\n"); prot_printf(nntp_out, "VERSION 2\r\n"); if (nntp_authstate || (config_serverinfo == IMAP_ENUM_SERVERINFO_ON)) { prot_printf(nntp...
0
[ "CWE-287" ]
cyrus-imapd
77903669e04c9788460561dd0560b9c916519594
96,705,534,033,984,220,000,000,000,000,000,000,000
58
Secunia SA46093 - make sure nntp authentication completes Discovered by Stefan Cornelius, Secunia Research The vulnerability is caused due to the access restriction for certain commands only checking whether or not variable "nntp_userid" is non-NULL, without performing additional checks to verify that a complete, suc...
Safe
287
{"cwe_id": "CWE-287", "vulnerability_type": "Improper Authentication", "description": "When an actor claims to have a given identity, the product does not prove or insufficiently proves that the claim is correct.", "severity": "High", "category": "authentification", "impact": ["Read Application Data", "Gain Privileges ...
void Compute(OpKernelContext* context) override { // Read ragged_splits inputs. OpInputList ragged_nested_splits_in; OP_REQUIRES_OK(context, context->input_list("rt_nested_splits", &ragged_nested_splits_in)); const int ragged_nested_splits_len = ragged_n...
1
[ "CWE-125", "CWE-824" ]
tensorflow
be7a4de6adfbd303ce08be4332554dff70362612
209,500,931,068,648,330,000,000,000,000,000,000,000
45
Ensure non-empty rt_nested_splits in tf.raw_ops.RaggedTensorToVariant PiperOrigin-RevId: 387664237 Change-Id: Ia1700c34b5610873d63561abc86e23b46ead93b3
Vulnerable
125
{"cwe_id": "CWE-125", "vulnerability_type": "Out-of-bounds Read", "description": "The product reads data past the end, or before the beginning, of the intended buffer.", "severity": null, "category": "OOB read", "impact": ["Read Memory", "Bypass Protection Mechanism", "DoS: Crash, Exit, or Restart", "Varies by Context"...
llsec_update_devkey_info(struct mac802154_llsec_device *dev, const struct ieee802154_llsec_key_id *in_key, u32 frame_counter) { struct mac802154_llsec_device_key *devkey = NULL; if (dev->dev.key_mode == IEEE802154_LLSEC_DEVKEY_RESTRICT) { devkey = llsec_devkey_find(dev, in_key); if (!devkey) return -E...
0
[ "CWE-416" ]
linux
1165affd484889d4986cf3b724318935a0b120d8
25,222,919,656,107,720,000,000,000,000,000,000,000
36
net: mac802154: Fix general protection fault syzbot found general protection fault in crypto_destroy_tfm()[1]. It was caused by wrong clean up loop in llsec_key_alloc(). If one of the tfm array members is in IS_ERR() range it will cause general protection fault in clean up function [1]. Call Trace: crypto_free_aead ...
Safe
416
{"cwe_id": "CWE-416", "vulnerability_type": "Use After Free", "description": "The product reuses or references memory after it has been freed. At some point afterward, the memory may be allocated again and saved in another pointer, while the original pointer references a location somewhere within the new allocation. An...
void clear_fifo (i) int i; { if (dev_fd_list[i]) { dev_fd_list[i] = 0; nfds--; }
0
[ "CWE-20" ]
bash
4f747edc625815f449048579f6e65869914dd715
256,528,028,332,019,100,000,000,000,000,000,000,000
9
Bash-4.4 patch 7
Safe
20
{"cwe_id": "CWE-20", "vulnerability_type": "Improper Input Validation", "description": "The product receives input or data, but it does\n not validate or incorrectly validates that the input has the\n properties that are required to process the data safely and\n correctly.", "severity": "High", "ca...
static inline void DetectRunPrefilterPkt( ThreadVars *tv, DetectEngineCtx *de_ctx, DetectEngineThreadCtx *det_ctx, Packet *p, DetectRunScratchpad *scratch ) { DetectPrefilterSetNonPrefilterList(p, det_ctx, scratch); /* create our prefilter mask */ PacketCreateMask(p, &scratch->pkt_mask,...
0
[ "CWE-347" ]
suricata
d8634daf74c882356659addb65fb142b738a186b
235,252,170,973,257,200,000,000,000,000,000,000,000
42
stream: fix false negative on bad RST If a bad RST was received the stream inspection would not happen for that packet, but it would still move the 'raw progress' tracker forward. Following good packets would then fail to detect anything before the 'raw progress' position. Bug #2770 Reported-by: Alexey Vishnyakov
Safe
347
{"cwe_id": "CWE-347", "vulnerability_type": "Improper Verification of Cryptographic Signature", "description": "The product does not verify, or incorrectly verifies, the cryptographic signature for data.", "severity": null, "category": null, "impact": ["Gain Privileges or Assume Identity", "Modify Application Data", "E...
static int check_version_match(void) { DYNAMIC_STRING ds_version; char version_str[NAME_CHAR_LEN + 1]; if (init_dynamic_string(&ds_version, NULL, NAME_CHAR_LEN, NAME_CHAR_LEN)) die("Out of memory"); if (run_query("show variables like 'version'", &ds_version, FALSE)) { fprintf(stderr, "Error: Failed ...
0
[ "CWE-319" ]
mysql-server
0002e1380d5f8c113b6bce91f2cf3f75136fd7c7
140,395,222,213,798,370,000,000,000,000,000,000,000
35
BUG#25575605: SETTING --SSL-MODE=REQUIRED SENDS CREDENTIALS BEFORE VERIFYING SSL CONNECTION MYSQL_OPT_SSL_MODE option introduced. It is set in case of --ssl-mode=REQUIRED and permits only SSL connection. (cherry picked from commit f91b941842d240b8a62645e507f5554e8be76aec)
Safe
319
{"cwe_id": "CWE-319", "vulnerability_type": "Cleartext Transmission of Sensitive Information", "description": "The product transmits sensitive or security-critical data in cleartext in a communication channel that can be sniffed by unauthorized actors.", "severity": "High", "category": null, "impact": ["Read Applicatio...
u32 parse_track_dump(char *arg, u32 dump_type) { if (!create_new_track_action(arg, TRACK_ACTION_RAW_EXTRACT, dump_type)) return 2; track_dump_type = dump_type; return 0;
0
[ "CWE-787" ]
gpac
4e56ad72ac1afb4e049a10f2d99e7512d7141f9d
219,920,299,519,188,300,000,000,000,000,000,000
7
fixed #2216
Safe
787
{"cwe_id": "CWE-787", "vulnerability_type": "Out-of-bounds Write", "description": "The product writes data past the end, or before the beginning, of the intended buffer.", "severity": "High", "category": "Memory Corruption", "impact": ["Modify Memory", "Execute Unauthorized Code or Commands", "DoS: Crash, Exit, or Rest...
void hci_conn_enter_active_mode(struct hci_conn *conn, __u8 force_active) { struct hci_dev *hdev = conn->hdev; BT_DBG("hcon %p mode %d", conn, conn->mode); if (conn->mode != HCI_CM_SNIFF) goto timer; if (!test_bit(HCI_CONN_POWER_SAVE, &conn->flags) && !force_active) goto timer; if (!test_and_set_bit(HCI_CO...
0
[ "CWE-327" ]
linux
d5bb334a8e171b262e48f378bd2096c0ea458265
125,774,088,669,376,160,000,000,000,000,000,000,000
23
Bluetooth: Align minimum encryption key size for LE and BR/EDR connections The minimum encryption key size for LE connections is 56 bits and to align LE with BR/EDR, enforce 56 bits of minimum encryption key size for BR/EDR connections as well. Signed-off-by: Marcel Holtmann <marcel@holtmann.org> Signed-off-by: Johan...
Safe
327
{"cwe_id": "CWE-327", "vulnerability_type": "Use of a Broken or Risky Cryptographic Algorithm", "description": "The product uses a broken or risky cryptographic algorithm or protocol.", "severity": "High", "category": null, "impact": ["Read Application Data", "Modify Application Data", "Hide Activities"], "languages": ...
e_mail_parser_parse (EMailParser *parser, CamelFolder *folder, const gchar *message_uid, CamelMimeMessage *message, GAsyncReadyCallback callback, GCancellable *cancellable, gpointer user_data) {...
0
[ "CWE-347" ]
evolution
9c55a311325f5905d8b8403b96607e46cf343f21
212,244,551,670,967,380,000,000,000,000,000,000,000
31
I#120 - Show security bar above message headers Closes https://gitlab.gnome.org/GNOME/evolution/issues/120
Safe
347
{"cwe_id": "CWE-347", "vulnerability_type": "Improper Verification of Cryptographic Signature", "description": "The product does not verify, or incorrectly verifies, the cryptographic signature for data.", "severity": null, "category": null, "impact": ["Gain Privileges or Assume Identity", "Modify Application Data", "E...
static bool check_underflow(const struct ip6t_entry *e) { const struct xt_entry_target *t; unsigned int verdict; if (!unconditional(&e->ipv6)) return false; t = ip6t_get_target_c(e); if (strcmp(t->u.user.name, XT_STANDARD_TARGET) != 0) return false; verdict = ((struct xt_standard_target *)t)->verdict; verdi...
1
[ "CWE-119", "CWE-787" ]
linux
54d83fc74aa9ec72794373cb47432c5f7fb1a309
69,891,328,452,143,980,000,000,000,000,000,000,000
14
netfilter: x_tables: fix unconditional helper Ben Hawkes says: In the mark_source_chains function (net/ipv4/netfilter/ip_tables.c) it is possible for a user-supplied ipt_entry structure to have a large next_offset field. This field is not bounds checked prior to writing a counter value at the supplied offset. Pr...
Vulnerable
119
{"cwe_id": "CWE-119", "vulnerability_type": "Improper Restriction of Operations within the Bounds of a Memory Buffer", "description": "The product performs operations on a memory buffer, but it reads from or writes to a memory location outside the buffer's intended boundary. This may result in read or write operations ...
static inline TCGMemOp mo_64_32(TCGMemOp ot) { #ifdef TARGET_X86_64 return ot == MO_64 ? MO_64 : MO_32; #else return MO_32; #endif }
0
[ "CWE-94" ]
qemu
30663fd26c0307e414622c7a8607fbc04f92ec14
250,893,554,458,281,860,000,000,000,000,000,000,000
8
tcg/i386: Check the size of instruction being translated This fixes the bug: 'user-to-root privesc inside VM via bad translation caching' reported by Jann Horn here: https://bugs.chromium.org/p/project-zero/issues/detail?id=1122 Reviewed-by: Richard Henderson <rth@twiddle.net> CC: Peter Maydell <peter.maydell@linaro....
Safe
94
{"cwe_id": "CWE-94", "vulnerability_type": "Improper Control of Generation of Code ('Code Injection')", "description": "The product constructs all or part of a code segment using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could mod...
lyxml_free_attrs(struct ly_ctx *ctx, struct lyxml_elem *elem) { struct lyxml_attr *a, *next; if (!elem || !elem->attr) { return; } a = elem->attr; do { next = a->next; lydict_remove(ctx, a->name); lydict_remove(ctx, a->value); if (a->type == LYXML_ATTR_STD_U...
0
[ "CWE-674" ]
libyang
298b30ea4ebee137226acf9bb38678bd82704582
35,593,257,233,789,404,000,000,000,000,000,000,000
21
common FEATURE add a hard limit for recursion Fixes #1453
Safe
674
{"cwe_id": "CWE-674", "vulnerability_type": "Uncontrolled Recursion", "description": "The product does not properly control the amount of recursion that takes place, consuming excessive resources, such as allocated memory or the program stack.", "severity": null, "category": "Stack Exhaustion", "impact": ["DoS: Resour...
SegmentCommand* Binary::segment_from_offset(uint64_t offset) { return const_cast<SegmentCommand*>(static_cast<const Binary*>(this)->segment_from_offset(offset)); }
1
[ "CWE-703" ]
LIEF
7acf0bc4224081d4f425fcc8b2e361b95291d878
42,342,701,268,356,780,000,000,000,000,000,000,000
3
Resolve #764
Vulnerable
703
{"cwe_id": "CWE-703", "vulnerability_type": "Improper Check or Handling of Exceptional Conditions", "description": "The product does not properly anticipate or handle exceptional conditions that rarely occur during normal operation of the product.", "severity": null, "category": null, "impact": ["Read Application Data"...
static int pfkey_error(const struct sadb_msg *orig, int err, struct sock *sk) { struct sk_buff *skb = alloc_skb(sizeof(struct sadb_msg) + 16, GFP_KERNEL); struct sadb_msg *hdr; if (!skb) return -ENOBUFS; /* Woe be to the platform trying to support PFKEY yet * having normal errnos outside the 1-255 range, incl...
0
[ "CWE-20", "CWE-269" ]
linux
f3d3342602f8bcbf37d7c46641cb9bca7618eb1c
68,105,614,729,744,530,000,000,000,000,000,000,000
30
net: rework recvmsg handler msg_name and msg_namelen logic This patch now always passes msg->msg_namelen as 0. recvmsg handlers must set msg_namelen to the proper size <= sizeof(struct sockaddr_storage) to return msg_name to the user. This prevents numerous uninitialized memory leaks we had in the recvmsg handlers an...
Safe
20
{"cwe_id": "CWE-20", "vulnerability_type": "Improper Input Validation", "description": "The product receives input or data, but it does\n not validate or incorrectly validates that the input has the\n properties that are required to process the data safely and\n correctly.", "severity": "High", "ca...
void saveVCalendar (TNEFStruct *tnef, const gchar *tmpdir) { gchar *ifilename; variableLength *filename; gchar *charptr, *charptr2; FILE *fptr; gint index; DWORD *dword_ptr; DWORD dword_val; dtr thedate; ifilename = g_build_filename (tmpdir, "calendar.vcf", NULL); printf("%s\n",...
0
[]
evolution
a9fb511ced4cfaffb7109e58a9db66e6279e309c
203,510,093,158,569,770,000,000,000,000,000,000,000
249
bug #641069 - tnef plugin vulnerabilities Resolves directory traversal and buffer overflow vulnerabilities.
Safe
null
null
static int mark_source_chains(const struct xt_table_info *newinfo, unsigned int valid_hooks, void *entry0, unsigned int *offsets) { unsigned int hook; /* No recursion; use packet counter to save back ptrs (reset * to 0 as we leave), and comefrom to save source hook bitmask. */ for (hook = 0; h...
0
[ "CWE-787" ]
linux
b29c457a6511435960115c0f548c4360d5f4801d
30,609,778,745,476,826,000,000,000,000,000,000,000
85
netfilter: x_tables: fix compat match/target pad out-of-bound write xt_compat_match/target_from_user doesn't check that zeroing the area to start of next rule won't write past end of allocated ruleset blob. Remove this code and zero the entire blob beforehand. Reported-by: syzbot+cfc0247ac173f597aaaa@syzkaller.appsp...
Safe
787
{"cwe_id": "CWE-787", "vulnerability_type": "Out-of-bounds Write", "description": "The product writes data past the end, or before the beginning, of the intended buffer.", "severity": "High", "category": "Memory Corruption", "impact": ["Modify Memory", "Execute Unauthorized Code or Commands", "DoS: Crash, Exit, or Rest...
static int ntop_set_second_traffic(lua_State* vm) { NetworkInterface *ntop_interface = getCurrentInterface(vm); ntop->getTrace()->traceEvent(TRACE_DEBUG, "%s() called", __FUNCTION__); if(!ntop_interface) return(CONST_LUA_ERROR); ntop_interface->updateSecondTraffic(time(NULL)); return(CONST_LUA_OK); }
0
[ "CWE-476" ]
ntopng
01f47e04fd7c8d54399c9e465f823f0017069f8f
255,683,374,254,688,600,000,000,000,000,000,000,000
10
Security fix: prevents empty host from being used
Safe
476
{"cwe_id": "CWE-476", "vulnerability_type": "NULL Pointer Dereference", "description": "The product dereferences a pointer that it expects to be valid but is NULL.", "severity": "Medium", "category": "NPD", "impact": ["DoS: Crash, Exit, or Restart", "Execute Unauthorized Code or Commands", "Read Memory", "Modify Memory...
End of preview. Expand in Data Studio

πŸ” Code Vulnerability Dataset (CWE-Enriched)

πŸ“Œ Overview

This dataset is built from the bstee615/diversevul dataset and enhanced with structured vulnerability intelligence from the MITRE Common Weakness Enumeration (CWE) database.

It provides a rich, machine-readable representation of software vulnerabilities, mapping raw vulnerable code samples to standardized CWE classifications.

The dataset is designed for research and development in:

  • Vulnerability detection models
  • Secure code generation
  • LLM fine-tuning for cybersecurity tasks
  • Static analysis and code understanding systems

🧠 Dataset Enrichment Process

Each sample in the dataset has been augmented using the MITRE CWE API to include structured security intelligence such as:

  • CWE identifier (e.g., CWE-787)
  • Vulnerability type (e.g., Out-of-bounds Write)
  • Human-readable description
  • Severity / exploit likelihood
  • Impact categories (e.g., code execution, crash)
  • Applicable programming languages
  • Security classification metadata

πŸ“Š Data Structure

Each row in the dataset contains:

πŸ”Ή Original Fields

  • func β†’ Source code snippet
  • cwe β†’ Original CWE labels from DiverseVul dataset

πŸ”Ή Enriched Field

  • cwe_details β†’ JSON object containing structured CWE metadata:
{
  "cwe_id": "CWE-787",
  "vulnerability_type": "Out-of-bounds Write",
  "description": "The product writes data past the end, or before the beginning, of the intended buffer.",
  "severity": "High",
  "category": "Memory Corruption",
  "impact": [
    "Modify Memory",
    "Execute Unauthorized Code",
    "Crash (DoS)"
  ],
  "languages": ["C", "C++"],
  "example": "Example not extracted"
}
Downloads last month
37