func
string
target
int64
cwe
list
project
string
commit_id
string
hash
float64
size
int64
message
string
static void process_bin_complete_sasl_auth(conn *c) { assert(settings.sasl); const char *out = NULL; unsigned int outlen = 0; assert(c->item); init_sasl_conn(c); int nkey = c->binary_header.request.keylen; int vlen = c->binary_header.request.bodylen - nkey; if (nkey > ((item*) c->item...
0
[ "CWE-20", "CWE-703", "CWE-400" ]
memcached
dbb7a8af90054bf4ef51f5814ef7ceb17d83d974
243,886,380,281,531,050,000,000,000,000,000,000,000
90
disable UDP port by default As reported, UDP amplification attacks have started to use insecure internet-exposed memcached instances. UDP used to be a lot more popular as a transport for memcached many years ago, but I'm not aware of many recent users. Ten years ago, the TCP connection overhead from many clients was ...
static s32 atl2_write_phy_reg(struct atl2_hw *hw, u32 reg_addr, u16 phy_data) { int i; u32 val; val = ((u32)(phy_data & MDIO_DATA_MASK)) << MDIO_DATA_SHIFT | (reg_addr & MDIO_REG_ADDR_MASK) << MDIO_REG_ADDR_SHIFT | MDIO_SUP_PREAMBLE | MDIO_START | MDIO_CLK_25_4 << MDIO_CLK_SEL_SHIFT; ATL2_WRITE_REG(hw, REG...
0
[ "CWE-200" ]
linux
f43bfaeddc79effbf3d0fcb53ca477cca66f3db8
275,651,953,073,062,960,000,000,000,000,000,000,000
28
atl2: Disable unimplemented scatter/gather feature atl2 includes NETIF_F_SG in hw_features even though it has no support for non-linear skbs. This bug was originally harmless since the driver does not claim to implement checksum offload and that used to be a requirement for SG. Now that SG and checksum offload are i...
static bool gx_ttfReader__Eof(ttfReader *self) { gx_ttfReader *r = (gx_ttfReader *)self; if (r->extra_glyph_index != -1) return r->pos >= r->glyph_data.bits.size; /* We can't know whether pfont->data.string_proc has more bytes, so we never report Eof for it. */ return false; }
0
[ "CWE-125" ]
ghostpdl
937ccd17ac65935633b2ebc06cb7089b91e17e6b
14,765,657,742,095,187,000,000,000,000,000,000,000
10
Bug 698056: make bounds check in gx_ttfReader__Read more robust
static int tiocsctty(struct tty_struct *tty, struct file *file, int arg) { int ret = 0; tty_lock(tty); read_lock(&tasklist_lock); if (current->signal->leader && (task_session(current) == tty->session)) goto unlock; /* * The process must be a session leader and * not have a controlling tty already. */ i...
0
[ "CWE-416" ]
linux
c8bcd9c5be24fb9e6132e97da5a35e55a83e36b9
146,446,025,411,608,920,000,000,000,000,000,000,000
47
tty: Fix ->session locking Currently, locking of ->session is very inconsistent; most places protect it using the legacy tty mutex, but disassociate_ctty(), __do_SAK(), tiocspgrp() and tiocgsid() don't. Two of the writers hold the ctrl_lock (because they already need it for ->pgrp), but __proc_set_tty() doesn't do tha...
void test_parser(void) { test_parser_param(0); }
0
[ "CWE-254", "CWE-787" ]
bzrtp
bbb1e6e2f467ee4bd7b9a8c800e4f07343d7d99b
90,753,970,426,187,220,000,000,000,000,000,000,000
3
Add ZRTP Commit packet hvi check on DHPart2 packet reception
static void put_uncharge_info(struct file_region *rg) { #ifdef CONFIG_CGROUP_HUGETLB if (rg->css) css_put(rg->css); #endif }
0
[]
linux
a4a118f2eead1d6c49e00765de89878288d4b890
75,233,635,742,822,820,000,000,000,000,000,000,000
7
hugetlbfs: flush TLBs correctly after huge_pmd_unshare When __unmap_hugepage_range() calls to huge_pmd_unshare() succeed, a TLB flush is missing. This TLB flush must be performed before releasing the i_mmap_rwsem, in order to prevent an unshared PMDs page from being released and reused before the TLB flush took place...
static int unlock_futex_pi(u32 __user *uaddr, u32 uval) { u32 oldval; /* * There is no waiter, so we unlock the futex. The owner died * bit has not to be preserved here. We are the owner: */ oldval = cmpxchg_futex_value_locked(uaddr, uval, 0); if (oldval == -EFAULT) return oldval; if (oldval != uval) r...
0
[]
linux-2.6
5ecb01cfdf96c5f465192bdb2a4fd4a61a24c6cc
234,532,365,493,921,500,000,000,000,000,000,000,000
17
futex_lock_pi() key refcnt fix This fixes a futex key reference count bug in futex_lock_pi(), where a key's reference count is incremented twice but decremented only once, causing the backing object to not be released. If the futex is created in a temporary file in an ext3 file system, this bug causes the file's inod...
vq_is_ready(struct virtio_net *dev, struct vhost_virtqueue *vq) { bool rings_ok; if (!vq) return false; if (vq_is_packed(dev)) rings_ok = !!vq->desc_packed; else rings_ok = vq->desc && vq->avail && vq->used; return rings_ok && vq->kickfd != VIRTIO_UNINITIALIZED_EVENTFD && vq->callfd != VIR...
0
[]
dpdk
612e17cf6d7b2bf05a687d8a9ba7be582a744e50
168,260,886,717,353,380,000,000,000,000,000,000,000
16
vhost: fix possible denial of service on SET_VRING_NUM vhost_user_set_vring_num() performs multiple allocations without checking whether data were previously allocated. It may cause a denial of service because of the memory leaks that happen if a malicious vhost-user master keeps sending VHOST_USER_SET_VRING_NUM requ...
static int sctp_v6_xmit(struct sk_buff *skb, struct sctp_transport *transport) { struct sock *sk = skb->sk; struct ipv6_pinfo *np = inet6_sk(sk); struct flowi6 fl6; memset(&fl6, 0, sizeof(fl6)); fl6.flowi6_proto = sk->sk_protocol; /* Fill in the dest address from the route entry passed with the skb * and the...
1
[ "CWE-310" ]
net
95ee62083cb6453e056562d91f597552021e6ae7
25,259,162,052,979,950,000,000,000,000,000,000,000
38
net: sctp: fix ipv6 ipsec encryption bug in sctp_v6_xmit Alan Chester reported an issue with IPv6 on SCTP that IPsec traffic is not being encrypted, whereas on IPv4 it is. Setting up an AH + ESP transport does not seem to have the desired effect: SCTP + IPv4: 22:14:20.809645 IP (tos 0x2,ECT(0), ttl 64, id 0, offse...
static double mp_argkth(_cimg_math_parser& mp) { const unsigned int i_end = (unsigned int)mp.opcode[2]; const double val = mp_kth(mp); for (unsigned int i = 4; i<i_end; ++i) if (val==_mp_arg(i)) return i - 3.; return 1;
0
[ "CWE-119", "CWE-787" ]
CImg
ac8003393569aba51048c9d67e1491559877b1d1
110,552,934,357,356,160,000,000,000,000,000,000,000
6
.
static void perf_event_mmap_event(struct perf_mmap_event *mmap_event) { struct vm_area_struct *vma = mmap_event->vma; struct file *file = vma->vm_file; int maj = 0, min = 0; u64 ino = 0, gen = 0; u32 prot = 0, flags = 0; unsigned int size; char tmp[16]; char *buf = NULL; char *name; if (file) { struct inod...
0
[ "CWE-416", "CWE-362" ]
linux
12ca6ad2e3a896256f086497a7c7406a547ee373
46,076,079,525,797,440,000,000,000,000,000,000,000
119
perf: Fix race in swevent hash There's a race on CPU unplug where we free the swevent hash array while it can still have events on. This will result in a use-after-free which is BAD. Simply do not free the hash array on unplug. This leaves the thing around and no use-after-free takes place. When the last swevent die...
size_t max_row_length(TABLE *table, MY_BITMAP const *cols, const uchar *data) { TABLE_SHARE *table_s= table->s; size_t length= table_s->reclength + 2 * table_s->fields; uint *const beg= table_s->blob_field; uint *const end= beg + table_s->blob_fields; my_ptrdiff_t const rec_offset= (my_ptrdiff_t) (data - tabl...
0
[ "CWE-416" ]
server
c02ebf3510850ba78a106be9974c94c3b97d8585
300,696,659,418,995,470,000,000,000,000,000,000,000
22
MDEV-24176 Preparations 1. moved fix_vcol_exprs() call to open_table() mysql_alter_table() doesn't do lock_tables() so it cannot win from fix_vcol_exprs() from there. Tests affected: main.default_session 2. Vanilla cleanups and comments.
GF_Err ftab_dump(GF_Box *a, FILE * trace) { u32 i; GF_FontTableBox *p = (GF_FontTableBox *)a; gf_isom_box_dump_start(a, "FontTableBox", trace); fprintf(trace, ">\n"); for (i=0; i<p->entry_count; i++) { fprintf(trace, "<FontRecord ID=\"%d\" name=\"%s\"/>\n", p->fonts[i].fontID, p->fonts[i].fontName ? p->fonts[i]....
0
[ "CWE-125" ]
gpac
bceb03fd2be95097a7b409ea59914f332fb6bc86
128,675,599,535,256,470,000,000,000,000,000,000,000
15
fixed 2 possible heap overflows (inc. #1088)
flatpak_run_apply_env_default (char **envp) { int i; for (i = 0; i < G_N_ELEMENTS (default_exports); i++) envp = g_environ_setenv (envp, default_exports[i].env, default_exports[i].val, TRUE); return envp; }
0
[ "CWE-20" ]
flatpak
902fb713990a8f968ea4350c7c2a27ff46f1a6c4
13,228,677,418,757,453,000,000,000,000,000,000,000
9
Use seccomp to filter out TIOCSTI ioctl This would otherwise let the sandbox add input to the controlling tty.
coproc_fdchk (fd) int fd; { #if MULTIPLE_COPROCS cpl_fdchk (fd); #else coproc_checkfd (&sh_coproc, fd); #endif }
0
[]
bash
955543877583837c85470f7fb8a97b7aa8d45e6c
136,686,316,725,800,500,000,000,000,000,000,000,000
9
bash-4.4-rc2 release
uid_t enc_untrusted_getuid() { return EnsureInitializedAndDispatchSyscall(asylo::system_call::kSYS_getuid); }
0
[ "CWE-125" ]
asylo
b1d120a2c7d7446d2cc58d517e20a1b184b82200
163,693,864,507,616,200,000,000,000,000,000,000,000
3
Check for return size in enc_untrusted_read Check return size does not exceed requested. The returned result and content still cannot be trusted, but it's expected behavior when not using a secure file system. PiperOrigin-RevId: 333827386 Change-Id: I0bdec0aec9356ea333dc8c647eba5d2772875f29
static int clgi_interception(struct vcpu_svm *svm) { if (nested_svm_check_permissions(svm)) return 1; svm->next_rip = kvm_rip_read(&svm->vcpu) + 3; skip_emulated_instruction(&svm->vcpu); disable_gif(svm); /* After a CLGI no interrupts should come */ svm_clear_vintr(svm); svm->vmcb->control.int_ctl &= ~V_IRQ...
0
[]
kvm
854e8bb1aa06c578c2c9145fa6bfe3680ef63b23
196,617,358,693,240,570,000,000,000,000,000,000,000
18
KVM: x86: Check non-canonical addresses upon WRMSR Upon WRMSR, the CPU should inject #GP if a non-canonical value (address) is written to certain MSRs. The behavior is "almost" identical for AMD and Intel (ignoring MSRs that are not implemented in either architecture since they would anyhow #GP). However, IA32_SYSENTE...
static ssize_t ossl_send(struct Curl_easy *data, int sockindex, const void *mem, size_t len, CURLcode *curlcode) { /* SSL_write() is said to return 'int' while write() and send() returns 'size_t' */ int err; c...
0
[]
curl
139a54ed0a172adaaf1a78d6f4fff50b2c3f9e08
315,609,327,959,334,300,000,000,000,000,000,000,000
83
openssl: don't leak the SRP credentials in redirects either Follow-up to 620ea21410030 Reported-by: Harry Sintonen Closes #8751
nm_gconf_set_bool_helper (GConfClient *client, const char *path, const char *key, const char *setting, gboolean value) { char * gc_key; g_return_val_if_fail (key != NULL, FALSE); g_return_val_if_fail (setting != ...
0
[ "CWE-310" ]
network-manager-applet
4020594dfbf566f1852f0acb36ad631a9e73a82b
193,000,964,039,019,930,000,000,000,000,000,000,000
20
core: fix CA cert mishandling after cert file deletion (deb #560067) (rh #546793) If a connection was created with a CA certificate, but the user later moved or deleted that CA certificate, the applet would simply provide the connection to NetworkManager without any CA certificate. This could cause NM to connect to t...
static int mov_read_sv3d(MOVContext *c, AVIOContext *pb, MOVAtom atom) { AVStream *st; MOVStreamContext *sc; int size, layout; int32_t yaw, pitch, roll; uint32_t l = 0, t = 0, r = 0, b = 0; uint32_t tag, padding = 0; enum AVSphericalProjection projection; if (c->fc->nb_streams < 1) ...
0
[ "CWE-399", "CWE-834" ]
FFmpeg
9cb4eb772839c5e1de2855d126bf74ff16d13382
238,006,014,713,874,200,000,000,000,000,000,000,000
118
avformat/mov: Fix DoS in read_tfra() Fixes: Missing EOF check in loop No testcase Found-by: Xiaohei and Wangchu from Alibaba Security Team Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
struct ldb_request *map_build_fixup_req(struct map_context *ac, struct ldb_dn *olddn, struct ldb_dn *newdn, void *context, ldb_map_callback_t callback) { struct ldb_context *ldb; struct ldb_request *req; struct ldb_message *msg; const char *dn; int ret; ldb = ldb_module_get_ctx(ac->module); ...
0
[ "CWE-200" ]
samba
0a3aa5f908e351201dc9c4d4807b09ed9eedff77
84,474,342,375,867,835,000,000,000,000,000,000,000
47
CVE-2022-32746 ldb: Make use of functions for appending to an ldb_message This aims to minimise usage of the error-prone pattern of searching for a just-added message element in order to make modifications to it (and potentially finding the wrong element). BUG: https://bugzilla.samba.org/show_bug.cgi?id=15009 Signed...
njs_array_prototype_join(njs_vm_t *vm, njs_value_t *args, njs_uint_t nargs, njs_index_t unused) { u_char *p, *last; int64_t i, size, len, length; njs_int_t ret; njs_chb_t chain; njs_utf8_t utf8; njs_value_t *value, *this, entry; njs...
0
[ "CWE-703" ]
njs
2e00e95473861846aa8538be87db07699d9f676d
320,273,969,022,160,040,000,000,000,000,000,000,000
121
Fixed Array.prototype.slice() with slow "this" argument. Previously, when "this" argument was not a fast array, but the "deleted" array was a fast array, the "deleted" array may be left in uninitialized state if "this" argument had gaps. This fix is to ensure that "deleted" is properly initialized. This fixes #485 i...
static int stv06xx_init_controls(struct gspca_dev *gspca_dev) { struct sd *sd = (struct sd *) gspca_dev; gspca_dbg(gspca_dev, D_PROBE, "Initializing controls\n"); gspca_dev->vdev.ctrl_handler = &gspca_dev->ctrl_handler; return sd->sensor->init_controls(sd); }
0
[ "CWE-476" ]
linux
485b06aadb933190f4bc44e006076bc27a23f205
284,506,314,780,853,200,000,000,000,000,000,000,000
9
media: stv06xx: add missing descriptor sanity checks Make sure to check that we have two alternate settings and at least one endpoint before accessing the second altsetting structure and dereferencing the endpoint arrays. This specifically avoids dereferencing NULL-pointers or corrupting memory when a device does not...
free_buffer(buf_T *buf) { ++buf_free_count; free_buffer_stuff(buf, TRUE); #ifdef FEAT_EVAL // b:changedtick uses an item in buf_T, remove it now dictitem_remove(buf->b_vars, (dictitem_T *)&buf->b_ct_di); unref_var_dict(buf->b_vars); remove_listeners(buf); #endif #ifdef FEAT_LUA lua_buffer_fr...
0
[ "CWE-416" ]
vim
9b4a80a66544f2782040b641498754bcb5b8d461
70,893,583,357,747,820,000,000,000,000,000,000,000
58
patch 8.2.4281: using freed memory with :lopen and :bwipe Problem: Using freed memory with :lopen and :bwipe. Solution: Do not use a wiped out buffer.
static SDL_INLINE int Find_GlyphByIndex(TTF_Font *font, FT_UInt idx, int want_bitmap, int want_pixmap, int want_color, int want_subpixel, int translation, c_glyph **out_glyph, TTF_Image **out_image) { /* cache size is 256, get key by masking */ c_glyph *glyph = &font->cache[idx & 0xff]; if...
0
[ "CWE-190", "CWE-787" ]
SDL_ttf
db1b41ab8bde6723c24b866e466cad78c2fa0448
161,921,459,554,346,340,000,000,000,000,000,000,000
92
More integer overflow (see bug #187) Make sure that 'width + alignment' doesn't overflow, otherwise it could create a SDL_Surface of 'width' but with wrong 'pitch'
ecma_stringbuilder_append_raw (ecma_stringbuilder_t *builder_p, /**< string builder */ const lit_utf8_byte_t *data_p, /**< pointer to data */ const lit_utf8_size_t data_size) /**< size of the data */ { lit_utf8_byte_t *dest_p = ecma_stringbuilder_grow (bui...
0
[ "CWE-416" ]
jerryscript
3bcd48f72d4af01d1304b754ef19fe1a02c96049
40,028,007,008,902,320,000,000,000,000,000,000,000
7
Improve parse_identifier (#4691) Ascii string length is no longer computed during string allocation. JerryScript-DCO-1.0-Signed-off-by: Daniel Batiz batizjob@gmail.com
ews_backend_create_resource_sync (ECollectionBackend *backend, ESource *source, GCancellable *cancellable, GError **error) { EEwsConnection *connection = NULL; EwsFolderId *out_folder_id = NULL; EEwsFolderType folde...
1
[ "CWE-295" ]
evolution-ews
915226eca9454b8b3e5adb6f2fff9698451778de
19,630,822,758,830,160,000,000,000,000,000,000,000
120
I#27 - SSL Certificates are not validated This depends on https://gitlab.gnome.org/GNOME/evolution-data-server/commit/6672b8236139bd6ef41ecb915f4c72e2a052dba5 too. Closes https://gitlab.gnome.org/GNOME/evolution-ews/issues/27
void LIRGenerator::array_store_check(LIR_Opr value, LIR_Opr array, CodeEmitInfo* store_check_info, ciMethod* profiled_method, int profiled_bci) { LIR_Opr tmp1 = new_register(objectType); LIR_Opr tmp2 = new_register(objectType); LIR_Opr tmp3 = new_register(objectType); __ store_check(value, array, tmp1, tmp2, tm...
0
[]
jdk17u
268c0159253b3de5d72eb826ef2329b27bb33fea
81,854,992,186,113,400,000,000,000,000,000,000,000
6
8272014: Better array indexing Reviewed-by: thartmann Backport-of: 937c31d896d05aa24543b74e98a2ea9f05b5d86f
static int ssl_check_clienthello_tlsext_early(SSL *s) { int ret=SSL_TLSEXT_ERR_NOACK; int al = SSL_AD_UNRECOGNIZED_NAME; #ifndef OPENSSL_NO_EC /* The handling of the ECPointFormats extension is done elsewhere, namely in * ssl3_choose_cipher in s3_lib.c. */ /* The handling of the EllipticCurves extension is d...
0
[]
openssl
80bd7b41b30af6ee96f519e629463583318de3b0
243,693,730,915,791,670,000,000,000,000,000,000,000
94
Fix SRP ciphersuite DoS vulnerability. If a client attempted to use an SRP ciphersuite and it had not been set up correctly it would crash with a null pointer read. A malicious server could exploit this in a DoS attack. Thanks to Joonas Kuorilehto and Riku Hietamäki from Codenomicon for reporting this issue. CVE-201...
njs_string_atob(njs_vm_t *vm, njs_value_t *args, njs_uint_t nargs, njs_index_t unused) { size_t i, n, len, pad; u_char *dst, *tmp, *p; ssize_t size; njs_str_t str; njs_int_t ret; njs_chb_t chain; njs_value_t *value, lvalue; const u_char *b64, *s; ...
0
[ "CWE-125" ]
njs
b9aea5854bcf6f2de8f7a7f1550874e392b94be2
54,954,107,548,576,540,000,000,000,000,000,000,000
124
Fixed String.prototype.trimEnd() with unicode string. Previously, when the method was invoked with a string consisting of space characters and at least one of them was a Unicode space separator (code point above 127) it returned invalid string value with non-zero size but zero length. The fix is to update the size of...
static TT_F26Dot6 Round_None( EXEC_OPS TT_F26Dot6 distance, TT_F26Dot6 compensation ) { TT_F26Dot6 val; (void)exc; if ( distance >= 0 ) { val = distance + compensation; if ( val < 0 ) val = 0; } else { val = distance - ...
0
[ "CWE-125" ]
ghostpdl
c7c55972758a93350882c32147801a3485b010fe
58,585,907,582,839,270,000,000,000,000,000,000,000
20
Bug 698024: bounds check zone pointer in Ins_MIRP()
inline void Http2Session::HandleGoawayFrame(const nghttp2_frame* frame) { Isolate* isolate = env()->isolate(); HandleScope scope(isolate); Local<Context> context = env()->context(); Context::Scope context_scope(context); nghttp2_goaway goaway_frame = frame->goaway; DEBUG_HTTP2SESSION(this, "handling goaway...
0
[]
node
ce22d6f9178507c7a41b04ac4097b9ea902049e3
81,624,669,356,573,110,000,000,000,000,000,000,000
24
http2: add altsvc support Add support for sending and receiving ALTSVC frames. PR-URL: https://github.com/nodejs/node/pull/17917 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com> Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
SPL_METHOD(SplObjectStorage, serialize) { spl_SplObjectStorage *intern = (spl_SplObjectStorage*)zend_object_store_get_object(getThis() TSRMLS_CC); spl_SplObjectStorageElement *element; zval members, *pmembers, *flags; HashPosition pos; php_serialize_data_t var_hash; smart_str buf = {0}; if (zend_parse_par...
1
[ "CWE-416" ]
php-src
c2e197e4efc663ca55f393bf0e799848842286f3
316,557,853,168,765,960,000,000,000,000,000,000,000
56
Fix bug #70168 - Use After Free Vulnerability in unserialize() with SplObjectStorage
//! Fill sequentially all pixel values with specified values \overloading. CImg<T>& fill(const T& val0, const T& val1, const T& val2, const T& val3, const T& val4, const T& val5, const T& val6, const T& val7, const T& val8, const T& val9, const T& val10, const T& val11, const...
0
[ "CWE-125" ]
CImg
10af1e8c1ad2a58a0a3342a856bae63e8f257abb
15,211,925,155,687,048,000,000,000,000,000,000,000
29
Fix other issues in 'CImg<T>::load_bmp()'.
xmlSerializeHexCharRef(unsigned char *out, int val) { unsigned char *ptr; *out++ = '&'; *out++ = '#'; *out++ = 'x'; if (val < 0x10) ptr = out; else if (val < 0x100) ptr = out + 1; else if (val < 0x1000) ptr = out + 2; else if (val < 0x10000) ptr = out + 3; else if (val < 0x100000) p...
0
[ "CWE-502" ]
libxml2
c97750d11bb8b6f3303e7131fe526a61ac65bcfd
25,946,403,158,703,180,000,000,000,000,000,000,000
39
Avoid an out of bound access when serializing malformed strings For https://bugzilla.gnome.org/show_bug.cgi?id=766414 * xmlsave.c: xmlBufAttrSerializeTxtContent() if an attribute value is not UTF-8 be more careful when serializing it as we may do an out of bound access as a result.
goa_utils_set_error_ssl (GError **err, GTlsCertificateFlags flags) { const gchar *error_msg; switch (flags) { case G_TLS_CERTIFICATE_UNKNOWN_CA: error_msg = _("The signing certificate authority is not known."); break; case G_TLS_CERTIFICATE_BAD_IDENTITY: error_msg = _("The certificat...
0
[ "CWE-310" ]
gnome-online-accounts
edde7c63326242a60a075341d3fea0be0bc4d80e
80,719,211,193,629,030,000,000,000,000,000,000,000
38
Guard against invalid SSL certificates None of the branded providers (eg., Google, Facebook and Windows Live) should ever have an invalid certificate. So set "ssl-strict" on the SoupSession object being used by GoaWebView. Providers like ownCloud and Exchange might have to deal with certificates that are not up to th...
GF_Err free_Size(GF_Box *s) { GF_FreeSpaceBox *ptr = (GF_FreeSpaceBox *)s; ptr->size += ptr->dataSize; return GF_OK; }
0
[ "CWE-400", "CWE-401" ]
gpac
d2371b4b204f0a3c0af51ad4e9b491144dd1225c
92,783,961,780,529,190,000,000,000,000,000,000,000
6
prevent dref memleak on invalid input (#1183)
static int posix_get_monotonic_coarse(clockid_t which_clock, struct timespec64 *tp) { ktime_get_coarse_ts64(tp); return 0; }
0
[ "CWE-190" ]
linux
78c9c4dfbf8c04883941445a195276bb4bb92c76
181,627,255,975,122,220,000,000,000,000,000,000,000
6
posix-timers: Sanitize overrun handling The posix timer overrun handling is broken because the forwarding functions can return a huge number of overruns which does not fit in an int. As a consequence timer_getoverrun(2) and siginfo::si_overrun can turn into random number generators. The k_clock::timer_forward() callb...
static int bin_pe_init_sections(struct PE_(r_bin_pe_obj_t)* bin) { bin->num_sections = bin->nt_headers->file_header.NumberOfSections; int sections_size; if (bin->num_sections < 1) { return true; } sections_size = sizeof (PE_(image_section_header)) * bin->num_sections; if (sections_size > bin->size) { sections...
0
[ "CWE-125" ]
radare2
4e1cf0d3e6f6fe2552a269def0af1cd2403e266c
235,031,157,617,839,100,000,000,000,000,000,000,000
69
Fix crash in pe
size_t puma_parser_execute(puma_parser *parser, const char *buffer, size_t len, size_t off) { const char *p, *pe; int cs = parser->cs; assert(off <= len && "offset past end of buffer"); p = buffer+off; pe = buffer+len; /* assert(*pe == '\0' && "pointer does not end on NUL"); */ assert((size_t) (pe - p...
1
[ "CWE-444" ]
puma
acdc3ae571dfae0e045cf09a295280127db65c7f
59,711,458,713,735,010,000,000,000,000,000,000,000
953
Merge pull request from GHSA-48w2-rm65-62xx * Fix HTTP request smuggling vulnerability See GHSA-48w2-rm65-62xx or CVE-2021-41136 for more info. * 4.3.9 release note * 5.5.1 release note * 5.5.1
void CClient::DemoRecorder_Start(const char *pFilename, bool WithTimestamp) { if(State() != IClient::STATE_ONLINE) m_pConsole->Print(IConsole::OUTPUT_LEVEL_STANDARD, "demorec/record", "client is not online"); else { char aFilename[128]; if(WithTimestamp) { char aDate[20]; str_timestamp(aDate, sizeof(aD...
0
[ "CWE-119", "CWE-787" ]
teeworlds
ff254722a2683867fcb3e67569ffd36226c4bc62
20,056,206,896,645,705,000,000,000,000,000,000,000
18
added some checks to snap handling
static struct snd_info_entry *create_subdir(struct module *mod, const char *name) { struct snd_info_entry *entry; entry = snd_info_create_module_entry(mod, name, NULL); if (!entry) return NULL; entry->mode = S_IFDIR | 0555; if (snd_info_register(entry) < 0) { snd_info_free_entry(entry); return NULL...
0
[ "CWE-416" ]
linux
8c2f870890fd28e023b0fcf49dcee333f2c8bad7
35,111,311,514,659,600,000,000,000,000,000,000,000
15
ALSA: info: Fix racy addition/deletion of nodes The ALSA proc helper manages the child nodes in a linked list, but its addition and deletion is done without any lock. This leads to a corruption if they are operated concurrently. Usually this isn't a problem because the proc entries are added sequentially in the driv...
tr_trans(VALUE str, VALUE src, VALUE repl, int sflag) { const unsigned int errc = -1; unsigned int trans[256]; rb_encoding *enc, *e1, *e2; struct tr trsrc, trrepl; int cflag = 0; unsigned int c, c0; int last = 0, modify = 0, i, l; char *s, *send; VALUE hash = 0; int singlebyte = ...
0
[ "CWE-119" ]
ruby
1c2ef610358af33f9ded3086aa2d70aac03dcac5
1,435,461,722,825,948,500,000,000,000,000,000,000
239
* 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
vim_memset(void *ptr, int c, size_t size) { char *p = ptr; while (size-- > 0) *p++ = c; return ptr; }
0
[ "CWE-120" ]
vim
7ce5b2b590256ce53d6af28c1d203fb3bc1d2d97
77,691,592,368,967,090,000,000,000,000,000,000,000
8
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.
qb_log_blackbox_open(struct qb_log_target *t) { if (t->size < 1024) { return -EINVAL; } snprintf(t->filename, PATH_MAX, "%s-%d-blackbox", t->name, getpid()); t->instance = qb_rb_open(t->filename, t->size, QB_RB_FLAG_CREATE | QB_RB_FLAG_OVERWRITE, 0); if (t->instance == NULL) { return -errno; } t->logg...
0
[ "CWE-59" ]
libqb
e322e98dc264bc5911d6fe1d371e55ac9f95a71e
136,033,930,734,458,250,000,000,000,000,000,000,000
19
ipc: use O_EXCL on SHM files, and randomize the names Signed-off-by: Christine Caulfield <ccaulfie@redhat.com>
next_trim (void *nxdata, uint32_t count, uint64_t offset, uint32_t flags, int *err) { struct b_conn *b_conn = nxdata; return backend_trim (b_conn->b, b_conn->conn, count, offset, flags, err); }
0
[ "CWE-406" ]
nbdkit
a6b88b195a959b17524d1c8353fd425d4891dc5f
318,170,838,431,475,400,000,000,000,000,000,000,000
6
server: Fix regression for NBD_OPT_INFO before NBD_OPT_GO Most known NBD clients do not bother with NBD_OPT_INFO (except for clients like 'qemu-nbd --list' that don't ever intend to connect), but go straight to NBD_OPT_GO. However, it's not too hard to hack up qemu to add in an extra client step (whether info on the ...
unpack_Z_stream(int fd_in, int fd_out) { IF_DESKTOP(long long total_written = 0;) IF_DESKTOP(long long) int retval = -1; unsigned char *stackp; long code; int finchar; long oldcode; long incode; int inbits; int posbits; int outpos; int insize; int bitmask; long free_ent; long maxcode; long maxmaxcode; i...
0
[]
busybox
251fc70e9722f931eec23a34030d05ba5f747b0e
15,654,791,308,084,390,000,000,000,000,000,000,000
235
uncompress: fix buffer underrun by corrupted input Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
static bool map_info2_flags_to_sbuf(const SMB_STRUCT_STAT *psbuf, const uint32_t smb_fflags, const uint32_t smb_fmask, int *stat_fflags) { uint32_t max_fmask = 0; int i; *stat_fflags = psbuf->st_ex_flags; /* For each flags requested in smb_fmask, check the state of the * corresponding flag in smb_ff...
0
[ "CWE-787" ]
samba
22b4091924977f6437b59627f33a8e6f02b41011
331,471,661,293,388,050,000,000,000,000,000,000,000
35
CVE-2021-44142: smbd: add Netatalk xattr used by vfs_fruit to the list of private Samba xattrs This is an internal xattr that should not be user visible. BUG: https://bugzilla.samba.org/show_bug.cgi?id=14914 Signed-off-by: Ralph Boehme <slow@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
f_assert_report(typval_T *argvars, typval_T *rettv) { garray_T ga; if (in_vim9script() && check_for_string_arg(argvars, 0) == FAIL) return; prepare_assert_error(&ga); ga_concat(&ga, tv_get_string(&argvars[0])); assert_error(&ga); ga_clear(&ga); rettv->vval.v_number = 1; }
0
[ "CWE-121", "CWE-787" ]
vim
34f8117dec685ace52cd9e578e2729db278163fc
186,090,526,888,500,370,000,000,000,000,000,000,000
13
patch 8.2.4397: crash when using many composing characters in error message Problem: Crash when using many composing characters in error message. Solution: Use mb_cptr2char_adv() instead of mb_ptr2char_adv().
xfs_attr_list_int( xfs_attr_list_context_t *context) { int error; xfs_inode_t *dp = context->dp; uint lock_mode; XFS_STATS_INC(xs_attr_list); if (XFS_FORCED_SHUTDOWN(dp->i_mount)) return EIO; /* * Decide on what work routines to call based on the inode size. */ lock_mode = xfs_ilock_attr_map_shared(dp...
0
[ "CWE-241", "CWE-19" ]
linux
8275cdd0e7ac550dcce2b3ef6d2fb3b808c1ae59
136,505,347,455,032,630,000,000,000,000,000,000,000
28
xfs: remote attribute overwrite causes transaction overrun Commit e461fcb ("xfs: remote attribute lookups require the value length") passes the remote attribute length in the xfs_da_args structure on lookup so that CRC calculations and validity checking can be performed correctly by related code. This, unfortunately h...
static int vrend_renderer_supported_structures(void *execute_args, uint32_t execute_size) { struct virgl_renderer_supported_structures *supported_structures = execute_args; if (execute_size != sizeof(struct virgl_renderer_supported_structures)) return -EINVAL; if (supported_structures->hdr.size != sizeo...
0
[ "CWE-787" ]
virglrenderer
cbc8d8b75be360236cada63784046688aeb6d921
267,611,792,668,555,670,000,000,000,000,000,000,000
19
vrend: check transfer bounds for negative values too and report error Closes #138 Signed-off-by: Gert Wollny <gert.wollny@collabora.com> Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
void respondResponseSpec(size_t index, ResponseSpec&& spec) { const bool trailers_empty = spec.trailers.empty(); const bool end_stream_on_headers = spec.body_chunks.empty() && trailers_empty; auto response_headers = std::make_unique<Http::TestResponseHeaderMapImpl>(); for (const auto& header : spec.re...
0
[ "CWE-476" ]
envoy
9b1c3962172a972bc0359398af6daa3790bb59db
262,316,888,513,332,360,000,000,000,000,000,000,000
28
healthcheck: fix grpc inline removal crashes (#749) Signed-off-by: Matt Klein <mklein@lyft.com> Signed-off-by: Pradeep Rao <pcrao@google.com>
void dump_xml(Formatter *f) const { encode_xml("Zone", zone_names, f); }
0
[ "CWE-79" ]
ceph
8f90658c731499722d5f4393c8ad70b971d05f77
329,983,321,217,410,000,000,000,000,000,000,000,000
3
rgw: reject unauthenticated response-header actions Signed-off-by: Matt Benjamin <mbenjamin@redhat.com> Reviewed-by: Casey Bodley <cbodley@redhat.com> (cherry picked from commit d8dd5e513c0c62bbd7d3044d7e2eddcd897bd400)
httpClientContinueDelayed(TimeEventHandlerPtr event) { static char httpContinue[] = "HTTP/1.1 100 Continue\r\n\r\n"; HTTPConnectionPtr connection = *(HTTPConnectionPtr*)event->data; do_stream(IO_WRITE, connection->fd, 0, httpContinue, 25, httpErrorNofinishStreamHandler, connection); retur...
0
[ "CWE-617" ]
polipo
0e2b44af619e46e365971ea52b97457bc0778cd3
134,351,324,283,366,250,000,000,000,000,000,000,000
9
Try to read POST requests to local configuration interface correctly.
int dsdb_load_udv_v2(struct ldb_context *samdb, struct ldb_dn *dn, TALLOC_CTX *mem_ctx, struct drsuapi_DsReplicaCursor2 **cursors, uint32_t *count) { static const char *attrs[] = { "replUpToDateVector", NULL }; struct ldb_result *r = NULL; const struct ldb_val *ouv_value; unsigned int i; int ret; uint64_t ...
0
[ "CWE-200" ]
samba
0a3aa5f908e351201dc9c4d4807b09ed9eedff77
305,586,513,628,663,700,000,000,000,000,000,000,000
85
CVE-2022-32746 ldb: Make use of functions for appending to an ldb_message This aims to minimise usage of the error-prone pattern of searching for a just-added message element in order to make modifications to it (and potentially finding the wrong element). BUG: https://bugzilla.samba.org/show_bug.cgi?id=15009 Signed...
static int tpacket_snd(struct packet_sock *po, struct msghdr *msg) { struct sk_buff *skb; struct net_device *dev; __be16 proto; int ifindex, err, reserve = 0; void *ph; struct sockaddr_ll *saddr = (struct sockaddr_ll *)msg->msg_name; int tp_len, size_max; unsigned char *addr; int len_sum = 0; int status = 0; ...
0
[ "CWE-200", "CWE-264" ]
linux
13fcb7bd322164c67926ffe272846d4860196dc6
303,024,903,600,859,650,000,000,000,000,000,000,000
124
af_packet: prevent information leak In 2.6.27, commit 393e52e33c6c2 (packet: deliver VLAN TCI to userspace) added a small information leak. Add padding field and make sure its zeroed before copy to user. Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com> CC: Patrick McHardy <kaber@trash.net> Signed-off-by: David S...
uint8_t* reallocate(uint8_t* ptr, int byte_size) { return reinterpret_cast<uint8_t*>(realloc(ptr, byte_size)); }
0
[ "CWE-200" ]
incubator-doris
246ac4e37aa4da6836b7850cb990f02d1c3725a3
164,233,001,174,147,100,000,000,000,000,000,000,000
3
[fix] fix a bug of encryption function with iv may return wrong result (#8277)
static long btrfs_ioctl_scrub_progress(struct btrfs_root *root, void __user *arg) { struct btrfs_ioctl_scrub_args *sa; int ret; if (!capable(CAP_SYS_ADMIN)) return -EPERM; sa = memdup_user(arg, sizeof(*sa)); if (IS_ERR(sa)) return PTR_ERR(sa); ret = btrfs_scrub_progress(root, sa->devid, &sa->pro...
0
[ "CWE-310" ]
linux-2.6
9c52057c698fb96f8f07e7a4bcf4801a092bda89
76,255,714,145,127,840,000,000,000,000,000,000,000
21
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...
static int unix_dgram_recvmsg(struct socket *sock, struct msghdr *msg, size_t size, int flags) { struct scm_cookie scm; struct sock *sk = sock->sk; struct unix_sock *u = unix_sk(sk); struct sk_buff *skb, *last; long timeo; int skip; int err; err = -EOPNOTSUPP; if (flags&MSG_OOB) goto out; timeo =...
0
[ "CWE-362" ]
linux
cbcf01128d0a92e131bd09f1688fe032480b65ca
49,026,160,709,335,950,000,000,000,000,000,000,000
106
af_unix: fix garbage collect vs MSG_PEEK unix_gc() assumes that candidate sockets can never gain an external reference (i.e. be installed into an fd) while the unix_gc_lock is held. Except for MSG_PEEK this is guaranteed by modifying inflight count under the unix_gc_lock. MSG_PEEK does not touch any variable protec...
bool isRootContext() { return root_context_id_ == 0; }
0
[ "CWE-476" ]
envoy
8788a3cf255b647fd14e6b5e2585abaaedb28153
242,614,362,000,982,930,000,000,000,000,000,000,000
1
1.4 - Do not call into the VM unless the VM Context has been created. (#24) * Ensure that the in VM Context is created before onDone is called. Signed-off-by: John Plevyak <jplevyak@gmail.com> * Update as per offline discussion. Signed-off-by: John Plevyak <jplevyak@gmail.com> * Set in_vm_context_created_ in onNet...
utf16_to_unicode(uint32_t *pwc, const char *s, size_t n, int be) { const char *utf16 = s; unsigned uc; if (n == 0) return (0); if (n == 1) { /* set the Replacement Character instead. */ *pwc = UNICODE_R_CHAR; return (-1); } if (be) uc = archive_be16dec(utf16); else uc = archive_le16dec(utf16); utf...
0
[ "CWE-476" ]
libarchive
42a3408ac7df1e69bea9ea12b72e14f59f7400c0
15,017,896,801,347,043,000,000,000,000,000,000,000
57
archive_strncat_l(): allocate and do not convert if length == 0 This ensures e.g. that archive_mstring_copy_mbs_len_l() does not set aes_set = AES_SET_MBS with aes_mbs.s == NULL. Resolves possible null-pointer dereference reported by OSS-Fuzz. Reported-By: OSS-Fuzz issue 286
static int row_compare(zval *object1, zval *object2 TSRMLS_DC) { return -1;
0
[ "CWE-476" ]
php-src
6045de69c7dedcba3eadf7c4bba424b19c81d00d
71,746,011,298,290,980,000,000,000,000,000,000,000
4
Fix bug #73331 - do not try to serialize/unserialize objects wddx can not handle Proper soltion would be to call serialize/unserialize and deal with the result, but this requires more work that should be done by wddx maintainer (not me).
static int dwt_plane(AVCodecContext *avctx, void *arg) { TransformArgs *transform_dat = arg; VC2EncContext *s = transform_dat->ctx; const void *frame_data = transform_dat->idata; const ptrdiff_t linesize = transform_dat->istride; const int field = transform_dat->field; const Plane *p = transfor...
0
[ "CWE-125" ]
FFmpeg
94e538aebbc9f9c529e8b1f2eda860cfb8c473b1
211,438,237,896,409,630,000,000,000,000,000,000,000
56
vc2enc_dwt: pad the temporary buffer by the slice size Since non-Haar wavelets need to look into pixels outside the frame, we need to pad the buffer. The old factor of two seemed to be a workaround that fact and only padded to the left and bottom. This correctly pads by the slice size and as such reduces memory usage ...
double val_real() { return value; }
0
[ "CWE-617" ]
server
807945f2eb5fa22e6f233cc17b85a2e141efe2c8
192,074,546,120,574,500,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 ...
vmxnet3_msix_load(QEMUFile *f, void *opaque, int version_id) { PCIDevice *d = PCI_DEVICE(opaque); msix_load(d, f); return 0; }
0
[ "CWE-20" ]
qemu
a7278b36fcab9af469563bd7b9dadebe2ae25e48
31,723,029,007,891,617,000,000,000,000,000,000,000
6
net/vmxnet3: Refine l2 header validation Validation of l2 header length assumed minimal packet size as eth_header + 2 * vlan_header regardless of the actual protocol. This caused crash for valid non-IP packets shorter than 22 bytes, as 'tx_pkt->packet_type' hasn't been assigned for such packets, and 'vmxnet3_on_tx_do...
SPICE_GNUC_VISIBLE int spice_server_add_renderer(SpiceServer *reds, const char *name) { if (!reds_add_renderer(reds, name)) { return -1; } return 0; }
0
[]
spice
ca5bbc5692e052159bce1a75f55dc60b36078749
286,918,970,603,915,100,000,000,000,000,000,000,000
7
With OpenSSL 1.1: Disable client-initiated renegotiation. Fixes issue #49 Fixes BZ#1904459 Signed-off-by: Julien Ropé <jrope@redhat.com> Reported-by: BlackKD Acked-by: Frediano Ziglio <fziglio@redhat.com>
time_t get_time_ref(void) { struct tm ltm; time_t t; if (DISPLAY_ONE_DAY(flags)) { localtime_r((time_t *) &(record_hdr[2].ust_time), &ltm); /* Move back to midnight */ ltm.tm_sec = ltm.tm_min = ltm.tm_hour = 0; t = mktime(&ltm); if (t != -1) return t; } return (time_t) record_hdr[2].ust_time; }
0
[ "CWE-125" ]
sysstat
fbc691eaaa10d0bcea6741d5a223dc3906106548
160,138,821,408,065,660,000,000,000,000,000,000,000
18
Fix #196 and #199: Out of bound reads security issues Check args before calling memmove() and memset() in remap_struct() function to avoid out of bound reads which would possibly lead to unknown code execution and/or sadf command crash. Signed-off-by: Sebastien GODARD <sysstat@users.noreply.github.com>
print_indent_tree(FILE* f, Node* node, int indent) { int i, type; int add = 3; UChar* p; Indent(f, indent); if (IS_NULL(node)) { fprintf(f, "ERROR: null node!!!\n"); exit (0); } type = NTYPE(node); switch (type) { case NT_LIST: case NT_ALT: if (NTYPE(node) == NT_LIST) fprintf(f, ...
0
[ "CWE-125" ]
php-src
c6e34d91b88638966662caac62c4d0e90538e317
252,918,768,153,402,300,000,000,000,000,000,000,000
162
Fix bug #77371 (heap buffer overflow in mb regex functions - compile_string_node)
static void posix_cpu_timers_init_group(struct signal_struct *sig) { /* Thread group counters. */ thread_group_cputime_init(sig); /* Expiration times and increments. */ sig->it_virt_expires = cputime_zero; sig->it_virt_incr = cputime_zero; sig->it_prof_expires = cputime_zero; sig->it_prof_incr = cputime_zero; ...
0
[ "CWE-264" ]
linux-2.6
2d5516cbb9daf7d0e342a2e3b0fc6f8c39a81205
234,542,378,659,341,800,000,000,000,000,000,000,000
21
copy_process: fix CLONE_PARENT && parent_exec_id interaction CLONE_PARENT can fool the ->self_exec_id/parent_exec_id logic. If we re-use the old parent, we must also re-use ->parent_exec_id to make sure exit_notify() sees the right ->xxx_exec_id's when the CLONE_PARENT'ed task exits. Also, move down the "p->parent_ex...
fribidi_get_type ( FriBidiChar ch /* input character */ ) { return fribidi_get_bidi_type (ch); }
0
[ "CWE-120" ]
fribidi
d989590e124ad995de3598800c8835d819fadf80
164,713,043,493,329,460,000,000,000,000,000,000,000
6
Reduce dynamic allocations by using arrays for all small arrays.
static int FNAME(walk_addr_generic)(struct guest_walker *walker, struct kvm_vcpu *vcpu, struct kvm_mmu *mmu, gva_t addr, u32 access) { pt_element_t pte; pt_element_t __user *ptep_user; gfn_t table_gfn; unsigned index, pt_access, uninitialized_var(pte_access); gpa_t pte_gpa; bool eperm, present, rs...
1
[ "CWE-20", "CWE-787" ]
linux
fa3d315a4ce2c0891cdde262562e710d95fba19e
50,262,660,279,963,230,000,000,000,000,000,000,000
200
KVM: Validate userspace_addr of memslot when registered This way, we can avoid checking the user space address many times when we read the guest memory. Although we can do the same for write if we check which slots are writable, we do not care write now: reading the guest memory happens more often than writing. [avi...
static int mov_preroll_write_stbl_atoms(AVIOContext *pb, MOVTrack *track) { struct sgpd_entry { int count; int16_t roll_distance; int group_description_index; }; struct sgpd_entry *sgpd_entries = NULL; int entries = -1; int group = 0; int i, j; const int OPUS_SEEK_P...
0
[ "CWE-125" ]
FFmpeg
95556e27e2c1d56d9e18f5db34d6f756f3011148
167,436,388,271,873,920,000,000,000,000,000,000,000
94
avformat/movenc: Do not pass AVCodecParameters in avpriv_request_sample Fixes: out of array read Fixes: ffmpeg_crash_8.avi Found-by: Thuan Pham, Marcel Böhme, Andrew Santosa and Alexandru Razvan Caciulescu with AFLSmart Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
void inet_frags_init_net(struct netns_frags *nf) { nf->nqueues = 0; init_frag_mem_limit(nf); INIT_LIST_HEAD(&nf->lru_list); }
1
[]
linux
3ef0eb0db4bf92c6d2510fe5c4dc51852746f206
125,028,594,000,871,860,000,000,000,000,000,000,000
6
net: frag, move LRU list maintenance outside of rwlock Updating the fragmentation queues LRU (Least-Recently-Used) list, required taking the hash writer lock. However, the LRU list isn't tied to the hash at all, so we can use a separate lock for it. Original-idea-by: Florian Westphal <fw@strlen.de> Signed-off-by: Je...
static void emulator_set_segment(struct x86_emulate_ctxt *ctxt, u16 selector, struct desc_struct *desc, u32 base3, int seg) { struct kvm_vcpu *vcpu = emul_to_vcpu(ctxt); struct kvm_segment var; var.selector = selector; var.base = get_desc_base(desc); #ifdef CONFIG_X86_64 var.base |= ((u64)base3) << 32; ...
0
[]
kvm
854e8bb1aa06c578c2c9145fa6bfe3680ef63b23
180,673,743,786,623,570,000,000,000,000,000,000,000
29
KVM: x86: Check non-canonical addresses upon WRMSR Upon WRMSR, the CPU should inject #GP if a non-canonical value (address) is written to certain MSRs. The behavior is "almost" identical for AMD and Intel (ignoring MSRs that are not implemented in either architecture since they would anyhow #GP). However, IA32_SYSENTE...
Gfx::Gfx(XRef *xrefA, OutputDev *outA, int pageNum, Dict *resDict, Catalog *catalogA, double hDPI, double vDPI, PDFRectangle *box, PDFRectangle *cropBox, int rotate, GBool (*abortCheckCbkA)(void *data), void *abortCheckCbkDataA) #ifdef USE_CMS : iccColorSpaceCache(5) #endif { int i; xref = xrefA; catalo...
0
[]
poppler
abf167af8b15e5f3b510275ce619e6fdb42edd40
12,785,658,402,128,644,000,000,000,000,000,000,000
55
Implement tiling/patterns in SplashOutputDev Fixes bug 13518
bool mark_unsupported_function(const char *w1, const char *w2, void *store, uint result) { char *ptr= (char*)current_thd->alloc(strlen(w1) + strlen(w2) + 1); if (ptr) strxmov(ptr, w1, w2, NullS); return mark_unsupported_function(ptr, store, result); }
0
[ "CWE-416" ]
server
c02ebf3510850ba78a106be9974c94c3b97d8585
12,354,256,538,368,470,000,000,000,000,000,000,000
8
MDEV-24176 Preparations 1. moved fix_vcol_exprs() call to open_table() mysql_alter_table() doesn't do lock_tables() so it cannot win from fix_vcol_exprs() from there. Tests affected: main.default_session 2. Vanilla cleanups and comments.
tape_buffered_peek (char *peek_buf, int in_des, int num_bytes) { long tmp_input_size; long got_bytes; char *append_buf; #ifdef BROKEN_LONG_TAPE_DRIVER /* Some tape drivers seem to have a signed internal seek pointer and they lose if it overflows and becomes negative (e.g. when writing tapes > 4Gb). ...
0
[ "CWE-190" ]
cpio
dd96882877721703e19272fe25034560b794061b
160,792,625,713,944,640,000,000,000,000,000,000,000
60
Rewrite dynamic string support. * src/dstring.c (ds_init): Take a single argument. (ds_free): New function. (ds_resize): Take a single argument. Use x2nrealloc to expand the storage. (ds_reset,ds_append,ds_concat,ds_endswith): New function. (ds_fgetstr): Rewrite. In particular, this fixes integer overflow. * src/dst...
nma_gconf_settings_add_connection (NMAGConfSettings *self, NMConnection *connection) { NMAGConfSettingsPrivate *priv; NMAGConfConnection *exported; guint32 i = 0; char *path = NULL; g_return_val_if_fail (NMA_IS_GCONF_SETTINGS (self), NULL); g_return_val_if_fail (NM_IS_CONNECTION (connection), NULL); priv = NMA...
0
[ "CWE-200" ]
network-manager-applet
8627880e07c8345f69ed639325280c7f62a8f894
255,673,554,111,850,340,000,000,000,000,000,000,000
42
editor: prevent any registration of objects on the system bus D-Bus access-control is name-based; so requests for a specific name are allowed/denied based on the rules in /etc/dbus-1/system.d. But apparently apps still get a non-named service on the bus, and if we register *any* object even though we don't have a nam...
static int wanxl_ioctl(struct net_device *dev, struct ifreq *ifr, int cmd) { const size_t size = sizeof(sync_serial_settings); sync_serial_settings line; port_t *port = dev_to_port(dev); if (cmd != SIOCWANDEV) return hdlc_ioctl(dev, ifr, cmd); switch (ifr->ifr_settings.type) { case IF_GET_IFACE: ifr->ifr_se...
0
[ "CWE-399" ]
linux
2b13d06c9584b4eb773f1e80bbaedab9a1c344e1
215,600,416,349,546,700,000,000,000,000,000,000,000
49
wanxl: fix info leak in ioctl The wanxl_ioctl() code fails to initialize the two padding bytes of struct sync_serial_settings after the ->loopback member. Add an explicit memset(0) before filling the structure to avoid the info leak. Signed-off-by: Salva Peiró <speiro@ai2.upv.es> Signed-off-by: David S. Miller <davem...
string_vformat(gstring * g, BOOL extend, const char *format, va_list ap) { enum ltypes { L_NORMAL=1, L_SHORT=2, L_LONG=3, L_LONGLONG=4, L_LONGDOUBLE=5, L_SIZE=6 }; int width, precision, off, lim; const char * fp = format; /* Deliberately not unsigned */ string_datestamp_offset = -1; /* Datestamp not inserted */ strin...
1
[ "CWE-787" ]
exim
478effbfd9c3cc5a627fc671d4bf94d13670d65f
326,088,426,302,491,780,000,000,000,000,000,000,000
302
Fix buffer overflow in string_vformat. Bug 2449
xmlStrlen(const xmlChar *str) { int len = 0; if (str == NULL) return(0); while (*str != 0) { /* non input consuming */ str++; len++; } return(len); }
0
[ "CWE-134" ]
libxml2
4472c3a5a5b516aaf59b89be602fbce52756c3e9
177,087,214,510,460,540,000,000,000,000,000,000,000
10
Fix some format string warnings with possible format string vulnerability For https://bugzilla.gnome.org/show_bug.cgi?id=761029 Decorate every method in libxml2 with the appropriate LIBXML_ATTR_FORMAT(fmt,args) macro and add some cleanups following the reports.
void allocate_data_block(struct f2fs_sb_info *sbi, struct page *page, block_t old_blkaddr, block_t *new_blkaddr, struct f2fs_summary *sum, int type, struct f2fs_io_info *fio, bool add_list) { struct sit_info *sit_i = SIT_I(sbi); struct curseg_info *curseg = CURSEG_I(sbi, type); mutex_lock(&curseg->curseg_mute...
0
[ "CWE-200", "CWE-476" ]
linux
d4fdf8ba0e5808ba9ad6b44337783bd9935e0982
186,932,139,226,864,340,000,000,000,000,000,000,000
52
f2fs: fix a panic caused by NULL flush_cmd_control Mount fs with option noflush_merge, boot failed for illegal address fcc in function f2fs_issue_flush: if (!test_opt(sbi, FLUSH_MERGE)) { ret = submit_flush_wait(sbi); atomic_inc(&fcc->issued_flush); -> Here, fcc illegal ...
static struct rpc_task *nfs4_do_unlck(struct file_lock *fl, struct nfs_open_context *ctx, struct nfs4_lock_state *lsp, struct nfs_seqid *seqid) { struct nfs4_unlockdata *data; struct rpc_message msg = { .rpc_proc = &nfs4_procedures[NFSPROC4_CLNT_LOCKU], .rpc_cred = ctx->cred, }; struct rpc_task_setup task...
0
[ "CWE-787" ]
linux
b4487b93545214a9db8cbf32e86411677b0cca21
235,665,283,541,213,900,000,000,000,000,000,000,000
40
nfs: Fix getxattr kernel panic and memory overflow Move the buffer size check to decode_attr_security_label() before memcpy() Only call memcpy() if the buffer is large enough Fixes: aa9c2669626c ("NFS: Client implementation of Labeled-NFS") Signed-off-by: Jeffrey Mitchell <jeffrey.mitchell@starlab.io> [Trond: clean u...
static uint32_t yuv_to_rgba(uint32_t ycbcr) { uint8_t r, g, b; int y, cb, cr; y = (ycbcr >> 16) & 0xFF; cr = (ycbcr >> 8) & 0xFF; cb = ycbcr & 0xFF; b = av_clip_uint8((1164 * (y - 16) + 2018 * (cb - 128)) / 1000); g = av_clip_uint8((1164 * (y - 16) - 813 * (c...
0
[ "CWE-399", "CWE-834" ]
FFmpeg
9cb4eb772839c5e1de2855d126bf74ff16d13382
90,248,199,274,038,860,000,000,000,000,000,000,000
15
avformat/mov: Fix DoS in read_tfra() Fixes: Missing EOF check in loop No testcase Found-by: Xiaohei and Wangchu from Alibaba Security Team Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
issuerAndThisUpdateValidate( Syntax *syntax, struct berval *in ) { int rc; struct berval i, tu; Debug( LDAP_DEBUG_TRACE, ">>> issuerAndThisUpdateValidate: <%s>\n", in->bv_val ); rc = issuerAndThisUpdateCheck( in, &i, &tu, NULL ); if ( rc ) { goto done; } /* validate DN -- doesn't handle double dquote */...
0
[ "CWE-617" ]
openldap
3539fc33212b528c56b716584f2c2994af7c30b0
236,793,413,976,636,460,000,000,000,000,000,000,000
34
ITS#9454 fix issuerAndThisUpdateCheck
short CLASS guess_byte_order (int words) { uchar test[4][2]; int t=2, msb; double diff, sum[2] = {0,0}; fread (test[0], 2, 2, ifp); for (words-=2; words--; ) { fread (test[t], 2, 1, ifp); for (msb=0; msb < 2; msb++) { diff = (test[t^2][msb] << 8 | test[t^2][!msb]) - (test[t ][msb] << 8 | t...
0
[ "CWE-703" ]
LibRaw
11909cc59e712e09b508dda729b99aeaac2b29ad
43,481,385,598,763,880,000,000,000,000,000,000,000
18
cumulated data checks patch
long long getInt64( int offsetBytes ) const { const char * x = afterNS(); x += offsetBytes; const long long * ll = (const long long*)x; return ll[0]; }
0
[ "CWE-20" ]
mongo
f9817a6cf64bdba8e1e1cef30a798110df746b58
325,607,483,094,962,100,000,000,000,000,000,000,000
6
SERVER-7769 - turn objcheck on by default and use new fast bson validate
SV* Perl_reg_named_buff_firstkey(pTHX_ REGEXP * const r, const U32 flags) { struct regexp *const rx = ReANY(r); PERL_ARGS_ASSERT_REG_NAMED_BUFF_FIRSTKEY; if ( rx && RXp_PAREN_NAMES(rx) ) { (void)hv_iterinit(RXp_PAREN_NAMES(rx)); return CALLREG_NAMED_BUFF_NEXTKEY(r, NULL, flags & ~RXapif_FIRSTKEY); ...
0
[ "CWE-190", "CWE-787" ]
perl5
897d1f7fd515b828e4b198d8b8bef76c6faf03ed
308,504,365,074,731,000,000,000,000,000,000,000,000
14
regcomp.c: Prevent integer overflow from nested regex quantifiers. (CVE-2020-10543) On 32bit systems the size calculations for nested regular expression quantifiers could overflow causing heap memory corruption. Fixes: Perl/perl5-security#125 (cherry picked from commit bfd31397db5dc1a5c5d3e0a1f753a4f89a736e71)
static int ext4_convert_unwritten_extents_endio(handle_t *handle, struct inode *inode, struct ext4_map_blocks *map, struct ext4_ext_path **ppath) { struct ext4_ext_path *path = *ppath; struct ext4_extent *ex; ext4_lblk_t ee_block; unsigned int ee_len; int depth; int err = 0; depth = ext_depth(...
0
[ "CWE-703" ]
linux
ce9f24cccdc019229b70a5c15e2b09ad9c0ab5d1
331,532,980,697,024,260,000,000,000,000,000,000,000
61
ext4: check journal inode extents more carefully Currently, system zones just track ranges of block, that are "important" fs metadata (bitmaps, group descriptors, journal blocks, etc.). This however complicates how extent tree (or indirect blocks) can be checked for inodes that actually track such metadata - currently...
static void addUser(OperationContext* opCtx, AuthorizationManager* authzManager, StringData db, bool update, stdx::unordered_set<UserName>* usersToDrop, const BSONObj& userObj) { UserName ...
0
[ "CWE-613" ]
mongo
e55d6e2292e5dbe2f97153251d8193d1cc89f5d7
171,756,070,430,560,880,000,000,000,000,000,000,000
30
SERVER-38984 Validate unique User ID on UserCache hit
CModule::EModRet CModule::OnChanNotice(CNick& Nick, CChan& Channel, CString& sMessage) { return CONTINUE; }
0
[ "CWE-20", "CWE-264" ]
znc
8de9e376ce531fe7f3c8b0aa4876d15b479b7311
332,084,941,452,343,030,000,000,000,000,000,000,000
4
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
mcs_recv_connect_response(STREAM mcs_data) { UNUSED(mcs_data); uint8 result; int length; STREAM s; RD_BOOL is_fastpath; uint8 fastpath_hdr; logger(Protocol, Debug, "%s()", __func__); s = iso_recv(&is_fastpath, &fastpath_hdr); if (s == NULL) return False; ber_parse_header(s, MCS_CONNECT_RESPONSE, &length)...
1
[ "CWE-119", "CWE-125", "CWE-703", "CWE-787" ]
rdesktop
4dca546d04321a610c1835010b5dad85163b65e1
327,188,869,959,354,300,000,000,000,000,000,000,000
45
Malicious RDP server security fixes This commit includes fixes for a set of 21 vulnerabilities in rdesktop when a malicious RDP server is used. All vulnerabilities was identified and reported by Eyal Itkin. * Add rdp_protocol_error function that is used in several fixes * Refactor of process_bitmap_updates * Fix ...
struct dump_dir *dd_create(const char *dir, uid_t uid, mode_t mode) { struct dump_dir *dd = dd_create_skeleton(dir, uid, mode, DD_CREATE_PARENTS); if (dd == NULL) return NULL; /* ignore results */ dd_reset_ownership(dd); return dd; }
0
[ "CWE-22" ]
libreport
239c4f7d1f47265526b39ad70106767d00805277
31,494,403,093,870,485,000,000,000,000,000,000,000
11
dd: harden functions against directory traversal issues Test correctness of all accessed dump dir files in all dd* functions. Before this commit, the callers were allowed to pass strings like "../../etc/shadow" in the filename argument of all dd* functions. Related: #1214457 Signed-off-by: Jakub Filak <jfilak@redhat...
gql_intro_eval(agooErr err, gqlDoc doc, gqlSel sel, gqlValue result, int depth) { struct _gqlField field; struct _gqlCobj obj; if (0 == strcmp("__type", sel->name)) { if (2 < depth) { return agoo_err_set(err, AGOO_ERR_EVAL, "__type can only be called from a query root."); } obj.clas = &root_class; ...
0
[ "CWE-703" ]
agoo
ecb72fa66f3d846b724b4fa1d7648669cebabe0c
35,524,304,798,482,140,000,000,000,000,000,000,000
28
Protect against recursive fragment in schema Really a error on the developers part but this catches the error.
slapi_pblock_set_ldif_dump_replica(Slapi_PBlock *pb, int32_t dump_replica) { #ifdef PBLOCK_ANALYTICS pblock_analytics_record(pb, SLAPI_LDIF_DUMP_REPLICA); #endif _pblock_assert_pb_task(pb); pb->pb_task->ldif_dump_replica = dump_replica; }
0
[ "CWE-415" ]
389-ds-base
a3c298f8140d3e4fa1bd5a670f1bb965a21a9b7b
140,017,178,889,255,610,000,000,000,000,000,000,000
8
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...
GF_Err tims_box_read(GF_Box *s, GF_BitStream *bs) { GF_TSHintEntryBox *ptr = (GF_TSHintEntryBox *)s; ISOM_DECREASE_SIZE(ptr, 4); ptr->timeScale = gf_bs_read_u32(bs); return GF_OK; }
0
[ "CWE-787" ]
gpac
388ecce75d05e11fc8496aa4857b91245007d26e
224,311,951,292,142,430,000,000,000,000,000,000,000
7
fixed #1587
static int xt_match_open(struct inode *inode, struct file *file) { struct nf_mttg_trav *trav; trav = __seq_open_private(file, &xt_match_seq_ops, sizeof(*trav)); if (!trav) return -ENOMEM; trav->nfproto = (unsigned long)PDE_DATA(inode); return 0; }
0
[ "CWE-119" ]
nf-next
d7591f0c41ce3e67600a982bab6989ef0f07b3ce
284,466,928,406,229,700,000,000,000,000,000,000,000
10
netfilter: x_tables: introduce and use xt_copy_counters_from_user The three variants use same copy&pasted code, condense this into a helper and use that. Make sure info.name is 0-terminated. Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
static int createFromTiffRgba(TIFF * tif, gdImagePtr im) { int a; int x, y; int alphaBlendingFlag = 0; int color; int width = im->sx; int height = im->sy; uint32 *buffer; uint32 rgba; /* switch off colour merging on target gd image just while we write out * content - we want to preserve the alpha data until...
1
[ "CWE-125" ]
libgd
4859d69e07504d4b0a4bdf9bcb4d9e3769ca35ae
6,118,651,100,920,499,000,000,000,000,000,000,000
43
Fix invalid read in gdImageCreateFromTiffPtr() tiff_invalid_read.tiff is corrupt, and causes an invalid read in gdImageCreateFromTiffPtr(), but not in gdImageCreateFromTiff(). The culprit is dynamicGetbuf(), which doesn't check for out-of-bound reads. In this case, dynamicGetbuf() is called with a negative dp->pos, bu...
static int mov_write_trailer(AVFormatContext *s) { MOVMuxContext *mov = s->priv_data; AVIOContext *pb = s->pb; int res = 0; int i; int64_t moov_pos; if (mov->need_rewrite_extradata) { for (i = 0; i < s->nb_streams; i++) { MOVTrack *track = &mov->tracks[i]; AVCode...
0
[ "CWE-125" ]
FFmpeg
95556e27e2c1d56d9e18f5db34d6f756f3011148
65,348,009,250,132,400,000,000,000,000,000,000,000
114
avformat/movenc: Do not pass AVCodecParameters in avpriv_request_sample Fixes: out of array read Fixes: ffmpeg_crash_8.avi Found-by: Thuan Pham, Marcel Böhme, Andrew Santosa and Alexandru Razvan Caciulescu with AFLSmart Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
unsigned long nr_free_buffer_pages(void) { return nr_free_zone_pages(gfp_zone(GFP_USER)); }
0
[]
linux
400e22499dd92613821374c8c6c88c7225359980
240,656,915,142,025,800,000,000,000,000,000,000,000
4
mm: don't warn about allocations which stall for too long Commit 63f53dea0c98 ("mm: warn about allocations which stall for too long") was a great step for reducing possibility of silent hang up problem caused by memory allocation stalls. But this commit reverts it, for it is possible to trigger OOM lockup and/or soft...