func
string
target
int64
cwe
list
project
string
commit_id
string
hash
float64
size
int64
message
string
void ImapModelOpenConnectionTest::testOkMissingImap4rev1() { SOCK->fakeReading( "* OK [CAPABILITY pwn] foo\r\n" ); QCoreApplication::processEvents(); QCoreApplication::processEvents(); QCoreApplication::processEvents(); QCOMPARE(SOCK->writtenStuff(), QByteArray("y0 LOGOUT\r\n")); QCoreApplicatio...
0
[ "CWE-200" ]
trojita
25fffa3e25cbad85bbca804193ad336b090a9ce1
31,417,542,423,252,965,000,000,000,000,000,000,000
13
IMAP: refuse to work when STARTTLS is required but server sends PREAUTH Oops, we cannot send STARTTLS when the connection is already authenticated. This is serious enough to warrant an error; an attacker might be going after a plaintext of a message we're going to APPEND, etc. Thanks to Arnt Gulbrandsen on the imap-p...
bytes_lstrip(PyBytesObject *self, PyObject *args) { if (PyTuple_GET_SIZE(args) == 0) return do_strip(self, LEFTSTRIP); /* Common case */ else return do_argstrip(self, LEFTSTRIP, args); }
0
[ "CWE-190" ]
cpython
6c004b40f9d51872d848981ef1a18bb08c2dfc42
97,962,249,268,192,600,000,000,000,000,000,000,000
7
bpo-30657: Fix CVE-2017-1000158 (#4758) Fixes possible integer overflow in PyBytes_DecodeEscape. Co-Authored-By: Jay Bosamiya <jaybosamiya@gmail.com>
void xfrm_audit_state_replay_overflow(struct xfrm_state *x, struct sk_buff *skb) { struct audit_buffer *audit_buf; u32 spi; audit_buf = xfrm_audit_start("SA-replay-overflow"); if (audit_buf == NULL) return; xfrm_audit_helper_pktinfo(skb, x->props.family, audit_buf); /* don't record the sequence numbe...
0
[ "CWE-416" ]
linux
dbb2483b2a46fbaf833cfb5deb5ed9cace9c7399
86,552,609,187,205,800,000,000,000,000,000,000,000
16
xfrm: clean up xfrm protocol checks In commit 6a53b7593233 ("xfrm: check id proto in validate_tmpl()") I introduced a check for xfrm protocol, but according to Herbert IPSEC_PROTO_ANY should only be used as a wildcard for lookup, so it should be removed from validate_tmpl(). And, IPSEC_PROTO_ANY is expected to only m...
const char *ssh_scp_request_get_warning(ssh_scp scp){ if(scp==NULL) return NULL; return scp->warning; }
1
[]
libssh
4aea835974996b2deb011024c53f4ff4329a95b5
261,871,064,608,404,140,000,000,000,000,000,000,000
5
CVE-2019-14889: scp: Reformat scp.c Fixes T181 Signed-off-by: Anderson Toshiyuki Sasaki <ansasaki@redhat.com> Reviewed-by: Andreas Schneider <asn@cryptomilk.org> (cherry picked from commit 42c727d0c186a1e2fa84a31ab40e16e58b404ab3)
static int get_spn_dn(struct ldb_context *ldb, TALLOC_CTX *tmp_ctx, const char *candidate, struct ldb_dn **dn) { int ret; const char *empty_attrs[] = { NULL }; struct ldb_message *msg = NULL; struct ldb_dn *base_dn = ldb_get_default_basedn(ldb); const char *enc_candidate = NULL; *dn = NU...
0
[ "CWE-200" ]
samba
0a3aa5f908e351201dc9c4d4807b09ed9eedff77
188,384,262,854,405,100,000,000,000,000,000,000,000
34
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 void _slurm_rpc_job_sbcast_cred(slurm_msg_t * msg) { #ifdef HAVE_FRONT_END slurm_send_rc_msg(msg, ESLURM_NOT_SUPPORTED); #else int error_code = SLURM_SUCCESS; slurm_msg_t response_msg; struct job_record *job_ptr = NULL, *job_pack_ptr; struct step_record *step_ptr; char *local_node_list = NULL, *node_list =...
0
[ "CWE-20" ]
slurm
033dc0d1d28b8d2ba1a5187f564a01c15187eb4e
298,543,105,741,176,870,000,000,000,000,000,000,000
209
Fix insecure handling of job requested gid. Only trust MUNGE signed values, unless the RPC was signed by SlurmUser or root. CVE-2018-10995.
xfs_isilocked( xfs_inode_t *ip, uint lock_flags) { if (lock_flags & (XFS_ILOCK_EXCL|XFS_ILOCK_SHARED)) { if (!(lock_flags & XFS_ILOCK_SHARED)) return !!ip->i_lock.mr_writer; return rwsem_is_locked(&ip->i_lock.mr_lock); } if (lock_flags & (XFS_MMAPLOCK_EXCL|XFS_MMAPLOCK_SHARED)) { if (!(lock_flags & XF...
0
[]
linux
01ea173e103edd5ec41acec65b9261b87e123fc2
10,805,381,793,425,810,000,000,000,000,000,000,000
26
xfs: fix up non-directory creation in SGID directories XFS always inherits the SGID bit if it is set on the parent inode, while the generic inode_init_owner does not do this in a few cases where it can create a possible security problem, see commit 0fa3ecd87848 ("Fix up non-directory creation in SGID directories") for...
bool CAlert::ProcessAlert() { if (!CheckSignature()) return false; if (!IsInEffect()) return false; CRITICAL_BLOCK(cs_mapAlerts) { // Cancel previous alerts for (map<uint256, CAlert>::iterator mi = mapAlerts.begin(); mi != mapAlerts.end();) { const CA...
0
[ "CWE-16", "CWE-787" ]
bitcoin
a206b0ea12eb4606b93323268fc81a4f1f952531
132,119,437,183,986,160,000,000,000,000,000,000,000
46
Do not allow overwriting unspent transactions (BIP 30) Introduce the following network rule: * a block is not valid if it contains a transaction whose hash already exists in the block chain, unless all that transaction's outputs were already spent before said block. Warning: this is effectively a network rule ...
void kvm_lapic_expired_hv_timer(struct kvm_vcpu *vcpu) { struct kvm_lapic *apic = vcpu->arch.apic; preempt_disable(); /* If the preempt notifier has already run, it also called apic_timer_expired */ if (!apic->lapic_timer.hv_timer_in_use) goto out; WARN_ON(rcuwait_active(&vcpu->wait)); apic_timer_expired(apic,...
0
[ "CWE-703", "CWE-459" ]
linux
f7d8a19f9a056a05c5c509fa65af472a322abfee
191,741,623,423,876,100,000,000,000,000,000,000,000
19
Revert "KVM: x86: Open code necessary bits of kvm_lapic_set_base() at vCPU RESET" Revert a change to open code bits of kvm_lapic_set_base() when emulating APIC RESET to fix an apic_hw_disabled underflow bug due to arch.apic_base and apic_hw_disabled being unsyncrhonized when the APIC is created. If kvm_arch_vcpu_crea...
TEST_P(DownstreamProtocolIntegrationTest, MissingHeadersLocalReplyUpstreamBytesCount) { useAccessLog("%UPSTREAM_WIRE_BYTES_SENT% %UPSTREAM_WIRE_BYTES_RECEIVED% " "%UPSTREAM_HEADER_BYTES_SENT% %UPSTREAM_HEADER_BYTES_RECEIVED%"); config_helper_.addFilter("{ name: invalid-header-filter, typed_config: { ...
0
[ "CWE-416" ]
envoy
148de954ed3585d8b4298b424aa24916d0de6136
172,360,433,247,886,360,000,000,000,000,000,000,000
23
CVE-2021-43825 Response filter manager crash Signed-off-by: Yan Avlasov <yavlasov@google.com>
static int em_sysexit(struct x86_emulate_ctxt *ctxt) { const struct x86_emulate_ops *ops = ctxt->ops; struct desc_struct cs, ss; u64 msr_data; int usermode; u16 cs_sel = 0, ss_sel = 0; /* inject #GP if in real mode or Virtual 8086 mode */ if (ctxt->mode == X86EMUL_MODE_REAL || ctxt->mode == X86EMUL_MODE_VM...
1
[]
kvm
234f3ce485d54017f15cf5e0699cff4100121601
58,092,279,782,719,850,000,000,000,000,000,000,000
50
KVM: x86: Emulator fixes for eip canonical checks on near branches Before changing rip (during jmp, call, ret, etc.) the target should be asserted to be canonical one, as real CPUs do. During sysret, both target rsp and rip should be canonical. If any of these values is noncanonical, a #GP exception should occur. Th...
static ssize_t shared_cpumap_show_func(struct device *dev, bool list, char *buf) { struct cacheinfo *this_leaf = dev_get_drvdata(dev); const struct cpumask *mask = &this_leaf->shared_cpu_map; return cpumap_print_to_pagebuf(list, buf, mask); }
0
[ "CWE-787" ]
linux
aa838896d87af561a33ecefea1caa4c15a68bc47
179,538,349,902,101,530,000,000,000,000,000,000,000
7
drivers core: Use sysfs_emit and sysfs_emit_at for show(device *...) functions Convert the various sprintf fmaily calls in sysfs device show functions to sysfs_emit and sysfs_emit_at for PAGE_SIZE buffer safety. Done with: $ spatch -sp-file sysfs_emit_dev.cocci --in-place --max-width=80 . And cocci script: $ cat s...
static int ZEND_FASTCALL ZEND_FETCH_OBJ_W_SPEC_VAR_CONST_HANDLER(ZEND_OPCODE_HANDLER_ARGS) { zend_op *opline = EX(opline); zend_free_op free_op1; zval *property = &opline->op2.u.constant; zval **container; if (IS_VAR == IS_VAR && (opline->extended_value & ZEND_FETCH_ADD_LOCK)) { PZVAL_LOCK(*EX_T(opline->op1.u....
0
[]
php-src
ce96fd6b0761d98353761bf78d5bfb55291179fd
46,987,377,995,603,490,000,000,000,000,000,000,000
44
- 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
static st8 mem_16bit_2reg(ArmOpcode *ao, ut64 m) { ut8 rd = getreg (ao->a[0]); ut8 rn = getregmemstart (ao->a[1]); if ( (rd < 8) && (rn < 8) && !(m & DOTW_BIT)) { ao->o |= rd << 8; ao->o |= rn << 11; return 2; } return 0; }
0
[ "CWE-125", "CWE-787" ]
radare2
e5c14c167b0dcf0a53d76bd50bacbbcc0dfc1ae7
40,423,334,438,324,680,000,000,000,000,000,000,000
10
Fix #12417/#12418 (arm assembler heap overflows)
static inline void pte_clear(struct mm_struct *mm, unsigned long addr, pte_t *ptep) { set_pte_at(mm, addr, ptep, __pte(0)); }
0
[ "CWE-276" ]
linux
cadfad870154e14f745ec845708bc17d166065f2
270,991,901,947,591,300,000,000,000,000,000,000,000
5
x86/ioperm: Fix io bitmap invalidation on Xen PV tss_invalidate_io_bitmap() wasn't wired up properly through the pvop machinery, so the TSS and Xen's io bitmap would get out of sync whenever disabling a valid io bitmap. Add a new pvop for tss_invalidate_io_bitmap() to fix it. This is XSA-329. Fixes: 22fe5b0439dd ("...
int check_change_password(THD *thd, const char *host, const char *user, char *new_password, uint new_password_len) { if (!initialized) { my_error(ER_OPTION_PREVENTS_STATEMENT, MYF(0), "--skip-grant-tables"); return(1); } if (!thd->slave_thread && (strcmp(thd->security_ct...
0
[]
mysql-server
25d1b7e03b9b375a243fabdf0556c063c7282361
88,614,327,356,016,000,000,000,000,000,000,000,000
25
Bug #22722946: integer overflow may lead to wrong results in get_56_lenc_string
int setup_tests(void) { ADD_TEST(test_x509_cmp_time_current); ADD_ALL_TESTS(test_x509_cmp_time, OSSL_NELEM(x509_cmp_tests)); ADD_ALL_TESTS(test_x509_time, OSSL_NELEM(x509_format_tests)); ADD_ALL_TESTS(test_days, OSSL_NELEM(day_of_week_tests)); ADD_ALL_TESTS(test_x509_time_print, OSSL_NELEM(x509_prin...
0
[ "CWE-125" ]
openssl
4de66925203ca99189c842136ec4a623137ea447
180,925,071,286,908,600,000,000,000,000,000,000,000
9
Fix test code to not assume NUL terminated strings ASN.1 strings may not be NUL terminated. Don't assume they are. CVE-2021-3712 Reviewed-by: Viktor Dukhovni <viktor@openssl.org> Reviewed-by: Paul Dale <pauli@openssl.org>
static void yy_stack_print (yytype_int16 *yybottom, yytype_int16 *yytop) { YYFPRINTF (stderr, "Stack now"); for (; yybottom <= yytop; yybottom++) { int yybot = *yybottom; YYFPRINTF (stderr, " %d", yybot); }
0
[ "CWE-674", "CWE-787" ]
yara
10e8bd3071677dd1fa76beeef4bc2fc427cea5e7
107,558,190,317,509,180,000,000,000,000,000,000,000
10
Fix issue #674 for hex strings.
static void r_anal_set_stringrefs(RCore *core, RAnalFunction *fcn) { RListIter *iter; RAnalRef *ref; RList *refs = r_anal_function_get_refs (fcn); r_list_foreach (refs, iter, ref) { if (ref->type == R_ANAL_REF_TYPE_DATA && r_bin_is_string (core->bin, ref->addr)) { r_anal_xrefs_set (core->anal, ref->at, ref-...
0
[ "CWE-416" ]
radare2
10517e3ff0e609697eb8cde60ec8dc999ee5ea24
51,636,085,179,408,060,000,000,000,000,000,000,000
12
aaef on arm/thumb switches causes uaf ##crash * Reported by peacock-doris via huntr.dev * Reproducer: poc_uaf_r_reg_get
void ndpi_apply_flow_protocol_to_packet(struct ndpi_flow_struct *flow, struct ndpi_packet_struct *packet) { memcpy(&packet->detected_protocol_stack, &flow->detected_protocol_stack, sizeof(packet->detected_protocol_stack)); memcpy(&packet->protocol_stack_info, &flow->protocol_stack_info, sizeof(packet->protocol_stac...
0
[ "CWE-416", "CWE-787" ]
nDPI
6a9f5e4f7c3fd5ddab3e6727b071904d76773952
307,157,262,927,429,640,000,000,000,000,000,000,000
4
Fixed use after free caused by dangling pointer * This fix also improved RCE Injection detection Signed-off-by: Toni Uhlig <matzeton@googlemail.com>
uint32_t skip(Protocol_& prot, TType arg_type) { switch (arg_type) { case T_BOOL: { bool boolv; return prot.readBool(boolv); } case T_BYTE: { int8_t bytev = 0; return prot.readByte(bytev); } case T_I16: { int16_t i16; return prot.readI16(i16); } case T_I...
1
[ "CWE-20", "CWE-755" ]
fbthrift
01686e15ec77ccb4d49a77d5bce3a01601e54d64
100,606,779,553,170,800,000,000,000,000,000,000,000
112
Throw on skipping an invalid type. Summary: Certain values (e.g.) T_STOP should not appear as a skip type. Allowing them to can cause thrift to loop unboundedly. Reviewed By: spalamarchuk Differential Revision: D15102451 fbshipit-source-id: c08d52f44f37e9c212d3480233ac217105586c9f
void X509Certificate::ValidTo(const FunctionCallbackInfo<Value>& args) { Environment* env = Environment::GetCurrent(args); X509Certificate* cert; ASSIGN_OR_RETURN_UNWRAP(&cert, args.Holder()); BIOPointer bio(BIO_new(BIO_s_mem())); Local<Value> ret; if (GetValidTo(env, cert->get(), bio).ToLocal(&ret)) ar...
0
[ "CWE-295" ]
node
466e5415a2b7b3574ab5403acb87e89a94a980d1
300,974,215,283,683,500,000,000,000,000,000,000,000
9
crypto,tls: implement safe x509 GeneralName format This change introduces JSON-compatible escaping rules for strings that include X.509 GeneralName components (see RFC 5280). This non-standard format avoids ambiguities and prevents injection attacks that could previously lead to X.509 certificates being accepted even ...
static s32 atl2_read_mac_addr(struct atl2_hw *hw) { if (get_permanent_address(hw)) { /* for test */ /* FIXME: shouldn't we use eth_random_addr() here? */ hw->perm_mac_addr[0] = 0x00; hw->perm_mac_addr[1] = 0x13; hw->perm_mac_addr[2] = 0x74; hw->perm_mac_addr[3] = 0x00; hw->perm_mac_addr[4] = 0x5c; hw->...
0
[ "CWE-200" ]
linux
f43bfaeddc79effbf3d0fcb53ca477cca66f3db8
191,946,342,018,994,030,000,000,000,000,000,000,000
17
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...
void MainWindow::seekTimeline(int position, bool seekPlayer) { if (!multitrack()) return; // we bypass this->open() to prevent sending producerOpened signal to self, which causes to reload playlist if (MLT.producer() && (void*) MLT.producer()->get_producer() != (void*) multitrack()->get_producer()) { ...
0
[ "CWE-89", "CWE-327", "CWE-295" ]
shotcut
f008adc039642307f6ee3378d378cdb842e52c1d
173,660,694,825,120,630,000,000,000,000,000,000,000
23
fix upgrade check is not using TLS correctly
context_independent_aggregate_values (class ipcp_param_lattices *plats) { vec<ipa_agg_value> res = vNULL; if (plats->aggs_bottom || plats->aggs_contain_variable || plats->aggs_count == 0) return vNULL; for (struct ipcp_agg_lattice *aglat = plats->aggs; aglat; aglat = aglat->next) ...
0
[ "CWE-20" ]
gcc
a09ccc22459c565814f79f96586fe4ad083fe4eb
92,376,085,569,506,660,000,000,000,000,000,000,000
21
Avoid segfault when doing IPA-VRP but not IPA-CP (PR 93015) 2019-12-21 Martin Jambor <mjambor@suse.cz> PR ipa/93015 * ipa-cp.c (ipcp_store_vr_results): Check that info exists testsuite/ * gcc.dg/lto/pr93015_0.c: New test. From-SVN: r279695
static double mp_min(_cimg_math_parser& mp) { const unsigned int i_end = (unsigned int)mp.opcode[2]; double val = _mp_arg(3); for (unsigned int i = 4; i<i_end; ++i) val = std::min(val,_mp_arg(i)); return val; }
0
[ "CWE-770" ]
cimg
619cb58dd90b4e03ac68286c70ed98acbefd1c90
300,993,579,284,938,680,000,000,000,000,000,000,000
6
CImg<>::load_bmp() and CImg<>::load_pandore(): Check that dimensions encoded in file does not exceed file size.
SPL_METHOD(SplPriorityQueue, current) { spl_heap_object *intern = (spl_heap_object*)zend_object_store_get_object(getThis() TSRMLS_CC); zval **element = (zval **)&intern->heap->elements[0]; if (zend_parse_parameters_none() == FAILURE) { return; } if (!intern->heap->count || !*element) { RETURN_N...
0
[]
php-src
1cbd25ca15383394ffa9ee8601c5de4c0f2f90e1
110,682,364,336,202,130,000,000,000,000,000,000,000
22
Fix bug #69737 - Segfault when SplMinHeap::compare produces fatal error
GF_Err sidx_box_read(GF_Box *s,GF_BitStream *bs) { u32 i; GF_SegmentIndexBox *ptr = (GF_SegmentIndexBox*) s; ISOM_DECREASE_SIZE(ptr, 8); ptr->reference_ID = gf_bs_read_u32(bs); ptr->timescale = gf_bs_read_u32(bs); if (ptr->version==0) { ISOM_DECREASE_SIZE(ptr, 8); ptr->earliest_presentation_time = gf_bs_re...
0
[ "CWE-787" ]
gpac
388ecce75d05e11fc8496aa4857b91245007d26e
174,738,248,864,824,740,000,000,000,000,000,000,000
36
fixed #1587
polkit_system_bus_name_new (const gchar *name) { g_return_val_if_fail (g_dbus_is_unique_name (name), NULL); return POLKIT_SUBJECT (g_object_new (POLKIT_TYPE_SYSTEM_BUS_NAME, "name", name, NULL)); }
0
[ "CWE-754" ]
polkit
a04d13affe0fa53ff618e07aa8f57f4c0e3b9b81
232,932,275,612,063,560,000,000,000,000,000,000,000
7
GHSL-2021-074: authentication bypass vulnerability in polkit initial values returned if error caught
static void nft_setelem_remove(const struct net *net, const struct nft_set *set, const struct nft_set_elem *elem) { if (nft_setelem_is_catchall(set, elem)) nft_setelem_catchall_remove(net, set, elem); else set->ops->remove(net, set, elem); }
0
[ "CWE-665" ]
linux
ad9f151e560b016b6ad3280b48e42fa11e1a5440
56,461,097,629,945,210,000,000,000,000,000,000,000
9
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: ...
ex_startinsert(exarg_T *eap) { if (eap->forceit) { // cursor line can be zero on startup if (!curwin->w_cursor.lnum) curwin->w_cursor.lnum = 1; set_cursor_for_append_to_line(); } #ifdef FEAT_TERMINAL // Ignore this when running in an active terminal. if (term_job_running(curbuf->b_term)) re...
0
[ "CWE-126", "CWE-703" ]
vim
4d97a565ae8be0d4debba04ebd2ac3e75a0c8010
42,549,032,311,937,820,000,000,000,000,000,000,000
37
patch 8.2.5037: cursor position may be invalid after "0;" range Problem: Cursor position may be invalid after "0;" range. Solution: Check the cursor position when it was set by ";" in the range.
read_applet_private_values_from_gconf (NMSetting *setting, ReadFromGConfInfo *info) { if (NM_IS_SETTING_802_1X (setting)) { const char *setting_name = nm_setting_get_name (setting); gboolean value; if (nm_gconf_get_bool_helper (info->client, info->dir, ...
1
[ "CWE-310" ]
network-manager-applet
4020594dfbf566f1852f0acb36ad631a9e73a82b
237,410,975,103,383,960,000,000,000,000,000,000,000
36
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...
int jbd2_journal_get_write_access(handle_t *handle, struct buffer_head *bh) { struct journal_head *jh; int rc; if (jbd2_write_access_granted(handle, bh, false)) return 0; jh = jbd2_journal_add_journal_head(bh); /* We do not want to get caught playing with fields which the * log thread also manipulates. Make...
0
[ "CWE-787" ]
linux
e09463f220ca9a1a1ecfda84fcda658f99a1f12a
135,762,394,864,197,800,000,000,000,000,000,000,000
16
jbd2: don't mark block as modified if the handle is out of credits Do not set the b_modified flag in block's journal head should not until after we're sure that jbd2_journal_dirty_metadat() will not abort with an error due to there not being enough space reserved in the jbd2 handle. Otherwise, future attempts to modi...
static void vnc_mouse_set(DisplayState *ds, int x, int y, int visible) { /* can we ask the client(s) to move the pointer ??? */ }
0
[ "CWE-125" ]
qemu
9f64916da20eea67121d544698676295bbb105a7
172,784,173,666,353,800,000,000,000,000,000,000,000
4
pixman/vnc: use pixman images in vnc. The vnc code uses *three* DisplaySurfaces: First is the surface of the actual QemuConsole, usually the guest screen, but could also be a text console (monitor/serial reachable via Ctrl-Alt-<nr> keys). This is left as-is. Second is the current server's view of the screen content...
static void mon_update_local_domain(struct tipc_monitor *mon) { struct tipc_peer *self = mon->self; struct tipc_mon_domain *cache = &mon->cache; struct tipc_mon_domain *dom = self->domain; struct tipc_peer *peer = self; u64 prev_up_map = dom->up_map; u16 member_cnt, i; bool diff; /* Update local domain size ba...
0
[ "CWE-787" ]
linux
9aa422ad326634b76309e8ff342c246800621216
105,860,633,324,169,030,000,000,000,000,000,000,000
35
tipc: improve size validations for received domain records The function tipc_mon_rcv() allows a node to receive and process domain_record structs from peer nodes to track their views of the network topology. This patch verifies that the number of members in a received domain record does not exceed the limit defined b...
static void do_busid_cmd(ESPState *s, uint8_t busid) { uint32_t cmdlen; int32_t datalen; int lun; SCSIDevice *current_lun; uint8_t buf[ESP_CMDFIFO_SZ]; trace_esp_do_busid_cmd(busid); lun = busid & 7; cmdlen = fifo8_num_used(&s->cmdfifo); esp_fifo_pop_buf(&s->cmdfifo, buf, cmdlen); ...
1
[ "CWE-476" ]
qemu
99545751734035b76bd372c4e7215bb337428d89
288,321,476,951,010,860,000,000,000,000,000,000,000
40
esp: ensure cmdfifo is not empty and current_dev is non-NULL When about to execute a SCSI command, ensure that cmdfifo is not empty and current_dev is non-NULL. This can happen if the guest tries to execute a TI (Transfer Information) command without issuing one of the select commands first. Buglink: https://bugs.lau...
TPM2B_AUTH_Marshal(TPM2B_AUTH *source, BYTE **buffer, INT32 *size) { UINT16 written = 0; written += TPM2B_DIGEST_Marshal(source, buffer, size); return written; }
0
[ "CWE-787" ]
libtpms
3ef9b26cb9f28bd64d738bff9505a20d4eb56acd
59,116,736,749,594,610,000,000,000,000,000,000,000
6
tpm2: Add maxSize parameter to TPM2B_Marshal for sanity checks Add maxSize parameter to TPM2B_Marshal and assert on it checking the size of the data intended to be marshaled versus the maximum buffer size. Signed-off-by: Stefan Berger <stefanb@linux.ibm.com>
void __init signals_init(void) { /* If this check fails, the __ARCH_SI_PREAMBLE_SIZE value is wrong! */ BUILD_BUG_ON(__ARCH_SI_PREAMBLE_SIZE != offsetof(struct siginfo, _sifields._pad)); sigqueue_cachep = KMEM_CACHE(sigqueue, SLAB_PANIC); }
0
[ "CWE-119", "CWE-787" ]
linux
4ea77014af0d6205b05503d1c7aac6eace11d473
150,319,454,383,306,010,000,000,000,000,000,000,000
8
kernel/signal.c: avoid undefined behaviour in kill_something_info When running kill(72057458746458112, 0) in userspace I hit the following issue. UBSAN: Undefined behaviour in kernel/signal.c:1462:11 negation of -2147483648 cannot be represented in type 'int': CPU: 226 PID: 9849 Comm: test Tainted: G B ...
static void irda_connect_indication(void *instance, void *sap, struct qos_info *qos, __u32 max_sdu_size, __u8 max_header_size, struct sk_buff *skb) { struct irda_sock *self; struct sock *sk; self = instance; pr_debug("%s(%p)\n", __func__, self); sk = instance; if (sk == NULL) { dev_kfree_skb(...
0
[]
net
79462ad02e861803b3840cc782248c7359451cd9
142,962,254,894,717,670,000,000,000,000,000,000,000
55
net: add validation for the socket syscall protocol argument 郭永刚 reported that one could simply crash the kernel as root by using a simple program: int socket_fd; struct sockaddr_in addr; addr.sin_port = 0; addr.sin_addr.s_addr = INADDR_ANY; addr.sin_family = 10; socket_fd = socket(10,3,0x40000000); connect(s...
static int ttm_tt_set_page_caching(struct page *p, enum ttm_caching_state c_old, enum ttm_caching_state c_new) { int ret = 0; if (PageHighMem(p)) return 0; if (c_old != tt_cached) { /* p isn't in the default caching state, set it to * writeback first to free its current memtype. */ ret = tt...
0
[]
linux
5de5b6ecf97a021f29403aa272cb4e03318ef586
141,617,827,192,998,950,000,000,000,000,000,000,000
25
drm/ttm/nouveau: don't call tt destroy callback on alloc failure. This is confusing, and from my reading of all the drivers only nouveau got this right. Just make the API act under driver control of it's own allocation failing, and don't call destroy, if the page table fails to create there is nothing to cleanup here...
ngx_http_lua_subrequest(ngx_http_request_t *r, ngx_str_t *uri, ngx_str_t *args, ngx_http_request_t **psr, ngx_http_post_subrequest_t *ps, ngx_uint_t flags) { ngx_time_t *tp; ngx_connection_t *c; ngx_http_request_t *sr; ngx_http_core_srv_conf_t *csc...
0
[ "CWE-444" ]
lua-nginx-module
9ab38e8ee35fc08a57636b1b6190dca70b0076fa
162,290,439,629,997,130,000,000,000,000,000,000,000
146
bugfix: prevented request smuggling in the ngx.location.capture API. Signed-off-by: Yichun Zhang (agentzh) <yichun@openresty.com>
static void check_session_recv_data_with_padding(nghttp2_bufs *bufs, size_t datalen, nghttp2_mem *mem) { nghttp2_session *session; my_user_data ud; nghttp2_session_callbacks callbacks; uint8_t *in; size_t inlen; ...
0
[]
nghttp2
0a6ce87c22c69438ecbffe52a2859c3a32f1620f
204,569,776,382,762,650,000,000,000,000,000,000,000
29
Add nghttp2_option_set_max_outbound_ack
int cil_resolve_typepermissive(struct cil_tree_node *current, void *extra_args) { struct cil_typepermissive *typeperm = current->data; struct cil_symtab_datum *type_datum = NULL; struct cil_tree_node *type_node = NULL; int rc = SEPOL_ERR; rc = cil_resolve_name(current, typeperm->type_str, CIL_SYM_TYPES, extra_arg...
0
[ "CWE-125" ]
selinux
340f0eb7f3673e8aacaf0a96cbfcd4d12a405521
300,514,899,091,104,430,000,000,000,000,000,000,000
27
libsepol/cil: Check for statements not allowed in optional blocks While there are some checks for invalid statements in an optional block when resolving the AST, there are no checks when building the AST. OSS-Fuzz found the following policy which caused a null dereference in cil_tree_get_next_path(). (blockinherit ...
std::unique_ptr<Aead> getInitialCipher( QuicVersion version = QuicVersion::MVFST) { FizzCryptoFactory cryptoFactory; return cryptoFactory.getClientInitialCipher( *initialDestinationConnectionId, version); }
0
[ "CWE-617", "CWE-703" ]
mvfst
a67083ff4b8dcbb7ee2839da6338032030d712b0
130,137,472,833,704,010,000,000,000,000,000,000,000
6
Close connection if we derive an extra 1-rtt write cipher Summary: Fixes CVE-2021-24029 Reviewed By: mjoras, lnicco Differential Revision: D26613890 fbshipit-source-id: 19bb2be2c731808144e1a074ece313fba11f1945
find_binding_msg_data(struct mswsp_ct *ct, packet_info *pinfo, void *private_data) { struct CPMSetBindingsIn *result = NULL; struct message_data *data = find_matching_request_by_fid(ct, pinfo, 0xD0, TRUE, private_data); if (data) { result = &data->content.bindingsin; } return result; }
0
[ "CWE-770" ]
wireshark
b7a0650e061b5418ab4a8f72c6e4b00317aff623
309,986,563,203,618,560,000,000,000,000,000,000,000
9
MS-WSP: Don't allocate huge amounts of memory. Add a couple of memory allocation sanity checks, one of which fixes #17331.
dns_zone_getgluecachestats(dns_zone_t *zone) { REQUIRE(DNS_ZONE_VALID(zone)); return (zone->gluecachestats); }
0
[ "CWE-327" ]
bind9
f09352d20a9d360e50683cd1d2fc52ccedcd77a0
184,853,498,336,741,400,000,000,000,000,000,000,000
5
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.
zzip_mem_entry_new(ZZIP_DISK* disk, ZZIP_DISK_ENTRY* entry) { if (! disk || ! entry) { errno=EINVAL; return 0; } ___ ZZIP_MEM_ENTRY* item = calloc(1, sizeof(*item)); if (! item) return 0; /* errno=ENOMEM; */ ___ struct zzip_file_header* header = zzip_disk_entry_to_file_header(disk, entry); /* th...
0
[ "CWE-119" ]
zziplib
596d9dfce2624e849417d4301e8d67935608aa5e
324,666,092,565,057,470,000,000,000,000,000,000,000
59
memdisk (.)
unsigned long (*CRYPTO_get_id_callback(void))(void) { return(id_callback); }
0
[ "CWE-310" ]
openssl
270881316664396326c461ec7a124aec2c6cc081
275,117,340,011,282,160,000,000,000,000,000,000,000
4
Add and use a constant-time memcmp. This change adds CRYPTO_memcmp, which compares two vectors of bytes in an amount of time that's independent of their contents. It also changes several MAC compares in the code to use this over the standard memcmp, which may leak information about the size of a matching prefix. (cher...
jpc_pi_t *jpc_enc_pi_create(jpc_enc_cp_t *cp, jpc_enc_tile_t *tile) { jpc_pi_t *pi; int compno; jpc_picomp_t *picomp; jpc_pirlvl_t *pirlvl; jpc_enc_tcmpt_t *tcomp; int rlvlno; jpc_enc_rlvl_t *rlvl; int prcno; int *prclyrno; if (!(pi = jpc_pi_create0())) { return 0; } pi->pktno = -1; pi->numcomps = cp->n...
0
[ "CWE-189" ]
jasper
3c55b399c36ef46befcb21e4ebc4799367f89684
47,113,183,929,432,490,000,000,000,000,000,000,000
105
At many places in the code, jas_malloc or jas_recalloc was being invoked with the size argument being computed in a manner that would not allow integer overflow to be detected. Now, these places in the code have been modified to use special-purpose memory allocation functions (e.g., jas_alloc2, jas_alloc3, jas_realloc...
struct r_bin_pe_section_t* PE_(r_bin_pe_get_sections)(struct PE_(r_bin_pe_obj_t)* bin) { struct r_bin_pe_section_t* sections = NULL; PE_(image_section_header) * shdr; int i, j, section_count = 0; if (!bin || !bin->nt_headers) { return NULL; } shdr = bin->section_header; for (i = 0; i < bin->num_sections; i++)...
0
[ "CWE-125" ]
radare2
4e1cf0d3e6f6fe2552a269def0af1cd2403e266c
166,279,226,562,802,650,000,000,000,000,000,000,000
70
Fix crash in pe
_g_file_set_attributes_from_entry (GFile *file, struct archive_entry *entry, ExtractData *extract_data, GCancellable *cancellable) { GFileInfo *info; GError *error = NULL; info = g_file_info_new (); /* times */ if (archive_entry_ctime_is_set (entry)) { g...
0
[ "CWE-22" ]
file-roller
b147281293a8307808475e102a14857055f81631
233,346,529,916,769,400,000,000,000,000,000,000,000
67
libarchive: sanitize filenames before extracting
GF_Err elng_box_write(GF_Box *s, GF_BitStream *bs) { GF_Err e; GF_ExtendedLanguageBox *ptr = (GF_ExtendedLanguageBox *)s; e = gf_isom_full_box_write(s, bs); if (e) return e; if (ptr->extended_language) { gf_bs_write_data(bs, ptr->extended_language, (u32)(strlen(ptr->extended_language)+1)); } return GF_OK; }
0
[ "CWE-787" ]
gpac
388ecce75d05e11fc8496aa4857b91245007d26e
310,288,800,809,483,370,000,000,000,000,000,000,000
11
fixed #1587
de265_error read_scaling_list(bitreader* br, const seq_parameter_set* sps, scaling_list_data* sclist, bool inPPS) { int dc_coeff[4][6]; for (int sizeId=0;sizeId<4;sizeId++) { //int n = ((sizeId==3) ? 2 : 6); uint8_t scaling_list[6][32*32]; for (int matrixId=0 ; matrixId<6...
0
[ "CWE-787" ]
libde265
8e89fe0e175d2870c39486fdd09250b230ec10b8
160,669,395,458,798,150,000,000,000,000,000,000,000
138
error on out-of-range cpb_cnt_minus1 (oss-fuzz issue 27590)
Nonlocal(asdl_seq * names, int lineno, int col_offset, int end_lineno, int end_col_offset, PyArena *arena) { stmt_ty p; p = (stmt_ty)PyArena_Malloc(arena, sizeof(*p)); if (!p) return NULL; p->kind = Nonlocal_kind; p->v.Nonlocal.names = names; p->lineno = lineno; p->col_offse...
0
[ "CWE-125" ]
cpython
dcfcd146f8e6fc5c2fc16a4c192a0c5f5ca8c53c
179,838,827,278,027,850,000,000,000,000,000,000,000
15
bpo-35766: Merge typed_ast back into CPython (GH-11645)
static void on_btn_add_file(GtkButton *button) { GtkWidget *dialog = gtk_file_chooser_dialog_new( "Attach File", GTK_WINDOW(g_wnd_assistant), GTK_FILE_CHOOSER_ACTION_OPEN, _("_Cancel"), GTK_RESPONSE_CANCEL, _("_Open"), GTK_RESPONSE_ACCEPT, NULL...
0
[ "CWE-200" ]
libreport
257578a23d1537a2d235aaa2b1488ee4f818e360
209,334,022,499,991,900,000,000,000,000,000,000,000
84
wizard: fix save users changes after reviewing dump dir files If the user reviewed the dump dir's files during reporting the crash, the changes was thrown away and original data was passed to the bugzilla bug report. report-gtk saves the first text view buffer and then reloads data from the reported problem directory...
int addrconf_set_dstaddr(struct net *net, void __user *arg) { struct in6_ifreq ireq; struct net_device *dev; int err = -EINVAL; rtnl_lock(); err = -EFAULT; if (copy_from_user(&ireq, arg, sizeof(struct in6_ifreq))) goto err_exit; dev = __dev_get_by_index(net, ireq.ifr6_ifindex); err = -ENODEV; if (dev == ...
0
[]
net
4b08a8f1bd8cb4541c93ec170027b4d0782dab52
323,800,654,649,422,200,000,000,000,000,000,000,000
60
ipv6: remove max_addresses check from ipv6_create_tempaddr Because of the max_addresses check attackers were able to disable privacy extensions on an interface by creating enough autoconfigured addresses: <http://seclists.org/oss-sec/2012/q4/292> But the check is not actually needed: max_addresses protects the kerne...
static CPINLINE void swoole_serialize_string(seriaString *buffer, zval *zvalue) { swoole_string_cpy(buffer, Z_STRVAL_P(zvalue), Z_STRLEN_P(zvalue)); }
0
[ "CWE-200", "CWE-502" ]
swoole-src
4cdbce5d9bf2fe596bb6acd7d6611f9e8c253a76
17,055,306,713,878,790,000,000,000,000,000,000,000
5
add buffer end check
static void append_cs_return(cs_entry *ptr) { unsigned short cr; int i; byte *p, *q, *data, *new_data; assert(ptr != NULL && ptr->valid && ptr->used); /* decrypt the cs data to t1_buf_array, append CS_RETURN */ p = (byte *) t1_buf_array; data = ptr->data + 4; cr = 4330; for (i = 0; ...
0
[ "CWE-119" ]
texlive-source
6ed0077520e2b0da1fd060c7f88db7b2e6068e4c
211,512,886,437,208,400,000,000,000,000,000,000,000
31
writet1 protection against buffer overflow git-svn-id: svn://tug.org/texlive/trunk/Build/source@48697 c570f23f-e606-0410-a88d-b1316a301751
esmtp_get_authtypes (const guchar *buffer) { const guchar *start, *end; GHashTable *table = NULL; start = buffer; /* make sure there is at least one delimiter * character in the AUTH response */ if (!isspace ((gint) *start) && *start != '=') return NULL; /* advance to the first token */ while (isspace ((g...
0
[ "CWE-74" ]
evolution-data-server
ba82be72cfd427b5d72ff21f929b3a6d8529c4df
13,966,191,963,741,022,000,000,000,000,000,000,000
40
I#226 - CVE-2020-14928: Response Injection via STARTTLS in SMTP and POP3 Closes https://gitlab.gnome.org/GNOME/evolution-data-server/-/issues/226
int setup_tests(void) { #ifndef OPENSSL_NO_DEPRECATED_3_0 ADD_TEST(test_long); #endif ADD_TEST(test_int32); ADD_TEST(test_uint32); ADD_TEST(test_int64); ADD_TEST(test_uint64); ADD_TEST(test_invalid_template); return 1; }
0
[ "CWE-476" ]
openssl
22b88fc9c0e22545401c0b34d24843883ea73fec
295,804,694,544,330,820,000,000,000,000,000,000,000
12
Add a test for encoding/decoding using an invalid ASN.1 Template If you have a CHOICE type that it must use explicit tagging - otherwise the template is invalid. We add tests for this. Reviewed-by: Tomas Mraz <tmraz@fedoraproject.org>
int g_dhcp_server_set_ip_range(GDHCPServer *dhcp_server, const char *start_ip, const char *end_ip) { struct in_addr _host_addr; if (inet_aton(start_ip, &_host_addr) == 0) return -ENXIO; dhcp_server->start_ip = ntohl(_host_addr.s_addr); if (inet_aton(end_ip, &_host_addr) == 0) return -ENXIO; dhcp_server->...
0
[]
connman
58d397ba74873384aee449690a9070bacd5676fa
263,309,956,580,778,640,000,000,000,000,000,000,000
17
gdhcp: Avoid reading invalid data in dhcp_get_option
PackLinuxElf32armLe::buildLoader(Filter const *ft) { if (Elf32_Ehdr::ELFOSABI_LINUX==ei_osabi) { if (0!=xct_off) { // shared library buildLinuxLoader( stub_arm_v5t_linux_shlib_init, sizeof(stub_arm_v5t_linux_shlib_init), NULL, 0, ...
0
[ "CWE-476" ]
upx
ef336dbcc6dc8344482f8cf6c909ae96c3286317
257,767,302,365,570,370,000,000,000,000,000,000,000
20
Protect against bad crafted input. https://github.com/upx/upx/issues/128 modified: p_lx_elf.cpp
static void perf_pmu_sched_task(struct task_struct *prev, struct task_struct *next, bool sched_in) { struct perf_cpu_context *cpuctx; struct pmu *pmu; unsigned long flags; if (prev == next) return; local_irq_save(flags); rcu_read_lock(); list_for_each_entry_rcu(pmu, &pmus, entry) { if (pmu->sched...
0
[ "CWE-416", "CWE-362" ]
linux
12ca6ad2e3a896256f086497a7c7406a547ee373
234,248,958,097,106,800,000,000,000,000,000,000,000
35
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...
GF_Err mvcg_box_write(GF_Box *s, GF_BitStream *bs) { GF_Err e; u32 i; GF_MultiviewGroupBox *ptr = (GF_MultiviewGroupBox *) s; e = gf_isom_full_box_write(s, bs); if (e) return e; gf_bs_write_u32(bs, ptr->multiview_group_id); gf_bs_write_u16(bs, ptr->num_entries); gf_bs_write_u8(bs, 0); for (i=0; i<ptr->num_e...
0
[ "CWE-787" ]
gpac
77510778516803b7f7402d7423c6d6bef50254c3
197,138,767,630,814,540,000,000,000,000,000,000,000
36
fixed #2255
xmlSchemaAddIDC(xmlSchemaParserCtxtPtr ctxt, xmlSchemaPtr schema, const xmlChar *name, const xmlChar *nsName, int category, xmlNodePtr node) { xmlSchemaIDCPtr ret = NULL; if ((ctxt == NULL) || (schema == NULL) || (name == NULL)) return (NULL); ret = (xmlSchemaIDCPtr) xmlMallo...
0
[ "CWE-134" ]
libxml2
4472c3a5a5b516aaf59b89be602fbce52756c3e9
140,213,651,259,859,240,000,000,000,000,000,000,000
30
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.
dtls1_reassemble_fragment(SSL *s, struct hm_header_st* msg_hdr, int *ok) { hm_fragment *frag = NULL; pitem *item = NULL; int i = -1, is_complete; unsigned char seq64be[8]; unsigned long frag_len = msg_hdr->frag_len; if ((msg_hdr->frag_off+frag_len) > msg_hdr->msg_len || msg_hdr->msg_len > dtls1_max_handsha...
1
[ "CWE-399" ]
openssl
d0a4b7d1a2948fce38515b8d862f43e7ba0ebf74
314,404,160,826,741,400,000,000,000,000,000,000,000
99
Fix memory leak from zero-length DTLS fragments. The |pqueue_insert| function can fail if one attempts to insert a duplicate sequence number. When handling a fragment of an out of sequence message, |dtls1_process_out_of_seq_message| would not call |dtls1_reassemble_fragment| if the fragment's length was zero. It would...
static void SFDEnc85EndEnc(struct enc85 *enc) { int i; int ch2, ch3, ch4, ch5; unsigned val; if ( enc->pos==0 ) return; for ( i=enc->pos; i<4; ++i ) enc->sofar[i] = 0; val = (enc->sofar[0]<<24)|(enc->sofar[1]<<16)|(enc->sofar[2]<<8)|enc->sofar[3]; if ( val==0 ) { fputc('z',enc->sfd); }...
0
[ "CWE-416" ]
fontforge
048a91e2682c1a8936ae34dbc7bd70291ec05410
174,090,887,400,294,620,000,000,000,000,000,000,000
28
Fix for #4084 Use-after-free (heap) in the SFD_GetFontMetaData() function Fix for #4086 NULL pointer dereference in the SFDGetSpiros() function Fix for #4088 NULL pointer dereference in the SFD_AssignLookups() function Add empty sf->fontname string if it isn't set, fixing #4089 #4090 and many other potential issues (...
static struct avl_table *create_t1_glyph_tree(char **glyph_names) { int i; void **aa; static struct avl_table *gl_tree; gl_tree = avl_create(comp_t1_glyphs, NULL, &avl_xallocator); for (i = 0; i < 256; i++) { if (glyph_names[i] != notdef && (char **) avl_find(gl_tree, &glyph_name...
0
[ "CWE-119" ]
texlive-source
6ed0077520e2b0da1fd060c7f88db7b2e6068e4c
66,882,191,735,677,490,000,000,000,000,000,000,000
18
writet1 protection against buffer overflow git-svn-id: svn://tug.org/texlive/trunk/Build/source@48697 c570f23f-e606-0410-a88d-b1316a301751
static int irda_data_indication(void *instance, void *sap, struct sk_buff *skb) { struct irda_sock *self; struct sock *sk; int err; self = instance; sk = instance; err = sock_queue_rcv_skb(sk, skb); if (err) { pr_debug("%s(), error: no more mem!\n", __func__); self->rx_flow = FLOW_STOP; /* When we retur...
0
[]
net
79462ad02e861803b3840cc782248c7359451cd9
224,597,438,237,010,000,000,000,000,000,000,000,000
20
net: add validation for the socket syscall protocol argument 郭永刚 reported that one could simply crash the kernel as root by using a simple program: int socket_fd; struct sockaddr_in addr; addr.sin_port = 0; addr.sin_addr.s_addr = INADDR_ANY; addr.sin_family = 10; socket_fd = socket(10,3,0x40000000); connect(s...
ofputil_encode_ofp10_phy_port(const struct ofputil_phy_port *pp, struct ofp10_phy_port *opp) { memset(opp, 0, sizeof *opp); opp->port_no = htons(ofp_to_u16(pp->port_no)); opp->hw_addr = pp->hw_addr; ovs_strlcpy_arrays(opp->name, pp->name); opp->config = htonl(pp->conf...
0
[ "CWE-772" ]
ovs
77ad4225d125030420d897c873e4734ac708c66b
261,945,599,981,053,230,000,000,000,000,000,000,000
17
ofp-util: Fix memory leaks on error cases in ofputil_decode_group_mod(). Found by libFuzzer. Reported-by: Bhargava Shastry <bshastry@sec.t-labs.tu-berlin.de> Signed-off-by: Ben Pfaff <blp@ovn.org> Acked-by: Justin Pettit <jpettit@ovn.org>
sctp_disposition_t sctp_sf_do_9_2_shutdown_ack( const struct sctp_endpoint *ep, const struct sctp_association *asoc, const sctp_subtype_t type, void *arg, sctp_cmd_seq_t *commands) { struct sctp_chunk *chunk = (struct sctp_chunk *) arg; struct sctp_chunk *reply; /* There are 2 ways of getting here: * 1) c...
0
[ "CWE-20" ]
linux-2.6
ba0166708ef4da7eeb61dd92bbba4d5a749d6561
85,376,089,343,855,600,000,000,000,000,000,000,000
65
sctp: Fix kernel panic while process protocol violation parameter Since call to function sctp_sf_abort_violation() need paramter 'arg' with 'struct sctp_chunk' type, it will read the chunk type and chunk length from the chunk_hdr member of chunk. But call to sctp_sf_violation_paramlen() always with 'struct sctp_paramh...
*/ static int xmlXPathCompOpEval(xmlXPathParserContextPtr ctxt, xmlXPathStepOpPtr op) { int total = 0; int equal, ret; xmlXPathCompExprPtr comp; xmlXPathObjectPtr arg1, arg2; xmlNodePtr bak; xmlDocPtr bakd; int pp; int cs; CHECK_ERROR0; comp = ctxt->comp; switch (op->op) { ...
0
[ "CWE-416" ]
libxml2
9ab01a277d71f54d3143c2cf333c5c2e9aaedd9e
53,474,107,823,882,560,000,000,000,000,000,000,000
891
Fix XPointer paths beginning with range-to The old code would invoke the broken xmlXPtrRangeToFunction. range-to isn't really a function but a special kind of location step. Remove this function and always handle range-to in the XPath code. The old xmlXPtrRangeToFunction could also be abused to trigger a use-after-fr...
static const char* tunnel_response_fields_present_to_string(UINT16 fieldsPresent) { return fields_present_to_string(fieldsPresent, tunnel_response_fields_present, ARRAYSIZE(tunnel_response_fields_present)); }
0
[ "CWE-125" ]
FreeRDP
6b485b146a1b9d6ce72dfd7b5f36456c166e7a16
226,299,452,101,406,600,000,000,000,000,000,000,000
5
Fixed oob read in irp_write and similar
_equalFieldSelect(const FieldSelect *a, const FieldSelect *b) { COMPARE_NODE_FIELD(arg); COMPARE_SCALAR_FIELD(fieldnum); COMPARE_SCALAR_FIELD(resulttype); COMPARE_SCALAR_FIELD(resulttypmod); COMPARE_SCALAR_FIELD(resultcollid); return true; }
0
[ "CWE-362" ]
postgres
5f173040e324f6c2eebb90d86cf1b0cdb5890f0a
218,702,629,642,343,480,000,000,000,000,000,000,000
10
Avoid repeated name lookups during table and index DDL. If the name lookups come to different conclusions due to concurrent activity, we might perform some parts of the DDL on a different table than other parts. At least in the case of CREATE INDEX, this can be used to cause the permissions checks to be performed aga...
void ComputeAsync(OpKernelContext* context, DoneCallback done) override { // The shape of 'grads' is [num_boxes, crop_height, crop_width, depth]. const Tensor& grads = context->input(0); // The shape of 'boxes' is [num_boxes, 4]. const Tensor& boxes = context->input(1); // The shape of 'box_index'...
0
[ "CWE-190" ]
tensorflow
7c1692bd417eb4f9b33ead749a41166d6080af85
218,931,951,117,130,200,000,000,000,000,000,000,000
85
PR #51732: Fix crash of tf.image.crop_and_resize when input is large number Imported from GitHub PR https://github.com/tensorflow/tensorflow/pull/51732 This PR is part of the effort in #46890 where tf.image.crop_and_resize will crash if shape consists of large number. Signed-off-by: Yong Tang <yong.tang.github@outlo...
static inline int cpu_has_virtual_nmis(void) { return vmcs_config.pin_based_exec_ctrl & PIN_BASED_VIRTUAL_NMIS; }
0
[ "CWE-20" ]
linux-2.6
16175a796d061833aacfbd9672235f2d2725df65
252,516,853,242,559,000,000,000,000,000,000,000,000
4
KVM: VMX: Don't allow uninhibited access to EFER on i386 vmx_set_msr() does not allow i386 guests to touch EFER, but they can still do so through the default: label in the switch. If they set EFER_LME, they can oops the host. Fix by having EFER access through the normal channel (which will check for EFER_LME) even o...
is_binary_field(MYSQL_FIELD *field) { if ((field->charsetnr == 63) && (field->type == MYSQL_TYPE_BIT || field->type == MYSQL_TYPE_BLOB || field->type == MYSQL_TYPE_LONG_BLOB || field->type == MYSQL_TYPE_MEDIUM_BLOB || field->type == MYSQL_TYPE_TINY_BLOB || field->type == MYSQL_...
0
[]
mysql-server
20addb05e58fdf822896f490fcaaf2ec5ed4bcb5
88,107,126,317,623,050,000,000,000,000,000,000,000
15
Bug# 25998635: Client does not escape the USE statement When there are quotes in the USE statement, the mysql client does not correctly escape them. The USE statement is processed line by line from the client's parser, and cannot handle multi-line commands as the server. The fix is to escape the USE parameters whene...
**/ double mean() const { double res = 0; cimg_for(*this,ptrs,T) res+=(double)*ptrs; return res/size();
0
[ "CWE-125" ]
CImg
10af1e8c1ad2a58a0a3342a856bae63e8f257abb
113,386,852,213,455,430,000,000,000,000,000,000,000
5
Fix other issues in 'CImg<T>::load_bmp()'.
int ssl3_write_pending(SSL *s, int type, const unsigned char *buf, unsigned int len) { int i; /* XXXX */ if ((s->s3->wpend_tot > (int)len) || ((s->s3->wpend_buf != buf) && !(s->mode & SSL_MODE_ACCEPT_MOVING_WRITE_BUFFER)) || (s->s3->wpend_type != type)) { SSLerr(SSL_F_SSL3_WRITE_PENDING,SSL_R_BAD_WRITE_...
0
[ "CWE-310" ]
openssl
270881316664396326c461ec7a124aec2c6cc081
201,081,089,823,829,700,000,000,000,000,000,000,000
49
Add and use a constant-time memcmp. This change adds CRYPTO_memcmp, which compares two vectors of bytes in an amount of time that's independent of their contents. It also changes several MAC compares in the code to use this over the standard memcmp, which may leak information about the size of a matching prefix. (cher...
nl80211_parse_sched_scan_per_band_rssi(struct wiphy *wiphy, struct cfg80211_match_set *match_sets, struct nlattr *tb_band_rssi, s32 rssi_thold) { struct nlattr *attr; int i, tmp, ret = 0; if (!wiphy_ext_feature_isset(wiphy, NL80211_EXT_FEATURE_SCHED_SCAN_BAND_SPECIFIC_RSSI_THO...
0
[ "CWE-120" ]
linux
f88eb7c0d002a67ef31aeb7850b42ff69abc46dc
18,796,895,577,777,006,000,000,000,000,000,000,000
33
nl80211: validate beacon head We currently don't validate the beacon head, i.e. the header, fixed part and elements that are to go in front of the TIM element. This means that the variable elements there can be malformed, e.g. have a length exceeding the buffer size, but most downstream code from this assumes that thi...
static void peek_char(compiler_common *common, sljit_u32 max) { /* Reads the character into TMP1, keeps STR_PTR. Does not check STR_END. TMP2 Destroyed. */ DEFINE_COMPILER; #if defined SUPPORT_UNICODE && PCRE2_CODE_UNIT_WIDTH != 32 struct sljit_jump *jump; #endif SLJIT_UNUSED_ARG(max); OP1(MOV_UCHAR, TMP1, 0, SLJIT_M...
0
[ "CWE-125" ]
php-src
8947fd9e9fdce87cd6c59817b1db58e789538fe9
243,892,781,384,505,670,000,000,000,000,000,000,000
42
Fix #78338: Array cross-border reading in PCRE We backport r1092 from pcre2.
GF_Err gf_isom_get_visual_info(GF_ISOFile *movie, u32 trackNumber, u32 StreamDescriptionIndex, u32 *Width, u32 *Height) { GF_TrackBox *trak; GF_SampleEntryBox *entry; GF_SampleDescriptionBox *stsd; trak = gf_isom_get_track_from_file(movie, trackNumber); if (!trak) return GF_BAD_PARAM; stsd = trak->Media->inform...
0
[ "CWE-787" ]
gpac
f0a41d178a2dc5ac185506d9fa0b0a58356b16f7
191,062,801,999,847,680,000,000,000,000,000,000,000
29
fixed #2120
static void vhost_vq_free_iovecs(struct vhost_virtqueue *vq) { kfree(vq->indirect); vq->indirect = NULL; kfree(vq->log); vq->log = NULL; kfree(vq->heads); vq->heads = NULL; }
0
[ "CWE-399" ]
linux
7932c0bd7740f4cd2aa168d3ce0199e7af7d72d5
227,815,551,803,732,360,000,000,000,000,000,000,000
9
vhost: actually track log eventfd file While reviewing vhost log code, I found out that log_file is never set. Note: I haven't tested the change (QEMU doesn't use LOG_FD yet). Cc: stable@vger.kernel.org Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
R_API void r_anal_function_vars_cache_init(RAnal *anal, RAnalFcnVarsCache *cache, RAnalFunction *fcn) { cache->bvars = r_anal_var_list (anal, fcn, R_ANAL_VAR_KIND_BPV); cache->rvars = r_anal_var_list (anal, fcn, R_ANAL_VAR_KIND_REG); cache->svars = r_anal_var_list (anal, fcn, R_ANAL_VAR_KIND_SPV); r_list_sort (cach...
0
[ "CWE-416" ]
radare2
a7ce29647fcb38386d7439696375e16e093d6acb
111,640,843,145,557,440,000,000,000,000,000,000,000
13
Fix UAF in aaaa on arm/thumb switching ##crash * Reported by @peacock-doris via huntr.dev * Reproducer tests_65185 * This is a logic fix, but not the fully safe as changes in the code can result on UAF again, to properly protect r2 from crashing we need to break the ABI and add refcounting to RRegItem, which can't...
void gf_sg_reset(GF_SceneGraph *sg) { GF_SceneGraph *par; GF_List *gc; #ifndef GPAC_DISABLE_SVG u32 type; #endif u32 count; NodeIDedItem *reg_node; if (!sg) return; GF_LOG(GF_LOG_DEBUG, GF_LOG_SCENE, ("[SceneGraph] resetting scene graph\n")); #if 0 /*inline graph, remove any of this graph nodes from the parent...
1
[ "CWE-416" ]
gpac
9723dd0955894f2cb7be13b94cf7a47f2754b893
18,199,121,782,358,878,000,000,000,000,000,000,000
218
fixed #2109
int is_unix(char *socket_name, int len) { return !memchr(socket_name, ':', len); }
0
[ "CWE-119", "CWE-703", "CWE-787" ]
uwsgi
cb4636f7c0af2e97a4eef7a3cdcbd85a71247bfe
5,963,912,959,660,833,000,000,000,000,000,000,000
3
improve uwsgi_expand_path() to sanitize input, avoiding stack corruption and potential security issue
do_async_page_fault(struct pt_regs *regs, unsigned long error_code) { enum ctx_state prev_state; switch (kvm_read_and_reset_pf_reason()) { default: trace_do_page_fault(regs, error_code); break; case KVM_PV_REASON_PAGE_NOT_PRESENT: /* page is swapped out by the host. */ prev_state = exception_enter(); exi...
0
[]
kvm
29fa6825463c97e5157284db80107d1bfac5d77b
134,908,054,858,830,050,000,000,000,000,000,000,000
23
x86, kvm: Clear paravirt_enabled on KVM guests for espfix32's benefit paravirt_enabled has the following effects: - Disables the F00F bug workaround warning. There is no F00F bug workaround any more because Linux's standard IDT handling already works around the F00F bug, but the warning still exists. This ...
void f2fs_wait_on_page_writeback(struct page *page, enum page_type type, bool ordered) { if (PageWriteback(page)) { struct f2fs_sb_info *sbi = F2FS_P_SB(page); f2fs_submit_merged_write_cond(sbi, page->mapping->host, 0, page->index, type); if (ordered) wait_on_page_writeback(page); else wait_fo...
0
[ "CWE-20" ]
linux
638164a2718f337ea224b747cf5977ef143166a4
216,296,598,412,607,950,000,000,000,000,000,000,000
14
f2fs: fix potential panic during fstrim As Ju Hyung Park reported: "When 'fstrim' is called for manual trim, a BUG() can be triggered randomly with this patch. I'm seeing this issue on both x86 Desktop and arm64 Android phone. On x86 Desktop, this was caused during Ubuntu boot-up. I have a cronjob installed which c...
void usb_enable_interface(struct usb_device *dev, struct usb_interface *intf, bool reset_eps) { struct usb_host_interface *alt = intf->cur_altsetting; int i; for (i = 0; i < alt->desc.bNumEndpoints; ++i) usb_enable_endpoint(dev, &alt->endpoint[i], reset_eps); }
0
[ "CWE-119", "CWE-787" ]
linux
2e1c42391ff2556387b3cb6308b24f6f65619feb
6,992,004,842,074,508,000,000,000,000,000,000,000
9
USB: core: harden cdc_parse_cdc_header Andrey Konovalov reported a possible out-of-bounds problem for the cdc_parse_cdc_header function. He writes: It looks like cdc_parse_cdc_header() doesn't validate buflen before accessing buffer[1], buffer[2] and so on. The only check present is while (buflen > 0). So fix thi...
static int nl80211_pre_doit(const struct genl_ops *ops, struct sk_buff *skb, struct genl_info *info) { struct cfg80211_registered_device *rdev; struct wireless_dev *wdev; struct net_device *dev; bool rtnl = ops->internal_flags & NL80211_FLAG_NEED_RTNL; if (rtnl) rtnl_lock(); if (ops->internal_flags & N...
0
[ "CWE-120" ]
linux
f88eb7c0d002a67ef31aeb7850b42ff69abc46dc
288,091,925,238,362,800,000,000,000,000,000,000,000
61
nl80211: validate beacon head We currently don't validate the beacon head, i.e. the header, fixed part and elements that are to go in front of the TIM element. This means that the variable elements there can be malformed, e.g. have a length exceeding the buffer size, but most downstream code from this assumes that thi...
PJ_DEF(pjmedia_sdp_attr*) pjmedia_sdp_attr_create_ssrc( pj_pool_t *pool, pj_uint32_t ssrc, const pj_str_t *cname) { pjmedia_sdp_attr *attr; if (cname->slen == 0) return NULL; attr = PJ_POOL_ALLOC_T(pool, pjmedia_sdp_attr); attr->name = pj_str("ssrc"); attr->value.ptr = (char*...
0
[ "CWE-121", "CWE-120", "CWE-787" ]
pjproject
560a1346f87aabe126509bb24930106dea292b00
304,140,270,879,261,520,000,000,000,000,000,000,000
20
Merge pull request from GHSA-f5qg-pqcg-765m
int ByteStride(const BufferView &bufferViewObject) const { if (bufferViewObject.byteStride == 0) { // Assume data is tightly packed. int componentSizeInBytes = GetComponentSizeInBytes(static_cast<uint32_t>(componentType)); if (componentSizeInBytes <= 0) { return -1; } ...
0
[ "CWE-20" ]
tinygltf
52ff00a38447f06a17eab1caa2cf0730a119c751
152,839,328,982,391,150,000,000,000,000,000,000,000
32
Do not expand file path since its not necessary for glTF asset path(URI) and for security reason(`wordexp`).
generate_code(mrb_state *mrb, parser_state *p, int val) { codegen_scope *scope = scope_new(mrb, 0, 0); struct mrb_jmpbuf *prev_jmp = mrb->jmp; struct mrb_jmpbuf jmpbuf; struct RProc *proc; mrb->jmp = &jmpbuf; scope->mrb = mrb; scope->parser = p; scope->filename_sym = p->filename_sym; scope->filename...
0
[ "CWE-415", "CWE-122" ]
mruby
38b164ace7d6ae1c367883a3d67d7f559783faad
71,532,365,924,202,240,000,000,000,000,000,000,000
35
codegen.c: fix a bug in `gen_values()`. - Fix limit handling that fails 15 arguments method calls. - Fix too early argument packing in arrays.
static int nested_io_open(AVFormatContext *s, AVIOContext **pb, const char *url, int flags, AVDictionary **opts) { av_log(s, AV_LOG_ERROR, "A HLS playlist item '%s' referred to an external file '%s'. " "Opening this file was forbidden for security reasons\n", ...
0
[ "CWE-703", "CWE-835" ]
FFmpeg
7ec414892ddcad88313848494b6fc5f437c9ca4a
62,258,420,986,559,030,000,000,000,000,000,000,000
9
avformat/hls: Fix DoS due to infinite loop Fixes: loop.m3u The default max iteration count of 1000 is arbitrary and ideas for a better solution are welcome Found-by: Xiaohei and Wangchu from Alibaba Security Team Previous version reviewed-by: Steven Liu <lingjiujianke@gmail.com> Signed-off-by: Michael Niedermayer <...
ews_backend_dispose (GObject *object) { EEwsBackendPrivate *priv; ESource *source; priv = E_EWS_BACKEND_GET_PRIVATE (object); source = e_backend_get_source (E_BACKEND (object)); if (source && priv->source_changed_id) { g_signal_handler_disconnect (source, priv->source_changed_id); priv->source_changed_id = 0...
0
[ "CWE-295" ]
evolution-ews
915226eca9454b8b3e5adb6f2fff9698451778de
318,586,620,581,680,360,000,000,000,000,000,000,000
22
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
brcmf_cfg80211_cancel_remain_on_channel(struct wiphy *wiphy, struct wireless_dev *wdev, u64 cookie) { struct brcmf_cfg80211_info *cfg = wiphy_to_cfg(wiphy); struct brcmf_cfg80211_vif *vif; int err = 0; brcmf_dbg(TRACE, "Enter p2p listen cancel\n"); vif = cfg->p2p.bss_idx[P2PAPI_BSSCFG_DEVICE].vif; if ...
0
[ "CWE-787" ]
linux
1b5e2423164b3670e8bc9174e4762d297990deff
273,360,003,186,119,630,000,000,000,000,000,000,000
20
brcmfmac: assure SSID length from firmware is limited The SSID length as received from firmware should not exceed IEEE80211_MAX_SSID_LEN as that would result in heap overflow. Reviewed-by: Hante Meuleman <hante.meuleman@broadcom.com> Reviewed-by: Pieter-Paul Giesberts <pieter-paul.giesberts@broadcom.com> Reviewed-by:...
comics_document_get_page_size (EvDocument *document, EvPage *page, double *width, double *height) { GdkPixbufLoader *loader; char **argv; guchar buf[1024]; gboolean success, got_size = FALSE; gint outpipe = -1; GPid child_pid; gssize bytes; GdkPixbuf *pixbuf; gchar *fi...
0
[]
atril
f4291fd62f7dfe6460d2406a979ccfac0c68dd59
42,093,752,426,338,560,000,000,000,000,000,000,000
67
comics: make the files containing "--checkpoint-action=" unsupported Fixes #257
static ssize_t ib_ucm_send_apr(struct ib_ucm_file *file, const char __user *inbuf, int in_len, int out_len) { return ib_ucm_send_info(file, inbuf, in_len, (void *)ib_send_cm_apr); }
0
[ "CWE-284", "CWE-264" ]
linux
e6bd18f57aad1a2d1ef40e646d03ed0f2515c9e3
246,801,150,825,734,180,000,000,000,000,000,000,000
6
IB/security: Restrict use of the write() interface The drivers/infiniband stack uses write() as a replacement for bi-directional ioctl(). This is not safe. There are ways to trigger write calls that result in the return structure that is normally written to user space being shunted off to user specified kernel memory...
static int cap_sb_set_mnt_opts(struct super_block *sb, struct security_mnt_opts *opts) { if (unlikely(opts->num_mnt_opts)) return -EOPNOTSUPP; return 0; }
0
[]
linux-2.6
ee18d64c1f632043a02e6f5ba5e045bb26a5465f
205,488,163,376,898,200,000,000,000,000,000,000,000
7
KEYS: Add a keyctl to install a process's session keyring on its parent [try #6] Add a keyctl to install a process's session keyring onto its parent. This replaces the parent's session keyring. Because the COW credential code does not permit one process to change another process's credentials directly, the change is...
PJ_DEF(pj_status_t) pj_stun_msg_add_empty_attr( pj_pool_t *pool, pj_stun_msg *msg, int attr_type) { pj_stun_empty_attr *attr = NULL; pj_status_t status; status = pj_stun_empty_attr_create(pool, attr_type, &attr); if (status != PJ_SUCCESS) return status; return pj_stun_msg_add_attr(msg...
0
[ "CWE-191" ]
pjproject
15663e3f37091069b8c98a7fce680dc04bc8e865
13,061,607,663,131,128,000,000,000,000,000,000,000
13
Merge pull request from GHSA-2qpg-f6wf-w984