func
string
target
int64
cwe
list
project
string
commit_id
string
hash
float64
size
int64
message
string
static int exec_context_named_iofds(const ExecContext *c, const ExecParameters *p, int named_iofds[static 3]) { size_t i, targets; const char* stdio_fdname[3]; size_t n_fds; assert(c); assert(p); targets = (c->std_input == EXEC_INPUT_NAMED_FD) + (c->st...
0
[ "CWE-269" ]
systemd
f69567cbe26d09eac9d387c0be0fc32c65a83ada
131,284,934,369,513,500,000,000,000,000,000,000,000
45
core: expose SUID/SGID restriction as new unit setting RestrictSUIDSGID=
static u32 temac_dma_in32_be(struct temac_local *lp, int reg) { return ioread32be(lp->sdma_regs + (reg << 2)); }
0
[ "CWE-120", "CWE-787" ]
linux
c364df2489b8ef2f5e3159b1dff1ff1fdb16040d
35,318,853,281,931,080,000,000,000,000,000,000,000
4
net: ll_temac: Fix TX BD buffer overwrite Just as the initial check, we need to ensure num_frag+1 buffers available, as that is the number of buffers we are going to use. This fixes a buffer overflow, which might be seen during heavy network load. Complete lockup of TEMAC was reproducible within about 10 minutes of a...
static void tcp_v6_reqsk_send_ack(struct sock *sk, struct sk_buff *skb, struct request_sock *req) { tcp_v6_send_ack(skb, tcp_rsk(req)->snt_isn + 1, tcp_rsk(req)->rcv_isn + 1, req->rcv_wnd, tcp_time_stamp, req->ts_recent, tcp_v6_md5_do_lookup(sk, &ipv6_hdr(skb)->daddr), 0, 0); }
0
[]
linux
7bced397510ab569d31de4c70b39e13355046387
114,769,582,146,616,920,000,000,000,000,000,000,000
8
net_dma: simple removal Per commit "77873803363c net_dma: mark broken" net_dma is no longer used and there is no plan to fix it. This is the mechanical removal of bits in CONFIG_NET_DMA ifdef guards. Reverting the remainder of the net_dma induced changes is deferred to subsequent patches. Marked for stable due to Ro...
static void alloc_aligned_buffer(bufferlist& data, unsigned len, unsigned off) { // create a buffer to read into that matches the data alignment unsigned left = len; if (off & ~CEPH_PAGE_MASK) { // head unsigned head = 0; head = MIN(CEPH_PAGE_SIZE - (off & ~CEPH_PAGE_MASK), left); data.push_back(b...
0
[ "CWE-287", "CWE-284" ]
ceph
5ead97120e07054d80623dada90a5cc764c28468
265,821,263,325,024,200,000,000,000,000,000,000,000
20
auth/cephx: add authorizer challenge Allow the accepting side of a connection to reject an initial authorizer with a random challenge. The connecting side then has to respond with an updated authorizer proving they are able to decrypt the service's challenge and that the new authorizer was produced for this specific ...
static void reload_tss(void) { /* * VT restores TR but not its size. Useless. */ struct desc_ptr *gdt = &__get_cpu_var(host_gdt); struct desc_struct *descs; descs = (void *)gdt->address; descs[GDT_ENTRY_TSS].type = 9; /* available TSS */ load_TR_desc(); }
0
[ "CWE-20" ]
linux
bfd0a56b90005f8c8a004baf407ad90045c2b11e
157,193,005,680,886,380,000,000,000,000,000,000,000
12
nEPT: Nested INVEPT If we let L1 use EPT, we should probably also support the INVEPT instruction. In our current nested EPT implementation, when L1 changes its EPT table for L2 (i.e., EPT12), L0 modifies the shadow EPT table (EPT02), and in the course of this modification already calls INVEPT. But if last level of sh...
print_r2p_slotstatus (const unsigned char *msg, size_t msglen) { print_r2p_header ("RDR_to_PC_SlotStatus", msg, msglen); if (msglen < 10) return; printf (" bClockStatus ......: 0x%02x%s\n", msg[9], msg[9] == 0? " (running)": msg[9] == 1? " (stopped-L)": msg[9] == 2? " (stopped-H...
0
[ "CWE-20" ]
gnupg
2183683bd633818dd031b090b5530951de76f392
199,658,549,278,002,120,000,000,000,000,000,000,000
12
Use inline functions to convert buffer data to scalars. * common/host2net.h (buf16_to_ulong, buf16_to_uint): New. (buf16_to_ushort, buf16_to_u16): New. (buf32_to_size_t, buf32_to_ulong, buf32_to_uint, buf32_to_u32): New. -- Commit 91b826a38880fd8a989318585eb502582636ddd8 was not enough to avoid all sign extension on ...
void TrustedPrimitives::UntrustedLocalFree(void *ptr) noexcept { CHECK_OCALL(ocall_untrusted_local_free(ptr)); }
0
[ "CWE-200", "CWE-668" ]
asylo
ecfcd0008b6f8f63c6fa3cc1b62fcd4a52f2c0ad
17,828,195,739,606,988,000,000,000,000,000,000,000
3
Store untrusted input to enclave variable The untrusted input pointer should be stored to trusted variable before checking to avoid unexpected modifications after checking. PiperOrigin-RevId: 362553830 Change-Id: I743f9bd3487de60269e247d74f2188f2ffc06d01
static void aliascmd(RCore *core, const char *str) { switch (str[0]) { case '-': if (str[1]) { r_cmd_alias_del (core->rcmd, str + 2); } else { r_cmd_alias_del (core->rcmd, NULL); // r_cmd_alias_reset (core->rcmd); } break; case '?': eprintf ("Usage: =$[-][remotecmd] # remote command alias\n"); e...
0
[ "CWE-119", "CWE-787" ]
radare2
00e8f205475332d7842d0f0d1481eeab4e83017c
239,410,516,442,225,640,000,000,000,000,000,000,000
23
Fix #7727 - undefined pointers and out of band string access fixes
static void xdr_buf_iov_zero(const struct kvec *iov, unsigned int base, unsigned int len) { if (base >= iov->iov_len) return; if (len > iov->iov_len - base) len = iov->iov_len - base; memset(iov->iov_base + base, 0, len); }
0
[ "CWE-119", "CWE-787" ]
linux
6d1c0f3d28f98ea2736128ed3e46821496dc3a8c
163,903,050,059,254,580,000,000,000,000,000,000,000
9
sunrpc: Avoid a KASAN slab-out-of-bounds bug in xdr_set_page_base() This seems to happen fairly easily during READ_PLUS testing on NFS v4.2. I found that we could end up accessing xdr->buf->pages[pgnr] with a pgnr greater than the number of pages in the array. So let's just return early if we're setting base to a poin...
static int io_do_iopoll(struct io_ring_ctx *ctx, unsigned int *nr_events, long min) { struct io_kiocb *req, *tmp; LIST_HEAD(done); bool spin; int ret; /* * Only spin for completions if we don't have multiple devices hanging * off our complete list, and we're under the requested amount. */ spin = !ctx->p...
0
[ "CWE-125" ]
linux
89c2b3b74918200e46699338d7bcc19b1ea12110
24,537,958,098,197,610,000,000,000,000,000,000,000
48
io_uring: reexpand under-reexpanded iters [ 74.211232] BUG: KASAN: stack-out-of-bounds in iov_iter_revert+0x809/0x900 [ 74.212778] Read of size 8 at addr ffff888025dc78b8 by task syz-executor.0/828 [ 74.214756] CPU: 0 PID: 828 Comm: syz-executor.0 Not tainted 5.14.0-rc3-next-20210730 #1 [ 74.216525] Hardware n...
static void ipc_log_header(struct device *dev, u8 *text, u32 cmd) { u8 *str; u8 *str2 = NULL; u32 glb; u32 type; glb = cmd & SOF_GLB_TYPE_MASK; type = cmd & SOF_CMD_TYPE_MASK; switch (glb) { case SOF_IPC_GLB_REPLY: str = "GLB_REPLY"; break; case SOF_IPC_GLB_COMPOUND: str = "GLB_COMPOUND"; break; case SO...
0
[ "CWE-400", "CWE-401" ]
linux
45c1380358b12bf2d1db20a5874e9544f56b34ab
125,379,548,219,837,720,000,000,000,000,000,000,000
140
ASoC: SOF: ipc: Fix memory leak in sof_set_get_large_ctrl_data In the implementation of sof_set_get_large_ctrl_data() there is a memory leak in case an error. Release partdata if sof_get_ctrl_copy_params() fails. Fixes: 54d198d5019d ("ASoC: SOF: Propagate sof_get_ctrl_copy_params() error properly") Signed-off-by: Nav...
static ssize_t sched_smt_power_savings_store(struct sys_device *dev, const char *buf, size_t count) { return sched_power_savings_store(buf, count, 1); }
0
[]
linux-2.6
8f1bc385cfbab474db6c27b5af1e439614f3025c
181,575,894,413,262,500,000,000,000,000,000,000,000
5
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 ...
static u64 find_next_chunk(struct btrfs_fs_info *fs_info) { struct extent_map_tree *em_tree; struct extent_map *em; struct rb_node *n; u64 ret = 0; em_tree = &fs_info->mapping_tree.map_tree; read_lock(&em_tree->lock); n = rb_last(&em_tree->map.rb_root); if (n) { em = rb_entry(n, struct extent_map, rb_node); ...
0
[ "CWE-476", "CWE-284" ]
linux
09ba3bc9dd150457c506e4661380a6183af651c1
78,249,662,551,151,030,000,000,000,000,000,000,000
18
btrfs: merge btrfs_find_device and find_device Both btrfs_find_device() and find_device() does the same thing except that the latter does not take the seed device onto account in the device scanning context. We can merge them. Signed-off-by: Anand Jain <anand.jain@oracle.com> Reviewed-by: David Sterba <dsterba@suse.c...
gst_matroska_decode_buffer (GstMatroskaTrackContext * context, GstBuffer * buf) { GstMapInfo map; gpointer data; gsize size; GstBuffer *out_buf = buf; g_return_val_if_fail (GST_IS_BUFFER (buf), NULL); GST_DEBUG ("decoding buffer %p", buf); gst_buffer_map (out_buf, &map, GST_MAP_READ); data = map.data...
0
[]
gst-plugins-good
9181191511f9c0be6a89c98b311f49d66bd46dc3
73,614,563,609,300,200,000,000,000,000,000,000,000
71
matroskademux: Fix extraction of multichannel WavPack The old code had a couple of issues that all lead to potential memory safety bugs. - Use a constant for the Wavpack4Header size instead of using sizeof. It's written out into the data and not from the struct and who knows what special alignment/padding r...
struct gg_session *gg_login(const struct gg_login_params *p) { struct gg_session *sess = NULL; if (p == NULL) { gg_debug(GG_DEBUG_FUNCTION, "** gg_login(%p);\n", p); errno = EFAULT; return NULL; } gg_debug(GG_DEBUG_FUNCTION, "** gg_login(%p: [uin=%u, async=%d, ...]);\n", p, p->uin, p->async); sess = mallo...
0
[ "CWE-310" ]
libgadu
23644f1fb8219031b3cac93289a588b05f90226b
302,561,456,886,734,740,000,000,000,000,000,000,000
210
Poprawka ograniczania długości opisu.
uint32_t cli_bcapi_buffer_pipe_read_avail(struct cli_bc_ctx *ctx , int32_t id) { struct bc_buffer *b = get_buffer(ctx, id); if (!b) return 0; if (b->data) { if (b->write_cursor <= b->read_cursor) return 0; return b->write_cursor - b->read_cursor; } if (!ctx->fmap || b->read_cursor >= ctx->fi...
0
[ "CWE-189" ]
clamav-devel
3d664817f6ef833a17414a4ecea42004c35cc42f
195,906,446,841,875,700,000,000,000,000,000,000,000
16
fix recursion level crash (bb #3706). Thanks to Stephane Chazelas for the analysis.
gdImagePtr gdImageCreateFromGifSource(gdSourcePtr inSource) /* {{{ */ { gdIOCtx *in = gdNewSSCtx(inSource, NULL); gdImagePtr im; im = gdImageCreateFromGifCtx(in); in->gd_free(in); return im; }
0
[ "CWE-119" ]
php-src
07b5896a1389c3e865cbd2fb353806b2cefe4f5c
189,162,230,038,138,200,000,000,000,000,000,000,000
11
Fix bug #68601 buffer read overflow in gd_gif_in.c
idr_set_num_beutf16(unsigned char *p, int num) { static const uint16_t xdig[] = { 0x0030, 0x0031, 0x0032, 0x0033, 0x0034, 0x0035, 0x0036, 0x0037, 0x0038, 0x0039, 0x0041, 0x0042, 0x0043, 0x0044, 0x0045, 0x0046, 0x0047, 0x0048, 0x0049, 0x004A, 0x004B, 0x004C, 0x004D, 0x004E, 0x004F, 0x0050, 0x0051, 0x0052, 0...
0
[ "CWE-190" ]
libarchive
3014e19820ea53c15c90f9d447ca3e668a0b76c6
62,539,423,617,985,770,000,000,000,000,000,000,000
20
Issue 711: Be more careful about verifying filename lengths when writing ISO9660 archives * Don't cast size_t to int, since this can lead to overflow on machines where sizeof(int) < sizeof(size_t) * Check a + b > limit by writing it as a > limit || b > limit || a + b > limit to avoid problems when a + b wraps...
ObjectContextLoad( ANY_OBJECT_BUFFER *object, // IN: pointer to object structure in saved // context TPMI_DH_OBJECT *handle // OUT: object handle ) { OBJECT *newObject = ObjectAllocateSlot(handle); // Try to allocate a slot for new object if(newObject != NULL) ...
0
[ "CWE-119" ]
libtpms
ea62fd9679f8c6fc5e79471b33cfbd8227bfed72
176,769,955,704,656,930,000,000,000,000,000,000,000
27
tpm2: Initialize a whole OBJECT before using it Initialize a whole OBJECT before using it. This is necessary since an OBJECT may also be used as a HASH_OBJECT via the ANY_OBJECT union and that HASH_OBJECT can leave bad size inidicators in TPM2B buffer in the OBJECT. To get rid of this problem we reset the whole OBJECT...
void nested_vmcb02_compute_g_pat(struct vcpu_svm *svm) { if (!svm->nested.vmcb02.ptr) return; /* FIXME: merge g_pat from vmcb01 and vmcb12. */ svm->nested.vmcb02.ptr->save.g_pat = svm->vmcb01.ptr->save.g_pat; }
0
[ "CWE-862" ]
kvm
0f923e07124df069ba68d8bb12324398f4b6b709
935,309,624,291,596,000,000,000,000,000,000,000
8
KVM: nSVM: avoid picking up unsupported bits from L2 in int_ctl (CVE-2021-3653) * Invert the mask of bits that we pick from L2 in nested_vmcb02_prepare_control * Invert and explicitly use VIRQ related bits bitmask in svm_clear_vintr This fixes a security issue that allowed a malicious L1 to run L2 with AVIC enable...
static void kvm_inc_notifier_count(struct kvm *kvm, unsigned long start, unsigned long end) { /* * The count increase must become visible at unlock time as no * spte can be established without taking the mmu_lock and * count is also read inside the mmu_lock critical section. */ kvm->mmu_notifier_count+...
0
[ "CWE-119" ]
linux
f8be156be163a052a067306417cd0ff679068c97
95,130,063,541,537,280,000,000,000,000,000,000,000
28
KVM: do not allow mapping valid but non-reference-counted pages It's possible to create a region which maps valid but non-refcounted pages (e.g., tail pages of non-compound higher order allocations). These host pages can then be returned by gfn_to_page, gfn_to_pfn, etc., family of APIs, which take a reference to the p...
void set_agg_func_used(bool val) { m_agg_func_used= val; }
0
[ "CWE-703" ]
server
39feab3cd31b5414aa9b428eaba915c251ac34a2
76,534,557,563,566,070,000,000,000,000,000,000,000
1
MDEV-26412 Server crash in Item_field::fix_outer_field for INSERT SELECT IF an INSERT/REPLACE SELECT statement contained an ON expression in the top level select and this expression used a subquery with a column reference that could not be resolved then an attempt to resolve this reference as an outer reference caused...
PM_io_parser(std::ostream& os, const PMDEC& D) : Base(D), in(std::cin), out(os), VI(Base::vertices_begin(),Base::vertices_end(),'v'), EI(Base::halfedges_begin(),Base::halfedges_end(),'e'), FI(Base::faces_begin(),Base::faces_end(),'f'), vn(Base::number_of_vertices()), en(Base::number_of_halfedges()), fn(Base...
0
[ "CWE-269" ]
cgal
618b409b0fbcef7cb536a4134ae3a424ef5aae45
161,344,869,535,765,980,000,000,000,000,000,000,000
11
Fix Nef_2 and Nef_S2 IO
double Item_ref::val_result() { if (result_field) { if ((null_value= result_field->is_null())) return 0.0; return result_field->val_real(); } return val_real(); }
0
[]
server
b000e169562697aa072600695d4f0c0412f94f4f
74,718,497,386,328,890,000,000,000,000,000,000,000
10
Bug#26361149 MYSQL SERVER CRASHES AT: COL IN(IFNULL(CONST, COL), NAME_CONST('NAME', NULL)) based on: commit f7316aa0c9a Author: Ajo Robert <ajo.robert@oracle.com> Date: Thu Aug 24 17:03:21 2017 +0530 Bug#26361149 MYSQL SERVER CRASHES AT: COL IN(IFNULL(CONST, COL), NAME_CONST('NAME'...
xmlXPathNodeSetMerge(xmlNodeSetPtr val1, xmlNodeSetPtr val2) { int i, j, initNr, skip; xmlNodePtr n1, n2; if (val2 == NULL) return(val1); if (val1 == NULL) { val1 = xmlXPathNodeSetCreate(NULL); if (val1 == NULL) return (NULL); #if 0 /* * TODO: The optimization won't work in every case, s...
1
[ "CWE-189" ]
libxml2
d7958b21e7f8c447a26bb2436f08402b2c308be4
12,787,125,674,291,892,000,000,000,000,000,000,000
102
Fix some potential problems on reallocation failures The count was incremented before the allocation and not fixed in case of failure * xpath.c: corrects a few instances where the available count of some structure is updated before we know the allocation actually succeeds
match_device_hwaddr_eval(const char *spec_str, MatchDeviceData *match_data) { if (G_UNLIKELY(!match_data->hwaddr.is_parsed)) { match_data->hwaddr.is_parsed = TRUE; if (match_data->hwaddr.value) { gsize l; if (!_nm_utils_hwaddr_aton(match_data->hwaddr.value, ...
0
[ "CWE-20" ]
NetworkManager
420784e342da4883f6debdfe10cde68507b10d27
9,111,857,775,425,658,000,000,000,000,000,000,000
21
core: fix crash in nm_wildcard_match_check() It's not entirely clear how to treat %NULL. Clearly "match.interface-name=eth0" should not match with an interface %NULL. But what about "match.interface-name=!eth0"? It's now implemented that negative matches still succeed against %NULL. What about "match.interface-name=*"...
static int reencrypt_verify_and_upload_keys(struct crypt_device *cd, struct luks2_hdr *hdr, int digest_old, int digest_new, struct volume_key *vks) { int r; struct volume_key *vk; if (digest_new >= 0) { vk = crypt_volume_key_by_id(vks, digest_new); if (!vk) return -ENOENT; else { if (LUKS2_digest_verify...
0
[ "CWE-345" ]
cryptsetup
0113ac2d889c5322659ad0596d4cfc6da53e356c
273,739,585,393,281,980,000,000,000,000,000,000,000
40
Fix CVE-2021-4122 - LUKS2 reencryption crash recovery attack Fix possible attacks against data confidentiality through LUKS2 online reencryption extension crash recovery. An attacker can modify on-disk metadata to simulate decryption in progress with crashed (unfinished) reencryption step and persistently decrypt par...
irc_nick_mode_for_display (struct t_irc_server *server, struct t_irc_nick *nick, int prefix) { static char result[32]; char str_prefix[2]; int nick_mode; const char *str_prefix_color; str_prefix[0] = (nick) ? nick->prefix[0] : '\0'; str_prefix[1] = '\0'; nick_mod...
0
[ "CWE-120", "CWE-787" ]
weechat
40ccacb4330a64802b1f1e28ed9a6b6d3ca9197f
337,019,878,325,965,160,000,000,000,000,000,000,000
44
irc: fix crash when a new message 005 is received with longer nick prefixes Thanks to Stuart Nevans Locke for reporting the issue.
void lxc_cgroup_process_info_free(struct cgroup_process_info *info) { struct cgroup_process_info *next; if (!info) return; next = info->next; lxc_cgroup_put_meta(info->meta_ref); free(info->cgroup_path); free(info->cgroup_path_sub); lxc_free_array((void **)info->created_paths, free); free(info); lxc_cgroup_p...
0
[ "CWE-59", "CWE-61" ]
lxc
592fd47a6245508b79fe6ac819fe6d3b2c1289be
114,984,627,207,918,850,000,000,000,000,000,000,000
13
CVE-2015-1335: Protect container mounts against symlinks When a container starts up, lxc sets up the container's inital fstree by doing a bunch of mounting, guided by the container configuration file. The container config is owned by the admin or user on the host, so we do not try to guard against bad entries. Howev...
context_switch(struct rq *rq, struct task_struct *prev, struct task_struct *next) { struct mm_struct *mm, *oldmm; prepare_task_switch(rq, prev, next); mm = next->mm; oldmm = prev->active_mm; /* * For paravirt, this is coupled with an exit in switch_to to * combine the page table reload and the switch...
0
[ "CWE-119" ]
linux
29d6455178a09e1dc340380c582b13356227e8df
338,543,412,832,282,100,000,000,000,000,000,000,000
42
sched: panic on corrupted stack end Until now, hitting this BUG_ON caused a recursive oops (because oops handling involves do_exit(), which calls into the scheduler, which in turn raises an oops), which caused stuff below the stack to be overwritten until a panic happened (e.g. via an oops in interrupt context, cause...
int treeRead(struct READER *reader, struct DATAOBJECT *data) { int i, j, err, olen, elements, size, x, y, z, b, e, dy, dz, sx, sy, sz, dzy, szy; char *input, *output; uint8_t node_type, node_level; uint16_t entries_used; uint32_t size_of_chunk; uint32_t filter_mask; uint64_t address_of_left_sibling, address_...
1
[ "CWE-20", "CWE-703" ]
libmysofa
d39a171e9c6a1c44dbdf43f9db6c3fbd887e38c1
58,197,382,460,868,980,000,000,000,000,000,000,000
165
Fixed security issue 1
static void increment_fstein_dither(void) { return; }
0
[ "CWE-369" ]
libcaca
84bd155087b93ab2d8d7cb5b1ac94ecd4cf4f93c
313,546,639,131,192,850,000,000,000,000,000,000,000
4
dither: fix integer overflows that were causing a division by zero. Fixes: #36 (CVE-2018-20544)
open_shell_script (script_name) char *script_name; { int fd, e, fd_is_tty; char *filename, *path_filename, *t; char sample[80]; int sample_len; struct stat sb; #if defined (ARRAY_VARS) SHELL_VAR *funcname_v, *bash_source_v, *bash_lineno_v; ARRAY *funcname_a, *bash_source_a, *bash_lineno_a; #endif ...
0
[ "CWE-273", "CWE-787" ]
bash
951bdaad7a18cc0dc1036bba86b18b90874d39ff
127,706,353,506,865,580,000,000,000,000,000,000,000
173
commit bash-20190628 snapshot
_dwarf_get_addr_index_itself(int theform, Dwarf_Small *info_ptr, Dwarf_Debug dbg, Dwarf_CU_Context cu_context, Dwarf_Unsigned *val_out, Dwarf_Error * error) { Dwarf_Unsigned index = 0; Dwarf_Byte_Ptr section_end = 0; section_end = _dwarf_calculate_info_section_end_ptr(cu_context...
0
[ "CWE-703", "CWE-125" ]
libdwarf-code
7ef09e1fc9ba07653dd078edb2408631c7969162
300,994,095,353,740,630,000,000,000,000,000,000,000
56
Fixes old bug(which could result in Denial of Service) due to a missing check before reading the 8 bytes of a DW_FORM_ref_sig8. DW202206-001 modified: src/lib/libdwarf/dwarf_form.c
static inline bool kvm_apic_has_events(struct kvm_vcpu *vcpu) { return kvm_vcpu_has_lapic(vcpu) && vcpu->arch.apic->pending_events; }
0
[ "CWE-703" ]
linux
ce40cd3fc7fa40a6119e5fe6c0f2bc0eb4541009
84,569,055,835,578,210,000,000,000,000,000,000,000
4
kvm: x86: fix kvm_apic_has_events to check for NULL pointer Malicious (or egregiously buggy) userspace can trigger it, but it should never happen in normal operation. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
static inline int is_dtext(char ch) { unsigned char uch = (unsigned char) ch; if (is_no_ws_ctl(ch)) return TRUE; if (uch < 33) return FALSE; if ((uch >= 91) && (uch <= 93)) return FALSE; if (uch == 127) return FALSE; return TRUE; }
0
[ "CWE-476" ]
libetpan
1fe8fbc032ccda1db9af66d93016b49c16c1f22d
225,932,784,160,276,530,000,000,000,000,000,000,000
18
Fixed crash #274
bool has_long_data_value() const { return state == LONG_DATA_VALUE; }
0
[ "CWE-617" ]
server
2e7891080667c59ac80f788eef4d59d447595772
140,246,242,213,487,820,000,000,000,000,000,000,000
4
MDEV-25635 Assertion failure when pushing from HAVING into WHERE of view This bug could manifest itself after pushing a where condition over a mergeable derived table / view / CTE DT into a grouping view / derived table / CTE V whose item list contained set functions with constant arguments such as MIN(2), SUM(1) etc....
xfs_inode_supports_dax( struct xfs_inode *ip) { struct xfs_mount *mp = ip->i_mount; /* Only supported on non-reflinked files. */ if (!S_ISREG(VFS_I(ip)->i_mode) || xfs_is_reflink_inode(ip)) return false; /* DAX mount option or DAX iflag must be set. */ if (!(mp->m_flags & XFS_MOUNT_DAX) && !(ip->i_d.di_f...
0
[ "CWE-400", "CWE-399", "CWE-703" ]
linux
1fb254aa983bf190cfd685d40c64a480a9bafaee
124,214,792,402,555,790,000,000,000,000,000,000,000
21
xfs: fix missing ILOCK unlock when xfs_setattr_nonsize fails due to EDQUOT Benjamin Moody reported to Debian that XFS partially wedges when a chgrp fails on account of being out of disk quota. I ran his reproducer script: # adduser dummy # adduser dummy plugdev # dd if=/dev/zero bs=1M count=100 of=test.img # mkfs.x...
static int file_sum(STANZA *s) { BIGNUM *a = NULL, *b = NULL, *sum = NULL, *ret = NULL; BN_ULONG b_word; int st = 0; if (!TEST_ptr(a = getBN(s, "A")) || !TEST_ptr(b = getBN(s, "B")) || !TEST_ptr(sum = getBN(s, "Sum")) || !TEST_ptr(ret = BN_new())) goto err; ...
0
[]
openssl
e9e726506cd2a3fd9c0f12daf8cc1fe934c7dddb
204,022,487,752,875,740,000,000,000,000,000,000,000
108
Fix a carry overflow bug in bn_sqr_comba4/8 for mips 32-bit targets bn_sqr_comba8 does for instance compute a wrong result for the value: a=0x4aaac919 62056c84 fba7334e 1a6be678 022181ba fd3aa878 899b2346 ee210f45 The correct result is: r=0x15c72e32 605a3061 d11b1012 3c187483 6df96999 bd0c22ba d3e7d437 4724a82f 9...
int unit_prepare_exec(Unit *u) { int r; assert(u); /* Prepares everything so that we can fork of a process for this unit */ (void) unit_realize_cgroup(u); if (u->reset_accounting) { (void) unit_reset_cpu_accounting(u); (void) unit_reset_ip_acco...
0
[ "CWE-269" ]
systemd
bf65b7e0c9fc215897b676ab9a7c9d1c688143ba
231,840,015,456,100,930,000,000,000,000,000,000,000
27
core: imply NNP and SUID/SGID restriction for DynamicUser=yes service Let's be safe, rather than sorry. This way DynamicUser=yes services can neither take benefit of, nor create SUID/SGID binaries. Given that DynamicUser= is a recent addition only we should be able to get away with turning this on, even though this i...
lseg_interpt(PG_FUNCTION_ARGS) { LSEG *l1 = PG_GETARG_LSEG_P(0); LSEG *l2 = PG_GETARG_LSEG_P(1); Point *result; result = lseg_interpt_internal(l1, l2); if (!PointerIsValid(result)) PG_RETURN_NULL(); PG_RETURN_POINT_P(result); }
0
[ "CWE-703", "CWE-189" ]
postgres
31400a673325147e1205326008e32135a78b4d8a
31,591,314,383,001,116,000,000,000,000,000,000,000
12
Predict integer overflow to avoid buffer overruns. Several functions, mostly type input functions, calculated an allocation size such that the calculation wrapped to a small positive value when arguments implied a sufficiently-large requirement. Writes past the end of the inadvertent small allocation followed shortly...
base::string16 WebContents::GetTitle() const { return web_contents()->GetTitle(); }
0
[ "CWE-284", "CWE-693" ]
electron
18613925610ba319da7f497b6deed85ad712c59b
23,630,153,729,511,227,000,000,000,000,000,000,000
3
refactor: wire will-navigate up to a navigation throttle instead of OpenURL (#25108) * refactor: wire will-navigate up to a navigation throttle instead of OpenURL (#25065) * refactor: wire will-navigate up to a navigation throttle instead of OpenURL * spec: add test for x-site _top navigation * chore: old cod...
int& pullInt() { if ( nextjsobj == data ) nextjsobj += strlen(data) + 1; // skip namespace int& i = *((int *)nextjsobj); nextjsobj += 4; return i; }
0
[ "CWE-20" ]
mongo
f9817a6cf64bdba8e1e1cef30a798110df746b58
186,224,903,033,784,900,000,000,000,000,000,000,000
7
SERVER-7769 - turn objcheck on by default and use new fast bson validate
static int ib_uverbs_mmap(struct file *filp, struct vm_area_struct *vma) { struct ib_uverbs_file *file = filp->private_data; struct ib_device *ib_dev; int ret = 0; int srcu_key; srcu_key = srcu_read_lock(&file->device->disassociate_srcu); ib_dev = srcu_dereference(file->device->ib_dev, &file->device->disas...
0
[ "CWE-284", "CWE-264" ]
linux
e6bd18f57aad1a2d1ef40e646d03ed0f2515c9e3
118,195,962,400,639,240,000,000,000,000,000,000,000
23
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...
unsigned char yyGet() { char c= *m_ptr++; if (m_echo) *m_cpp_ptr++ = c; return c; }
0
[ "CWE-703" ]
server
39feab3cd31b5414aa9b428eaba915c251ac34a2
62,660,000,645,750,640,000,000,000,000,000,000,000
7
MDEV-26412 Server crash in Item_field::fix_outer_field for INSERT SELECT IF an INSERT/REPLACE SELECT statement contained an ON expression in the top level select and this expression used a subquery with a column reference that could not be resolved then an attempt to resolve this reference as an outer reference caused...
static int ssl3_generate_key_block(SSL *s, unsigned char *km, int num) { EVP_MD_CTX m5; EVP_MD_CTX s1; unsigned char buf[16],smd[SHA_DIGEST_LENGTH]; unsigned char c='A'; unsigned int i,j,k; #ifdef CHARSET_EBCDIC c = os_toascii[c]; /*'A' in ASCII */ #endif k=0; EVP_MD_CTX_init(&m5); EVP_MD_CTX_set_flags(&m5, ...
0
[ "CWE-310" ]
openssl
35a65e814beb899fa1c69a7673a8956c6059dce7
323,106,054,689,344,400,000,000,000,000,000,000,000
55
Make CBC decoding constant time. This patch makes the decoding of SSLv3 and TLS CBC records constant time. Without this, a timing side-channel can be used to build a padding oracle and mount Vaudenay's attack. This patch also disables the stitched AESNI+SHA mode pending a similar fix to that code. In order to be eas...
ref_param_begin_read_collection(gs_param_list * plist, gs_param_name pkey, gs_param_dict * pvalue, gs_param_collection_type_t coll_type) { iparam_list *const iplist = (iparam_list *) plist; iparam_loc loc; bool int_keys = coll_type != 0; in...
0
[]
ghostpdl
bfa6b2ecbe48edc69a7d9d22a12419aed25960b8
117,844,610,645,328,140,000,000,000,000,000,000,000
37
Bug 697548: use the correct param list enumerator When we encountered dictionary in a ref_param_list, we were using the enumerator for the "parent" param_list, rather than the enumerator for the param_list we just created for the dictionary. That parent was usually the stack list enumerator, and caused a segfault. Us...
TSessionData * __fastcall DoSaveSession(TSessionData * SessionData, TSessionData * OriginalSession, bool ForceDialog, TStrings * AdditionalFolders) { bool SavePassword = false; bool * PSavePassword; bool NotRecommendedSavingPassword = !CustomWinConfiguration->UseMasterPassword && !SameText(Ses...
0
[ "CWE-787" ]
winscp
faa96e8144e6925a380f94a97aa382c9427f688d
253,710,230,624,503,450,000,000,000,000,000,000,000
79
Bug 1943: Prevent loading session settings that can lead to remote code execution from handled URLs https://winscp.net/tracker/1943 (cherry picked from commit ec584f5189a856cd79509f754722a6898045c5e0) Source commit: 0f4be408b3f01132b00682da72d925d6c4ee649b
static int nci_set_local_general_bytes(struct nfc_dev *nfc_dev) { struct nci_dev *ndev = nfc_get_drvdata(nfc_dev); struct nci_set_config_param param; int rc; param.val = nfc_get_local_general_bytes(nfc_dev, &param.len); if ((param.val == NULL) || (param.len == 0)) return 0; if (param.len > NFC_MAX_GT_LEN) r...
0
[]
linux
48b71a9e66c2eab60564b1b1c85f4928ed04e406
231,240,627,095,070,980,000,000,000,000,000,000,000
25
NFC: add NCI_UNREG flag to eliminate the race There are two sites that calls queue_work() after the destroy_workqueue() and lead to possible UAF. The first site is nci_send_cmd(), which can happen after the nci_close_device as below nfcmrvl_nci_unregister_dev | nfc_genl_dev_up nci_close_device | f...
static int kvm_vm_ioctl_set_pit(struct kvm *kvm, struct kvm_pit_state *ps) { mutex_lock(&kvm->arch.vpit->pit_state.lock); memcpy(&kvm->arch.vpit->pit_state, ps, sizeof(struct kvm_pit_state)); kvm_pit_load_count(kvm, 0, ps->channels[0].count, 0); mutex_unlock(&kvm->arch.vpit->pit_state.lock); return 0; }
1
[ "CWE-369" ]
linux
0185604c2d82c560dab2f2933a18f797e74ab5a8
9,863,473,026,991,116,000,000,000,000,000,000,000
8
KVM: x86: Reload pit counters for all channels when restoring state Currently if userspace restores the pit counters with a count of 0 on channels 1 or 2 and the guest attempts to read the count on those channels, then KVM will perform a mod of 0 and crash. This will ensure that 0 values are converted to 65536 as per...
_gnutls_server_select_suite(gnutls_session_t session, uint8_t * data, unsigned int datalen) { int ret; unsigned int i, j, cipher_suites_size; size_t pk_algos_size; uint8_t cipher_suites[MAX_CIPHERSUITE_SIZE]; int retval; gnutls_pk_algorithm_t pk_algos[MAX_ALGOS]; /* will hold the pk algorithms * su...
0
[ "CWE-310" ]
gnutls
20a98e817713764b9df5306286091df1b61190d9
149,215,112,424,047,160,000,000,000,000,000,000,000
184
handshake: check inappropriate fallback against the configured max version That allows to operate on a server which is explicitly configured to utilize earlier than TLS 1.2 versions.
explicit LowerBoundOp(OpKernelConstruction* ctx) : OpKernel(ctx) {}
0
[ "CWE-125", "CWE-369" ]
tensorflow
42459e4273c2e47a3232cc16c4f4fff3b3a35c38
63,016,675,381,232,960,000,000,000,000,000,000,000
1
Prevent CHECK-fail/heap OOB in UpperBound and LowerBound PiperOrigin-RevId: 387738073 Change-Id: Iee74de95ddad18440d052a75a5a1cb67544f490a
static double mp_display_memory(_cimg_math_parser& mp) { cimg::unused(mp); std::fputc('\n',cimg::output()); CImg<charT> title(128); cimg_snprintf(title,title._width,"%s (%u)","[" cimg_appname "_math_parser] Memory snapshot",mp.mem._width); mp.mem.display(title); ret...
0
[ "CWE-770" ]
cimg
619cb58dd90b4e03ac68286c70ed98acbefd1c90
119,873,709,299,945,060,000,000,000,000,000,000,000
8
CImg<>::load_bmp() and CImg<>::load_pandore(): Check that dimensions encoded in file does not exceed file size.
void PackLinuxElf32x86::defineSymbols(Filter const *const ft) { PackLinuxElf32::defineSymbols(ft); if (0x80==(ft->id & 0xF0)) { int const mru = ft->n_mru ? 1+ ft->n_mru : 0; if (mru && mru!=256) { unsigned const is_pwr2 = (0==((mru -1) & mru)); linker->defineSymbol("NMRU...
0
[ "CWE-476" ]
upx
ef336dbcc6dc8344482f8cf6c909ae96c3286317
320,173,892,350,411,000,000,000,000,000,000,000,000
12
Protect against bad crafted input. https://github.com/upx/upx/issues/128 modified: p_lx_elf.cpp
format_SET_MPLS_TC(const struct ofpact_mpls_tc *a, struct ds *s) { ds_put_format(s, "%sset_mpls_ttl(%s%"PRIu8"%s)%s", colors.paren, colors.end, a->tc, colors.paren, colors.end); }
0
[ "CWE-125" ]
ovs
9237a63c47bd314b807cda0bd2216264e82edbe8
138,671,545,123,811,900,000,000,000,000,000,000,000
6
ofp-actions: Avoid buffer overread in BUNDLE action decoding. Reported-at: https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=9052 Signed-off-by: Ben Pfaff <blp@ovn.org> Acked-by: Justin Pettit <jpettit@ovn.org>
static void rt_add_uncached_list(struct rtable *rt) { spin_lock_bh(&rt_uncached_lock); list_add_tail(&rt->rt_uncached, &rt_uncached_list); spin_unlock_bh(&rt_uncached_lock); }
0
[ "CWE-17" ]
linux
df4d92549f23e1c037e83323aff58a21b3de7fe0
115,984,462,981,674,450,000,000,000,000,000,000,000
6
ipv4: try to cache dst_entries which would cause a redirect Not caching dst_entries which cause redirects could be exploited by hosts on the same subnet, causing a severe DoS attack. This effect aggravated since commit f88649721268999 ("ipv4: fix dst race in sk_dst_get()"). Lookups causing redirects will be allocated...
static int sco_sock_getsockopt(struct socket *sock, int level, int optname, char __user *optval, int __user *optlen) { struct sock *sk = sock->sk; int len, err = 0; struct bt_voice voice; BT_DBG("sk %p", sk); if (level == SOL_SCO) return sco_sock_getsockopt_old(sock, optname, optval, optlen); if (g...
0
[ "CWE-200" ]
net
5233252fce714053f0151680933571a2da9cbfb4
316,538,053,975,015,900,000,000,000,000,000,000,000
48
bluetooth: Validate socket address length in sco_sock_bind(). Signed-off-by: David S. Miller <davem@davemloft.net>
QByteArray CtcpParser::lowLevelQuote(const QByteArray &message) { QByteArray quotedMessage = message; QHash<QByteArray, QByteArray> quoteHash = _ctcpMDequoteHash; QByteArray MQUOTE = QByteArray("\020"); quoteHash.remove(MQUOTE + MQUOTE); quotedMessage.replace(MQUOTE, MQUOTE + MQUOTE); QHash<QB...
0
[ "CWE-399" ]
quassel
b5e38970ffd55e2dd9f706ce75af9a8d7730b1b8
55,215,027,162,064,150,000,000,000,000,000,000,000
16
Improve the message-splitting algorithm for PRIVMSG and CTCP This introduces a new message splitting algorithm based on QTextBoundaryFinder. It works by first starting with the entire message to be sent, encoding it, and checking to see if it is over the maximum message length. If it is, it uses QTBF to find the wor...
close_attr_file(ATTR_FILE_T * attr_file) { if (attr_file == NULL) { tsk_error_set_errno(TSK_ERR_FS_READ); tsk_error_set_errstr("close_attr_file: NULL attr_file arg"); return 1; } if (attr_file->file != NULL) { tsk_fs_file_close(attr_file->file); attr_file->file = NUL...
0
[ "CWE-190", "CWE-284" ]
sleuthkit
114cd3d0aac8bd1aeaf4b33840feb0163d342d5b
253,706,022,957,262,800,000,000,000,000,000,000,000
21
hfs: fix keylen check in hfs_cat_traverse() If key->key_len is 65535, calculating "uint16_t keylen' would cause an overflow: uint16_t keylen; ... keylen = 2 + tsk_getu16(hfs->fs_info.endian, key->key_len) so the code bypasses the sanity check "if (keylen > nodesize)" which results in crash later: ./too...
void __unmap_hugepage_range(struct vm_area_struct *vma, unsigned long start, unsigned long end, struct page *ref_page) { struct mm_struct *mm = vma->vm_mm; unsigned long address; pte_t *ptep; pte_t pte; struct page *page; struct page *tmp; struct hstate *h = hstate_vma(vma); unsigned long sz = huge_page_...
0
[ "CWE-399" ]
linux
c50ac050811d6485616a193eb0f37bfbd191cc89
129,813,012,802,492,480,000,000,000,000,000,000,000
79
hugetlb: fix resv_map leak in error path When called for anonymous (non-shared) mappings, hugetlb_reserve_pages() does a resv_map_alloc(). It depends on code in hugetlbfs's vm_ops->close() to release that allocation. However, in the mmap() failure path, we do a plain unmap_region() without the remove_vma() which act...
void CDCCBounce::ReachedMaxBuffer() { DEBUG(GetSockName() << " == ReachedMaxBuffer()"); CString sType = (m_bIsChat) ? "Chat" : "Xfer"; m_pModule->PutModule("DCC " + sType + " Bounce (" + m_sRemoteNick + "): Too long line received"); Close(); }
0
[ "CWE-399" ]
znc
11508aa72efab4fad0dbd8292b9614d9371b20a9
8,345,214,381,847,137,000,000,000,000,000,000,000
8
Fix crash in bouncedcc module. It happens when DCC RESUME is received. Affected ZNC versions: 0.200, 0.202. Thanks to howeyc for reporting this and providing the patch.
int tls_global_version_check(char const *acknowledged) { uint64_t v; if ((strcmp(acknowledged, libssl_defects[0].id) != 0) && (strcmp(acknowledged, "yes") != 0)) { bool bad = false; size_t i; /* Check for bad versions */ v = (uint64_t) SSLeay(); for (i = 0; i < (sizeof(libssl_defects) / sizeof(*libssl_de...
0
[ "CWE-295" ]
freeradius-server
874b39451702338389260edbfc52b381b20352ec
116,774,863,685,010,180,000,000,000,000,000,000,000
33
Set X509_V_FLAG_CRL_CHECK_ALL
static const char *cmd_content_injection(cmd_parms *cmd, void *_dcfg, int flag) { directory_config *dcfg = (directory_config *)_dcfg; if (dcfg == NULL) return NULL; dcfg->content_injection_enabled = flag; return NULL; }
0
[ "CWE-20", "CWE-611" ]
ModSecurity
d4d80b38aa85eccb26e3c61b04d16e8ca5de76fe
334,888,076,953,503,400,000,000,000,000,000,000,000
7
Added SecXmlExternalEntity
realpath_stk (const char *name, char *resolved, struct scratch_buffer *rname_buf) { char *dest; char const *start; char const *end; int num_links = 0; if (name == NULL) { /* As per Single Unix Specification V2 we must return an error if either parameter is a null pointer. We...
1
[ "CWE-125" ]
glibc
ee8d5e33adb284601c00c94687bc907e10aec9bb
137,106,727,751,924,430,000,000,000,000,000,000,000
220
realpath: Set errno to ENAMETOOLONG for result larger than PATH_MAX [BZ #28770] realpath returns an allocated string when the result exceeds PATH_MAX, which is unexpected when its second argument is not NULL. This results in the second argument (resolved) being uninitialized and also results in a memory leak since th...
check_constrained_delegation(krb5_context context, krb5_kdc_configuration *config, HDB *clientdb, hdb_entry_ex *client, hdb_entry_ex *server, krb5_const_principal target) { const HDB_Ext_Constrained_delegation_acl *acl; krb5_error_code ret; size_t i; /* * co...
0
[ "CWE-476" ]
heimdal
04171147948d0a3636bc6374181926f0fb2ec83a
180,357,670,498,229,980,000,000,000,000,000,000,000
51
kdc: validate sname in TGS-REQ In tgs_build_reply(), validate the server name in the TGS-REQ is present before dereferencing.
static int gfs2_ri_update(struct gfs2_inode *ip) { struct gfs2_sbd *sdp = GFS2_SB(&ip->i_inode); int error; do { error = read_rindex_entry(ip); } while (error == 0); if (error < 0) return error; set_rgrp_preferences(sdp); sdp->sd_rindex_uptodate = 1; return 0; }
0
[ "CWE-416" ]
linux
36e4ad0316c017d5b271378ed9a1c9a4b77fab5f
31,072,082,918,588,020,000,000,000,000,000,000,000
17
GFS2: don't set rgrp gl_object until it's inserted into rgrp tree Before this patch, function read_rindex_entry would set a rgrp glock's gl_object pointer to itself before inserting the rgrp into the rgrp rbtree. The problem is: if another process was also reading the rgrp in, and had already inserted its newly create...
void Magick::Image::reduceNoise(const size_t order_) { MagickCore::Image *newImage; GetPPException; newImage=StatisticImage(constImage(),NonpeakStatistic,order_, order_,exceptionInfo); replaceImage(newImage); ThrowImageException; }
0
[ "CWE-416" ]
ImageMagick
8c35502217c1879cb8257c617007282eee3fe1cc
144,086,809,886,721,710,000,000,000,000,000,000,000
11
Added missing return to avoid use after free.
void smtp_server_connection_uncork(struct smtp_server_connection *conn) { conn->corked = FALSE; if (conn->conn.output != NULL) { if (o_stream_uncork_flush(conn->conn.output) < 0) { smtp_server_connection_handle_output_error(conn); return; } smtp_server_connection_trigger_output(conn); } }
0
[ "CWE-77" ]
core
321c339756f9b2b98fb7326359d1333adebb5295
111,408,513,055,547,070,000,000,000,000,000,000,000
11
lib-smtp: smtp-server-connection - Fix STARTTLS command injection vulnerability. The input handler kept reading more commands even though the input was locked by the STARTTLS command, thereby causing it to read the command pipelined beyond STARTTLS. This causes a STARTTLS command injection vulerability.
template<typename to> float* _object3dtoCImg3d(const CImgList<to>& opacities, float *ptrd) const { cimglist_for(opacities,o) { const CImg<to>& opacity = opacities[o]; const to *ptro = opacity._data; if (opacity.size()==1) *(ptrd++) = (float)*ptro; else { *(ptrd++)...
0
[ "CWE-125" ]
CImg
10af1e8c1ad2a58a0a3342a856bae63e8f257abb
262,485,477,372,816,440,000,000,000,000,000,000,000
23
Fix other issues in 'CImg<T>::load_bmp()'.
static int table_lookup(const struct annotate_attrib *table, const char *name) { for ( ; table->name ; table++) { if (!strcasecmp(table->name, name)) return table->entry; } return -1; }
0
[ "CWE-732" ]
cyrus-imapd
621f9e41465b521399f691c241181300fab55995
312,932,764,110,203,920,000,000,000,000,000,000,000
9
annotate: don't allow everyone to write shared server entries
static void nsc_encode_argb_to_aycocg_sse2(NSC_CONTEXT* context, const BYTE* data, UINT32 scanline) { UINT16 x; UINT16 y; UINT16 rw; BYTE ccl; const BYTE* src; BYTE* yplane = NULL; BYTE* coplane = NULL; BYTE* cgplane = NULL; BYTE* aplane = NULL; __m128i r_val; __m128i g_val; __m128i b_val; __m128i ...
0
[ "CWE-200", "CWE-787" ]
FreeRDP
d1112c279bd1a327e8e4d0b5f371458bf2579659
35,917,953,833,920,333,000,000,000,000,000,000,000
298
Fixed CVE-2018-8788 Thanks to Eyal Itkin from Check Point Software Technologies.
static MagickBooleanType MonitorProgress(const char *text, const MagickOffsetType offset,const MagickSizeType extent, void *wand_unused(client_data)) { char message[MagickPathExtent], tag[MagickPathExtent]; const char *locale_message; char *p; magick_unreferenced(client_data); if ((ext...
0
[ "CWE-617" ]
ImageMagick
716496e6df0add89e9679d6da9c0afca814cfe49
263,326,485,935,262,150,000,000,000,000,000,000,000
41
do not attempt to write a null image list (thanks to Vinay Rohila)
_outMergeAppend(StringInfo str, const MergeAppend *node) { int i; WRITE_NODE_TYPE("MERGEAPPEND"); _outPlanInfo(str, (const Plan *) node); WRITE_NODE_FIELD(mergeplans); WRITE_INT_FIELD(numCols); appendStringInfoString(str, " :sortColIdx"); for (i = 0; i < node->numCols; i++) appendStringInfo(str, " %d", ...
0
[ "CWE-362" ]
postgres
5f173040e324f6c2eebb90d86cf1b0cdb5890f0a
291,603,910,383,232,870,000,000,000,000,000,000,000
28
Avoid repeated name lookups during table and index DDL. If the name lookups come to different conclusions due to concurrent activity, we might perform some parts of the DDL on a different table than other parts. At least in the case of CREATE INDEX, this can be used to cause the permissions checks to be performed aga...
sig_handler endprog(int signal_number MY_ATTRIBUTE((unused))) { interrupted=1; }
0
[ "CWE-319" ]
mysql-server
0002e1380d5f8c113b6bce91f2cf3f75136fd7c7
139,641,302,820,369,900,000,000,000,000,000,000,000
4
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)
static int zr364xx_vidioc_qbuf(struct file *file, void *priv, struct v4l2_buffer *p) { int rc; struct zr364xx_camera *cam = video_drvdata(file); _DBG("%s\n", __func__); if (cam->owner && cam->owner != priv) return -EBUSY; rc = videobuf_qbuf(&cam->vb_vidq, p); return rc; }
0
[ "CWE-476" ]
linux
5d2e73a5f80a5b5aff3caf1ec6d39b5b3f54b26e
12,006,360,270,602,178,000,000,000,000,000,000,000
12
media: usb:zr364xx:Fix KASAN:null-ptr-deref Read in zr364xx_vidioc_querycap SyzKaller hit the null pointer deref while reading from uninitialized udev->product in zr364xx_vidioc_querycap(). ================================================================== BUG: KASAN: null-ptr-deref in read_word_at_a_time+0xe/0x20 in...
static int __io_destroy_buffers(int id, void *p, void *data) { struct io_ring_ctx *ctx = data; struct io_buffer *buf = p; __io_remove_buffers(ctx, buf, id, -1U); return 0; }
0
[]
linux
0f2122045b946241a9e549c2a76cea54fa58a7ff
111,398,458,721,865,450,000,000,000,000,000,000,000
8
io_uring: don't rely on weak ->files references Grab actual references to the files_struct. To avoid circular references issues due to this, we add a per-task note that keeps track of what io_uring contexts a task has used. When the tasks execs or exits its assigned files, we cancel requests based on this tracking. W...
static void vp8_get_quants(VP8Context *s) { VP56RangeCoder *c = &s->c; int i, base_qi; int yac_qi = vp8_rac_get_uint(c, 7); int ydc_delta = vp8_rac_get_sint(c, 4); int y2dc_delta = vp8_rac_get_sint(c, 4); int y2ac_delta = vp8_rac_get_sint(c, 4); int uvdc_delta = vp8_rac_get_sint(c, 4);...
0
[ "CWE-119", "CWE-787" ]
FFmpeg
6b5d3fb26fb4be48e4966e4b1d97c2165538d4ef
202,561,374,949,570,000,000,000,000,000,000,000,000
32
avcodec/webp: Always set pix_fmt Fixes: out of array access Fixes: 1434/clusterfuzz-testcase-minimized-6314998085189632 Fixes: 1435/clusterfuzz-testcase-minimized-6483783723253760 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/targets/ffmpeg Reviewed-by: "Ronald S. Bultje" <rsbult...
STREAM* rdp_pdu_init(rdpRdp* rdp) { STREAM* s; s = transport_send_stream_init(rdp->transport, 2048); stream_seek(s, RDP_PACKET_HEADER_MAX_LENGTH); rdp_security_stream_init(rdp, s); stream_seek(s, RDP_SHARE_CONTROL_HEADER_LENGTH); return s; }
0
[ "CWE-476" ]
FreeRDP
7d58aac24fe20ffaad7bd9b40c9ddf457c1b06e7
200,717,889,753,317,840,000,000,000,000,000,000,000
9
security: add a NULL pointer check to fix a server crash.
void RWFunction::DEREncode(BufferedTransformation &bt) const { DERSequenceEncoder seq(bt); m_n.DEREncode(seq); seq.MessageEnd(); }
0
[ "CWE-200", "CWE-399" ]
cryptopp
9425e16437439e68c7d96abef922167d68fafaff
306,254,073,227,412,550,000,000,000,000,000,000,000
6
Fix for CVE-2015-2141. Thanks to Evgeny Sidorov for reporting. Squaring to satisfy Jacobi requirements suggested by JPM.
crypto_ident( struct peer *peer /* peer structure pointer */ ) { char filename[MAXFILENAME]; const char * scheme_name; u_int scheme_id; /* * We come here after the group trusted host has been found; its * name defines the group name. Search the key cache for all * keys matching the same group name in ord...
0
[ "CWE-20" ]
ntp
c4cd4aaf418f57f7225708a93bf48afb2bc9c1da
262,121,595,694,366,740,000,000,000,000,000,000,000
41
CVE-2014-9297
static int exif_scan_JPEG_header(image_info_type *ImageInfo) { int section, sn; int marker = 0, last_marker = M_PSEUDO, comment_correction=1; unsigned int ll, lh; uchar *Data; size_t fpos, size, got, itemlen; jpeg_sof_info sof_info; for(section=0;;section++) { #ifdef EXIF_DEBUG fpos = php_stream_tell(ImageIn...
0
[ "CWE-125" ]
php-src
887a7b571407f7a49a5e7cf1e612d21ef83fedb4
221,898,206,365,258,670,000,000,000,000,000,000,000
164
Fixed bug #77831 - Heap-buffer-overflow in exif_iif_add_value in EXIF
ofputil_match_to_ofp10_match(const struct match *match, struct ofp10_match *ofmatch) { const struct flow_wildcards *wc = &match->wc; uint32_t ofpfw; /* Figure out most OpenFlow wildcards. */ ofpfw = 0; if (!wc->masks.in_port.ofp_port) { ofpfw |= OFPFW10_IN_PORT;...
0
[ "CWE-617", "CWE-703" ]
ovs
4af6da3b275b764b1afe194df6499b33d2bf4cde
209,398,982,884,081,500,000,000,000,000,000,000,000
74
ofp-group: Don't assert-fail decoding bad OF1.5 group mod type or command. When decoding a group mod, the current code validates the group type and command after the whole group mod has been decoded. The OF1.5 decoder, however, tries to use the type and command earlier, when it might still be invalid. This caused an...
ext4_ext_search_right(struct inode *inode, struct ext4_ext_path *path, ext4_lblk_t *logical, ext4_fsblk_t *phys) { struct buffer_head *bh = NULL; struct ext4_extent_header *eh; struct ext4_extent_idx *ix; struct ext4_extent *ex; ext4_fsblk_t block; int depth; /* Note, NOT eh_depth; depth from top of tree */ i...
0
[ "CWE-703" ]
linux
744692dc059845b2a3022119871846e74d4f6e11
329,046,612,171,626,450,000,000,000,000,000,000,000
90
ext4: use ext4_get_block_write in buffer write Allocate uninitialized extent before ext4 buffer write and convert the extent to initialized after io completes. The purpose is to make sure an extent can only be marked initialized after it has been written with new data so we can safely drop the i_mutex lock in ext4 DIO...
verbose_enter_scroll(void) { if (*p_vfile != NUL) ++msg_silent; else // always scroll up, don't overwrite msg_scroll = TRUE; }
0
[ "CWE-416" ]
vim
9f1a39a5d1cd7989ada2d1cb32f97d84360e050f
279,336,534,507,881,650,000,000,000,000,000,000,000
8
patch 8.2.4040: keeping track of allocated lines is too complicated Problem: Keeping track of allocated lines in user functions is too complicated. Solution: Instead of freeing individual lines keep them all until the end.
static inline void vpid_sync_context(struct vcpu_vmx *vmx) { if (cpu_has_vmx_invvpid_single()) vpid_sync_vcpu_single(vmx); else vpid_sync_vcpu_global(); }
0
[ "CWE-400" ]
linux-2.6
9581d442b9058d3699b4be568b6e5eae38a41493
118,102,809,611,555,290,000,000,000,000,000,000,000
7
KVM: Fix fs/gs reload oops with invalid ldt kvm reloads the host's fs and gs blindly, however the underlying segment descriptors may be invalid due to the user modifying the ldt after loading them. Fix by using the safe accessors (loadsegment() and load_gs_index()) instead of home grown unsafe versions. This is CVE-...
int TC_LOG_MMAP::log_xid(THD *thd, my_xid xid) { int err; PAGE *p; ulong cookie; mysql_mutex_lock(&LOCK_active); /* if active page is full - just wait... frankly speaking, active->free here accessed outside of mutex protection, but it's safe, because it only means we may miss an unlog() for ...
0
[ "CWE-264" ]
mysql-server
48bd8b16fe382be302c6f0b45931be5aa6f29a0e
169,909,689,502,311,160,000,000,000,000,000,000,000
74
Bug#24388753: PRIVILEGE ESCALATION USING MYSQLD_SAFE [This is the 5.5/5.6 version of the bugfix]. The problem was that it was possible to write log files ending in .ini/.cnf that later could be parsed as an options file. This made it possible for users to specify startup options without the permissions to do so. Thi...
static void show_shortstats(struct diffstat_t* data, struct diff_options *options) { int i, adds = 0, dels = 0, total_files = data->nr; if (data->nr == 0) return; for (i = 0; i < data->nr; i++) { if (!data->files[i]->is_binary && !data->files[i]->is_unmerged) { int added = data->files[i]->added; in...
0
[ "CWE-119" ]
git
fd55a19eb1d49ae54008d932a65f79cd6fda45c9
208,469,053,669,334,200,000,000,000,000,000,000,000
24
Fix buffer overflow in git diff If PATH_MAX on your system is smaller than a path stored, it may cause buffer overflow and stack corruption in diff_addremove() and diff_change() functions when running git-diff Signed-off-by: Dmitry Potapov <dpotapov@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
setup_sigcontext(struct sigcontext __user *sc, struct pt_regs *regs, int in_syscall) { unsigned long flags = 0; long err = 0; if (on_sig_stack((unsigned long) sc)) flags |= PARISC_SC_FLAG_ONSTACK; if (in_syscall) { flags |= PARISC_SC_FLAG_IN_SYSCALL; /* regs->iaoq is undefined in the syscall return path ...
0
[]
linux-2.6
ee18d64c1f632043a02e6f5ba5e045bb26a5465f
44,513,219,650,305,190,000,000,000,000,000,000,000
32
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...
int accept_conn(AsyncConnectionRef conn) { Mutex::Locker l(lock); auto it = conns.find(conn->peer_addr); if (it != conns.end()) { AsyncConnectionRef existing = it->second; // lazy delete, see "deleted_conns" // If conn already in, we will return 0 Mutex::Locker l(deleted_lock); ...
0
[ "CWE-287", "CWE-284" ]
ceph
5ead97120e07054d80623dada90a5cc764c28468
134,767,727,743,351,120,000,000,000,000,000,000,000
21
auth/cephx: add authorizer challenge Allow the accepting side of a connection to reject an initial authorizer with a random challenge. The connecting side then has to respond with an updated authorizer proving they are able to decrypt the service's challenge and that the new authorizer was produced for this specific ...
void Set(const CString& sLine) { const CString sVar = sLine.Token(1).AsLower(); CString sUserName = sLine.Token(2); CString sValue = sLine.Token(3, true); if (sValue.empty()) { PutModule(t_s("Usage: Set <variable> <username> <value>")); return; } ...
1
[ "CWE-20" ]
znc
64613bc8b6b4adf1e32231f9844d99cd512b8973
226,541,701,754,489,900,000,000,000,000,000,000,000
202
Don't crash if user specified invalid encoding. This is CVE-2019-9917
PJ_DEF(pj_status_t) pj_stun_errcode_attr_create(pj_pool_t *pool, int err_code, const pj_str_t *err_reason, pj_stun_errcode_attr **p_attr) { pj_stun_errcode_attr *attr; char err_buf[80]; pj_str_t str; PJ_ASSERT_RETURN(pool && err_code && p_attr, PJ_EINVAL); if (err_reason == NULL)...
0
[ "CWE-191" ]
pjproject
15663e3f37091069b8c98a7fce680dc04bc8e865
317,196,018,781,416,700,000,000,000,000,000,000,000
30
Merge pull request from GHSA-2qpg-f6wf-w984
PHP_LIBXML_API xmlNodePtr php_libxml_import_node(zval *object TSRMLS_DC) { zend_class_entry *ce = NULL; xmlNodePtr node = NULL; php_libxml_func_handler *export_hnd; if (object->type == IS_OBJECT) { ce = Z_OBJCE_P(object); while (ce->parent != NULL) { ce = ce->parent; } if (zend_hash_find(&php_libxml_exp...
0
[ "CWE-200" ]
php-src
8e76d0404b7f664ee6719fd98f0483f0ac4669d6
34,639,576,434,487,100,000,000,000,000,000,000,000
17
Fixed external entity loading
static void nfs4_proc_unlink_setup(struct rpc_message *msg, struct inode *dir) { struct nfs_server *server = NFS_SERVER(dir); struct nfs_removeargs *args = msg->rpc_argp; struct nfs_removeres *res = msg->rpc_resp; args->bitmask = server->cache_consistency_bitmask; res->server = server; msg->rpc_proc = &nfs4_proc...
0
[ "CWE-703", "CWE-189" ]
linux
20e0fa98b751facf9a1101edaefbc19c82616a68
70,025,701,552,113,020,000,000,000,000,000,000,000
11
Fix length of buffer copied in __nfs4_get_acl_uncached _copy_from_pages() used to copy data from the temporary buffer to the user passed buffer is passed the wrong size parameter when copying data. res.acl_len contains both the bitmap and acl lenghts while acl_len contains the acl length after adjusting for the bitmap...
static PyObject* authGSSClientInit(PyObject* self, PyObject* args, PyObject* keywds) { const char *service = NULL; const char *principal = NULL; gss_client_state *state; PyObject *pystate; static char *kwlist[] = {"service", "principal", "gssflags", NULL}; long int gss_flags = GSS_C_MUTUAL_FLAG ...
0
[ "CWE-287" ]
pykerberos
02d13860b25fab58e739f0e000bed0067b7c6f9c
140,992,692,702,250,400,000,000,000,000,000,000,000
26
adding KDC verification support (enabled by default)
void Scan::StartParseScan(class ByteStream *io,class Checksum *chk,class BufferCtrl *ctrl) { // // The residual scan has the parser set here already. if (m_pParser == NULL) CreateParser(); ctrl->PrepareForDecoding(); m_pParser->StartParseScan(io,chk,ctrl); }
0
[ "CWE-476" ]
libjpeg
ea6315164b1649ff932a396b7600eac4bffcfaba
268,474,133,566,361,470,000,000,000,000,000,000,000
10
Added a check whether all components in a scan are actually present.
static int lo_do_open(struct lo_data *lo, struct lo_inode *inode, int existing_fd, struct fuse_file_info *fi) { ssize_t fh; int fd = existing_fd; int err; bool cap_fsetid_dropped = false; bool kill_suidgid = lo->killpriv_v2 && fi->kill_priv; update_open_flags(lo->writeback...
0
[ "CWE-281" ]
qemu
e586edcb410543768ef009eaa22a2d9dd4a53846
24,396,183,435,160,236,000,000,000,000,000,000,000
54
virtiofs: drop remapped security.capability xattr as needed On Linux, the 'security.capability' xattr holds a set of capabilities that can change when an executable is run, giving a limited form of privilege escalation to those programs that the writer of the file deemed worthy. Any write causes the 'security.capabil...
static struct sock *tcp_v4_hnd_req(struct sock *sk, struct sk_buff *skb) { struct tcphdr *th = tcp_hdr(skb); const struct iphdr *iph = ip_hdr(skb); struct sock *nsk; struct request_sock **prev; /* Find possible connection requests. */ struct request_sock *req = inet_csk_search_req(sk, &prev, th->source, ...
0
[ "CWE-362" ]
linux-2.6
f6d8bd051c391c1c0458a30b2a7abcd939329259
295,189,927,588,618,800,000,000,000,000,000,000,000
30
inet: add RCU protection to inet->opt We lack proper synchronization to manipulate inet->opt ip_options Problem is ip_make_skb() calls ip_setup_cork() and ip_setup_cork() possibly makes a copy of ipc->opt (struct ip_options), without any protection against another thread manipulating inet->opt. Another thread can ch...
pdf14_ctx_new(gs_int_rect *rect, int n_chan, bool additive, gx_device *dev) { pdf14_ctx *result; pdf14_buf *buf; gs_memory_t *memory = dev->memory; bool has_tags = dev->graphics_type_tag & GS_DEVICE_ENCODES_TAGS; pdf14_device *pdev = (pdf14_device *)dev; result = gs_alloc_struct(memory, pdf14_c...
0
[ "CWE-416" ]
ghostpdl
90fd0c7ca3efc1ddff64a86f4104b13b3ac969eb
29,062,021,340,116,606,000,000,000,000,000,000,000
40
Bug 697456. Dont create new ctx when pdf14 device reenabled This bug had yet another weird case where the user created a file that pushed the pdf14 device twice. We were in that case, creating a new ctx and blowing away the original one with out proper clean up. To avoid, only create a new one when we need it.
mt76_dma_rx_fill(struct mt76_dev *dev, struct mt76_queue *q) { dma_addr_t addr; void *buf; int frames = 0; int len = SKB_WITH_OVERHEAD(q->buf_size); int offset = q->buf_offset; spin_lock_bh(&q->lock); while (q->queued < q->ndesc - 1) { struct mt76_queue_buf qbuf; buf = page_frag_alloc(&q->rx_page, q->buf_...
0
[ "CWE-120", "CWE-787" ]
linux
b102f0c522cf668c8382c56a4f771b37d011cda2
251,061,346,407,375,630,000,000,000,000,000,000,000
36
mt76: fix array overflow on receiving too many fragments for a packet If the hardware receives an oversized packet with too many rx fragments, skb_shinfo(skb)->frags can overflow and corrupt memory of adjacent pages. This becomes especially visible if it corrupts the freelist pointer of a slab page. Cc: stable@vger.k...
int Curl_fnmatch(void *ptr, const char *pattern, const char *string) { (void)ptr; /* the argument is specified by the curl_fnmatch_callback prototype, but not used by Curl_fnmatch() */ if(!pattern || !string) { return CURL_FNMATCH_FAIL; } return loop((unsigned char *)pattern, (unsigned char ...
0
[ "CWE-125" ]
curl
0b664ba968437715819bfe4c7ada5679d16ebbc3
158,144,012,624,096,130,000,000,000,000,000,000,000
9
wildcardmatch: fix heap buffer overflow in setcharset The code would previous read beyond the end of the pattern string if the match pattern ends with an open bracket when the default pattern matching function is used. Detected by OSS-Fuzz: https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=4161 CVE-2017-8817 Bu...