func
string
target
int64
cwe
list
project
string
commit_id
string
hash
float64
size
int64
message
string
static struct lock *locks_conflict(struct node *node, const struct lock *lock) { struct lock *l; for (l = node->locks; l; l = l->next) if (l->owner != lock->owner && lock->start <= l->end && l->start <= lock->end && (l->type == F_WRLCK || lock->type == F_WRLCK)) brea...
0
[]
ntfs-3g
fb28eef6f1c26170566187c1ab7dc913a13ea43c
171,136,350,321,100,230,000,000,000,000,000,000,000
12
Hardened the checking of directory offset requested by a readdir When asked for the next directory entries, make sure the chunk offset is within valid values, otherwise return no more entries in chunk.
const Integer& DSA_PublicKey::GetSubGroupOrder() const { return q_; }
0
[]
mysql-server
5c6169fb309981b564a17bee31b367a18866d674
57,390,422,447,142,070,000,000,000,000,000,000,000
4
Bug #24740291: YASSL UPDATE TO 2.4.2
static int ZEND_FASTCALL ZEND_DIV_SPEC_CV_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { zend_op *opline = EX(opline); zend_free_op free_op2; div_function(&EX_T(opline->result.u.var).tmp_var, _get_zval_ptr_cv(&opline->op1, EX(Ts), BP_VAR_R TSRMLS_CC), _get_zval_ptr_var(&opline->op2, EX(Ts), &free_op2 TSRMLS_CC) TSRML...
0
[]
php-src
ce96fd6b0761d98353761bf78d5bfb55291179fd
155,623,916,676,692,470,000,000,000,000,000,000,000
12
- fix #39863, do not accept paths with NULL in them. See http://news.php.net/php.internals/50191, trunk will have the patch later (adding a macro and/or changing (some) APIs. Patch by Rasmus
md_build_attr_append_substr(MD_CTX* ctx, MD_ATTRIBUTE_BUILD* build, MD_TEXTTYPE type, OFF off) { if(build->substr_count >= build->substr_alloc) { MD_TEXTTYPE* new_substr_types; OFF* new_substr_offsets; build->substr_alloc = (build->substr_alloc > 0 ...
0
[ "CWE-125", "CWE-908" ]
md4c
4fc808d8fe8d8904f8525bb4231d854f45e23a19
115,870,168,965,719,220,000,000,000,000,000,000,000
34
md_analyze_line: Avoid reading 1 byte beyond the input size. Fixes #155.
static int __init mkiss_init_driver(void) { int status; printk(banner); status = tty_register_ldisc(&ax_ldisc); if (status != 0) printk(msg_regfail, status); return status; }
0
[ "CWE-416" ]
linux
b2f37aead1b82a770c48b5d583f35ec22aabb61e
118,224,098,997,902,200,000,000,000,000,000,000,000
12
hamradio: improve the incomplete fix to avoid NPD The previous commit 3e0588c291d6 ("hamradio: defer ax25 kfree after unregister_netdev") reorder the kfree operations and unregister_netdev operation to prevent UAF. This commit improves the previous one by also deferring the nullify of the ax->tty pointer. Otherwise, ...
AnyP::Uri::parse(const HttpRequestMethod& method, const SBuf &rawUrl) { try { LOCAL_ARRAY(char, login, MAX_URL); LOCAL_ARRAY(char, foundHost, MAX_URL); LOCAL_ARRAY(char, urlpath, MAX_URL); char *t = NULL; char *q = NULL; int foundPort; int l; int i; ...
0
[ "CWE-20" ]
squid
dfd818595b54942cb1adc45f6aed95c9b706e3a8
55,151,480,947,816,175,000,000,000,000,000,000,000
269
Merge pull request from GHSA-jvf6-h9gj-pmj6 * Add slash prefix to path-rootless or path-noscheme URLs * Update src/anyp/Uri.cc Co-authored-by: Alex Rousskov <rousskov@measurement-factory.com> * restore file trailer GH auto-removes * Remove redundant path-empty check * Removed stale comment left behind by b2ab59a ...
static int bpf_map_mmap(struct file *filp, struct vm_area_struct *vma) { struct bpf_map *map = filp->private_data; int err; if (!map->ops->map_mmap || map_value_has_spin_lock(map)) return -ENOTSUPP; if (!(vma->vm_flags & VM_SHARED)) return -EINVAL; mutex_lock(&map->freeze_mutex); if (vma->vm_flags & VM_WR...
0
[ "CWE-307" ]
linux
350a5c4dd2452ea999cc5e1d4a8dbf12de2f97ef
317,256,207,821,632,840,000,000,000,000,000,000,000
47
bpf: Dont allow vmlinux BTF to be used in map_create and prog_load. The syzbot got FD of vmlinux BTF and passed it into map_create which caused crash in btf_type_id_size() when it tried to access resolved_ids. The vmlinux BTF doesn't have 'resolved_ids' and 'resolved_sizes' initialized to save memory. To avoid such is...
static int sched_dl_global_constraints(void) { u64 runtime = global_rt_runtime(); u64 period = global_rt_period(); u64 new_bw = to_ratio(period, runtime); int cpu, ret = 0; unsigned long flags; /* * Here we want to check the bandwidth not being set to some * value smaller than the currently allocated bandwid...
0
[ "CWE-200" ]
linux
4efbc454ba68def5ef285b26ebfcfdb605b52755
286,050,099,003,654,180,000,000,000,000,000,000,000
31
sched: Fix information leak in sys_sched_getattr() We're copying the on-stack structure to userspace, but forgot to give the right number of bytes to copy. This allows the calling process to obtain up to PAGE_SIZE bytes from the stack (and possibly adjacent kernel memory). This fix copies only as much as we actually ...
dse_delete_plugin(Slapi_Entry *entry, char *returntext) { int rc = LDAP_SUCCESS; if (!slapi_entry_attr_hasvalue(entry, SLAPI_ATTR_OBJECTCLASS, "nsSlapdPlugin") || slapi_entry_attr_hasvalue(entry, "nsslapd-PluginEnabled", "off") || !config_get_dynamic_plugins()) { /* * This is n...
0
[ "CWE-200", "CWE-203" ]
389-ds-base
b6aae4d8e7c8a6ddd21646f94fef1bf7f22c3f32
317,923,975,453,235,140,000,000,000,000,000,000,000
17
Issue 4609 - CVE - info disclosure when authenticating Description: If you bind as a user that does not exist. Error 49 is returned instead of error 32. As error 32 discloses that the entry does not exist. When you bind as an entry that does not have userpassword set then ...
evdev_tag_keyboard_external(struct evdev_device *device) { device->tags |= EVDEV_TAG_EXTERNAL_KEYBOARD; device->tags &= ~EVDEV_TAG_INTERNAL_KEYBOARD; }
0
[ "CWE-134" ]
libinput
a423d7d3269dc32a87384f79e29bb5ac021c83d1
191,380,611,669,450,050,000,000,000,000,000,000,000
5
evdev: strip the device name of format directives This fixes a format string vulnerabilty. evdev_log_message() composes a format string consisting of a fixed prefix (including the rendered device name) and the passed-in format buffer. This format string is then passed with the arguments to the actual log handler, whi...
struct r_bin_pe_addr_t* PE_(r_bin_pe_get_entrypoint)(struct PE_(r_bin_pe_obj_t)* bin) { struct r_bin_pe_addr_t* entry = NULL; static bool debug = false; PE_DWord pe_entry; int i; ut64 base_addr = PE_(r_bin_pe_get_image_base) (bin); if (!bin || !bin->optional_header) { return NULL; } if (!(entry = malloc (size...
0
[ "CWE-125" ]
radare2
4e1cf0d3e6f6fe2552a269def0af1cd2403e266c
246,670,539,767,484,800,000,000,000,000,000,000,000
84
Fix crash in pe
compose_header_get (compose_env_t *env, char *name, char *defval) { char const *p; if (mu_header_sget_value (env->header, name, &p)) p = defval; return p; }
0
[]
mailutils
4befcfd015256c568121653038accbd84820198f
69,645,942,483,120,800,000,000,000,000,000,000,000
8
mail: disable compose escapes in non-interctive mode. * NEWS: Document changes. * doc/texinfo/programs/mail.texi: Document changes. * mail/send.c (mail_compose_send): Recognize escapes only in interactive mode.
static int sig_cb(const char *elem, int len, void *arg) { sig_cb_st *sarg = arg; size_t i; char etmp[20], *p; int sig_alg = NID_undef, hash_alg = NID_undef; if (elem == NULL) return 0; if (sarg->sigalgcnt == MAX_SIGALGLEN) return 0; if (len > (int)(sizeof(etmp) - 1)) ...
0
[ "CWE-20" ]
openssl
4ad93618d26a3ea23d36ad5498ff4f59eff3a4d2
260,704,077,199,120,880,000,000,000,000,000,000,000
36
Don't change the state of the ETM flags until CCS processing Changing the ciphersuite during a renegotiation can result in a crash leading to a DoS attack. ETM has not been implemented in 1.1.0 for DTLS so this is TLS only. The problem is caused by changing the flag indicating whether to use ETM or not immediately on...
nfs3svc_encode_post_op_attr(struct svc_rqst *rqstp, __be32 *p, struct svc_fh *fhp) { return encode_post_op_attr(rqstp, p, fhp); }
0
[ "CWE-119", "CWE-703" ]
linux
13bf9fbff0e5e099e2b6f003a0ab8ae145436309
277,829,227,819,124,930,000,000,000,000,000,000,000
4
nfsd: stricter decoding of write-like NFSv2/v3 ops The NFSv2/v3 code does not systematically check whether we decode past the end of the buffer. This generally appears to be harmless, but there are a few places where we do arithmetic on the pointers involved and don't account for the possibility that a length could b...
PyBytes_FromObject(PyObject *x) { PyObject *new, *it; Py_ssize_t i, size; if (x == NULL) { PyErr_BadInternalCall(); return NULL; } if (PyBytes_CheckExact(x)) { Py_INCREF(x); return x; } /* Use the modern buffer interface */ if (PyObject_CheckBuffer(x)) ...
0
[ "CWE-190" ]
cpython
fd8614c5c5466a14a945db5b059c10c0fb8f76d9
278,271,786,375,165,570,000,000,000,000,000,000,000
147
bpo-30657: Fix CVE-2017-1000158 (#4664) Fixes possible integer overflow in PyBytes_DecodeEscape. Co-Authored-By: Jay Bosamiya <jaybosamiya@gmail.com>
unsigned long task_vsize(struct mm_struct *mm) { return PAGE_SIZE * mm->total_vm; }
0
[ "CWE-264" ]
linux-2.6
1a5a9906d4e8d1976b701f889d8f35d54b928f25
55,819,888,481,796,030,000,000,000,000,000,000,000
4
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 format_adata(u8 *adata, unsigned int a) { int len = 0; /* add control info for associated data * RFC 3610 and NIST Special Publication 800-38C */ if (a < 65280) { *(__be16 *)adata = cpu_to_be16(a); len = 2; } else { *(__be16 *)adata = cpu_to_be16(0xfffe); *(__be32 *)&adata[2] = cpu_to_be32(...
0
[ "CWE-119", "CWE-787" ]
linux
3b30460c5b0ed762be75a004e924ec3f8711e032
96,965,255,011,727,980,000,000,000,000,000,000,000
18
crypto: ccm - move cbcmac input off the stack Commit f15f05b0a5de ("crypto: ccm - switch to separate cbcmac driver") refactored the CCM driver to allow separate implementations of the underlying MAC to be provided by a platform. However, in doing so, it moved some data from the linear region to the stack, which violat...
same_color(NCURSES_CONST char *oldcap, NCURSES_CONST char *newcap, int limit) { bool result = FALSE; if (limit > 16) limit = 16; if (limit >= 8) { int n; int same; for (n = same = 0; n < limit; ++n) { char *oldvalue = safe_strdup(TIPARM_1(oldcap, n)); char *newvalue = safe_strdup(TIPARM_1(newc...
0
[]
ncurses
790a85dbd4a81d5f5d8dd02a44d84f01512ef443
253,825,300,174,622,360,000,000,000,000,000,000,000
19
ncurses 6.2 - patch 20200531 + correct configure version-check/warnng for g++ to allow for 10.x + re-enable "bel" in konsole-base (report by Nia Huang) + add linux-s entry (patch by Alexandre Montaron). + drop long-obsolete convert_configure.pl + add test/test_parm.c, for checking tparm changes. + improve parameter-ch...
zalloc (voidpf opaque, uInt items, uInt size) { return g_malloc (items *size); }
0
[ "CWE-787" ]
gcab
c512f6ff0c82a1139b36db2b28f93edc01c74b4b
218,979,485,535,165,950,000,000,000,000,000,000,000
4
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()
get_word_rgb_row(j_compress_ptr cinfo, cjpeg_source_ptr sinfo) /* This version is for reading raw-word-format PPM files with any maxval */ { ppm_source_ptr source = (ppm_source_ptr)sinfo; register JSAMPROW ptr; register U_CHAR *bufferptr; register JSAMPLE *rescale = source->rescale; JDIMENSION col; unsigned...
1
[ "CWE-200", "CWE-787" ]
libjpeg-turbo
f35fd27ec641c42d6b115bfa595e483ec58188d2
204,167,080,044,373,300,000,000,000,000,000,000,000
34
tjLoadImage: Fix issues w/loading 16-bit PPMs/PGMs - The PPM reader now throws an error rather than segfaulting (due to a buffer overrun) if an application attempts to load a 16-bit PPM file into a grayscale uncompressed image buffer. No known applications allowed that (not even the test applications in libjpeg...
static __always_inline void vmcs_clear_bits(unsigned long field, u32 mask) { BUILD_BUG_ON_MSG(__builtin_constant_p(field) && ((field) & 0x6000) == 0x2000, "vmcs_clear_bits does not support 64-bit fields"); if (static_branch_unlikely(&enable_evmcs)) return evmcs_write32(field, evmcs_read32(field) & ~mask)...
0
[ "CWE-284" ]
linux
727ba748e110b4de50d142edca9d6a9b7e6111d8
176,640,779,138,141,550,000,000,000,000,000,000,000
9
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...
__acquires(&hb->lock) { struct futex_hash_bucket *hb; hb = hash_futex(&q->key); /* * Increment the counter before taking the lock so that * a potential waker won't miss a to-be-slept task that is * waiting for the spinlock. This is safe as all queue_lock() * users end up calling queue_me(). Similarly, for...
0
[ "CWE-416" ]
tip
8019ad13ef7f64be44d4f892af9c840179009254
197,990,017,869,982,700,000,000,000,000,000,000,000
21
futex: Fix inode life-time issue As reported by Jann, ihold() does not in fact guarantee inode persistence. And instead of making it so, replace the usage of inode pointers with a per boot, machine wide, unique inode identifier. This sequence number is global, but shared (file backed) futexes are rare enough that thi...
static inline const char *skip_separator(const char *p) { while (p && (*p == ' ' || *p == '\t')) ++p; return p; }
0
[ "CWE-552", "CWE-703" ]
util-linux
166e87368ae88bf31112a30e078cceae637f4cdb
150,168,733,657,161,540,000,000,000,000,000,000,000
6
libmount: remove support for deleted mount table entries The "(deleted)" suffix has been originally used by kernel for deleted mountpoints. Since kernel commit 9d4d65748a5ca26ea8650e50ba521295549bf4e3 (Dec 2014) kernel does not use this suffix for mount stuff in /proc at all. Let's remove this support from libmount to...
long long SegmentInfo::GetTimeCodeScale() const { return m_timecodeScale; }
0
[ "CWE-20" ]
libvpx
34d54b04e98dd0bac32e9aab0fbda0bf501bc742
17,995,909,418,888,928,000,000,000,000,000,000,000
1
update libwebm to libwebm-1.0.0.27-358-gdbf1d10 changelog: https://chromium.googlesource.com/webm/libwebm/+log/libwebm-1.0.0.27-351-g9f23fbc..libwebm-1.0.0.27-358-gdbf1d10 Change-Id: I28a6b3ae02a53fb1f2029eee11e9449afb94c8e3
cdf_read_property_info(const cdf_stream_t *sst, const cdf_header_t *h, uint32_t offs, cdf_property_info_t **info, size_t *count, size_t *maxcount) { const cdf_section_header_t *shp; cdf_section_header_t sh; const uint8_t *p, *q, *e; int16_t s16; int32_t s32; uint32_t u32; int64_t s64; uint64_t u64; cdf_tim...
1
[ "CWE-20" ]
file
93e063ee374b6a75729df9e7201fb511e47e259d
282,236,046,523,842,370,000,000,000,000,000,000,000
193
Add missing check offset test (Francisco Alonso, Jan Kaluza at RedHat)
virtual ~FeatureReader() {}
0
[ "CWE-125", "CWE-369" ]
tensorflow
44b7f486c0143f68b56c34e2d01e146ee445134a
53,095,704,346,182,130,000,000,000,000,000,000,000
1
Fix out of bounds read in `ragged_cross_op.cc`. PiperOrigin-RevId: 369757702 Change-Id: Ie6e5d2c21513a8d56bf41fcf35960caf76e890f9
static void mntput_no_expire(struct mount *mnt) { put_again: #ifdef CONFIG_SMP br_read_lock(&vfsmount_lock); if (likely(mnt->mnt_ns)) { /* shouldn't be the last one */ mnt_add_count(mnt, -1); br_read_unlock(&vfsmount_lock); return; } br_read_unlock(&vfsmount_lock); br_write_lock(&vfsmount_lock); mnt_add_...
0
[ "CWE-284", "CWE-264" ]
linux
3151527ee007b73a0ebd296010f1c0454a919c7d
146,232,645,442,865,420,000,000,000,000,000,000,000
37
userns: Don't allow creation if the user is chrooted Guarantee that the policy of which files may be access that is established by setting the root directory will not be violated by user namespaces by verifying that the root directory points to the root of the mount namespace at the time of user namespace creation. ...
int vterm_screen_get_attrs_extent(const VTermScreen *screen, VTermRect *extent, VTermPos pos, VTermAttrMask attrs) { int col; ScreenCell *target = getcell(screen, pos.row, pos.col); // TODO: bounds check extent->start_row = pos.row; extent->end_row = pos.row + 1; if(extent->start_col < 0) extent->s...
0
[ "CWE-476" ]
vim
cd929f7ba8cc5b6d6dcf35c8b34124e969fed6b8
216,464,322,928,107,830,000,000,000,000,000,000,000
27
patch 8.1.0633: crash when out of memory while opening a terminal window Problem: Crash when out of memory while opening a terminal window. Solution: Handle out-of-memory more gracefully.
GF_Err gf_bin128_parse(const char *string, bin128 value) { u32 len; u32 i=0; if (!strnicmp(string, "0x", 2)) string += 2; len = (u32) strlen(string); if (len >= 32) { u32 j; for (j=0; j<len; j+=2) { u32 v; char szV[5]; while (string[j] && !isalnum(string[j])) j++; if (!string[j]) break; ...
1
[ "CWE-787" ]
gpac
f3698bb1bce62402805c3fda96551a23101a32f9
5,091,138,800,974,277,000,000,000,000,000,000,000
28
fix buffer overrun in gf_bin128_parse closes #1204 closes #1205
rb_external_str_new_cstr(const char *ptr) { return rb_external_str_new_with_enc(ptr, strlen(ptr), rb_default_external_encoding()); }
0
[ "CWE-119" ]
ruby
1c2ef610358af33f9ded3086aa2d70aac03dcac5
103,408,705,123,285,280,000,000,000,000,000,000,000
4
* string.c (rb_str_justify): CVE-2009-4124. Fixes a bug reported by Emmanouel Kellinis <Emmanouel.Kellinis AT kpmg.co.uk>, KPMG London; Patch by nobu. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@26038 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
eval1_emsg(char_u **arg, typval_T *rettv, exarg_T *eap) { char_u *start = *arg; int ret; int did_emsg_before = did_emsg; int called_emsg_before = called_emsg; evalarg_T evalarg; fill_evalarg_from_eap(&evalarg, eap, eap != NULL && eap->skip); ret = eval1(arg, rettv, &evalarg); if (re...
0
[ "CWE-122", "CWE-787" ]
vim
605ec91e5a7330d61be313637e495fa02a6dc264
224,595,178,270,029,750,000,000,000,000,000,000,000
24
patch 8.2.3847: illegal memory access when using a lambda with an error Problem: Illegal memory access when using a lambda with an error. Solution: Avoid skipping over the NUL after a string.
get_y_previous(void) { return y_previous; }
0
[ "CWE-122", "CWE-787" ]
vim
d25f003342aca9889067f2e839963dfeccf1fe05
87,682,327,803,436,200,000,000,000,000,000,000,000
4
patch 9.0.0011: reading beyond the end of the line with put command Problem: Reading beyond the end of the line with put command. Solution: Adjust the end mark position.
defaultFormat (Compressor * compressor) { return compressor? compressor->format(): Compressor::XDR; }
0
[ "CWE-125" ]
openexr
e79d2296496a50826a15c667bf92bdc5a05518b4
58,664,259,914,795,940,000,000,000,000,000,000,000
4
fix memory leaks and invalid memory accesses Signed-off-by: Peter Hillman <peterh@wetafx.co.nz>
build_packet( IOBUF out, PACKET *pkt ) { int new_ctb=0, rc=0, ctb; int pkttype; if( DBG_PACKET ) log_debug("build_packet() type=%d\n", pkt->pkttype ); assert( pkt->pkt.generic ); switch ((pkttype = pkt->pkttype)) { case PKT_PUBLIC_KEY: if (pkt->pkt.public_key->seckey_info) ...
0
[ "CWE-20" ]
gnupg
2183683bd633818dd031b090b5530951de76f392
280,230,942,584,419,560,000,000,000,000,000,000,000
90
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 ...
static void adaptive_pebs_save_regs(struct pt_regs *regs, struct pebs_gprs *gprs) { regs->ax = gprs->ax; regs->bx = gprs->bx; regs->cx = gprs->cx; regs->dx = gprs->dx; regs->si = gprs->si; regs->di = gprs->di; regs->bp = gprs->bp; regs->sp = gprs->sp; #ifndef CONFIG_X86_32 regs->r8 = gprs->r8; regs->r...
0
[ "CWE-755" ]
linux
d88d05a9e0b6d9356e97129d4ff9942d765f46ea
164,293,093,453,037,700,000,000,000,000,000,000,000
22
perf/x86/intel: Fix a crash caused by zero PEBS status A repeatable crash can be triggered by the perf_fuzzer on some Haswell system. https://lore.kernel.org/lkml/7170d3b-c17f-1ded-52aa-cc6d9ae999f4@maine.edu/ For some old CPUs (HSW and earlier), the PEBS status in a PEBS record may be mistakenly set to 0. To minimiz...
WandExport void DrawSetStrokeColor(DrawingWand *wand, const PixelWand *stroke_wand) { PixelInfo *current_stroke, new_stroke, stroke_color; assert(wand != (DrawingWand *) NULL); assert(wand->signature == MagickWandSignature); if (wand->debug != MagickFalse) (void) LogMagickEvent(WandEvent,GetM...
0
[ "CWE-476" ]
ImageMagick
6ad5fc3c9b652eec27fc0b1a0817159f8547d5d9
120,592,477,387,747,890,000,000,000,000,000,000,000
25
https://github.com/ImageMagick/ImageMagick/issues/716
static inline ut64 r_read_at_le64(const void *src, size_t offset) { const ut8 *s = ((const ut8*)src) + offset; return r_read_le64 (s); }
0
[ "CWE-476" ]
radare2
1ea23bd6040441a21fbcfba69dce9a01af03f989
61,058,702,779,389,335,000,000,000,000,000,000,000
4
Fix #6816 - null deref in r_read_*
static void input_dev_release(struct device *device) { struct input_dev *dev = to_input_dev(device); input_ff_destroy(dev); input_mt_destroy_slots(dev); kfree(dev->poller); kfree(dev->absinfo); kfree(dev->vals); kfree(dev); module_put(THIS_MODULE); }
0
[ "CWE-703", "CWE-787" ]
linux
cb222aed03d798fc074be55e59d9a112338ee784
59,736,267,741,139,600,000,000,000,000,000,000,000
13
Input: add safety guards to input_set_keycode() If we happen to have a garbage in input device's keycode table with values too big we'll end up doing clear_bit() with offset way outside of our bitmaps, damaging other objects within an input device or even outside of it. Let's add sanity checks to the returned old keyc...
static php_cli_server_chunk *php_cli_server_chunk_heap_new(char *block, char *buf, size_t len) /* {{{ */ { php_cli_server_chunk *chunk = pemalloc(sizeof(php_cli_server_chunk), 1); if (!chunk) { return NULL; } chunk->type = PHP_CLI_SERVER_CHUNK_HEAP; chunk->next = NULL; chunk->data.heap.block = block; chunk->d...
0
[]
php-src
2438490addfbfba51e12246a74588b2382caa08a
265,749,506,289,682,600,000,000,000,000,000,000,000
14
slim post data
MonoReflectionMethod* mono_reflection_bind_generic_method_parameters (MonoReflectionMethod *rmethod, MonoArray *types) { MonoClass *klass; MonoMethod *method, *inflated; MonoMethodInflated *imethod; MonoGenericContext tmp_context; MonoGenericInst *ginst; MonoType **type_argv; int count, i; MONO_ARCH_SAVE_REGS;...
1
[ "CWE-20" ]
mono
4905ef1130feb26c3150b28b97e4a96752e0d399
340,166,980,670,027,100,000,000,000,000,000,000,000
67
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
Unpickler_set_memo(UnpicklerObject *self, PyObject *obj) { PyObject **new_memo; Py_ssize_t new_memo_size = 0; Py_ssize_t i; if (obj == NULL) { PyErr_SetString(PyExc_TypeError, "attribute deletion is not supported"); return -1; } if (Py_TYPE(obj) == &Unpi...
1
[ "CWE-190", "CWE-369" ]
cpython
a4ae828ee416a66d8c7bf5ee71d653c2cc6a26dd
58,930,962,556,747,295,000,000,000,000,000,000,000
77
closes bpo-34656: Avoid relying on signed overflow in _pickle memos. (GH-9261)
OFCondition DcmSCP::sendFINDResponse(const T_ASC_PresentationContextID presID, const Uint16 messageID, const OFString &sopClassUID, DcmDataset *rspDataset, const Uint16 rsp...
0
[ "CWE-264" ]
dcmtk
beaf5a5c24101daeeafa48c375120b16197c9e95
268,770,246,063,523,730,000,000,000,000,000,000,000
44
Make sure to handle setuid() return code properly. In some tools the return value of setuid() is not checked. In the worst case this could lead to privilege escalation since the process does not give up its root privileges and continue as root.
static int checkout_stream_write( git_writestream *s, const char *buffer, size_t len) { struct checkout_stream *stream = (struct checkout_stream *)s; int ret; if ((ret = p_write(stream->fd, buffer, len)) < 0) git_error_set(GIT_ERROR_OS, "could not write to '%s'", stream->path); return ret; }
0
[ "CWE-20", "CWE-706" ]
libgit2
64c612cc3e25eff5fb02c59ef5a66ba7a14751e4
47,796,957,840,740,080,000,000,000,000,000,000,000
11
Protect against 8.3 "short name" attacks also on Linux/macOS The Windows Subsystem for Linux (WSL) is getting increasingly popular, in particular because it makes it _so_ easy to run Linux software on Windows' files, via the auto-mounted Windows drives (`C:\` is mapped to `/mnt/c/`, no need to set that up manually). ...
void shut_down(int code) { int i; in_shutdown = 1; proc_cleanup(); /* close local mailbox */ if (group_state) index_close(&group_state); /* close backend connections */ i = 0; while (backend_cached && backend_cached[i]) { proxy_downserver(backend_cached[i]); free(backend_cached[i]...
0
[ "CWE-119" ]
cyrus-imapd
0f8f026699829b65733c3081657b24e2174f4f4d
302,721,312,990,611,400,000,000,000,000,000,000,000
61
CVE-2011-3208 - fix buffer overflow in nntpd
explicit MemoryBuffer(const Allocator &alloc = Allocator()) : Allocator(alloc), Buffer<T>(data_, SIZE) {}
0
[ "CWE-134", "CWE-119", "CWE-787" ]
fmt
8cf30aa2be256eba07bb1cefb998c52326e846e7
159,848,544,744,621,230,000,000,000,000,000,000,000
2
Fix segfault on complex pointer formatting (#642)
bool Item_cache_row::check_cols(uint c) { if (c != item_count) { my_error(ER_OPERAND_COLUMNS, MYF(0), c); return 1; } return 0; }
0
[]
server
b000e169562697aa072600695d4f0c0412f94f4f
212,972,756,036,716,250,000,000,000,000,000,000,000
9
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'...
int Elf_(r_bin_elf_has_nx)(ELFOBJ *bin) { int i; if (bin && bin->phdr) { for (i = 0; i < bin->ehdr.e_phnum; i++) { if (bin->phdr[i].p_type == PT_GNU_STACK) { return (!(bin->phdr[i].p_flags & 1))? 1: 0; } } } return 0; }
0
[ "CWE-125" ]
radare2
c6d0076c924891ad9948a62d89d0bcdaf965f0cd
48,934,573,641,249,970,000,000,000,000,000,000,000
11
Fix #8731 - Crash in ELF parser with negative 32bit number
static irqreturn_t ismt_do_msi_interrupt(int vec, void *data) { return ismt_handle_isr(data); }
0
[ "CWE-120", "CWE-131", "CWE-703" ]
linux
690b2549b19563ec5ad53e5c82f6a944d910086e
322,383,189,011,596,900,000,000,000,000,000,000,000
4
i2c: ismt: prevent memory corruption in ismt_access() The "data->block[0]" variable comes from the user and is a number between 0-255. It needs to be capped to prevent writing beyond the end of dma_buffer[]. Fixes: 5e9a97b1f449 ("i2c: ismt: Adding support for I2C_SMBUS_BLOCK_PROC_CALL") Reported-and-tested-by: Zheyu...
create_watching_parent (void) { pid_t child; sigset_t ourset; struct sigaction oldact[3]; int status = 0; int retval; retval = pam_open_session (pamh, 0); if (is_pam_failure(retval)) { cleanup_pam (retval); errx (EXIT_FAILURE, _("cannot open session: %s"), pam_strerror (pamh, retval...
1
[ "CWE-362" ]
util-linux
dffab154d29a288aa171ff50263ecc8f2e14a891
232,848,394,112,488,340,000,000,000,000,000,000,000
148
su: properly clear child PID Reported-by: Tobias Stöckmann <tobias@stoeckmann.org> Signed-off-by: Karel Zak <kzak@redhat.com>
static struct buffer_head *ext4_append(handle_t *handle, struct inode *inode, ext4_lblk_t *block, int *err) { struct buffer_head *bh; if (unlikely(EXT4_SB(inode->i_sb)->s_max_dir_size_kb && ((inode->i_size >> 10) >= EXT4_SB(inode->i_sb)->s_max_dir_size_kb))) { *err = -ENOSPC; return NULL...
0
[ "CWE-20" ]
linux
c9b92530a723ac5ef8e352885a1862b18f31b2f5
28,064,461,047,973,560,000,000,000,000,000,000,000
27
ext4: make orphan functions be no-op in no-journal mode Instead of checking whether the handle is valid, we check if journal is enabled. This avoids taking the s_orphan_lock mutex in all cases when there is no journal in use, including the error paths where ext4_orphan_del() is called with a handle set to NULL. Signe...
static int callback_get(void *data) { char c; callback_data_t *stream = data; if(stream->pos >= stream->len) { stream->pos = 0; stream->len = stream->callback(stream->data, MAX_BUF_LEN, stream->arg); if(stream->len == 0 || stream->len == (size_t)-1) return EOF; } ...
0
[ "CWE-20" ]
jansson
64ce0ad3731ebd77e02897b07920eadd0e2cc318
170,153,215,340,954,100,000,000,000,000,000,000,000
16
Fix for issue #282 The fix limits recursion depths when parsing arrays and objects. The limit is configurable via the `JSON_PARSER_MAX_DEPTH` setting within `jansson_config.h` and is set by default to 2048. Update the RFC conformance document to note the limit; the RFC allows limits to be set by the implementation so...
void ModuleSQL::OnRehash(User* user) { ConnMap conns; ConfigTagList tags = ServerInstance->Config->ConfTags("database"); for(ConfigIter i = tags.first; i != tags.second; i++) { if (i->second->getString("module", "mysql") != "mysql") continue; std::string id = i->second->getString("id"); ConnMap::iterator c...
0
[ "CWE-476" ]
inspircd
2cc35d8625b7ea5cbd1d1ebb116aff86c5280162
164,633,032,726,259,730,000,000,000,000,000,000,000
49
Initialise and deallocate the MySQL library correctly.
ftp_do_port (int csock, int *local_sock) { if (!opt.server_response) logputs (LOG_VERBOSE, "==> PORT ... "); return ftp_port (csock, local_sock); }
0
[ "CWE-20" ]
wget
3e25a9817f47fbb8660cc6a3b2f3eea239526c6c
38,416,232,074,415,263,000,000,000,000,000,000,000
6
Introduce --trust-server-names. Close CVE-2010-2252.
static double ga_get_login_time(struct utmpx *user_info) { double seconds = (double)user_info->ut_tv.tv_sec; double useconds = (double)user_info->ut_tv.tv_usec; useconds /= QGA_MICRO_SECOND_TO_SECOND; return seconds + useconds; }
0
[ "CWE-190" ]
qemu
141b197408ab398c4f474ac1a728ab316e921f2b
117,450,033,702,481,570,000,000,000,000,000,000,000
7
qga: check bytes count read by guest-file-read While reading file content via 'guest-file-read' command, 'qmp_guest_file_read' routine allocates buffer of count+1 bytes. It could overflow for large values of 'count'. Add check to avoid it. Reported-by: Fakhri Zulkifli <mohdfakhrizulkifli@gmail.com> Signed-off-by: Pra...
static VOID VCAPITYPE drdynvc_virtual_channel_init_event_ex(LPVOID lpUserParam, LPVOID pInitHandle, UINT event, LPVOID pData, UINT dataLength) { UINT error = CHANNEL_RC_OK; drdynvcPlugin* drdynvc = (drdynvcPlugin*) lpUserParam; if (!drdynvc || (drdynvc->InitHandle != pInitHandle)) { WLog_ERR(TAG, "drdynv...
0
[ "CWE-125" ]
FreeRDP
baee520e3dd9be6511c45a14c5f5e77784de1471
132,056,273,617,003,850,000,000,000,000,000,000,000
57
Fix for #4866: Added additional length checks
enum_func_status php_mysqlnd_rowp_read_text_protocol_aux(MYSQLND_MEMORY_POOL_CHUNK * row_buffer, zval ** fields, unsigned int field_count, const MYSQLND_FIELD * fields_metadata, zend_bool as_int_or_float, zend_bool copy_data, MYSQLND_STATS * stats TSRMLS_DC) { unsigned int i; zend_bool last_field_...
1
[ "CWE-119", "CWE-787" ]
php-src
28f80baf3c53e267c9ce46a2a0fadbb981585132
185,803,420,179,456,460,000,000,000,000,000,000,000
182
Fix bug #72293 - Heap overflow in mysqlnd related to BIT fields
bool is_shared() const { return _is_shared; }
0
[ "CWE-770" ]
cimg
619cb58dd90b4e03ac68286c70ed98acbefd1c90
316,606,923,210,641,440,000,000,000,000,000,000,000
3
CImg<>::load_bmp() and CImg<>::load_pandore(): Check that dimensions encoded in file does not exceed file size.
int ttm_populate_and_map_pages(struct device *dev, struct ttm_dma_tt *tt, struct ttm_operation_ctx *ctx) { unsigned i, j; int r; r = ttm_pool_populate(&tt->ttm, ctx); if (r) return r; for (i = 0; i < tt->ttm.num_pages; ++i) { struct page *p = tt->ttm.pages[i]; size_t num_pages = 1; for (j = i + 1; ...
0
[ "CWE-125" ]
linux
453393369dc9806d2455151e329c599684762428
70,713,205,533,137,100,000,000,000,000,000,000,000
41
drm/ttm: fix incrementing the page pointer for huge pages When we increment the counter we need to increment the pointer as well. Signed-off-by: Christian König <christian.koenig@amd.com> Fixes: e16858a7e6e7 drm/ttm: fix start page for huge page check in ttm_put_pages() Reviewed-by: Michel Dänzer <michel.daenzer@amd....
void ComparisonQuantized(const TfLiteTensor* input1, const TfLiteTensor* input2, TfLiteTensor* output, bool requires_broadcast) { if (input1->type == kTfLiteUInt8 || input1->type == kTfLiteInt8) { auto input1_offset = -input1->params.zero_point; auto input2_offset = -input2->params.ze...
1
[ "CWE-20", "CWE-703" ]
tensorflow
a989426ee1346693cc015792f11d715f6944f2b8
207,684,057,347,604,920,000,000,000,000,000,000,000
37
Improve to cover scale value greater than one PiperOrigin-RevId: 433050921
bool AuthorizationManager::hasInternalAuthorization() { ActionSet allActions; allActions.addAllActions(); return _acquiredPrivileges.hasPrivilege(Privilege(PrivilegeSet::WILDCARD_RESOURCE, allActions)); }
0
[ "CWE-264" ]
mongo
23344f8b7506df694f66999693ee3c00dfd6afae
97,636,876,752,207,000,000,000,000,000,000,000,000
6
SERVER-9983 Do not needlessly lock when looking up privileges for the __system@local user. Uncorrected, this can cause replica set heartbeats to stall behind operations that hold the read lock for a long time.
static sdp_record_t *avrcp_tg_record(void) { sdp_list_t *svclass_id, *pfseq, *apseq, *root, *apseq_browsing; uuid_t root_uuid, l2cap, avctp, avrtg; sdp_profile_desc_t profile[1]; sdp_list_t *aproto_control, *proto_control[2]; sdp_record_t *record; sdp_data_t *psm_control, *version, *features, *psm_browsing; sdp_...
0
[ "CWE-200" ]
bluez
e2b0f0d8d63e1223bb714a9efb37e2257818268b
96,463,097,507,875,550,000,000,000,000,000,000,000
88
avrcp: Fix not checking if params_len match number of received bytes This makes sure the number of bytes in the params_len matches the remaining bytes received so the code don't end up accessing invalid memory.
MagickExport MagickBooleanType SetQuantumPad(const Image *image, QuantumInfo *quantum_info,const size_t pad) { assert(image != (Image *) NULL); assert(image->signature == MagickCoreSignature); if (image->debug != MagickFalse) (void) LogMagickEvent(TraceEvent,GetMagickModule(),"%s",image->filename); assert...
0
[ "CWE-369" ]
ImageMagick
c4e63ad30bc42da691f2b5f82a24516dd6b4dc70
34,134,135,888,430,935,000,000,000,000,000,000,000
12
https://github.com/ImageMagick/ImageMagick/issues/105
static void wcd9335_codec_enable_int_port(struct wcd_slim_codec_dai_data *dai, struct snd_soc_component *component) { int port_num = 0; unsigned short reg = 0; unsigned int val = 0; struct wcd9335_codec *wcd = dev_get_drvdata(component->dev); struct wcd9335_slim_ch *ch; list_for_each_entry(ch, &dai->slim_ch...
0
[]
sound
a54988113985ca22e414e132054f234fc8a92604
206,876,293,095,809,180,000,000,000,000,000,000,000
24
wcd9335: fix a incorrect use of kstrndup() In wcd9335_codec_enable_dec(), 'widget_name' is allocated by kstrndup(). However, according to doc: "Note: Use kmemdup_nul() instead if the size is known exactly." So we should use kmemdup_nul() here instead of kstrndup(). Signed-off-by: Gen Zhang <blackgod016574@gmail.com> ...
p_ere_exp(p) register struct parse *p; { register char c; register sopno pos; register int count; register int count2; register sopno subno; int wascaret = 0; assert(MORE()); /* caller should have ensured this */ c = GETNEXT(); pos = HERE(); switch (c) { case '(': if(REQUIRE(MORE(), REG_EPAREN)) {} p-...
0
[ "CWE-190" ]
mysql-server
dc45e408250c582eb532417a42cef5b5a8e2fe77
187,731,089,868,674,200,000,000,000,000,000,000,000
133
Bug#20642505: HENRY SPENCER REGULAR EXPRESSIONS (REGEX) LIBRARY The MySQL server uses Henry Spencer's library for regular expressions to support the REGEXP/RLIKE string operator. This changeset adapts a recent fix from the upstream for better 32-bit compatiblity. (Note that we cannot simply use the current upstream ve...
ftrace_suspend_notifier_call(struct notifier_block *bl, unsigned long state, void *unused) { switch (state) { case PM_HIBERNATION_PREPARE: pause_graph_tracing(); break; case PM_POST_HIBERNATION: unpause_graph_tracing(); break; } return NOTIFY_DONE; }
0
[ "CWE-703" ]
linux
6a76f8c0ab19f215af2a3442870eeb5f0e81998d
286,205,025,420,262,300,000,000,000,000,000,000,000
14
tracing: Fix possible NULL pointer dereferences Currently set_ftrace_pid and set_graph_function files use seq_lseek for their fops. However seq_open() is called only for FMODE_READ in the fops->open() so that if an user tries to seek one of those file when she open it for writing, it sees NULL seq_file and then panic...
void nl80211_send_cqm_pktloss_notify(struct cfg80211_registered_device *rdev, struct net_device *netdev, const u8 *peer, u32 num_packets, gfp_t gfp) { struct sk_buff *msg; struct nlattr *pinfoattr; void *hdr; msg = nlmsg_new(NLMSG_GOODSIZE, gfp); if (!msg) return; hdr = nl80211hdr_put(msg, 0, 0, 0, NL...
0
[ "CWE-362", "CWE-119" ]
linux
208c72f4fe44fe09577e7975ba0e7fa0278f3d03
126,712,464,025,361,960,000,000,000,000,000,000,000
43
nl80211: fix check for valid SSID size in scan operations In both trigger_scan and sched_scan operations, we were checking for the SSID length before assigning the value correctly. Since the memory was just kzalloc'ed, the check was always failing and SSID with over 32 characters were allowed to go through. This was...
check_visual_pos(void) { if (VIsual.lnum > curbuf->b_ml.ml_line_count) { VIsual.lnum = curbuf->b_ml.ml_line_count; VIsual.col = 0; VIsual.coladd = 0; } else { int len = (int)STRLEN(ml_get(VIsual.lnum)); if (VIsual.col > len) { VIsual.col = len; VIsual.coladd = 0; } } }
0
[ "CWE-120" ]
vim
7ce5b2b590256ce53d6af28c1d203fb3bc1d2d97
33,656,371,437,360,500,000,000,000,000,000,000,000
19
patch 8.2.4969: changing text in Visual mode may cause invalid memory access Problem: Changing text in Visual mode may cause invalid memory access. Solution: Check the Visual position after making a change.
CharacterClass(const std::vector<std::pair<char32_t, char32_t>> &ranges, bool negated) : ranges_(ranges), negated_(negated) { assert(!ranges_.empty()); }
0
[ "CWE-125" ]
cpp-peglib
b3b29ce8f3acf3a32733d930105a17d7b0ba347e
148,555,921,241,380,650,000,000,000,000,000,000,000
5
Fix #122
double val_real() { return has_value() ? Date(this).to_double() : 0; }
0
[ "CWE-617" ]
server
807945f2eb5fa22e6f233cc17b85a2e141efe2c8
225,941,273,365,644,900,000,000,000,000,000,000,000
1
MDEV-26402: A SEGV in Item_field::used_tables/update_depend_map_for_order... When doing condition pushdown from HAVING into WHERE, Item_equal::create_pushable_equalities() calls item->set_extraction_flag(IMMUTABLE_FL) for constant items. Then, Item::cleanup_excluding_immutables_processor() checks for this flag to see ...
static int wcd9335_set_compander(struct snd_kcontrol *kc, struct snd_ctl_elem_value *ucontrol) { struct snd_soc_component *component = snd_soc_kcontrol_component(kc); struct wcd9335_codec *wcd = dev_get_drvdata(component->dev); int comp = ((struct soc_mixer_control *) kc->private_value)->shift; int value = uco...
0
[]
sound
a54988113985ca22e414e132054f234fc8a92604
167,694,654,264,579,440,000,000,000,000,000,000,000
38
wcd9335: fix a incorrect use of kstrndup() In wcd9335_codec_enable_dec(), 'widget_name' is allocated by kstrndup(). However, according to doc: "Note: Use kmemdup_nul() instead if the size is known exactly." So we should use kmemdup_nul() here instead of kstrndup(). Signed-off-by: Gen Zhang <blackgod016574@gmail.com> ...
void php_wddx_packet_end(wddx_packet *packet) { php_wddx_add_chunk_static(packet, WDDX_DATA_E); php_wddx_add_chunk_static(packet, WDDX_PACKET_E); }
1
[]
php-src
1785d2b805f64eaaacf98c14c9e13107bf085ab1
304,531,000,985,284,900,000,000,000,000,000,000,000
5
Fixed bug #70741: Session WDDX Packet Deserialization Type Confusion Vulnerability
static void client_alloc(void) { int i; if (!(clients = realloc( clients, (client_size + CLIENT_NALLOC) * sizeof(*clients)) ) || !(pollfds = realloc( pollfds, (client_size + CLIENT_NALLOC) * sizeof(*pollfds)) )) { log_error("can't alloc for client array"); exit(1); } for (i = client_size; i < client_siz...
0
[ "CWE-287", "CWE-284" ]
booth
35bf0b7b048d715f671eb68974fb6b4af6528c67
278,570,269,115,040,300,000,000,000,000,000,000,000
22
Revert "Refactor: main: substitute is_auth_req macro" This reverts commit da79b8ba28ad4837a0fee13e5f8fb6f89fe0e24c. authfile != authkey Signed-off-by: Jan Friesse <jfriesse@redhat.com>
processWorkItem(epolld_t *epd) { int continue_polling = 1; switch(epd->typ) { case epolld_lstn: /* listener never stops polling (except server shutdown) */ lstnActivity((ptcplstn_t *) epd->ptr); break; case epolld_sess: sessActivity((ptcpsess_t *) epd->ptr, &continue_polling); break; default: errmsg.L...
0
[ "CWE-190" ]
rsyslog
0381a0de64a5a048c3d48b79055bd9848d0c7fc2
299,746,065,379,458,170,000,000,000,000,000,000,000
21
imptcp: fix Segmentation Fault when octet count is to high
peer_clear( struct peer *peer, /* peer structure */ const char *ident /* tally lights */ ) { u_char u; #ifdef AUTOKEY /* * If cryptographic credentials have been acquired, toss them to * Valhalla. Note that autokeys are ephemeral, in that they are * tossed immediately upon use. Therefore, the keylist can ...
0
[ "CWE-287" ]
ntp
71a962710bfe066f76da9679cf4cfdeffe34e95e
160,895,273,590,135,500,000,000,000,000,000,000,000
84
[Sec 2936] Skeleton Key: Any trusted key system can serve time. HStenn.
static ssize_t tulip_receive_nc(NetClientState *nc, const uint8_t *buf, size_t size) { return tulip_receive(qemu_get_nic_opaque(nc), buf, size); }
0
[ "CWE-787" ]
qemu
8ffb7265af64ec81748335ec8f20e7ab542c3850
212,970,531,799,888,820,000,000,000,000,000,000,000
5
net: tulip: check frame size and r/w data length Tulip network driver while copying tx/rx buffers does not check frame size against r/w data length. This may lead to OOB buffer access. Add check to avoid it. Limit iterations over descriptors to avoid potential infinite loop issue in tulip_xmit_list_update. Reported-...
static int unsolicited_report_interval(struct in_device *in_dev) { int interval_ms, interval_jiffies; if (IGMP_V1_SEEN(in_dev) || IGMP_V2_SEEN(in_dev)) interval_ms = IN_DEV_CONF_GET( in_dev, IGMPV2_UNSOLICITED_REPORT_INTERVAL); else /* v3 */ interval_ms = IN_DEV_CONF_GET( in_dev, IGMPV3_UNSOLICITED_...
0
[ "CWE-362" ]
linux
23d2b94043ca8835bd1e67749020e839f396a1c2
285,105,464,379,152,540,000,000,000,000,000,000,000
22
igmp: Add ip_mc_list lock in ip_check_mc_rcu I got below panic when doing fuzz test: Kernel panic - not syncing: panic_on_warn set ... CPU: 0 PID: 4056 Comm: syz-executor.3 Tainted: G B 5.14.0-rc1-00195-gcff5c4254439-dirty #2 Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS rel-1.12.0-59-gc9...
dns_zone_get_parentcatz(const dns_zone_t *zone) { REQUIRE(DNS_ZONE_VALID(zone)); return (zone->parentcatz); }
0
[ "CWE-327" ]
bind9
f09352d20a9d360e50683cd1d2fc52ccedcd77a0
264,837,043,617,815,900,000,000,000,000,000,000,000
4
Update keyfetch_done compute_tag check If in keyfetch_done the compute_tag fails (because for example the algorithm is not supported), don't crash, but instead ignore the key.
static bool isEmpty(const folly::IOBuf& str) { return str.empty(); }
0
[ "CWE-20", "CWE-703", "CWE-755" ]
fbthrift
c5d6e07588cd03061bc54d451a7fa6e84883d62b
134,349,100,283,343,550,000,000,000,000,000,000,000
3
Throw on bad types during skipping data Summary: The current code silently returns on bad types. In case when we have an invalid data, we may get a container of a large size with a bad type, this would lead to us running long loop doing nothing (though we already can say that the data is invalid). The new code would ...
static int mt_touch_input_mapping(struct hid_device *hdev, struct hid_input *hi, struct hid_field *field, struct hid_usage *usage, unsigned long **bit, int *max, struct mt_application *app) { struct mt_device *td = hid_get_drvdata(hdev); struct mt_class *cls = &td->mtclass; int code; struct hid_usage *prev_usag...
0
[ "CWE-787" ]
linux
35556bed836f8dc07ac55f69c8d17dce3e7f0e25
237,709,689,285,808,670,000,000,000,000,000,000,000
189
HID: core: Sanitize event code and type when mapping input When calling into hid_map_usage(), the passed event code is blindly stored as is, even if it doesn't fit in the associated bitmap. This event code can come from a variety of sources, including devices masquerading as input devices, only a bit more "programmab...
zsetdevice(i_ctx_t *i_ctx_p) { gx_device *odev = NULL, *dev = gs_currentdevice(igs); gx_device *ndev = NULL; os_ptr op = osp; int code = dev_proc(dev, dev_spec_op)(dev, gxdso_current_output_device, (void *)&odev, 0); if (code < 0) return code; check_write_type(*o...
0
[]
ghostpdl
ea1b3ef437f39e45874f821c06bd953196625ac5
143,766,922,004,955,190,000,000,000,000,000,000,000
43
Bug 700176: Use the actual output device for both devices in setdevice Also fixes bug 700189. The pdf14 compositor device, despite being a forwarding device, does not forward all spec_ops to it's target, only a select few are special cased for that. gxdso_current_output_device needs to be included in those special ca...
uint MYSQL_BIN_LOG::next_file_id() { uint res; mysql_mutex_lock(&LOCK_log); res = file_id++; mysql_mutex_unlock(&LOCK_log); return res; }
0
[ "CWE-264" ]
mysql-server
48bd8b16fe382be302c6f0b45931be5aa6f29a0e
182,616,658,328,329,200,000,000,000,000,000,000,000
8
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 int handle_machine_check(struct kvm_vcpu *vcpu) { /* already handled by vcpu_run */ return 1; }
0
[ "CWE-400" ]
linux-2.6
9581d442b9058d3699b4be568b6e5eae38a41493
15,753,393,149,629,898,000,000,000,000,000,000,000
5
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-...
bool is_sameYZ(const unsigned int size_y, const unsigned int size_z) const { return _height==size_y && _depth==size_z; }
0
[ "CWE-770" ]
cimg
619cb58dd90b4e03ac68286c70ed98acbefd1c90
172,805,408,678,731,050,000,000,000,000,000,000,000
3
CImg<>::load_bmp() and CImg<>::load_pandore(): Check that dimensions encoded in file does not exceed file size.
static int cmd_join(void *data, const char *input) { // "join" RCore *core = (RCore *)data; const char *tmp = strdup (input); const char *arg1 = strchr (tmp, ' '); if (!arg1) { goto beach; } arg1 = r_str_trim_ro (arg1); char *end = strchr (arg1, ' '); if (!end) { goto beach; } *end = '\0'; const char *ar...
0
[ "CWE-78" ]
radare2
dd739f5a45b3af3d1f65f00fe19af1dbfec7aea7
254,877,784,952,735,820,000,000,000,000,000,000,000
43
Fix #14990 - multiple quoted command parsing issue ##core > "?e hello""?e world" hello world" > "?e hello";"?e world" hello world
static int cp2112_gpio_direction_input(struct gpio_chip *chip, unsigned offset) { struct cp2112_device *dev = gpiochip_get_data(chip); struct hid_device *hdev = dev->hdev; u8 *buf = dev->in_out_buffer; unsigned long flags; int ret; spin_lock_irqsave(&dev->lock, flags); ret = hid_hw_raw_request(hdev, CP2112_GPI...
1
[ "CWE-404", "CWE-703" ]
linux
7a7b5df84b6b4e5d599c7289526eed96541a0654
19,441,869,473,043,617,000,000,000,000,000,000,000
35
HID: cp2112: fix sleep-while-atomic A recent commit fixing DMA-buffers on stack added a shared transfer buffer protected by a spinlock. This is broken as the USB HID request callbacks can sleep. Fix this up by replacing the spinlock with a mutex. Fixes: 1ffb3c40ffb5 ("HID: cp2112: make transfer buffers DMA capable") ...
static int tg3_set_features(struct net_device *dev, netdev_features_t features) { netdev_features_t changed = dev->features ^ features; if ((changed & NETIF_F_LOOPBACK) && netif_running(dev)) tg3_set_loopback(dev, features); return 0; }
0
[ "CWE-476", "CWE-119" ]
linux
715230a44310a8cf66fbfb5a46f9a62a9b2de424
167,770,082,331,022,220,000,000,000,000,000,000,000
9
tg3: fix length overflow in VPD firmware parsing Commit 184b89044fb6e2a74611dafa69b1dce0d98612c6 ("tg3: Use VPD fw version when present") introduced VPD parsing that contained a potential length overflow. Limit the hardware's reported firmware string length (max 255 bytes) to stay inside the driver's firmware string ...
void CrwMap::encode(CiffHeader* pHead, const Image& image) { for (const CrwMapping* cmi = crwMapping_; cmi->ifdId_ != ifdIdNotSet; ++cmi) { if (cmi->fromExif_ != 0) { cmi->fromExif_(image, cmi, pHead); } } } // CrwMap::encode
0
[ "CWE-400" ]
exiv2
b3d077dcaefb6747fff8204490f33eba5a144edb
255,178,712,007,241,000,000,000,000,000,000,000,000
8
Fix #460 by adding more checks in CiffDirectory::readDirectory
static void *wsgi_merge_server_config(apr_pool_t *p, void *base_conf, void *new_conf) { WSGIServerConfig *config = NULL; WSGIServerConfig *parent = NULL; WSGIServerConfig *child = NULL; config = newWSGIServerConfig(p); parent = (WSGIServerConfig *)base_conf; ...
0
[ "CWE-254" ]
mod_wsgi
545354a80b9cc20d8b6916ca30542eab36c3b8bd
129,355,962,324,044,440,000,000,000,000,000,000,000
91
When there is any sort of error in setting up daemon process group, kill the process rather than risk running in an unexpected state.
size_t bdrv_opt_mem_align(BlockDriverState *bs) { if (!bs || !bs->drv) { /* 4k should be on the safe side */ return 4096; } return bs->bl.opt_mem_alignment; }
0
[ "CWE-190" ]
qemu
8f4754ede56e3f9ea3fd7207f4a7c4453e59285b
128,273,412,856,315,370,000,000,000,000,000,000,000
9
block: Limit request size (CVE-2014-0143) Limiting the size of a single request to INT_MAX not only fixes a direct integer overflow in bdrv_check_request() (which would only trigger bad behaviour with ridiculously huge images, as in close to 2^64 bytes), but can also prevent overflows in all block drivers. Signed-off...
ldns_tsig_keydata_clone(const ldns_tsig_credentials *tc) { return strdup(tc->keydata); }
0
[]
ldns
f9073d9fc313b19f51a5aa160584f2bdccda637a
146,778,687,245,989,780,000,000,000,000,000,000,000
4
* Detect fixed time memory compare for openssl 0.9.8.
static void ev_stream_submitted(h2_proxy_session *session, int stream_id, const char *msg) { switch (session->state) { case H2_PROXYS_ST_IDLE: case H2_PROXYS_ST_WAIT: transit(session, "stream submitted", H2_PROXYS_ST_BUSY); break; defa...
0
[ "CWE-770" ]
mod_h2
dd05d49abe0f67512ce9ed5ba422d7711effecfb
283,949,416,406,936,850,000,000,000,000,000,000,000
13
* fixes Timeout vs. KeepAliveTimeout behaviour, see PR 63534 (for trunk now, mpm event backport to 2.4.x up for vote). * Fixes stream cleanup when connection throttling is in place. * Counts stream resets by client on streams initiated by client as cause for connection throttling. * Header length checks are no...
static void __net_exit nf_tables_exit_net(struct net *net) { struct nftables_pernet *nft_net = nft_pernet(net); mutex_lock(&nft_net->commit_mutex); if (!list_empty(&nft_net->commit_list)) __nf_tables_abort(net, NFNL_ABORT_NONE); __nft_release_tables(net); mutex_unlock(&nft_net->commit_mutex); WARN_ON_ONCE(!lis...
0
[ "CWE-665" ]
linux
ad9f151e560b016b6ad3280b48e42fa11e1a5440
292,070,696,614,127,360,000,000,000,000,000,000,000
13
netfilter: nf_tables: initialize set before expression setup nft_set_elem_expr_alloc() needs an initialized set if expression sets on the NFT_EXPR_GC flag. Move set fields initialization before expression setup. [4512935.019450] ================================================================== [4512935.019456] BUG: ...
static int decode_read(struct xdr_stream *xdr, struct rpc_rqst *req, struct nfs_readres *res) { struct kvec *iov = req->rq_rcv_buf.head; __be32 *p; uint32_t count, eof, recvd, hdrlen; int status; status = decode_op_hdr(xdr, OP_READ); if (status) return status; READ_BUF(8); READ32(eof); READ32(count); hdrle...
0
[ "CWE-703" ]
linux
dc0b027dfadfcb8a5504f7d8052754bf8d501ab9
166,458,058,372,856,050,000,000,000,000,000,000,000
26
NFSv4: Convert the open and close ops to use fmode Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
int ldb_kv_search_key(struct ldb_module *module, struct ldb_kv_private *ldb_kv, const struct ldb_val ldb_key, struct ldb_message *msg, unsigned int unpack_flags) { int ret; struct ldb_kv_parse_data_unpack_ctx ctx = { .msg = msg, .module = module, .unpack_flags = unpack_flags }; ...
0
[ "CWE-20" ]
samba
3c1fbb18321f61df44d7b0f0c7452ae230960293
305,697,350,700,795,580,000,000,000,000,000,000,000
37
CVE-2018-1140 ldb_tdb: Check for DN validity in add, rename and search This ensures we fail with a good error code before an eventual ldb_dn_get_casefold() which would otherwise fail. Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz> BUG: https://bugzil...
int btrfs_create_subvol_root(struct btrfs_trans_handle *trans, struct btrfs_root *new_root, u64 new_dirid) { struct inode *inode; int err; u64 index = 0; inode = btrfs_new_inode(trans, new_root, NULL, "..", 2, new_dirid, new_dirid, S_IFDIR | (~current_umask() & S_IRWXUGO), &index); if (IS_ERR(...
0
[ "CWE-310" ]
linux-2.6
9c52057c698fb96f8f07e7a4bcf4801a092bda89
144,748,466,631,538,630,000,000,000,000,000,000,000
24
Btrfs: fix hash overflow handling The handling for directory crc hash overflows was fairly obscure, split_leaf returns EOVERFLOW when we try to extend the item and that is supposed to bubble up to userland. For a while it did so, but along the way we added better handling of errors and forced the FS readonly if we hi...
bool update_vcol_processor(void *arg) { return 0; }
0
[ "CWE-617" ]
server
2e7891080667c59ac80f788eef4d59d447595772
163,132,630,728,488,650,000,000,000,000,000,000,000
1
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....
psutil_getpagesize(PyObject *self, PyObject *args) { // XXX: we may want to use GetNativeSystemInfo to differentiate // page size for WoW64 processes (but am not sure). return Py_BuildValue("I", PSUTIL_SYSTEM_INFO.dwPageSize); }
0
[ "CWE-415" ]
psutil
7d512c8e4442a896d56505be3e78f1156f443465
66,256,042,572,922,310,000,000,000,000,000,000,000
5
Use Py_CLEAR instead of Py_DECREF to also set the variable to NULL (#1616) These files contain loops that convert system data into python objects and during the process they create objects and dereference their refcounts after they have been added to the resulting list. However, in case of errors during the creat...
static int curve_id2nid(int curve_id) { /* ECC curves from draft-ietf-tls-ecc-01.txt (Mar 15, 2001) * (no changes in draft-ietf-tls-ecc-03.txt [June 2003]) */ static int nid_list[26] = { 0, NID_sect163k1, /* sect163k1 (1) */ NID_sect163r1, /* sect163r1 (2) */ NID_sect163r2, /* sect163r2 (3) */ NID_sect19...
0
[ "CWE-326" ]
openssl
410a49a4fa1d2a1a9775ee29f9e40cbbda79c149
314,958,890,754,353,350,000,000,000,000,000,000,000
38
Fix for CVE-2014-0224 Only accept change cipher spec when it is expected instead of at any time. This prevents premature setting of session keys before the master secret is determined which an attacker could use as a MITM attack. Thanks to KIKUCHI Masashi (Lepidum Co. Ltd.) for reporting this issue and providing the ...
int smb_vfs_call_chflags(struct vfs_handle_struct *handle, const char *path, unsigned int flags) { VFS_FIND(chflags); return handle->fns->chflags_fn(handle, path, flags); }
0
[ "CWE-264" ]
samba
4278ef25f64d5fdbf432ff1534e275416ec9561e
257,982,630,021,357,220,000,000,000,000,000,000,000
6
CVE-2015-5252: s3: smbd: Fix symlink verification (file access outside the share). Ensure matching component ends in '/' or '\0'. BUG: https://bugzilla.samba.org/show_bug.cgi?id=11395 Signed-off-by: Jeremy Allison <jra@samba.org> Reviewed-by: Volker Lendecke <vl@samba.org>
cockpit_auth_steal_authorization (GHashTable *headers, GIOStream *connection, gchar **ret_type, gchar **ret_conversation) { char *type = NULL; gchar *ret = NULL; gchar *line; gpointer key; g_assert (headers ...
0
[ "CWE-1021" ]
cockpit
46f6839d1af4e662648a85f3e54bba2d57f39f0e
7,031,708,652,394,899,000,000,000,000,000,000,000
78
ws: Restrict our cookie to the login host only Mark our cookie as `SameSite: Strict` [1]. The current `None` default will soon be moved to `Lax` by Firefox and Chromium, and recent versions started to throw a warning about it. [1] https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Set-Cookie/SameSite https://...