func
string
target
int64
cwe
list
project
string
commit_id
string
hash
float64
size
int64
message
string
int save_in_field(Field *field, bool no_conversions) { field->set_notnull(); return field->store_hex_hybrid(str_value.ptr(), str_value.length()); }
0
[ "CWE-617" ]
server
2e7891080667c59ac80f788eef4d59d447595772
326,047,647,818,030,050,000,000,000,000,000,000,000
5
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....
printInfo(ev::sig &watcher, int revents) { cerr << "---------- Begin LoggingAgent status ----------\n"; loggingServer->dump(cerr); cerr.flush(); cerr << "---------- End LoggingAgent status ----------\n"; }
0
[ "CWE-59" ]
passenger
9dda49f4a3ebe9bafc48da1bd45799f30ce19566
272,209,930,183,734,620,000,000,000,000,000,000,000
6
Fixed a problem with graceful web server restarts. This problem was introduced in 4.0.6 during the attempt to fix issue #910.
static inline void control_tx_irq_watermark(struct cx23885_dev *dev, enum tx_fifo_watermark level) { cx23888_ir_and_or4(dev, CX23888_IR_CNTRL_REG, ~CNTRL_TIC, level); }
0
[ "CWE-400", "CWE-401" ]
linux
a7b2df76b42bdd026e3106cf2ba97db41345a177
62,536,058,320,782,240,000,000,000,000,000,000,000
5
media: rc: prevent memory leak in cx23888_ir_probe In cx23888_ir_probe if kfifo_alloc fails the allocated memory for state should be released. Signed-off-by: Navid Emamdoost <navid.emamdoost@gmail.com> Signed-off-by: Sean Young <sean@mess.org> Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
Next_select_func setup_end_select_func(JOIN *join, JOIN_TAB *tab) { TMP_TABLE_PARAM *tmp_tbl= tab ? tab->tmp_table_param : &join->tmp_table_param; /* Choose method for presenting result to user. Use end_send_group if the query requires grouping (has a GROUP BY clause and/or one or more aggregate fu...
0
[]
server
ff77a09bda884fe6bf3917eb29b9d3a2f53f919b
75,060,888,505,972,080,000,000,000,000,000,000,000
18
MDEV-22464 Server crash on UPDATE with nested subquery Uninitialized ref_pointer_array[] because setup_fields() got empty fields list. mysql_multi_update() for some reason does that by substituting the fields list with empty total_list for the mysql_select() call (looks like wrong merge since total_list is not used a...
static void proc_set_tty(struct tty_struct *tty) { spin_lock_irq(&current->sighand->siglock); __proc_set_tty(tty); spin_unlock_irq(&current->sighand->siglock); }
0
[ "CWE-200", "CWE-362" ]
linux
5c17c861a357e9458001f021a7afa7aab9937439
231,099,748,773,509,550,000,000,000,000,000,000,000
6
tty: Fix unsafe ldisc reference via ioctl(TIOCGETD) ioctl(TIOCGETD) retrieves the line discipline id directly from the ldisc because the line discipline id (c_line) in termios is untrustworthy; userspace may have set termios via ioctl(TCSETS*) without actually changing the line discipline via ioctl(TIOCSETD). However...
void sock_kfree_s(struct sock *sk, void *mem, int size) { __sock_kfree_s(sk, mem, size, false); }
0
[ "CWE-119", "CWE-787" ]
linux
b98b0bc8c431e3ceb4b26b0dfc8db509518fb290
104,686,827,137,613,100,000,000,000,000,000,000,000
4
net: avoid signed overflows for SO_{SND|RCV}BUFFORCE CAP_NET_ADMIN users should not be allowed to set negative sk_sndbuf or sk_rcvbuf values, as it can lead to various memory corruptions, crashes, OOM... Note that before commit 82981930125a ("net: cleanups in sock_setsockopt()"), the bug was even more serious, since ...
int snd_timer_open(struct snd_timer_instance **ti, char *owner, struct snd_timer_id *tid, unsigned int slave_id) { struct snd_timer *timer; struct snd_timer_instance *timeri = NULL; if (tid->dev_class == SNDRV_TIMER_CLASS_SLAVE) { /* open a slave instance */ if (tid->dev_sclass <= SNDRV_TIMER_SCLASS_N...
0
[ "CWE-200", "CWE-362" ]
linux
ee8413b01045c74340aa13ad5bdf905de32be736
15,464,896,072,493,654,000,000,000,000,000,000,000
69
ALSA: timer: Fix double unlink of active_list ALSA timer instance object has a couple of linked lists and they are unlinked unconditionally at snd_timer_stop(). Meanwhile snd_timer_interrupt() unlinks it, but it calls list_del() which leaves the element list itself unchanged. This ends up with unlinking twice, and i...
static double mp_linear_add(_cimg_math_parser& mp) { return _mp_arg(2)*_mp_arg(3) + _mp_arg(4);
0
[ "CWE-125" ]
CImg
10af1e8c1ad2a58a0a3342a856bae63e8f257abb
243,660,661,266,380,540,000,000,000,000,000,000,000
3
Fix other issues in 'CImg<T>::load_bmp()'.
static enum write_one_status write_one(struct sha1file *f, struct object_entry *e, off_t *offset) { unsigned long size; int recursing; /* * we set offset to 1 (which is an impossible value) to mark * the fact that this object is involved in "write its base * first before writing a deltif...
0
[ "CWE-119", "CWE-787" ]
git
de1e67d0703894cb6ea782e36abb63976ab07e60
148,525,408,013,273,290,000,000,000,000,000,000,000
52
list-objects: pass full pathname to callbacks When we find a blob at "a/b/c", we currently pass this to our show_object_fn callbacks as two components: "a/b/" and "c". Callbacks which want the full value then call path_name(), which concatenates the two. But this is an inefficient interface; the path is a strbuf, and ...
cJSON *cJSON_CreateBool(int b) {cJSON *item=cJSON_New_Item();if(item)item->type=b?cJSON_True:cJSON_False;return item;}
0
[ "CWE-120", "CWE-119", "CWE-787" ]
iperf
91f2fa59e8ed80dfbf400add0164ee0e508e412a
167,215,786,972,382,780,000,000,000,000,000,000,000
1
Fix a buffer overflow / heap corruption issue that could occur if a malformed JSON string was passed on the control channel. This issue, present in the cJSON library, was already fixed upstream, so was addressed here in iperf3 by importing a newer version of cJSON (plus local ESnet modifications). Discovered and repo...
static void vmx_set_cr0(struct kvm_vcpu *vcpu, unsigned long cr0) { unsigned long hw_cr0 = (cr0 & ~KVM_GUEST_CR0_MASK) | KVM_VM_CR0_ALWAYS_ON; vmx_fpu_deactivate(vcpu); if (vcpu->arch.rmode.active && (cr0 & X86_CR0_PE)) enter_pmode(vcpu); if (!vcpu->arch.rmode.active && !(cr0 & X86_CR0_PE)) enter_rmode(v...
0
[ "CWE-20" ]
linux-2.6
16175a796d061833aacfbd9672235f2d2725df65
280,484,419,707,230,100,000,000,000,000,000,000,000
32
KVM: VMX: Don't allow uninhibited access to EFER on i386 vmx_set_msr() does not allow i386 guests to touch EFER, but they can still do so through the default: label in the switch. If they set EFER_LME, they can oops the host. Fix by having EFER access through the normal channel (which will check for EFER_LME) even o...
do_unmount (UnmountData *data) { GMountOperation *mount_op; if (data->mount_operation) { mount_op = g_object_ref (data->mount_operation); } else { mount_op = gtk_mount_operation_new (data->parent_window); } if (data->eject) { g_mount_eject_with_operation (dat...
0
[ "CWE-20" ]
nautilus
1630f53481f445ada0a455e9979236d31a8d3bb0
245,214,132,343,058,070,000,000,000,000,000,000,000
32
mime-actions: use file metadata for trusting desktop files Currently we only trust desktop files that have the executable bit set, and don't replace the displayed icon or the displayed name until it's trusted, which prevents for running random programs by a malicious desktop file. However, the executable permission i...
string_to_compress_algo(const char *string) { /* TRANSLATORS: See doc/TRANSLATE about this string. */ if(match_multistr(_("uncompressed|none"),string)) return 0; else if(ascii_strcasecmp(string,"uncompressed")==0) return 0; else if(ascii_strcasecmp(string,"none")==0) return 0; else if(ascii_strcas...
0
[ "CWE-20" ]
gnupg
2183683bd633818dd031b090b5530951de76f392
256,713,126,905,033,000,000,000,000,000,000,000,000
30
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 ...
cli_file_t cli_get_container_type(cli_ctx *ctx, int index) { if (index < 0) index = ctx->recursion + index + 1; if (index >= 0 && index <= ctx->recursion) return ctx->containers[index].type; return CL_TYPE_ANY; }
1
[]
clamav-devel
167c0079292814ec5523d0b97a9e1b002bf8819b
27,427,583,034,634,850,000,000,000,000,000,000,000
8
fix 0.99.3 false negative of virus Pdf.Exploit.CVE_2016_1046-1.
check_signals_and_traps () { check_signals (); run_pending_traps (); }
0
[]
bash
955543877583837c85470f7fb8a97b7aa8d45e6c
271,044,569,725,834,100,000,000,000,000,000,000,000
6
bash-4.4-rc2 release
static int __htab_lru_percpu_map_update_elem(struct bpf_map *map, void *key, void *value, u64 map_flags, bool onallcpus) { struct bpf_htab *htab = container_of(map, struct bpf_htab, map); struct htab_elem *l_new = NULL, *l_old; struct hlist_nulls_head *head; unsigned long flags; struct bucket *...
0
[ "CWE-787" ]
bpf
c4eb1f403243fc7bbb7de644db8587c03de36da6
319,919,010,287,507,270,000,000,000,000,000,000,000
66
bpf: Fix integer overflow involving bucket_size In __htab_map_lookup_and_delete_batch(), hash buckets are iterated over to count the number of elements in each bucket (bucket_size). If bucket_size is large enough, the multiplication to calculate kvmalloc() size could overflow, resulting in out-of-bounds write as repor...
do_add_counters(struct net *net, const void __user *user, unsigned int len, int compat) { unsigned int i; struct xt_counters_info tmp; struct xt_counters *paddc; struct xt_table *t; const struct xt_table_info *private; int ret = 0; struct ipt_entry *iter; unsigned int addend; paddc = xt_copy_counters_from_u...
0
[ "CWE-476" ]
linux
57ebd808a97d7c5b1e1afb937c2db22beba3c1f8
190,973,438,484,682,200,000,000,000,000,000,000,000
48
netfilter: add back stackpointer size checks The rationale for removing the check is only correct for rulesets generated by ip(6)tables. In iptables, a jump can only occur to a user-defined chain, i.e. because we size the stack based on number of user-defined chains we cannot exceed stack size. However, the underlyi...
static bool winbind_name_list_to_sid_string_list(struct pwb_context *ctx, const char *user, const char *name_list, char *sid_list_buffer, int sid_list_buffer_size) { bool result = false; char *current_name = NULL; const char *search_location; const char *comma; int len; if (sid_list_b...
0
[ "CWE-20" ]
samba
f62683956a3b182f6a61cc7a2b4ada2e74cde243
59,746,306,607,684,390,000,000,000,000,000,000,000
89
fail authentication for single group name which cannot be converted to sid furthermore if more than one name is supplied and no sid is converted then also fail. Bug: https://bugzilla.samba.org/show_bug.cgi?id=8598 Signed-off-by: Noel Power <noel.power@suse.com> Reviewed-by: Andreas Schneider <asn@samba.org> Reviewed...
static void sig_usr1_handler(int sig) { sig_usr1_handler_called = 1; }
0
[ "CWE-287", "CWE-284" ]
booth
35bf0b7b048d715f671eb68974fb6b4af6528c67
265,755,758,471,631,900,000,000,000,000,000,000,000
4
Revert "Refactor: main: substitute is_auth_req macro" This reverts commit da79b8ba28ad4837a0fee13e5f8fb6f89fe0e24c. authfile != authkey Signed-off-by: Jan Friesse <jfriesse@redhat.com>
void test_nghttp2_session_pack_data_with_padding(void) { nghttp2_session *session; my_user_data ud; nghttp2_session_callbacks callbacks; nghttp2_data_provider data_prd; nghttp2_frame *frame; size_t datalen = 55; nghttp2_mem *mem; mem = nghttp2_mem_default(); memset(&callbacks, 0, sizeof(callbacks));...
0
[]
nghttp2
0a6ce87c22c69438ecbffe52a2859c3a32f1620f
247,825,625,068,621,620,000,000,000,000,000,000,000
39
Add nghttp2_option_set_max_outbound_ack
static Image *ReadPNGImage(const ImageInfo *image_info,ExceptionInfo *exception) { Image *image; MagickBooleanType logging, status; MngInfo *mng_info; char magic_number[MaxTextExtent]; ssize_t count; /* Open image file. */ assert(image_info != (const ImageInfo *) NULL); ...
0
[ "CWE-125" ]
ImageMagick6
34adc98afd5c7e7fb774d2ebdaea39e831c24dce
76,211,082,897,281,800,000,000,000,000,000,000,000
124
https://github.com/ImageMagick/ImageMagick/issues/1561
struct kvm_vcpu __percpu **kvm_get_running_vcpus(void) { return &kvm_arm_running_vcpu; }
0
[ "CWE-399", "CWE-284" ]
linux
e8180dcaa8470ceca21109f143876fdcd9fe050a
2,350,542,899,566,891,200,000,000,000,000,000,000
4
ARM: KVM: prevent NULL pointer dereferences with KVM VCPU ioctl Some ARM KVM VCPU ioctls require the vCPU to be properly initialized with the KVM_ARM_VCPU_INIT ioctl before being used with further requests. KVM_RUN checks whether this initialization has been done, but other ioctls do not. Namely KVM_GET_REG_LIST will ...
restore_original_file_attributes (GHashTable *created_files, GCancellable *cancellable) { GHashTableIter iter; gpointer key, value; g_hash_table_iter_init (&iter, created_files); while (g_hash_table_iter_next (&iter, &key, &value)) { GFile *file = key; GFileInfo *info = value; _g_file_se...
0
[ "CWE-22" ]
file-roller
21dfcdbfe258984db89fb65243a1a888924e45a0
275,519,960,365,304,970,000,000,000,000,000,000,000
14
libarchive: do not follow external links when extracting files Do not extract a file if its parent is a symbolic link to a directory external to the destination.
gcab_folder_new (gint comptype) { return g_object_new (GCAB_TYPE_FOLDER, "comptype", comptype, NULL); }
0
[ "CWE-787" ]
gcab
c512f6ff0c82a1139b36db2b28f93edc01c74b4b
178,859,928,285,457,700,000,000,000,000,000,000,000
6
trivial: Allocate cdata_t on the heap Using a 91kB stack allocation for one object isn't awesome, and it also allows us to use g_autoptr() to simplify gcab_folder_extract()
int rsCStrStartsWithSzStr(cstr_t *pCS1, uchar *psz, size_t iLenSz) { register size_t i; rsCHECKVALIDOBJECT(pCS1, OIDrsCStr); assert(psz != NULL); assert(iLenSz == strlen((char*)psz)); /* just make sure during debugging! */ if(pCS1->iStrLen >= iLenSz) { /* we are using iLenSz below, because we need to check *...
0
[ "CWE-189" ]
rsyslog
6bad782f154b7f838c7371bf99c13f6dc4ec4101
67,714,659,217,875,180,000,000,000,000,000,000,000
25
bugfix: abort if imfile reads file line of more than 64KiB Thanks to Peter Eisentraut for reporting and analysing this problem. bug tracker: http://bugzilla.adiscon.com/show_bug.cgi?id=221
void set_mm_exe_file(struct mm_struct *mm, struct file *new_exe_file) { if (new_exe_file) get_file(new_exe_file); if (mm->exe_file) fput(mm->exe_file); mm->exe_file = new_exe_file; mm->num_exe_file_vmas = 0; }
0
[ "CWE-20", "CWE-362", "CWE-416" ]
linux
86acdca1b63e6890540fa19495cfc708beff3d8b
221,023,335,865,394,300,000,000,000,000,000,000,000
9
fix autofs/afs/etc. magic mountpoint breakage We end up trying to kfree() nd.last.name on open("/mnt/tmp", O_CREAT) if /mnt/tmp is an autofs direct mount. The reason is that nd.last_type is bogus here; we want LAST_BIND for everything of that kind and we get LAST_NORM left over from finding parent directory. So make...
void exit_thread(struct task_struct *tsk) { struct thread_struct *t = &tsk->thread; struct fpu *fpu = &t->fpu; if (test_thread_flag(TIF_IO_BITMAP)) io_bitmap_exit(tsk); free_vm86(t); fpu__drop(fpu); }
0
[]
linux
dbbe2ad02e9df26e372f38cc3e70dab9222c832e
311,282,340,668,658,000,000,000,000,000,000,000,000
12
x86/speculation: Prevent rogue cross-process SSBD shutdown On context switch the change of TIF_SSBD and TIF_SPEC_IB are evaluated to adjust the mitigations accordingly. This is optimized to avoid the expensive MSR write if not needed. This optimization is buggy and allows an attacker to shutdown the SSBD protection o...
static struct basescript *SFDParseBaseScript(FILE *sfd,struct Base *base) { struct basescript *bs; int i, ch; struct baselangextent *last, *cur; if ( base==NULL ) return(NULL); bs = chunkalloc(sizeof(struct basescript)); bs->script = gettag(sfd); getint(sfd,&bs->def_baseline); if ( ba...
0
[ "CWE-416" ]
fontforge
048a91e2682c1a8936ae34dbc7bd70291ec05410
262,534,115,816,421,670,000,000,000,000,000,000,000
31
Fix for #4084 Use-after-free (heap) in the SFD_GetFontMetaData() function Fix for #4086 NULL pointer dereference in the SFDGetSpiros() function Fix for #4088 NULL pointer dereference in the SFD_AssignLookups() function Add empty sf->fontname string if it isn't set, fixing #4089 #4090 and many other potential issues (...
aiff_get_chunk_size (SF_PRIVATE *psf, const SF_CHUNK_ITERATOR * iterator, SF_CHUNK_INFO * chunk_info) { int indx ; if ((indx = psf_find_read_chunk_iterator (&psf->rchunks, iterator)) < 0) return SFE_UNKNOWN_CHUNK ; chunk_info->datalen = psf->rchunks.chunks [indx].len ; return SFE_NO_ERROR ; } /* aiff_get_chunk_...
0
[ "CWE-119", "CWE-787" ]
libsndfile
f833c53cb596e9e1792949f762e0b33661822748
18,936,243,274,477,895,000,000,000,000,000,000,000
10
src/aiff.c: Fix a buffer read overflow Secunia Advisory SA76717. Found by: Laurent Delosieres, Secunia Research at Flexera Software
static int __io_async_wake(struct io_kiocb *req, struct io_poll_iocb *poll, __poll_t mask, task_work_func_t func) { int ret; /* for instances that support it check for an event match first: */ if (mask && !(mask & poll->events)) return 0; trace_io_uring_task_add(req->ctx, req->opcode, req->user_data, mas...
0
[ "CWE-667" ]
linux
3ebba796fa251d042be42b929a2d916ee5c34a49
126,251,544,784,780,150,000,000,000,000,000,000,000
30
io_uring: ensure that SQPOLL thread is started for exit If we create it in a disabled state because IORING_SETUP_R_DISABLED is set on ring creation, we need to ensure that we've kicked the thread if we're exiting before it's been explicitly disabled. Otherwise we can run into a deadlock where exit is waiting go park t...
static void stbi__YCbCr_to_RGB_simd(stbi_uc *out, stbi_uc const *y, stbi_uc const *pcb, stbi_uc const *pcr, int count, int step) { int i = 0; #ifdef STBI_SSE2 // step == 3 is pretty ugly on the final interleave, and i'm not convinced // it's useful in practice (you wouldn't use it for textures, for example). ...
0
[ "CWE-787" ]
stb
5ba0baaa269b3fd681828e0e3b3ac0f1472eaf40
107,558,674,875,923,870,000,000,000,000,000,000,000
132
stb_image: Reject fractional JPEG component subsampling ratios The component resamplers are not written to support this and I've never seen it happen in a real (non-crafted) JPEG file so I'm fine rejecting this as outright corrupt. Fixes issue #1178.
static void dccp_enqueue_skb(struct sock *sk, struct sk_buff *skb) { __skb_pull(skb, dccp_hdr(skb)->dccph_doff * 4); __skb_queue_tail(&sk->sk_receive_queue, skb); skb_set_owner_r(skb, sk); sk->sk_data_ready(sk); }
0
[ "CWE-200", "CWE-415" ]
linux
5edabca9d4cff7f1f2b68f0bac55ef99d9798ba4
320,994,527,448,250,300,000,000,000,000,000,000,000
7
dccp: fix freeing skb too early for IPV6_RECVPKTINFO In the current DCCP implementation an skb for a DCCP_PKT_REQUEST packet is forcibly freed via __kfree_skb in dccp_rcv_state_process if dccp_v6_conn_request successfully returns. However, if IPV6_RECVPKTINFO is set on a socket, the address of the skb is saved to ire...
static int write_compression_header(blosc2_context* context, bool extended_header) { int32_t compformat; int dont_split; int dict_training = context->use_dict && (context->dict_cdict == NULL); // Set the whole header to zeros so that the reserved values are zeroed if (exte...
0
[ "CWE-787" ]
c-blosc2
c4c6470e88210afc95262c8b9fcc27e30ca043ee
201,856,728,996,569,780,000,000,000,000,000,000,000
153
Fixed asan heap buffer overflow when not enough space to write compressed block size.
static int pfkey_spdget(struct sock *sk, struct sk_buff *skb, const struct sadb_msg *hdr, void * const *ext_hdrs) { struct net *net = sock_net(sk); unsigned int dir; int err = 0, delete; struct sadb_x_policy *pol; struct xfrm_policy *xp; struct km_event c; if ((pol = ext_hdrs[SADB_X_EXT_POLICY-1]) == NULL) re...
0
[ "CWE-20", "CWE-269" ]
linux
f3d3342602f8bcbf37d7c46641cb9bca7618eb1c
263,933,714,021,575,450,000,000,000,000,000,000,000
44
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...
mono_assembly_get_object (MonoDomain *domain, MonoAssembly *assembly) { static MonoClass *System_Reflection_Assembly; MonoReflectionAssembly *res; CHECK_OBJECT (MonoReflectionAssembly *, assembly, NULL); if (!System_Reflection_Assembly) System_Reflection_Assembly = mono_class_from_name ( mono_defaults.corlib...
0
[ "CWE-20" ]
mono
4905ef1130feb26c3150b28b97e4a96752e0d399
336,677,163,835,691,100,000,000,000,000,000,000,000
14
Handle invalid instantiation of generic methods. * verify.c: Add new function to internal verifier API to check method instantiations. * reflection.c (mono_reflection_bind_generic_method_parameters): Check the instantiation before returning it. Fixes #655847
zbuilddevicecolorrendering1(i_ctx_t *i_ctx_p) { os_ptr op = osp; gs_memory_t *mem = gs_gstate_memory(igs); dict_param_list list; gs_cie_render *pcrd = 0; int code; check_type(*op, t_dictionary); code = dict_param_list_read(&list, op, NULL, false, iimemory); if (code < 0) return ...
0
[ "CWE-704" ]
ghostpdl
548bb434e81dadcc9f71adf891a3ef5bea8e2b4e
193,723,742,103,188,100,000,000,000,000,000,000,000
30
PS interpreter - add some type checking These were 'probably' safe anyway, since they mostly treat the objects as integers without checking, which at least can't result in a crash. Nevertheless, we ought to check. The return from comparedictkeys could be wrong if one of the keys had a value which was not an array, i...
set_filename_bstab (string) const char *string; { const char *s; memset (filename_bstab, 0, sizeof (filename_bstab)); for (s = string; s && *s; s++) filename_bstab[*s] = 1; }
0
[ "CWE-20" ]
bash
4f747edc625815f449048579f6e65869914dd715
93,220,543,676,882,220,000,000,000,000,000,000,000
9
Bash-4.4 patch 7
static const char *wsgi_server_group(request_rec *r, const char *s) { const char *name = NULL; const char *h = NULL; apr_port_t p = 0; if (!s) return ""; if (*s != '%') return s; name = s + 1; if (*name) { if (!strcmp(name, "{SERVER}")) { h = r->serve...
0
[ "CWE-254" ]
mod_wsgi
545354a80b9cc20d8b6916ca30542eab36c3b8bd
128,510,165,744,500,280,000,000,000,000,000,000,000
32
When there is any sort of error in setting up daemon process group, kill the process rather than risk running in an unexpected state.
bytes_richcompare(PyBytesObject *a, PyBytesObject *b, int op) { int c; Py_ssize_t len_a, len_b; Py_ssize_t min_len; PyObject *result; int rc; /* Make sure both arguments are strings. */ if (!(PyBytes_Check(a) && PyBytes_Check(b))) { if (Py_BytesWarningFlag && (op == Py_EQ || op == P...
0
[ "CWE-190" ]
cpython
6c004b40f9d51872d848981ef1a18bb08c2dfc42
284,096,448,858,167,480,000,000,000,000,000,000,000
77
bpo-30657: Fix CVE-2017-1000158 (#4758) Fixes possible integer overflow in PyBytes_DecodeEscape. Co-Authored-By: Jay Bosamiya <jaybosamiya@gmail.com>
static int handle_NPP_GetValue(rpc_connection_t *connection) { D(bug("handle_NPP_GetValue\n")); int error; PluginInstance *plugin; int32_t variable; error = rpc_method_get_args(connection, RPC_TYPE_NPW_PLUGIN_INSTANCE, &plugin, RPC_TYPE_INT32, &variable, RPC_TYPE_INVALID); if (...
0
[ "CWE-264" ]
nspluginwrapper
7e4ab8e1189846041f955e6c83f72bc1624e7a98
143,523,618,956,164,080,000,000,000,000,000,000,000
50
Support all the new variables added
TfLiteStatus Subgraph::SetTensorParametersReadOnly( int tensor_index, TfLiteType type, const char* name, const size_t rank, const int* dims, TfLiteQuantization quantization, const char* buffer, size_t bytes, const Allocation* allocation, TfLiteSparsity* sparsity) { // Ensure quantization cleanup on failur...
0
[ "CWE-20", "CWE-787" ]
tensorflow
d58c96946b2880991d63d1dacacb32f0a4dfa453
178,139,227,380,250,000,000,000,000,000,000,000,000
53
[tflite] Ensure inputs and outputs don't overlap. If a model uses the same tensor for both an input and an output then this can result in data loss and memory corruption. This should not happen. PiperOrigin-RevId: 332522916 Change-Id: If0905b142415a9dfceaf2d181872f2a8fb88f48a
cmsBool AllCurvesAreLinear(cmsStage* mpe) { cmsToneCurve** Curves; cmsUInt32Number i, n; Curves = _cmsStageGetPtrToCurveSet(mpe); if (Curves == NULL) return FALSE; n = cmsStageOutputChannels(mpe); for (i=0; i < n; i++) { if (!cmsIsToneCurveLinear(Curves[i])) return FALSE; } r...
0
[]
Little-CMS
41d222df1bc6188131a8f46c32eab0a4d4cdf1b6
136,137,962,083,068,680,000,000,000,000,000,000,000
16
Memory squeezing fix: lcms2 cmsPipeline construction When creating a new pipeline, lcms would often try to allocate a stage and pass it to cmsPipelineInsertStage without checking whether the allocation succeeded. cmsPipelineInsertStage would then assert (or crash) if it had not. The fix here is to change cmsPipelineI...
static noinline int free_debug_processing( struct kmem_cache *s, struct page *page, void *head, void *tail, int bulk_cnt, unsigned long addr) { struct kmem_cache_node *n = get_node(s, page_to_nid(page)); void *object = head; int cnt = 0; unsigned long uninitialized_var(flags); int ret = 0; spin_lock_irqsave(&...
0
[]
linux
fd4d9c7d0c71866ec0c2825189ebd2ce35bd95b8
150,522,492,727,481,440,000,000,000,000,000,000,000
51
mm: slub: add missing TID bump in kmem_cache_alloc_bulk() When kmem_cache_alloc_bulk() attempts to allocate N objects from a percpu freelist of length M, and N > M > 0, it will first remove the M elements from the percpu freelist, then call ___slab_alloc() to allocate the next element and repopulate the percpu freelis...
static char* get_private_subtags(const char* loc_name) { char* result =NULL; int singletonPos = 0; int len =0; const char* mod_loc_name =NULL; if( loc_name && (len = strlen(loc_name)>0 ) ){ mod_loc_name = loc_name ; len = strlen(mod_loc_name); while( (singletonPos = getSingletonPos(mod_loc_name))!= -1...
0
[ "CWE-125" ]
php-src
97eff7eb57fc2320c267a949cffd622c38712484
276,790,279,879,323,400,000,000,000,000,000,000,000
41
Fix bug #72241: get_icu_value_internal out-of-bounds read
PHP_FUNCTION(imagedashedline) { zval *IM; long x1, y1, x2, y2, col; gdImagePtr im; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rlllll", &IM, &x1, &y1, &x2, &y2, &col) == FAILURE) { return; } ZEND_FETCH_RESOURCE(im, gdImagePtr, &IM, -1, "Image", le_gd); gdImageDashedLine(im, x1, y1, x2, y2, col); R...
0
[ "CWE-703", "CWE-189" ]
php-src
2938329ce19cb8c4197dec146c3ec887c6f61d01
82,961,033,033,725,770,000,000,000,000,000,000,000
14
Fixed bug #66356 (Heap Overflow Vulnerability in imagecrop()) And also fixed the bug: arguments are altered after some calls
evdns_base_free_and_unlock(struct evdns_base *base, int fail_requests) { struct nameserver *server, *server_next; struct search_domain *dom, *dom_next; int i; /* Requires that we hold the lock. */ /* TODO(nickm) we might need to refcount here. */ for (i = 0; i < base->n_req_heads; ++i) { while (base->req_hea...
0
[ "CWE-125" ]
libevent
ec65c42052d95d2c23d1d837136d1cf1d9ecef9e
335,857,248,859,036,650,000,000,000,000,000,000,000
59
evdns: fix searching empty hostnames From #332: Here follows a bug report by **Guido Vranken** via the _Tor bug bounty program_. Please credit Guido accordingly. ## Bug report The DNS code of Libevent contains this rather obvious OOB read: ```c static char * search_make_new(const struct search_state *co...
xfs_inode_ag_iterator( struct xfs_mount *mp, int (*execute)(struct xfs_inode *ip, int flags, void *args), int flags, void *args) { return xfs_inode_ag_iterator_flags(mp, execute, flags, args, 0); }
0
[ "CWE-476" ]
linux
afca6c5b2595fc44383919fba740c194b0b76aff
301,124,222,340,836,140,000,000,000,000,000,000,000
9
xfs: validate cached inodes are free when allocated A recent fuzzed filesystem image cached random dcache corruption when the reproducer was run. This often showed up as panics in lookup_slow() on a null inode->i_ops pointer when doing pathwalks. BUG: unable to handle kernel NULL pointer dereference at 00000000000000...
void SetUp() override { TestUtility::loadFromYaml(kConfigTemplate, proto_config_); for (auto& it : *(proto_config_.mutable_providers())) { it.second.mutable_local_jwks()->set_inline_string(PublicKey); } }
0
[ "CWE-303", "CWE-703" ]
envoy
ea39e3cba652bcc4b11bb0d5c62b017e584d2e5a
100,579,973,814,928,260,000,000,000,000,000,000,000
6
jwt_authn: fix a bug where JWT with wrong issuer is allowed in allow_missing case (#15194) [jwt] When allow_missing is used inside RequiresAny, the requests with JWT with wrong issuer are accepted. This is a bug, allow_missing should only allow requests without any JWT. This change fixed the above issue by preserving ...
static int ntop_get_interface_dump_max_pkts(lua_State* vm) { NetworkInterface *ntop_interface = getCurrentInterface(vm); int max_pkts; ntop->getTrace()->traceEvent(TRACE_DEBUG, "%s() called", __FUNCTION__); if(!ntop_interface) return(CONST_LUA_ERROR); max_pkts = ntop_interface->getDumpTrafficMaxPktsPer...
0
[ "CWE-476" ]
ntopng
01f47e04fd7c8d54399c9e465f823f0017069f8f
318,360,707,117,437,170,000,000,000,000,000,000,000
15
Security fix: prevents empty host from being used
_flatpak_dir_find_new_flatpakrepos (FlatpakDir *self, OstreeRepo *repo) { g_autoptr(GHashTable) flatpakrepos = NULL; g_autoptr(GFile) conf_dir = NULL; g_autoptr(GFileEnumerator) dir_enum = NULL; g_autoptr(GError) my_error = NULL; g_autofree char *config_dir = NULL; g_auto(GStrv) remotes = NULL; g_auto(GSt...
0
[ "CWE-74" ]
flatpak
fb473cad801c6b61706353256cab32330557374a
176,738,497,951,489,800,000,000,000,000,000,000,000
73
dir: Pass environment via bwrap --setenv when running apply_extra This means we can systematically pass the environment variables through bwrap(1), even if it is setuid and thus is filtering out security-sensitive environment variables. bwrap ends up being run with an empty environment instead. As with the previous c...
int AVI_set_audio_position(avi_t *AVI, int byte) { int n0, n1; if(AVI->mode==AVI_MODE_WRITE) { AVI_errno = AVI_ERR_NOT_PERM; return -1; } if(!AVI->track[AVI->aptr].audio_index) { AVI_errno = AVI_ERR_NO_IDX; return -1; } if(byte < 0) byte = 0; /* Binary search in the audio chunks */ n0 = 0; ...
0
[ "CWE-835" ]
gpac
7f060bbb72966cae80d6fee338d0b07fa3fc06e1
158,167,899,914,870,620,000,000,000,000,000,000,000
34
fixed #2159
static int fts3TermSelectFinishMerge(Fts3Table *p, TermSelect *pTS){ char *aOut = 0; int nOut = 0; int i; /* Loop through the doclists in the aaOutput[] array. Merge them all ** into a single doclist. */ for(i=0; i<SizeofArray(pTS->aaOutput); i++){ if( pTS->aaOutput[i] ){ if( !aOut ){ a...
0
[ "CWE-787" ]
sqlite
c72f2fb7feff582444b8ffdc6c900c69847ce8a9
317,782,553,954,137,300,000,000,000,000,000,000,000
39
More improvements to shadow table corruption detection in FTS3. FossilOrigin-Name: 51525f9c3235967bc00a090e84c70a6400698c897aa4742e817121c725b8c99d
void ERR_free_strings(void) { // handled internally }
0
[ "CWE-254" ]
mysql-server
e7061f7e5a96c66cb2e0bf46bec7f6ff35801a69
291,799,593,988,953,820,000,000,000,000,000,000,000
4
Bug #22738607: YASSL FUNCTION X509_NAME_GET_INDEX_BY_NID IS NOT WORKING AS EXPECTED.
int tls12_copy_sigalgs(SSL *s, WPACKET *pkt, const uint16_t *psig, size_t psiglen) { size_t i; int rv = 0; for (i = 0; i < psiglen; i++, psig++) { const SIGALG_LOOKUP *lu = tls1_lookup_sigalg(*psig); if (!tls12_sigalg_allowed(s, SSL_SECOP_SIGALG_SUPPORTED, lu)) ...
0
[ "CWE-476" ]
openssl
5235ef44b93306a14d0b6c695b13c64b16e1fdec
339,561,213,569,919,430,000,000,000,000,000,000,000
27
Fix SSL_check_chain() The function SSL_check_chain() can be used by applications to check that a cert and chain is compatible with the negotiated parameters. This could be useful (for example) from the certificate callback. Unfortunately this function was applying TLSv1.2 sig algs rules and did not work correctly if T...
void CLASS redcine_load_raw() { #ifndef NO_JASPER int c, row, col; jas_stream_t *in; jas_image_t *jimg; jas_matrix_t *jmat; jas_seqent_t *data; ushort *img, *pix; jas_init(); #ifndef LIBRAW_LIBRARY_BUILD in = jas_stream_fopen (ifname, "rb"); #else in = (jas_stream_t*)ifp->make_jas_stream(); if(!in)...
0
[]
LibRaw
9ae25d8c3a6bfb40c582538193264f74c9b93bc0
300,279,864,316,522,920,000,000,000,000,000,000,000
89
backported 0.15.4 datachecks
template<typename t> CImgList<_cimg_Tt> operator,(const CImgList<t>& list) const { return CImgList<_cimg_Tt>(list,false).insert(*this,0);
0
[ "CWE-125" ]
CImg
10af1e8c1ad2a58a0a3342a856bae63e8f257abb
195,761,335,917,644,750,000,000,000,000,000,000,000
3
Fix other issues in 'CImg<T>::load_bmp()'.
struct sock *cookie_v6_check(struct sock *sk, struct sk_buff *skb) { struct tcp_options_received tcp_opt; struct inet_request_sock *ireq; struct tcp_request_sock *treq; struct ipv6_pinfo *np = inet6_sk(sk); struct tcp_sock *tp = tcp_sk(sk); const struct tcphdr *th = tcp_hdr(skb); __u32 cookie = ntohl(th->ack_seq...
0
[ "CWE-416", "CWE-284", "CWE-264" ]
linux
45f6fad84cc305103b28d73482b344d7f5b76f39
274,418,277,542,228,700,000,000,000,000,000,000,000
118
ipv6: add complete rcu protection around np->opt This patch addresses multiple problems : UDP/RAW sendmsg() need to get a stable struct ipv6_txoptions while socket is not locked : Other threads can change np->opt concurrently. Dmitry posted a syzkaller (http://github.com/google/syzkaller) program desmonstrating use-a...
vte_terminal_emit_restore_window(VteTerminal *terminal) { _vte_debug_print(VTE_DEBUG_SIGNALS, "Emitting `restore-window'.\n"); g_signal_emit_by_name(terminal, "restore-window"); }
0
[]
vte
58bc3a942f198a1a8788553ca72c19d7c1702b74
147,047,734,631,403,290,000,000,000,000,000,000,000
6
fix bug #548272 svn path=/trunk/; revision=2365
TfLiteStatus Subgraph::SetVariables(std::vector<int> variables) { TF_LITE_ENSURE_OK(&context_, CheckTensorIndices("variables", variables.data(), variables.size())); variables_ = std::move(variables); return kTfLiteOk; }
0
[ "CWE-20", "CWE-787" ]
tensorflow
d58c96946b2880991d63d1dacacb32f0a4dfa453
102,457,867,979,016,010,000,000,000,000,000,000,000
6
[tflite] Ensure inputs and outputs don't overlap. If a model uses the same tensor for both an input and an output then this can result in data loss and memory corruption. This should not happen. PiperOrigin-RevId: 332522916 Change-Id: If0905b142415a9dfceaf2d181872f2a8fb88f48a
show_entry_machine (ExifEntry *e, void *data) { unsigned int *ids = data; char v[TAG_VALUE_BUF]; ExifIfd ifd = exif_entry_get_ifd (e); if (*ids) { fprintf (stdout, "0x%04x", e->tag); } else { fputs (CN (exif_tag_get_title_in_ifd (e->tag, ifd)), stdout); } fputc ('\t', stdout); fputs (CN (exif_entry_get_val...
0
[ "CWE-476" ]
exif
f6334d9d32437ef13dc902f0a88a2be0063d9d1c
243,593,963,538,360,440,000,000,000,000,000,000,000
15
added empty strign check, which would lead to NULL ptr deref/crash in exif XML display. fixes https://github.com/libexif/exif/issues/4
int nghttp2_session_resume_data(nghttp2_session *session, int32_t stream_id) { int rv; nghttp2_stream *stream; stream = nghttp2_session_get_stream(session, stream_id); if (stream == NULL || !nghttp2_stream_check_deferred_item(stream)) { return NGHTTP2_ERR_INVALID_ARGUMENT; } rv = nghttp2_stream_resume_...
0
[]
nghttp2
0a6ce87c22c69438ecbffe52a2859c3a32f1620f
124,554,535,995,979,930,000,000,000,000,000,000,000
17
Add nghttp2_option_set_max_outbound_ack
cJSON *cJSON_Duplicate(cJSON *item,int recurse) { cJSON *newitem,*cptr,*nptr=0,*newchild; /* Bail on bad ptr */ if (!item) return 0; /* Create new item */ newitem=cJSON_New_Item(); if (!newitem) return 0; /* Copy over all vars */ newitem->type=item->type&(~cJSON_IsReference),newitem->valueint=item->valueint,new...
0
[ "CWE-120", "CWE-119", "CWE-787" ]
iperf
91f2fa59e8ed80dfbf400add0164ee0e508e412a
116,706,774,455,562,400,000,000,000,000,000,000,000
26
Fix a buffer overflow / heap corruption issue that could occur if a malformed JSON string was passed on the control channel. This issue, present in the cJSON library, was already fixed upstream, so was addressed here in iperf3 by importing a newer version of cJSON (plus local ESnet modifications). Discovered and repo...
static void unzzip_cat_file(ZZIP_DIR* disk, char* name, FILE* out) { ZZIP_FILE* file = zzip_file_open (disk, name, 0); if (file) { char buffer[1024]; int len; while ((len = zzip_file_read (file, buffer, 1024))) { fwrite (buffer, 1, len, out); } zzip_file_close (file); } }
1
[ "CWE-835" ]
zziplib
ac9ae39ef419e9f0f83da1e583314d8c7cda34a6
213,540,364,375,667,920,000,000,000,000,000,000,000
14
#68 ssize_t return value of zzip_file_read is a signed value being possibly -1
static void queue_request(struct avdtp *session, struct pending_req *req, gboolean priority) { if (priority) session->prio_queue = g_slist_append(session->prio_queue, req); else session->req_queue = g_slist_append(session->req_queue, req); }
0
[ "CWE-703" ]
bluez
7a80d2096f1b7125085e21448112aa02f49f5e9a
11,858,019,165,500,434,000,000,000,000,000,000,000
8
avdtp: Fix accepting invalid/malformed capabilities Check if capabilities are valid before attempting to copy them.
**/ T& atNXY(const int pos, const int x, const int y, const int z, const int c, const T& out_value) { return (pos<0 || pos>=width())?(cimg::temporary(out_value)=out_value):_data[pos].atXY(x,y,z,c,out_value);
0
[ "CWE-119", "CWE-787" ]
CImg
ac8003393569aba51048c9d67e1491559877b1d1
165,203,300,049,162,900,000,000,000,000,000,000,000
3
.
Image::AutoPtr ImageFactory::open(const std::wstring& wpath, bool useCurl) { Image::AutoPtr image = open(ImageFactory::createIo(wpath, useCurl)); // may throw if (image.get() == 0) throw WError(kerFileContainsUnknownImageType, wpath); return image; }
0
[ "CWE-835" ]
exiv2
ae49250942f4395639961abeed3c15920fcd7241
139,519,184,386,269,220,000,000,000,000,000,000,000
6
Check in Image::printIFDStructure if seek and reads are OK
static void gdImageHLine(gdImagePtr im, int y, int x1, int x2, int col) { if (im->thick > 1) { int thickhalf = im->thick >> 1; gdImageFilledRectangle(im, x1, y - thickhalf, x2, y + im->thick - thickhalf - 1, col); } else { if (x2 < x1) { int t = x2; x2 = x1; x1 = t; } for (;x1 <= x2; x1++) { gd...
0
[ "CWE-119" ]
php-src
e7f2356665c2569191a946b6fc35b437f0ae1384
91,038,157,956,486,540,000,000,000,000,000,000,000
18
Fix #66387: Stack overflow with imagefilltoborder The stack overflow is caused by the recursive algorithm in combination with a very large negative coordinate passed to gdImageFillToBorder(). As there is already a clipping for large positive coordinates to the width and height of the image, it seems to be consequent t...
GF_Err fiel_box_read(GF_Box *s, GF_BitStream *bs) { GF_FieldInfoBox *ptr = (GF_FieldInfoBox *)s; ISOM_DECREASE_SIZE(s, 2); ptr->field_count = gf_bs_read_u8(bs); ptr->field_order = gf_bs_read_u8(bs); return GF_OK; }
0
[ "CWE-476" ]
gpac
6170024568f4dda310e98ef7508477b425c58d09
296,333,299,803,844,900,000,000,000,000,000,000,000
10
fixed potential crash - cf #1263
int VvcVpsUnit::deserialize() { int rez = VvcUnit::deserialize(); if (rez) return rez; try { vps_id = m_reader.getBits(4); vps_max_layers = m_reader.getBits(6) + 1; vps_max_sublayers = m_reader.getBits(3) + 1; bool vps_default_ptl_dpb_hrd_max_tid_flag = ...
0
[ "CWE-22" ]
tsMuxer
3763dd34755a8944d903aa19578fa22cd3734165
123,442,046,737,267,450,000,000,000,000,000,000,000
173
Fix Buffer Overflow Fixes issue #509.
static void coroutine_fn v9fs_op_not_supp(void *opaque) { V9fsPDU *pdu = opaque; pdu_complete(pdu, -EOPNOTSUPP); }
0
[ "CWE-362" ]
qemu
89fbea8737e8f7b954745a1ffc4238d377055305
117,859,872,142,294,370,000,000,000,000,000,000,000
5
9pfs: Fully restart unreclaim loop (CVE-2021-20181) Depending on the client activity, the server can be asked to open a huge number of file descriptors and eventually hit RLIMIT_NOFILE. This is currently mitigated using a reclaim logic : the server closes the file descriptors of idle fids, based on the assumption that...
job_still_running(void) { struct job *job; LIST_FOREACH(job, &all_jobs, entry) { if ((~job->flags & JOB_NOWAIT) && job->state == JOB_RUNNING) return (1); } return (0); }
0
[]
src
b32e1d34e10a0da806823f57f02a4ae6e93d756e
135,343,172,075,003,060,000,000,000,000,000,000,000
10
evbuffer_new and bufferevent_new can both fail (when malloc fails) and return NULL. GitHub issue 1547.
igmp_scount(struct ip_mc_list *pmc, int type, int gdeleted, int sdeleted) { struct ip_sf_list *psf; int scount = 0; for (psf=pmc->sources; psf; psf=psf->sf_next) { if (!is_in(pmc, psf, type, gdeleted, sdeleted)) continue; scount++; } return scount; }
0
[ "CWE-399", "CWE-703", "CWE-369" ]
linux
a8c1f65c79cbbb2f7da782d4c9d15639a9b94b27
145,980,978,627,234,960,000,000,000,000,000,000,000
12
igmp: Avoid zero delay when receiving odd mixture of IGMP queries Commit 5b7c84066733c5dfb0e4016d939757b38de189e4 ('ipv4: correct IGMP behavior on v3 query during v2-compatibility mode') added yet another case for query parsing, which can result in max_delay = 0. Substitute a value of 1, as in the usual v3 case. Rep...
static int jas_cmputint(long **bufptr, int sgnd, int prec, long val) { int m; if (sgnd) { m = (1 << (prec - 1)); if (val < -m || val >= m) return -1; } else { if (val < 0 || val >= (1 << prec)) return -1; } **bufptr = val; ++(*bufptr); return 0; }
0
[ "CWE-189" ]
jasper
3c55b399c36ef46befcb21e4ebc4799367f89684
175,097,441,858,662,900,000,000,000,000,000,000,000
15
At many places in the code, jas_malloc or jas_recalloc was being invoked with the size argument being computed in a manner that would not allow integer overflow to be detected. Now, these places in the code have been modified to use special-purpose memory allocation functions (e.g., jas_alloc2, jas_alloc3, jas_realloc...
f_py3eval(typval_T *argvars, typval_T *rettv) { char_u *str; char_u buf[NUMBUFLEN]; if (p_pyx == 0) p_pyx = 3; str = tv_get_string_buf(&argvars[0], buf); do_py3eval(str, rettv); }
1
[ "CWE-78" ]
vim
8c62a08faf89663e5633dc5036cd8695c80f1075
191,800,715,166,976,230,000,000,000,000,000,000,000
11
patch 8.1.0881: can execute shell commands in rvim through interfaces Problem: Can execute shell commands in rvim through interfaces. Solution: Disable using interfaces in restricted mode. Allow for writing file with writefile(), histadd() and a few others.
static void SVGEndElement(void *context,const xmlChar *name) { SVGInfo *svg_info; /* Called when the end of an element has been detected. */ (void) LogMagickEvent(CoderEvent,GetMagickModule(), " SAX.endElement(%s)",name); svg_info=(SVGInfo *) context; if (strchr((char *) name,':') != (char *) ...
1
[ "CWE-401" ]
ImageMagick6
e3417aebe17cbe274b7361aa92c83226ca5b646b
213,422,284,416,318,250,000,000,000,000,000,000,000
350
https://github.com/ImageMagick/ImageMagick/issues/1533
static int handle_invept(struct kvm_vcpu *vcpu) { struct vcpu_vmx *vmx = to_vmx(vcpu); u32 vmx_instruction_info, types; unsigned long type; gva_t gva; struct x86_exception e; struct { u64 eptp, gpa; } operand; if (!(vmx->nested.msrs.secondary_ctls_high & SECONDARY_EXEC_ENABLE_EPT) || !(vmx->neste...
0
[ "CWE-284" ]
linux
727ba748e110b4de50d142edca9d6a9b7e6111d8
126,979,135,897,222,730,000,000,000,000,000,000,000
62
kvm: nVMX: Enforce cpl=0 for VMX instructions VMX instructions executed inside a L1 VM will always trigger a VM exit even when executed with cpl 3. This means we must perform the privilege check in software. Fixes: 70f3aac964ae("kvm: nVMX: Remove superfluous VMX instruction fault checks") Cc: stable@vger.kernel.org S...
void CModule::OnModCTCP(const CString& sMessage) {}
0
[ "CWE-20", "CWE-264" ]
znc
8de9e376ce531fe7f3c8b0aa4876d15b479b7311
272,146,748,093,147,400,000,000,000,000,000,000,000
1
Fix remote code execution and privilege escalation vulnerability. To trigger this, need to have a user already. Thanks for Jeriko One <jeriko.one@gmx.us> for finding and reporting this. CVE-2019-12816
free_akl (struct akl *akl) { if (akl->spec) free_keyserver_spec (akl->spec); xfree (akl); }
0
[ "CWE-310" ]
gnupg
4bde12206c5bf199dc6e12a74af8da4558ba41bf
271,057,681,727,584,280,000,000,000,000,000,000,000
7
gpg: Distinguish between missing and cleared key flags. * include/cipher.h (PUBKEY_USAGE_NONE): New. * g10/getkey.c (parse_key_usage): Set new flag. -- We do not want to use the default capabilities (derived from the algorithm) if any key flags are given in a signature. Thus if key flags are used in any way, the def...
brcmf_set_wsec_mode(struct net_device *ndev, struct cfg80211_connect_params *sme) { struct brcmf_if *ifp = netdev_priv(ndev); struct wiphy *wiphy = ifp->drvr->wiphy; struct brcmf_cfg80211_profile *profile = ndev_to_prof(ndev); struct brcmf_cfg80211_security *sec; s32 pval = 0; s32 gval = 0; s32 wsec; s32 ...
0
[ "CWE-787" ]
linux
1b5e2423164b3670e8bc9174e4762d297990deff
102,778,870,967,352,820,000,000,000,000,000,000,000
75
brcmfmac: assure SSID length from firmware is limited The SSID length as received from firmware should not exceed IEEE80211_MAX_SSID_LEN as that would result in heap overflow. Reviewed-by: Hante Meuleman <hante.meuleman@broadcom.com> Reviewed-by: Pieter-Paul Giesberts <pieter-paul.giesberts@broadcom.com> Reviewed-by:...
static ssize_t callback_static_file_uncompressed_stream(void * cls, uint64_t pos, char * buf, size_t max) { (void)(pos); if (cls != NULL) { return fread (buf, sizeof(char), max, (FILE *)cls); } else { return U_STREAM_END; } }
0
[ "CWE-269", "CWE-22" ]
glewlwyd
e3f7245c33897bf9b3a75acfcdb8b7b93974bf11
12,462,736,093,658,907,000,000,000,000,000,000,000
8
Fix file access check for directory traversal, and fix call for callback_static_file_uncompressed if header not set
static ssize_t waiting_for_supplier_show(struct device *dev, struct device_attribute *attr, char *buf) { bool val; device_lock(dev); mutex_lock(&wfs_lock); val = !list_empty(&dev->links.needs_suppliers) && dev->links.need_for_probe; mutex_unlock(&wfs_lock); device_unlock(dev); return sysfs_em...
0
[ "CWE-787" ]
linux
aa838896d87af561a33ecefea1caa4c15a68bc47
206,609,688,270,614,460,000,000,000,000,000,000,000
14
drivers core: Use sysfs_emit and sysfs_emit_at for show(device *...) functions Convert the various sprintf fmaily calls in sysfs device show functions to sysfs_emit and sysfs_emit_at for PAGE_SIZE buffer safety. Done with: $ spatch -sp-file sysfs_emit_dev.cocci --in-place --max-width=80 . And cocci script: $ cat s...
static void oidc_revoke_tokens(request_rec *r, oidc_cfg *c, oidc_session_t *session) { char *response = NULL; char *basic_auth = NULL; char *bearer_auth = NULL; apr_table_t *params = NULL; const char *token = NULL; oidc_provider_t *provider = NULL; oidc_debug(r, "enter"); if (oidc_get_provider_from_session...
0
[ "CWE-601" ]
mod_auth_openidc
5c15dfb08106c2451c2c44ce7ace6813c216ba75
247,344,149,488,179,000,000,000,000,000,000,000,000
65
improve validation of the post-logout URL; closes #449 - to avoid an open redirect; thanks AIMOTO Norihito - release 2.4.0.1 Signed-off-by: Hans Zandbelt <hans.zandbelt@zmartzone.eu>
int X509_REQ_add_extensions_nid(X509_REQ *req, STACK_OF(X509_EXTENSION) *exts, int nid) { ASN1_TYPE *at = NULL; X509_ATTRIBUTE *attr = NULL; if (!(at = ASN1_TYPE_new()) || !(at->value.sequence = ASN1_STRING_new())) goto err; at->type = V_ASN1_SEQUENCE; /* Gen...
0
[]
openssl
28a00bcd8e318da18031b2ac8778c64147cd54f9
335,839,940,628,864,800,000,000,000,000,000,000,000
35
Check public key is not NULL. CVE-2015-0288 PR#3708 Reviewed-by: Matt Caswell <matt@openssl.org>
static void __sync_task_rss_stat(struct task_struct *task, struct mm_struct *mm) { int i; for (i = 0; i < NR_MM_COUNTERS; i++) { if (task->rss_stat.count[i]) { add_mm_counter(mm, i, task->rss_stat.count[i]); task->rss_stat.count[i] = 0; } } task->rss_stat.events = 0; }
0
[ "CWE-264" ]
linux-2.6
1a5a9906d4e8d1976b701f889d8f35d54b928f25
33,903,573,889,085,660,000,000,000,000,000,000,000
12
mm: thp: fix pmd_bad() triggering in code paths holding mmap_sem read mode In some cases it may happen that pmd_none_or_clear_bad() is called with the mmap_sem hold in read mode. In those cases the huge page faults can allocate hugepmds under pmd_none_or_clear_bad() and that can trigger a false positive from pmd_bad(...
static int ssl3_get_record(SSL *s) { int ssl_major,ssl_minor,al; int enc_err,n,i,ret= -1; SSL3_RECORD *rr; SSL_SESSION *sess; unsigned char *p; unsigned char md[EVP_MAX_MD_SIZE]; short version; unsigned mac_size; int clear=0; size_t extra; rr= &(s->s3->rrec); sess=s->session; if (s->options & SSL_OP_MIC...
1
[ "CWE-310" ]
openssl
b3a959a337b8083bc855623f24cebaf43a477350
307,994,214,933,389,130,000,000,000,000,000,000,000
243
Don't crash when processing a zero-length, TLS >= 1.1 record. The previous CBC patch was bugged in that there was a path through enc() in s3_pkt.c/d1_pkt.c which didn't set orig_len. orig_len would be left at the previous value which could suggest that the packet was a sufficient length when it wasn't. (cherry picked ...
SPL_METHOD(GlobIterator, count) { spl_filesystem_object *intern = Z_SPLFILESYSTEM_P(getThis()); if (zend_parse_parameters_none() == FAILURE) { return; } if (intern->u.dir.dirp && php_stream_is(intern->u.dir.dirp ,&php_glob_stream_ops)) { RETURN_LONG(php_glob_stream_get_count(intern->u.dir.dirp, NULL)); } els...
0
[ "CWE-74" ]
php-src
a5a15965da23c8e97657278fc8dfbf1dfb20c016
283,763,949,884,465,450,000,000,000,000,000,000,000
15
Fix #78863: DirectoryIterator class silently truncates after a null byte Since the constructor of DirectoryIterator and friends is supposed to accepts paths (i.e. strings without NUL bytes), we must not accept arbitrary strings.
static int mszip_make_decode_table(unsigned int nsyms, unsigned int nbits, unsigned char *length, unsigned short *table) { register unsigned int leaf, reverse, fill; register unsigned short sym, next_sym; register unsigned char bit_num; unsigned int pos = 0; /* the current position in the decode...
0
[]
clamav-devel
158c35e81a25ea5fda55a2a7f62ea9fec2e883d9
304,185,382,710,024,950,000,000,000,000,000,000,000
75
libclamav/mspack.c: improve unpacking of malformed cabinets (bb#1826)
static int ext4_writepages(struct address_space *mapping, struct writeback_control *wbc) { pgoff_t writeback_index = 0; long nr_to_write = wbc->nr_to_write; int range_whole = 0; int cycled = 1; handle_t *handle = NULL; struct mpage_da_data mpd; struct inode *inode = mapping->host; int needed_blocks, rsv_b...
0
[ "CWE-362" ]
linux
ea3d7209ca01da209cda6f0dea8be9cc4b7a933b
87,839,126,850,812,200,000,000,000,000,000,000,000
188
ext4: fix races between page faults and hole punching Currently, page faults and hole punching are completely unsynchronized. This can result in page fault faulting in a page into a range that we are punching after truncate_pagecache_range() has been called and thus we can end up with a page mapped to disk blocks that...
void ConnectionManagerImpl::initializeReadFilterCallbacks(Network::ReadFilterCallbacks& callbacks) { read_callbacks_ = &callbacks; stats_.named_.downstream_cx_total_.inc(); stats_.named_.downstream_cx_active_.inc(); if (read_callbacks_->connection().ssl()) { stats_.named_.downstream_cx_ssl_total_.inc(); ...
0
[ "CWE-400" ]
envoy
0e49a495826ea9e29134c1bd54fdeb31a034f40c
274,926,383,262,637,380,000,000,000,000,000,000,000
30
http/2: add stats and stream flush timeout (#139) This commit adds a new stream flush timeout to guard against a remote server that does not open window once an entire stream has been buffered for flushing. Additional stats have also been added to better understand the codecs view of active streams as well as amount o...
PHPAPI int php_lint_script(zend_file_handle *file) { zend_op_array *op_array; int retval = FAILURE; zend_try { op_array = zend_compile_file(file, ZEND_INCLUDE); zend_destroy_file_handle(file); if (op_array) { destroy_op_array(op_array); efree(op_array); retval = SUCCESS; } } zend_end_try(); if (...
0
[]
php-src
9a07245b728714de09361ea16b9c6fcf70cb5685
17,632,733,470,227,389,000,000,000,000,000,000,000
21
Fixed bug #71273 A wrong ext directory setup in php.ini leads to crash
R_API RBinField *r_bin_field_new(ut64 paddr, ut64 vaddr, int size, const char *name, const char *comment, const char *format) { RBinField *ptr; if (!(ptr = R_NEW0 (RBinField))) { return NULL; } ptr->name = strdup (name); ptr->comment = (comment && *comment)? strdup (comment): NULL; ptr->format = (format && *for...
0
[ "CWE-125" ]
radare2
d31c4d3cbdbe01ea3ded16a584de94149ecd31d9
94,409,669,705,540,030,000,000,000,000,000,000,000
14
Fix #8748 - Fix oobread on string search
int security_file_ioctl(struct file *file, unsigned int cmd, unsigned long arg) { return security_ops->file_ioctl(file, cmd, arg); }
0
[]
linux-2.6
ee18d64c1f632043a02e6f5ba5e045bb26a5465f
84,611,148,197,438,220,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...
void ImapModelOpenConnectionTest::init( bool startTlsRequired ) { Imap::Mailbox::AbstractCache* cache = new Imap::Mailbox::MemoryCache(this); factory = new Streams::FakeSocketFactory(Imap::CONN_STATE_CONNECTED_PRETLS_PRECAPS); factory->setStartTlsRequired( startTlsRequired ); Imap::Mailbox::TaskFactoryP...
0
[ "CWE-200" ]
trojita
25fffa3e25cbad85bbca804193ad336b090a9ce1
285,752,368,617,241,500,000,000,000,000,000,000,000
19
IMAP: refuse to work when STARTTLS is required but server sends PREAUTH Oops, we cannot send STARTTLS when the connection is already authenticated. This is serious enough to warrant an error; an attacker might be going after a plaintext of a message we're going to APPEND, etc. Thanks to Arnt Gulbrandsen on the imap-p...
njs_vmcode_template_literal(njs_vm_t *vm, njs_value_t *invld1, njs_value_t *retval) { njs_array_t *array; njs_value_t *value; njs_jump_off_t ret; static const njs_function_t concat = { .native = 1, .args_offset = 1, .u.native = njs_string_prototype_concat ...
0
[ "CWE-703", "CWE-754" ]
njs
222d6fdcf0c6485ec8e175f3a7b70d650c234b4e
133,894,417,491,719,730,000,000,000,000,000,000,000
33
Fixed njs_vmcode_interpreter() when "toString" conversion fails. Previously, while interpreting a user function, njs_vmcode_interpreter() might return prematurely when an error happens. This is not correct because the current frame has to be unwound (or exception caught) first. The fix is exit through only 5 appropr...
AfterTriggerSetState(ConstraintsSetStmt *stmt) { int my_level = GetCurrentTransactionNestLevel(); /* * Ignore call if we aren't in a transaction. (Shouldn't happen?) */ if (afterTriggers == NULL) return; /* * If in a subtransaction, and we didn't save the current state already, * save it so it can be...
0
[ "CWE-362" ]
postgres
5f173040e324f6c2eebb90d86cf1b0cdb5890f0a
311,837,499,081,200,450,000,000,000,000,000,000,000
279
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...
static int airspy_s_ctrl(struct v4l2_ctrl *ctrl) { struct airspy *s = container_of(ctrl->handler, struct airspy, hdl); int ret; switch (ctrl->id) { case V4L2_CID_RF_TUNER_LNA_GAIN_AUTO: case V4L2_CID_RF_TUNER_LNA_GAIN: ret = airspy_set_lna_gain(s); break; case V4L2_CID_RF_TUNER_MIXER_GAIN_AUTO: case V4L...
0
[ "CWE-119" ]
media_tree
aa93d1fee85c890a34f2510a310e55ee76a27848
339,187,752,766,960,670,000,000,000,000,000,000,000
25
media: fix airspy usb probe error path Fix a memory leak on probe error of the airspy usb device driver. The problem is triggered when more than 64 usb devices register with v4l2 of type VFL_TYPE_SDR or VFL_TYPE_SUBDEV. The memory leak is caused by the probe function of the airspy driver mishandeling errors and not ...
connection_threadmain(void *arg) { Slapi_PBlock *pb = slapi_pblock_new(); int32_t *snmp_vars_idx = (int32_t *) arg; /* wait forever for new pb until one is available or shutdown */ int32_t interval = 0; /* used be 10 seconds */ Connection *conn = NULL; Operation *op; ber_tag_t tag = 0; ...
0
[ "CWE-415" ]
389-ds-base
a3c298f8140d3e4fa1bd5a670f1bb965a21a9b7b
323,666,962,874,318,800,000,000,000,000,000,000,000
419
Issue 5218 - double-free of the virtual attribute context in persistent search (#5219) description: A search is processed by a worker using a private pblock. If the search is persistent, the worker spawn a thread and kind of duplicate its private pblock so that the spawn thread continue to process the p...
PHP_METHOD(Phar, addFile) { char *fname, *localname = NULL; int fname_len, localname_len = 0; php_stream *resource; zval *zresource; PHAR_ARCHIVE_OBJECT(); if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|s", &fname, &fname_len, &localname, &localname_len) == FAILURE) { return; } #if PHP_API_VERSION ...
0
[ "CWE-416" ]
php-src
b2cf3f064b8f5efef89bb084521b61318c71781b
2,834,458,409,593,205,000,000,000,000,000,000,000
41
Fixed bug #68901 (use after free)
int qemu_chr_fe_get_msgfd(CharBackend *be) { CharDriverState *s = be->chr; int fd; int res = (qemu_chr_fe_get_msgfds(be, &fd, 1) == 1) ? fd : -1; if (s && s->replay) { fprintf(stderr, "Replay: get msgfd is not supported for serial devices yet\n"); exit(1); } retur...
0
[ "CWE-416" ]
qemu
a4afa548fc6dd9842ed86639b4d37d4d1c4ad480
36,266,934,134,330,770,000,000,000,000,000,000,000
12
char: move front end handlers in CharBackend Since the hanlders are associated with a CharBackend, rather than the CharDriverState, it is more appropriate to store in CharBackend. This avoids the handler copy dance in qemu_chr_fe_set_handlers() then mux_chr_update_read_handler(), by storing the CharBackend pointer dir...
host_write_s2d (SF_PRIVATE *psf, const short *ptr, sf_count_t len) { BUF_UNION ubuf ; int bufferlen, writecount ; sf_count_t total = 0 ; double scale ; scale = (psf->scale_int_float == 0) ? 1.0 : 1.0 / 0x8000 ; bufferlen = ARRAY_LEN (ubuf.dbuf) ; while (len > 0) { if (len < bufferlen) bufferlen = (int) l...
0
[ "CWE-369" ]
libsndfile
85c877d5072866aadbe8ed0c3e0590fbb5e16788
290,395,553,190,978,000,000,000,000,000,000,000,000
30
double64_init: Check psf->sf.channels against upper bound This prevents division by zero later in the code. While the trivial case to catch this (i.e. sf.channels < 1) has already been covered, a crafted file may report a number of channels that is so high (i.e. > INT_MAX/sizeof(double)) that it "somehow" gets miscal...