func
string
target
int64
cwe
list
project
string
commit_id
string
hash
float64
size
int64
message
string
int fsl_hv_failover_register(struct notifier_block *nb) { return blocking_notifier_chain_register(&failover_subscribers, nb); }
0
[ "CWE-190" ]
linux
6a024330650e24556b8a18cc654ad00cfecf6c6c
202,970,264,211,083,070,000,000,000,000,000,000,000
4
drivers/virt/fsl_hypervisor.c: prevent integer overflow in ioctl The "param.count" value is a u64 thatcomes from the user. The code later in the function assumes that param.count is at least one and if it's not then it leads to an Oops when we dereference the ZERO_SIZE_PTR. Also the addition can have an integer over...
const OID& oid() const { return m_oid; }
0
[ "CWE-200" ]
botan
48fc8df51d99f9d8ba251219367b3d629cc848e3
147,375,276,009,165,850,000,000,000,000,000,000,000
1
Address DSA/ECDSA side channel
int __fastcall TCustomDialog::GetMaxControlWidth(TControl * Control) { return GetDefaultParent()->ClientWidth - Control->Left - FHorizontalMargin; }
0
[ "CWE-787" ]
winscp
faa96e8144e6925a380f94a97aa382c9427f688d
10,155,012,967,156,151,000,000,000,000,000,000,000
4
Bug 1943: Prevent loading session settings that can lead to remote code execution from handled URLs https://winscp.net/tracker/1943 (cherry picked from commit ec584f5189a856cd79509f754722a6898045c5e0) Source commit: 0f4be408b3f01132b00682da72d925d6c4ee649b
static void device_link_wait_for_optional_supplier(struct device *consumer) { device_link_wait_for_supplier(consumer, false); }
0
[ "CWE-787" ]
linux
aa838896d87af561a33ecefea1caa4c15a68bc47
122,011,392,988,798,370,000,000,000,000,000,000,000
4
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...
UnpicklerMemoProxy_clear(UnpicklerMemoProxyObject *self) { Py_CLEAR(self->unpickler); return 0; }
0
[ "CWE-190", "CWE-369" ]
cpython
a4ae828ee416a66d8c7bf5ee71d653c2cc6a26dd
324,150,686,461,396,350,000,000,000,000,000,000,000
5
closes bpo-34656: Avoid relying on signed overflow in _pickle memos. (GH-9261)
apr_status_t modsecurity_request_body_retrieve_start(modsec_rec *msr, char **error_msg) { *error_msg = NULL; if (msr->msc_reqbody_storage == MSC_REQBODY_MEMORY) { msr->msc_reqbody_chunk_position = 0; msr->msc_reqbody_chunk_offset = 0; msr->msc_reqbody_disk_chunk = apr_pcalloc(msr->msc_...
0
[ "CWE-476" ]
ModSecurity
0840b13612a0b7ef1ce7441cf811dcfc6b463fba
109,414,669,055,635,860,000,000,000,000,000,000,000
42
Fixed: chuck null pointer when unknown CT is sent and over in-memory limit
int ioat_probe(struct ioatdma_device *device) { int err = -ENODEV; struct dma_device *dma = &device->common; struct pci_dev *pdev = device->pdev; struct device *dev = &pdev->dev; /* DMA coherent memory pool for DMA descriptor allocations */ device->dma_pool = pci_pool_create("dma_desc_pool", pdev, sizeof...
0
[]
linux
7bced397510ab569d31de4c70b39e13355046387
92,931,967,521,351,400,000,000,000,000,000,000,000
54
net_dma: simple removal Per commit "77873803363c net_dma: mark broken" net_dma is no longer used and there is no plan to fix it. This is the mechanical removal of bits in CONFIG_NET_DMA ifdef guards. Reverting the remainder of the net_dma induced changes is deferred to subsequent patches. Marked for stable due to Ro...
TEST_F(QueryPlannerTest, EmptyQueryWithProjectionUsesCoveredIxscanOnDotttedNonMultikeyIndexIfEnabled) { params.options = QueryPlannerParams::GENERATE_COVERED_IXSCANS; addIndex(BSON("a.b" << 1)); runQueryAsCommand(fromjson("{find: 'testns', projection: {_id: 0, 'a.b': 1}}")); assertNumSolutions(1)...
0
[]
mongo
ee97c0699fd55b498310996ee002328e533681a3
219,074,790,107,576,100,000,000,000,000,000,000,000
11
SERVER-36993 Fix crash due to incorrect $or pushdown for indexed $expr.
static int flashsv2_prime(FlashSVContext *s, uint8_t *src, int size) { z_stream zs; int zret; // Zlib return code if (!src) return AVERROR_INVALIDDATA; zs.zalloc = NULL; zs.zfree = NULL; zs.opaque = NULL; s->zstream.next_in = src; s->zstream.avail_in = size; s->zstream...
0
[ "CWE-20" ]
FFmpeg
880c73cd76109697447fbfbaa8e5ee5683309446
294,634,282,354,228,800,000,000,000,000,000,000,000
40
avcodec/flashsv: check diff_start/height Fixes out of array accesses Fixes Ticket2844 Found-by: ami_stuff Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
static void process_smi_save_state_64(struct kvm_vcpu *vcpu, char *buf) { #ifdef CONFIG_X86_64 struct desc_ptr dt; struct kvm_segment seg; unsigned long val; int i; for (i = 0; i < 16; i++) put_smstate(u64, buf, 0x7ff8 - i * 8, kvm_register_read(vcpu, i)); put_smstate(u64, buf, 0x7f78, kvm_rip_read(vcpu)); p...
0
[ "CWE-369" ]
linux
0185604c2d82c560dab2f2933a18f797e74ab5a8
313,404,806,904,383,250,000,000,000,000,000,000,000
56
KVM: x86: Reload pit counters for all channels when restoring state Currently if userspace restores the pit counters with a count of 0 on channels 1 or 2 and the guest attempts to read the count on those channels, then KVM will perform a mod of 0 and crash. This will ensure that 0 values are converted to 65536 as per...
nv_brace(cmdarg_T *cap) { cap->oap->motion_type = MCHAR; cap->oap->use_reg_one = TRUE; // The motion used to be inclusive for "(", but that is not what Vi does. cap->oap->inclusive = FALSE; curwin->w_set_curswant = TRUE; if (findsent(cap->arg, cap->count1) == FAIL) clearopbeep(cap->oap); e...
0
[ "CWE-416" ]
vim
35a9a00afcb20897d462a766793ff45534810dc3
266,214,511,686,872,100,000,000,000,000,000,000,000
21
patch 8.2.3428: using freed memory when replacing Problem: Using freed memory when replacing. (Dhiraj Mishra) Solution: Get the line pointer after calling ins_copychar().
GF_Box *ahdr_box_new() { ISOM_DECL_BOX_ALLOC(GF_AdobeDRMHeaderBox, GF_ISOM_BOX_TYPE_AHDR); tmp->version = 2; tmp->flags = 0; return (GF_Box *)tmp; }
0
[ "CWE-703" ]
gpac
f19668964bf422cf5a63e4dbe1d3c6c75edadcbb
324,010,871,381,260,300,000,000,000,000,000,000,000
7
fixed #1879
void AbstractSqlStorage::connectionDestroyed() { QMutexLocker locker(&_connectionPoolMutex); _connectionPool.remove(sender()->thread()); }
0
[ "CWE-89" ]
quassel
aa1008be162cb27da938cce93ba533f54d228869
297,897,008,859,708,970,000,000,000,000,000,000,000
5
Fixing security vulnerability with Qt 4.8.5+ and PostgreSQL. Properly detects whether Qt performs slash escaping in SQL queries or not, and then configures PostgreSQL accordingly. This bug was a introduced due to a bugfix in Qt 4.8.5 disables slash escaping when binding queries: https://bugreports.qt-project.org/brows...
proto_tree_add_text_node(proto_tree *tree, tvbuff_t *tvb, gint start, gint length) { proto_item *pi; if (tree == NULL) return NULL; pi = proto_tree_add_pi(tree, &hfi_text_only, tvb, start, &length); return pi; }
0
[ "CWE-401" ]
wireshark
a9fc769d7bb4b491efb61c699d57c9f35269d871
241,158,188,127,351,600,000,000,000,000,000,000,000
11
epan: Fix a memory leak. Make sure _proto_tree_add_bits_ret_val allocates a bits array using the packet scope, otherwise we leak memory. Fixes #17032.
lookup_job_for_window (GSManager *manager, GSWindow *window) { GSJob *job; if (manager->priv->jobs == NULL) { return NULL; } job = g_hash_table_lookup (manager->priv->jobs, window); return job; }
0
[]
gnome-screensaver
2f597ea9f1f363277fd4dfc109fa41bbc6225aca
45,533,926,717,287,530,000,000,000,000,000,000,000
13
Fix adding monitors Make sure to show windows that are added. And fix an off by one bug.
xwd_loader_goto_next_frame (G_GNUC_UNUSED XwdLoader *loader) { return FALSE; }
0
[ "CWE-125" ]
chafa
56fabfa18a6880b4cb66047fa6557920078048d9
337,094,979,693,730,600,000,000,000,000,000,000,000
4
XwdLoader: Fix buffer over-read and improve general robustness This commit fixes a buffer over-read that could occur due to g_ntohl() evaluating its argument more than once if at least one of the following is true: * Build target is not x86. * __OPTIMIZE__ is not set during compilation (e.g. -O0 was used). It also i...
static void test_wl6791() { int rc; uint idx; MYSQL *l_mysql; enum mysql_option uint_opts[] = { MYSQL_OPT_CONNECT_TIMEOUT, MYSQL_OPT_READ_TIMEOUT, MYSQL_OPT_WRITE_TIMEOUT, MYSQL_OPT_PROTOCOL, MYSQL_OPT_LOCAL_INFILE }, my_bool_opts[] = { MYSQL_OPT_COMPRESS, MYSQL_OPT_USE_REMOT...
0
[ "CWE-284", "CWE-295" ]
mysql-server
3bd5589e1a5a93f9c224badf983cd65c45215390
210,717,707,335,454,850,000,000,000,000,000,000,000
105
WL#6791 : Redefine client --ssl option to imply enforced encryption # Changed the meaning of the --ssl=1 option of all client binaries to mean force ssl, not try ssl and fail over to eunecrypted # Added a new MYSQL_OPT_SSL_ENFORCE mysql_options() option to specify that an ssl connection is required. # Added a new macr...
static void ide_identify(IDEState *s) { uint16_t *p; unsigned int oldsize; IDEDevice *dev = s->unit ? s->bus->slave : s->bus->master; p = (uint16_t *)s->identify_data; if (s->identify_set) { goto fill_buffer; } memset(p, 0, sizeof(s->identify_data)); put_le16(p + 0, 0x0040); ...
0
[ "CWE-399" ]
qemu
3251bdcf1c67427d964517053c3d185b46e618e8
11,194,689,777,608,047,000,000,000,000,000,000,000
111
ide: Correct handling of malformed/short PRDTs This impacts both BMDMA and AHCI HBA interfaces for IDE. Currently, we confuse the difference between a PRDT having "0 bytes" and a PRDT having "0 complete sectors." When we receive an incomplete sector, inconsistent error checking leads to an infinite loop wherein the c...
bool get_invoking_op_callbacks() const { return GetData()->invoking_op_callbacks; }
0
[ "CWE-20", "CWE-476", "CWE-908" ]
tensorflow
22e07fb204386768e5bcbea563641ea11f96ceb8
26,441,221,613,211,766,000,000,000,000,000,000,000
3
Fix multiple vulnerabilities in `tf.experimental.dlpack.to_dlpack`. We have a use after free caused by memory coruption, a segmentation fault caused by memory corruption, several memory leaks and an undefined behavior when taking the reference of a nullptr. PiperOrigin-RevId: 332568894 Change-Id: Ife0fc05e103b3532509...
static rfbBool rfbDefaultPasswordCheck(rfbClientPtr cl,const char* response,int len) { int i; char *passwd=rfbDecryptPasswdFromFile(cl->screen->authPasswdData); if(!passwd) { rfbErr("Couldn't read password file: %s\n",cl->screen->authPasswdData); return(FALSE); } rfbEncryptBytes(cl->authChallenge, p...
0
[]
libvncserver
804335f9d296440bb708ca844f5d89b58b50b0c6
290,524,856,962,120,670,000,000,000,000,000,000,000
27
Thread safety for zrle, zlib, tight. Proposed tight security type fix for debian bug 517422.
static void reset_bvr(struct kvm_vcpu *vcpu, const struct sys_reg_desc *rd) { vcpu->arch.vcpu_debug_state.dbg_bvr[rd->reg] = rd->val; }
0
[ "CWE-20", "CWE-617" ]
linux
9e3f7a29694049edd728e2400ab57ad7553e5aa9
284,479,931,987,065,300,000,000,000,000,000,000,000
5
arm64: KVM: pmu: Fix AArch32 cycle counter access We're missing the handling code for the cycle counter accessed from a 32bit guest, leading to unexpected results. Cc: stable@vger.kernel.org # 4.6+ Signed-off-by: Wei Huang <wei@redhat.com> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com>
static void qeth_init_func_level(struct qeth_card *card) { switch (card->info.type) { case QETH_CARD_TYPE_IQD: card->info.func_level = QETH_IDX_FUNC_LEVEL_IQD; break; case QETH_CARD_TYPE_OSD: case QETH_CARD_TYPE_OSN: card->info.func_level = QETH_IDX_FUNC_LEVEL_OSD; break; default: break; } }
0
[ "CWE-200", "CWE-119" ]
linux
6fb392b1a63ae36c31f62bc3fc8630b49d602b62
302,691,251,090,046,300,000,000,000,000,000,000,000
14
qeth: avoid buffer overflow in snmp ioctl Check user-defined length in snmp ioctl request and allow request only if it fits into a qeth command buffer. Signed-off-by: Ursula Braun <ursula.braun@de.ibm.com> Signed-off-by: Frank Blaschka <frank.blaschka@de.ibm.com> Reviewed-by: Heiko Carstens <heicars2@linux.vnet.ibm.c...
mrb_bob_not(mrb_state *mrb, mrb_value cv) { return mrb_bool_value(!mrb_test(cv)); }
0
[ "CWE-476", "CWE-415" ]
mruby
faa4eaf6803bd11669bc324b4c34e7162286bfa3
127,611,090,631,306,030,000,000,000,000,000,000,000
4
`mrb_class_real()` did not work for `BasicObject`; fix #4037
void hid_debug_register(struct hid_device *hdev, const char *name) { hdev->debug_dir = debugfs_create_dir(name, hid_debug_root); hdev->debug_rdesc = debugfs_create_file("rdesc", 0400, hdev->debug_dir, hdev, &hid_debug_rdesc_fops); hdev->debug_events = debugfs_create_file("events", 0400, hdev->debug_dir, hdev, ...
0
[ "CWE-835", "CWE-787" ]
linux
717adfdaf14704fd3ec7fa2c04520c0723247eac
83,991,378,445,110,825,000,000,000,000,000,000,000
9
HID: debug: check length before copy_to_user() If our length is greater than the size of the buffer, we overflow the buffer Cc: stable@vger.kernel.org Signed-off-by: Daniel Rosenberg <drosen@google.com> Reviewed-by: Benjamin Tissoires <benjamin.tissoires@redhat.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz>
static int proc_pid_fill_cache(struct file *filp, void *dirent, filldir_t filldir, struct tgid_iter iter) { char name[PROC_NUMBUF]; int len = snprintf(name, sizeof(name), "%d", iter.tgid); return proc_fill_cache(filp, dirent, filldir, name, len, proc_pid_instantiate, iter.task, NULL); }
0
[]
linux
0499680a42141d86417a8fbaa8c8db806bea1201
224,380,617,004,184,380,000,000,000,000,000,000,000
8
procfs: add hidepid= and gid= mount options Add support for mount options to restrict access to /proc/PID/ directories. The default backward-compatible "relaxed" behaviour is left untouched. The first mount option is called "hidepid" and its value defines how much info about processes we want to be available for non...
bool LEX::map_data_type(const Lex_ident_sys_st &schema_name, Lex_field_type_st *type) const { const Schema *schema= schema_name.str ? Schema::find_by_name(schema_name) : Schema::find_implied(thd); if (!schema) { char buf[128]; const N...
0
[ "CWE-703" ]
server
39feab3cd31b5414aa9b428eaba915c251ac34a2
253,335,231,215,914,550,000,000,000,000,000,000,000
26
MDEV-26412 Server crash in Item_field::fix_outer_field for INSERT SELECT IF an INSERT/REPLACE SELECT statement contained an ON expression in the top level select and this expression used a subquery with a column reference that could not be resolved then an attempt to resolve this reference as an outer reference caused...
int ablkcipher_walk_done(struct ablkcipher_request *req, struct ablkcipher_walk *walk, int err) { struct crypto_tfm *tfm = req->base.tfm; unsigned int nbytes = 0; if (likely(err >= 0)) { unsigned int n = walk->nbytes - err; if (likely(!(walk->flags & ABLKCIPHER_WALK_SLOW))) n = ablkcipher_done_fast(walk...
0
[ "CWE-310" ]
linux
9a5467bf7b6e9e02ec9c3da4e23747c05faeaac6
144,929,387,306,518,180,000,000,000,000,000,000,000
39
crypto: user - fix info leaks in report API Three errors resulting in kernel memory disclosure: 1/ The structures used for the netlink based crypto algorithm report API are located on the stack. As snprintf() does not fill the remainder of the buffer with null bytes, those stack bytes will be disclosed to users of th...
int proc_dointvec_userhz_jiffies(struct ctl_table *table, int write, void __user *buffer, size_t *lenp, loff_t *ppos) { return -ENOSYS; }
0
[ "CWE-284", "CWE-264" ]
linux
bfdc0b497faa82a0ba2f9dddcf109231dd519fcc
79,789,514,144,520,310,000,000,000,000,000,000,000
5
sysctl: restrict write access to dmesg_restrict When dmesg_restrict is set to 1 CAP_SYS_ADMIN is needed to read the kernel ring buffer. But a root user without CAP_SYS_ADMIN is able to reset dmesg_restrict to 0. This is an issue when e.g. LXC (Linux Containers) are used and complete user space is running without CA...
void isis_notif_db_overload(const struct isis_area *area, bool overload) { const char *xpath = "/frr-isisd:database-overload"; struct list *arguments = yang_data_list_new(); char xpath_arg[XPATH_MAXLEN]; struct yang_data *data; notif_prep_instance_hdr(xpath, area, "default", arguments); snprintf(xpath_arg, sizeo...
0
[ "CWE-119", "CWE-787" ]
frr
ac3133450de12ba86c051265fc0f1b12bc57b40c
139,083,711,313,355,170,000,000,000,000,000,000,000
14
isisd: fix #10505 using base64 encoding Using base64 instead of the raw string to encode the binary data. Signed-off-by: whichbug <whichbug@github.com>
virDomainVsockDefValidate(const virDomainVsockDef *vsock) { if (vsock->guest_cid > 0 && vsock->guest_cid <= 2) { virReportError(VIR_ERR_XML_ERROR, "%s", _("guest CIDs must be >= 3")); return -1; } return 0; }
0
[ "CWE-212" ]
libvirt
a5b064bf4b17a9884d7d361733737fb614ad8979
130,549,407,453,540,170,000,000,000,000,000,000,000
10
conf: Don't format http cookies unless VIR_DOMAIN_DEF_FORMAT_SECURE is used Starting with 3b076391befc3fe72deb0c244ac6c2b4c100b410 (v6.1.0-122-g3b076391be) we support http cookies. Since they may contain somewhat sensitive information we should not format them into the XML unless VIR_DOMAIN_DEF_FORMAT_SECURE is assert...
void __audit_mq_notify(mqd_t mqdes, const struct sigevent *notification) { struct audit_context *context = current->audit_context; if (notification) context->mq_notify.sigev_signo = notification->sigev_signo; else context->mq_notify.sigev_signo = 0; context->mq_notify.mqdes = mqdes; context->type = AUDIT_MQ_...
0
[ "CWE-362" ]
linux
43761473c254b45883a64441dd0bc85a42f3645c
69,188,802,205,450,420,000,000,000,000,000,000,000
12
audit: fix a double fetch in audit_log_single_execve_arg() There is a double fetch problem in audit_log_single_execve_arg() where we first check the execve(2) argumnets for any "bad" characters which would require hex encoding and then re-fetch the arguments for logging in the audit record[1]. Of course this leaves a...
bash_filename_stat_hook (dirname) char **dirname; { char *local_dirname, *new_dirname, *t; int should_expand_dirname, return_value; int global_nounset; WORD_LIST *wl; struct stat sb; local_dirname = *dirname; should_expand_dirname = return_value = 0; if (t = mbschr (local_dirname, '$')) should...
0
[ "CWE-20" ]
bash
4f747edc625815f449048579f6e65869914dd715
156,541,521,952,757,740,000,000,000,000,000,000,000
75
Bash-4.4 patch 7
static void rtreeCheckMapping( RtreeCheck *pCheck, /* RtreeCheck object */ int bLeaf, /* True for a leaf cell, false for interior */ i64 iKey, /* Key for mapping */ i64 iVal /* Expected value for mapping */ ){ int rc; sqlite3_stmt...
0
[ "CWE-125" ]
sqlite
e41fd72acc7a06ce5a6a7d28154db1ffe8ba37a8
285,620,942,643,468,500,000,000,000,000,000,000,000
39
Enhance the rtreenode() function of rtree (used for testing) so that it uses the newer sqlite3_str object for better performance and improved error reporting. FossilOrigin-Name: 90acdbfce9c088582d5165589f7eac462b00062bbfffacdcc786eb9cf3ea5377
inline bool WireFormatLite::ReadPrimitive<int64_t, WireFormatLite::TYPE_SINT64>( io::CodedInputStream* input, int64_t* value) { uint64_t temp; if (!input->ReadVarint64(&temp)) return false; *value = ZigZagDecode64(temp); return true; }
0
[ "CWE-703" ]
protobuf
d1635e1496f51e0d5653d856211e8821bc47adc4
7,148,803,327,827,283,000,000,000,000,000,000,000
7
Apply patch
PJ_DEF(void) pjsip_auth_create_digest( pj_str_t *result, const pj_str_t *nonce, const pj_str_t *nc, const pj_str_t *cnonce, const pj_str_t *qop, const pj_str_t *uri, const pj_str_t *realm, const pjsip_cred_info *cred_info, const pj_...
1
[ "CWE-120", "CWE-787" ]
pjproject
d27f79da11df7bc8bb56c2f291d71e54df8d2c47
261,272,774,072,878,000,000,000,000,000,000,000,000
86
Use PJ_ASSERT_RETURN() on pjsip_auth_create_digest() and pjsua_init_tpselector() (#3009) * Use PJ_ASSERT_RETURN on pjsip_auth_create_digest * Use PJ_ASSERT_RETURN on pjsua_init_tpselector() * Fix incorrect check. * Add return value to pjsip_auth_create_digest() and pjsip_auth_create_digestSHA256() * Modifi...
u32 parse_u32(char *val, char *log_name) { u32 res; if (sscanf(val, "%u", &res)==1) return res; M4_LOG(GF_LOG_ERROR, ("%s must be an unsigned integer (got %s), using 0\n", log_name, val)); return 0; }
0
[ "CWE-787" ]
gpac
4e56ad72ac1afb4e049a10f2d99e7512d7141f9d
310,885,003,476,190,800,000,000,000,000,000,000,000
7
fixed #2216
http_req_get_intercept_rule(struct proxy *px, struct list *rules, struct session *s, struct http_txn *txn) { struct http_req_rule *rule; struct hdr_ctx ctx; list_for_each_entry(rule, rules, list) { if (rule->action >= HTTP_REQ_ACT_MAX) continue; /* check optional condition */ if (rule->cond) { int ret;...
0
[]
haproxy
aae75e3279c6c9bd136413a72dafdcd4986bb89a
90,830,995,526,002,000,000,000,000,000,000,000,000
66
BUG/CRITICAL: using HTTP information in tcp-request content may crash the process During normal HTTP request processing, request buffers are realigned if there are less than global.maxrewrite bytes available after them, in order to leave enough room for rewriting headers after the request. This is done in http_wait_fo...
do_one_cmd( char_u **cmdlinep, int flags, #ifdef FEAT_EVAL cstack_T *cstack, #endif char_u *(*fgetline)(int, void *, int, getline_opt_T), void *cookie) // argument for fgetline() { char_u *p; linenr_T lnum; long n; char *errormsg = NULL; // error message char_u *after_modifier ...
0
[ "CWE-416" ]
vim
35d21c6830fc2d68aca838424a0e786821c5891c
58,859,021,734,871,250,000,000,000,000,000,000,000
930
patch 9.0.0360: crash when invalid line number on :for is ignored Problem: Crash when invalid line number on :for is ignored. Solution: Do not check breakpoint for non-existing line.
CmdResult HandleLocal(LocalUser* user, const Params& parameters) CXX11_OVERRIDE { if (parameters.empty()) return ShowSilenceList(user); // If neither add nor remove are specified we default to add. bool is_remove = parameters[0][0] == '-'; // If a prefix mask has been given then strip it and clean it up....
0
[ "CWE-416" ]
inspircd
7b47de3c194f239c5fea09a0e49696c9af017d51
335,417,790,935,067,600,000,000,000,000,000,000,000
37
Copy the silence flags when sending update notifications. This fixes a crash bug in the silence module on some versions of GCC.
int nfs_lookup_verify_inode(struct inode *inode, unsigned int flags) { struct nfs_server *server = NFS_SERVER(inode); int ret; if (IS_AUTOMOUNT(inode)) return 0; if (flags & LOOKUP_OPEN) { switch (inode->i_mode & S_IFMT) { case S_IFREG: /* A NFSv4 OPEN will revalidate later */ if (server->caps & NFS_C...
0
[ "CWE-909" ]
linux
ac795161c93699d600db16c1a8cc23a65a1eceaf
289,153,652,868,288,160,000,000,000,000,000,000,000
36
NFSv4: Handle case where the lookup of a directory fails If the application sets the O_DIRECTORY flag, and tries to open a regular file, nfs_atomic_open() will punt to doing a regular lookup. If the server then returns a regular file, we will happily return a file descriptor with uninitialised open state. The fix is ...
static coroutine_fn int qcow2_co_write_zeroes(BlockDriverState *bs, int64_t sector_num, int nb_sectors, BdrvRequestFlags flags) { int ret; BDRVQcowState *s = bs->opaque; /* Emulate misaligned zero writes */ if (sector_num % s->cluster_sectors || nb_sectors % s->cluster_sectors) { return -EN...
0
[ "CWE-476" ]
qemu
11b128f4062dd7f89b14abc8877ff20d41b28be9
103,798,563,730,056,420,000,000,000,000,000,000,000
19
qcow2: Fix NULL dereference in qcow2_open() error path (CVE-2014-0146) The qcow2 code assumes that s->snapshots is non-NULL if s->nb_snapshots != 0. By having the initialisation of both fields separated in qcow2_open(), any error occuring in between would cause the error path to dereference NULL in qcow2_free_snapshot...
slapi_pblock_set_pwdpolicy(Slapi_PBlock *pb, passwdPolicy *pwdpolicy) { #ifdef PBLOCK_ANALYTICS pblock_analytics_record(pb, SLAPI_PWDPOLICY); #endif _pblock_assert_pb_intop(pb); pb->pb_intop->pwdpolicy = pwdpolicy; }
0
[ "CWE-415" ]
389-ds-base
a3c298f8140d3e4fa1bd5a670f1bb965a21a9b7b
265,209,629,133,926,900,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...
void security_mac_data(const BYTE* mac_salt_key, const BYTE* data, UINT32 length, BYTE* output) { CryptoMd5 md5; CryptoSha1 sha1; BYTE length_le[4]; BYTE sha1_digest[CRYPTO_SHA1_DIGEST_LENGTH]; /* MacData = MD5(MacSaltKey + pad2 + SHA1(MacSaltKey + pad1 + length + data)) */ security_UINT32_le(length_le, lengt...
0
[ "CWE-476" ]
FreeRDP
7d58aac24fe20ffaad7bd9b40c9ddf457c1b06e7
224,893,736,852,205,870,000,000,000,000,000,000,000
27
security: add a NULL pointer check to fix a server crash.
Image() : as_is(false) { bufferView = -1; width = -1; height = -1; component = -1; bits = -1; pixel_type = -1; }
0
[ "CWE-20" ]
tinygltf
52ff00a38447f06a17eab1caa2cf0730a119c751
120,314,266,588,348,550,000,000,000,000,000,000,000
8
Do not expand file path since its not necessary for glTF asset path(URI) and for security reason(`wordexp`).
evbuffer_invoke_callbacks_(struct evbuffer *buffer) { if (LIST_EMPTY(&buffer->callbacks)) { buffer->n_add_for_cb = buffer->n_del_for_cb = 0; return; } if (buffer->deferred_cbs) { if (event_deferred_cb_schedule_(buffer->cb_queue, &buffer->deferred)) { evbuffer_incref_and_lock_(buffer); if (buffer->parent...
0
[ "CWE-189" ]
libevent
841ecbd96105c84ac2e7c9594aeadbcc6fb38bc4
53,862,509,065,960,990,000,000,000,000,000,000,000
18
Fix CVE-2014-6272 in Libevent 2.1 For this fix, we need to make sure that passing too-large inputs to the evbuffer functions can't make us do bad things with the heap. Also, lower the maximum chunk size to the lower of off_t, size_t maximum. This is necessary since otherwise we could get into an infinite loop if we ...
static void ipv6_route_check_sernum(struct ipv6_route_iter *iter) { if (iter->sernum != iter->w.root->fn_sernum) { iter->sernum = iter->w.root->fn_sernum; iter->w.state = FWS_INIT; iter->w.node = iter->w.root; WARN_ON(iter->w.skip); iter->w.skip = iter->w.count; } }
0
[ "CWE-755" ]
linux
7b09c2d052db4b4ad0b27b97918b46a7746966fa
140,674,250,363,020,430,000,000,000,000,000,000,000
10
ipv6: fix a typo in fib6_rule_lookup() Yi Ren reported an issue discovered by syzkaller, and bisected to the cited commit. Many thanks to Yi, this trivial patch does not reflect the patient work that has been done. Fixes: d64a1f574a29 ("ipv6: honor RT6_LOOKUP_F_DST_NOREF in rule lookup logic") Signed-off-by: Eric Du...
static ssize_t vfswrap_flistxattr(struct vfs_handle_struct *handle, struct files_struct *fsp, char *list, size_t size) { return flistxattr(fsp->fh->fd, list, size); }
0
[ "CWE-665" ]
samba
30e724cbff1ecd90e5a676831902d1e41ec1b347
5,753,773,939,591,650,000,000,000,000,000,000,000
4
FSCTL_GET_SHADOW_COPY_DATA: Initialize output array to zero Otherwise num_volumes and the end marker can return uninitialized data to the client. Signed-off-by: Christof Schmitt <christof.schmitt@us.ibm.com> Reviewed-by: Jeremy Allison <jra@samba.org> Reviewed-by: Simo Sorce <idra@samba.org>
static pj_bool_t ssock_on_data_sent (pj_ssl_sock_t *ssock, pj_ioqueue_op_key_t *send_key, pj_ssize_t sent) { write_data_t *wdata = (write_data_t*)send_key->user_data; pj_ioqueue_op_key_t *app_key = wdata->app_key; pj_ssize_t sent_len; sent_len = (sent > 0)? wdata->plain_data_len : sen...
0
[ "CWE-362", "CWE-703" ]
pjproject
d5f95aa066f878b0aef6a64e60b61e8626e664cd
93,008,980,738,988,830,000,000,000,000,000,000,000
53
Merge pull request from GHSA-cv8x-p47p-99wr * - Avoid SSL socket parent/listener getting destroyed during handshake by increasing parent's reference count. - Add missing SSL socket close when the newly accepted SSL socket is discarded in SIP TLS transport. * - Fix silly mistake: accepted active socket created without...
static struct sk_buff *add_grec(struct sk_buff *skb, struct ip_mc_list *pmc, int type, int gdeleted, int sdeleted) { struct net_device *dev = pmc->interface->dev; struct igmpv3_report *pih; struct igmpv3_grec *pgr = NULL; struct ip_sf_list *psf, *psf_next, *psf_prev, **psf_list; int scount, stotal, first, isquery...
0
[ "CWE-399", "CWE-703", "CWE-369" ]
linux
a8c1f65c79cbbb2f7da782d4c9d15639a9b94b27
29,852,438,843,549,304,000,000,000,000,000,000,000
108
igmp: Avoid zero delay when receiving odd mixture of IGMP queries Commit 5b7c84066733c5dfb0e4016d939757b38de189e4 ('ipv4: correct IGMP behavior on v3 query during v2-compatibility mode') added yet another case for query parsing, which can result in max_delay = 0. Substitute a value of 1, as in the usual v3 case. Rep...
int iwl_add_station_common(struct iwl_priv *priv, struct iwl_rxon_context *ctx, const u8 *addr, bool is_ap, struct ieee80211_sta *sta, u8 *sta_id_r) { unsigned long flags_spin; int ret = 0; u8 sta_id; struct iwl_addsta_cmd sta_cmd; *sta_id_r = 0; spin_lock_irqsave(&priv->shrd->sta_lock, flags_spin); ...
0
[ "CWE-119", "CWE-787" ]
linux
2da424b0773cea3db47e1e81db71eeebde8269d4
339,913,268,189,645,560,000,000,000,000,000,000,000
57
iwlwifi: Sanity check for sta_id On my testing, I saw some strange behavior [ 421.739708] iwlwifi 0000:01:00.0: ACTIVATE a non DRIVER active station id 148 addr 00:00:00:00:00:00 [ 421.739719] iwlwifi 0000:01:00.0: iwl_sta_ucode_activate Added STA id 148 addr 00:00:00:00:00:00 to uCode not sure how it happen, but ...
static inline int tty_put_user(struct tty_struct *tty, unsigned char x, unsigned char __user *ptr) { struct n_tty_data *ldata = tty->disc_data; tty_audit_add_data(tty, &x, 1, ldata->icanon); return put_user(x, ptr); }
0
[ "CWE-362" ]
tty
4291086b1f081b869c6d79e5b7441633dc3ace00
250,014,175,924,167,000,000,000,000,000,000,000,000
8
n_tty: Fix n_tty_write crash when echoing in raw mode The tty atomic_write_lock does not provide an exclusion guarantee for the tty driver if the termios settings are LECHO & !OPOST. And since it is unexpected and not allowed to call TTY buffer helpers like tty_insert_flip_string concurrently, this may lead to crashe...
static __latent_entropy void net_tx_action(struct softirq_action *h) { struct softnet_data *sd = this_cpu_ptr(&softnet_data); if (sd->completion_queue) { struct sk_buff *clist; local_irq_disable(); clist = sd->completion_queue; sd->completion_queue = NULL; local_irq_enable(); while (clist) { struct...
0
[ "CWE-476" ]
linux
0ad646c81b2182f7fa67ec0c8c825e0ee165696d
114,860,172,281,098,170,000,000,000,000,000,000,000
59
tun: call dev_get_valid_name() before register_netdevice() register_netdevice() could fail early when we have an invalid dev name, in which case ->ndo_uninit() is not called. For tun device, this is a problem because a timer etc. are already initialized and it expects ->ndo_uninit() to clean them up. We could move th...
PJ_DEF(void) pj_cis_add_str( pj_cis_t *cis, const char *str) { while (*str) { PJ_CIS_SET(cis, *str); ++str; } }
0
[ "CWE-125" ]
pjproject
077b465c33f0aec05a49cd2ca456f9a1b112e896
42,998,112,198,433,580,000,000,000,000,000,000,000
7
Merge pull request from GHSA-7fw8-54cv-r7pm
static void igmp6_group_queried(struct ifmcaddr6 *ma, unsigned long resptime) { unsigned long delay = resptime; /* Do not start work for these addresses */ if (ipv6_addr_is_ll_all_nodes(&ma->mca_addr) || IPV6_ADDR_MC_SCOPE(&ma->mca_addr) < IPV6_ADDR_SCOPE_LINKLOCAL) return; if (cancel_delayed_work(&ma->mca...
0
[ "CWE-703" ]
linux
2d3916f3189172d5c69d33065c3c21119fe539fc
217,484,945,471,829,840,000,000,000,000,000,000,000
21
ipv6: fix skb drops in igmp6_event_query() and igmp6_event_report() While investigating on why a synchronize_net() has been added recently in ipv6_mc_down(), I found that igmp6_event_query() and igmp6_event_report() might drop skbs in some cases. Discussion about removing synchronize_net() from ipv6_mc_down() will ha...
static void complicated_callback(struct urb *urb) { struct transfer_context *ctx = urb->context; spin_lock(&ctx->lock); ctx->count--; ctx->packet_count += urb->number_of_packets; if (urb->error_count > 0) ctx->errors += urb->error_count; else if (urb->status != 0) ctx->errors += (ctx->is_iso ? urb->number_o...
0
[ "CWE-476" ]
linux
7c80f9e4a588f1925b07134bb2e3689335f6c6d8
259,295,099,437,004,150,000,000,000,000,000,000,000
46
usb: usbtest: fix NULL pointer dereference If the usbtest driver encounters a device with an IN bulk endpoint but no OUT bulk endpoint, it will try to dereference a NULL pointer (out->desc.bEndpointAddress). The problem can be solved by adding a missing test. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Rep...
get_blip_conversation(packet_info* pinfo) { // Create a new conversation if needed and associate the blip_conversation_entry_t with it // Adapted from sample code in doc/README.dissector conversation_t *conversation; conversation = find_or_create_conversation(pinfo); blip_conversation_entry_t *conversation_entry_p...
0
[ "CWE-476" ]
wireshark
4a948427100b6c109f4ec7b4361f0d2aec5e5c3f
41,723,987,444,114,140,000,000,000,000,000,000,000
22
BLIP: Fix decompression buffer bug Until now, mistakenly, the buffer for decompressing compressed BLIP messages has been statically allocated as 16 Kb, but that is not valid behavior. 16 Kb is the maximum size of a _compressed_ frame. In theory, due to the ability to zipbomb, there is virtually no upper bound on what...
repodata_set_id(Repodata *data, Id solvid, Id keyname, Id id) { Repokey key; key.name = keyname; key.type = REPOKEY_TYPE_ID; key.size = 0; key.storage = KEY_STORAGE_INCORE; repodata_set(data, solvid, &key, id); }
0
[ "CWE-125" ]
libsolv
fdb9c9c03508990e4583046b590c30d958f272da
322,873,194,711,386,830,000,000,000,000,000,000,000
9
repodata_schema2id: fix heap-buffer-overflow in memcmp When the length of last schema in data->schemadata is less than length of input schema, we got a read overflow in asan test. Signed-off-by: Zhipeng Xie <xiezhipeng1@huawei.com>
static int ethtool_set_rx_csum(struct net_device *dev, char __user *useraddr) { struct ethtool_value edata; if (!dev->ethtool_ops->set_rx_csum) return -EOPNOTSUPP; if (copy_from_user(&edata, useraddr, sizeof(edata))) return -EFAULT; dev->ethtool_ops->set_rx_csum(dev, edata.data); return 0; }
0
[]
linux
e89e9cf539a28df7d0eb1d0a545368e9920b34ac
97,170,246,113,701,300,000,000,000,000,000,000,000
13
[IPv4/IPv6]: UFO Scatter-gather approach Attached is kernel patch for UDP Fragmentation Offload (UFO) feature. 1. This patch incorporate the review comments by Jeff Garzik. 2. Renamed USO as UFO (UDP Fragmentation Offload) 3. udp sendfile support with UFO This patches uses scatter-gather feature of skb to generate l...
fru_area_print_board(struct ipmi_intf * intf, struct fru_info * fru, uint8_t id, uint32_t offset) { char * fru_area; uint8_t * fru_data; uint32_t fru_len; uint32_t i; time_t ts; uint8_t tmp[2]; fru_len = 0; /* read enough to check length field */ if (read_fru_area(intf, fru, id, offset, 2, tmp) == 0) { ...
0
[ "CWE-120", "CWE-787" ]
ipmitool
e824c23316ae50beb7f7488f2055ac65e8b341f2
8,405,799,378,776,945,000,000,000,000,000,000,000
102
fru: Fix buffer overflow vulnerabilities Partial fix for CVE-2020-5208, see https://github.com/ipmitool/ipmitool/security/advisories/GHSA-g659-9qxw-p7cp The `read_fru_area_section` function only performs size validation of requested read size, and falsely assumes that the IPMI message will not respond with more than ...
create_distinct_group(THD *thd, Ref_ptr_array ref_pointer_array, ORDER *order_list, List<Item> &fields, List<Item> &all_fields, bool *all_order_by_fields_used) { List_iterator<Item> li(fields); Item *item; Ref_ptr_array orig_ref_pointer_array= ref_pointer_array;...
0
[ "CWE-89" ]
server
5ba77222e9fe7af8ff403816b5338b18b342053c
6,095,495,359,011,379,000,000,000,000,000,000,000
83
MDEV-21028 Server crashes in Query_arena::set_query_arena upon SELECT from view if the view has algorithm=temptable it is not updatable, so DEFAULT() for its fields is meaningless, and thus it's NULL or 0/'' for NOT NULL columns.
FunctionCall3Coll(FmgrInfo *flinfo, Oid collation, Datum arg1, Datum arg2, Datum arg3) { FunctionCallInfoData fcinfo; Datum result; InitFunctionCallInfoData(fcinfo, flinfo, 3, collation, NULL, NULL); fcinfo.arg[0] = arg1; fcinfo.arg[1] = arg2; fcinfo.arg[2] = arg3; fcinfo.argnull[0] = false; fcinfo.arg...
0
[ "CWE-264" ]
postgres
537cbd35c893e67a63c59bc636c3e888bd228bc7
337,540,418,882,656,100,000,000,000,000,000,000,000
23
Prevent privilege escalation in explicit calls to PL validators. The primary role of PL validators is to be called implicitly during CREATE FUNCTION, but they are also normal functions that a user can call explicitly. Add a permissions check to each validator to ensure that a user cannot use explicit validator calls ...
mrb_func_basic_p(mrb_state *mrb, mrb_value obj, mrb_sym mid, mrb_func_t func) { mrb_method_t m = mrb_method_search(mrb, mrb_class(mrb, obj), mid); struct RProc *p; if (MRB_METHOD_UNDEF_P(m)) return FALSE; if (MRB_METHOD_FUNC_P(m)) return MRB_METHOD_FUNC(m) == func; p = MRB_METHOD_PROC(m); if (MRB_PROC_...
0
[ "CWE-824" ]
mruby
b64ce17852b180dfeea81cf458660be41a78974d
61,456,905,817,414,075,000,000,000,000,000,000,000
13
Should not call `initialize_copy` for `TT_ICLASS`; fix #4027 Since `TT_ICLASS` is a internal object that should never be revealed to Ruby world.
static int tw5864_s_reg(struct file *file, void *fh, const struct v4l2_dbg_register *reg) { struct tw5864_input *input = video_drvdata(file); struct tw5864_dev *dev = input->root; if (reg->reg < INDIR_SPACE_MAP_SHIFT) { if (reg->reg > 0x87fff) return -EINVAL; tw_writel(reg->reg, reg->val); } else { __u...
0
[ "CWE-476" ]
linux
2e7682ebfc750177a4944eeb56e97a3f05734528
314,144,670,842,311,600,000,000,000,000,000,000,000
19
media: tw5864: Fix possible NULL pointer dereference in tw5864_handle_frame 'vb' null check should be done before dereferencing it in tw5864_handle_frame, otherwise a NULL pointer dereference may occur. Fixes: 34d1324edd31 ("[media] pci: Add tw5864 driver") Signed-off-by: YueHaibing <yuehaibing@huawei.com> Signed-of...
static void hugetlb_unregister_all_nodes(void) { }
0
[ "CWE-399" ]
linux
90481622d75715bfcb68501280a917dbfe516029
169,193,501,758,715,570,000,000,000,000,000,000,000
1
hugepages: fix use after free bug in "quota" handling hugetlbfs_{get,put}_quota() are badly named. They don't interact with the general quota handling code, and they don't much resemble its behaviour. Rather than being about maintaining limits on on-disk block usage by particular users, they are instead about maintai...
void PacketFreeOrRelease(Packet *p) { if (p->flags & PKT_ALLOC) PacketFree(p); else PacketPoolReturnPacket(p); }
0
[ "CWE-20" ]
suricata
11f3659f64a4e42e90cb3c09fcef66894205aefe
145,957,225,668,319,860,000,000,000,000,000,000,000
7
teredo: be stricter on what to consider valid teredo Invalid Teredo can lead to valid DNS traffic (or other UDP traffic) being misdetected as Teredo. This leads to false negatives in the UDP payload inspection. Make the teredo code only consider a packet teredo if the encapsulated data was decoded without any 'invali...
struct tipc_node *tipc_node_create(struct net *net, u32 addr, u8 *peer_id, u16 capabilities, u32 hash_mixes, bool preliminary) { struct tipc_net *tn = net_generic(net, tipc_net_id); struct tipc_node *n, *temp_node; struct tipc_link *l; unsigned long intv; int bearer_id; int i; spin_lock_bh(&tn->no...
0
[]
linux
0217ed2848e8538bcf9172d97ed2eeb4a26041bb
215,276,817,266,973,730,000,000,000,000,000,000,000
125
tipc: better validate user input in tipc_nl_retrieve_key() Before calling tipc_aead_key_size(ptr), we need to ensure we have enough data to dereference ptr->keylen. We probably also want to make sure tipc_aead_key_size() wont overflow with malicious ptr->keylen values. Syzbot reported: BUG: KMSAN: uninit-value in _...
vips_foreign_load_start( VipsImage *out, void *a, void *b ) { VipsForeignLoad *load = VIPS_FOREIGN_LOAD( b ); VipsForeignLoadClass *class = VIPS_FOREIGN_LOAD_GET_CLASS( load ); if( !load->real ) { if( !(load->real = vips_foreign_load_temp( load )) ) return( NULL ); #ifdef DEBUG printf( "vips_foreign_load_st...
1
[ "CWE-362", "CWE-476" ]
libvips
20d840e6da15c1574b3ed998bc92f91d1e36c2a5
120,845,744,665,840,740,000,000,000,000,000,000,000
51
fix a crash with delayed load If a delayed load failed, it could leave the pipeline only half-set up. Sebsequent threads could then segv. Set a load-has-failed flag and test before generate. See https://github.com/jcupitt/libvips/issues/893
static struct sk_buff *tcp_sacktag_walk(struct sk_buff *skb, struct sock *sk, struct tcp_sack_block *next_dup, struct tcp_sacktag_state *state, u32 start_seq, u32 end_seq, bool dup_sack_in) { struct tcp_sock *tp = tcp_sk(sk); struct sk_buff *tmp; skb_rbtree_walk_from(skb) { int in_sack = 0; ...
0
[ "CWE-190" ]
net
3b4929f65b0d8249f19a50245cd88ed1a2f78cff
15,848,224,017,793,283,000,000,000,000,000,000,000
71
tcp: limit payload size of sacked skbs Jonathan Looney reported that TCP can trigger the following crash in tcp_shifted_skb() : BUG_ON(tcp_skb_pcount(skb) < pcount); This can happen if the remote peer has advertized the smallest MSS that linux TCP accepts : 48 An skb can hold 17 fragments, and each fragment can ho...
grantpt (int fd) { int retval = -1; #ifdef PATH_MAX char _buf[PATH_MAX]; #else char _buf[512]; #endif char *buf = _buf; struct stat64 st; if (__builtin_expect (pts_name (fd, &buf, sizeof (_buf), &st), 0)) { int save_errno = errno; /* Check, if the file descriptor is valid. pts_name return...
1
[ "CWE-284" ]
glibc
e4608715e6e1dd2adc91982fd151d5ba4f761d69
55,488,823,009,452,920,000,000,000,000,000,000,000
141
CVE-2013-2207, BZ #15755: Disable pt_chown. The helper binary pt_chown tricked into granting access to another user's pseudo-terminal. Pre-conditions for the attack: * Attacker with local user account * Kernel with FUSE support * "user_allow_other" in /etc/fuse.conf * Victim with allocated slave in /dev/pts Usi...
Status PyObjectToString(PyObject* obj, const char** ptr, Py_ssize_t* len, PyObject** ptr_owner) { *ptr_owner = nullptr; if (PyBytes_Check(obj)) { char* buf; if (PyBytes_AsStringAndSize(obj, &buf, len) != 0) { return errors::Internal("Unable to get element as bytes."); } ...
0
[ "CWE-476", "CWE-843" ]
tensorflow
030af767d357d1b4088c4a25c72cb3906abac489
121,658,595,224,769,150,000,000,000,000,000,000,000
29
Fix `tf.raw_ops.ResourceCountUpTo` null pointer dereference. PiperOrigin-RevId: 368294347 Change-Id: I2c16fbfc9b4966c402c3d8e311f0d665a9c852d8
bool operator == (const _glat_iterator<W> & rhs) { return _v >= rhs._e - 1; }
0
[ "CWE-476" ]
graphite
db132b4731a9b4c9534144ba3a18e65b390e9ff6
237,507,606,676,397,740,000,000,000,000,000,000,000
1
Deprecate and make ineffective gr_face_dumbRendering
static void mwifiex_check_next_scan_command(struct mwifiex_private *priv) { struct mwifiex_adapter *adapter = priv->adapter; struct cmd_ctrl_node *cmd_node; spin_lock_bh(&adapter->scan_pending_q_lock); if (list_empty(&adapter->scan_pending_q)) { spin_unlock_bh(&adapter->scan_pending_q_lock); spin_lock_bh(&ada...
0
[ "CWE-269", "CWE-787" ]
linux
b70261a288ea4d2f4ac7cd04be08a9f0f2de4f4d
189,106,705,379,707,150,000,000,000,000,000,000,000
73
mwifiex: Fix possible buffer overflows in mwifiex_cmd_append_vsie_tlv() mwifiex_cmd_append_vsie_tlv() calls memcpy() without checking the destination size may trigger a buffer overflower, which a local user could use to cause denial of service or the execution of arbitrary code. Fix it by putting the length check befo...
static int phar_tar_writeheaders(zval *zv, void *argument) /* {{{ */ { return phar_tar_writeheaders_int(Z_PTR_P(zv), argument); }
0
[ "CWE-119" ]
php-src
e0f5d62bd6690169998474b62f92a8c5ddf0e699
149,964,114,767,276,890,000,000,000,000,000,000,000
4
Fix bug #77586 - phar_tar_writeheaders_int() buffer overflow
static void dcc_chat_listen(CHAT_DCC_REC *dcc) { IPADDR ip; GIOChannel *handle; int port; g_return_if_fail(IS_DCC_CHAT(dcc)); /* accept connection */ handle = net_accept(dcc->handle, &ip, &port); if (handle == NULL) return; /* TODO: add paranoia check - see dcc-files.c */ net_disconnect(dcc->handl...
0
[ "CWE-416" ]
irssi
43e44d553d44e313003cee87e6ea5e24d68b84a1
30,247,042,907,636,417,000,000,000,000,000,000,000
30
Merge branch 'security' into 'master' Security Closes GL#12, GL#13, GL#14, GL#15, GL#16 See merge request irssi/irssi!23
static int raw_getsockopt(struct sock *sk, int level, int optname, char __user *optval, int __user *optlen) { return -EOPNOTSUPP; }
0
[ "CWE-276" ]
linux
e69dbd4619e7674c1679cba49afd9dd9ac347eef
319,168,426,169,024,230,000,000,000,000,000,000,000
5
ieee802154: enforce CAP_NET_RAW for raw sockets When creating a raw AF_IEEE802154 socket, CAP_NET_RAW needs to be checked first. Signed-off-by: Ori Nimron <orinimron123@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Acked-by: Stefan Schmidt <stefan@datenfreihafen.org> Signed-off-by: David S...
return err; } static int iscsi_if_ep_connect(struct iscsi_transport *transport, struct iscsi_uevent *ev, int msg_type) { struct iscsi_endpoint *ep; struct sockaddr *dst_addr; struct Scsi_Host *shost = NULL; int non_blocking, err = 0; if (!transport->ep_connect) return -EINVAL; if (msg_type == ISCS...
0
[ "CWE-787" ]
linux
ec98ea7070e94cc25a422ec97d1421e28d97b7ee
216,001,460,016,196,820,000,000,000,000,000,000,000
36
scsi: iscsi: Ensure sysfs attributes are limited to PAGE_SIZE As the iSCSI parameters are exported back through sysfs, it should be enforcing that they never are more than PAGE_SIZE (which should be more than enough) before accepting updates through netlink. Change all iSCSI sysfs attributes to use sysfs_emit(). Cc:...
static unsigned long power_of(int cpu) { return cpu_rq(cpu)->cpu_power; }
0
[ "CWE-703", "CWE-835" ]
linux
f26f9aff6aaf67e9a430d16c266f91b13a5bff64
214,444,366,401,216,200,000,000,000,000,000,000,000
4
Sched: fix skip_clock_update optimization idle_balance() drops/retakes rq->lock, leaving the previous task vulnerable to set_tsk_need_resched(). Clear it after we return from balancing instead, and in setup_thread_stack() as well, so no successfully descheduled or never scheduled task has it set. Need resched confus...
Expr *sqlite3ExprFunction( Parse *pParse, /* Parsing context */ ExprList *pList, /* Argument list */ Token *pToken, /* Name of the function */ int eDistinct /* SF_Distinct or SF_ALL or 0 */ ){ Expr *pNew; sqlite3 *db = pParse->db; assert( pToken ); pNew = sqlite3ExprAlloc(db, ...
0
[ "CWE-476" ]
sqlite
57f7ece78410a8aae86aa4625fb7556897db384c
44,358,709,456,225,480,000,000,000,000,000,000,000
24
Fix a problem that comes up when using generated columns that evaluate to a constant in an index and then making use of that index in a join. FossilOrigin-Name: 8b12e95fec7ce6e0de82a04ca3dfcf1a8e62e233b7382aa28a8a9be6e862b1af
static bool ossl_cert_status_request(void) { #if (OPENSSL_VERSION_NUMBER >= 0x0090808fL) && !defined(OPENSSL_NO_TLSEXT) && \ !defined(OPENSSL_NO_OCSP) return TRUE; #else return FALSE; #endif }
0
[ "CWE-290" ]
curl
b09c8ee15771c614c4bf3ddac893cdb12187c844
309,285,276,102,197,020,000,000,000,000,000,000,000
9
vtls: add 'isproxy' argument to Curl_ssl_get/addsessionid() To make sure we set and extract the correct session. Reported-by: Mingtao Yang Bug: https://curl.se/docs/CVE-2021-22890.html CVE-2021-22890
static int old_rsa_priv_decode(EVP_PKEY *pkey, const unsigned char **pder, int derlen) { RSA *rsa; if (!(rsa = d2i_RSAPrivateKey(NULL, pder, derlen))) { RSAerr(RSA_F_OLD_RSA_PRIV_DECODE, ERR_R_RSA_LIB); return 0; } EVP_PKEY_assign_RSA(pkey, rsa); return...
0
[]
openssl
4b22cce3812052fe64fc3f6d58d8cc884e3cb834
145,203,775,386,911,360,000,000,000,000,000,000,000
11
Reject invalid PSS parameters. Fix a bug where invalid PSS parameters are not rejected resulting in a NULL pointer exception. This can be triggered during certificate verification so could be a DoS attack against a client or a server enabling client authentication. Thanks to Brian Carpenter for reporting this issues....
void FreeTrustedPeer(TrustedPeerCert* tp, void* heap) { if (tp == NULL) { return; } if (tp->name) { XFREE(tp->name, heap, DYNAMIC_TYPE_SUBJECT_CN); } if (tp->sig) { XFREE(tp->sig, heap, DYNAMIC_TYPE_SIGNATURE); } #ifndef IGNORE_NAME_CONSTRAINTS if (tp->permittedName...
0
[ "CWE-125", "CWE-345" ]
wolfssl
f93083be72a3b3d956b52a7ec13f307a27b6e093
291,983,174,101,189,400,000,000,000,000,000,000,000
23
OCSP: improve handling of OCSP no check extension
static BOOL update_send_notify_icon_delete(rdpContext* context, const WINDOW_ORDER_INFO* orderInfo) { wStream* s; rdpUpdate* update = context->update; BYTE controlFlags = ORDER_SECONDARY | (ORDER_TYPE_WINDOW << 2); UINT16 orderSize = 15; update_check_flush(context, orderSize); s = update->us; if (!s) return ...
0
[ "CWE-125" ]
FreeRDP
f8890a645c221823ac133dbf991f8a65ae50d637
207,244,329,752,623,970,000,000,000,000,000,000,000
22
Fixed #6005: Bounds checks in update_read_bitmap_data
crm_trigger_prepare(GSource * source, gint * timeout) { crm_trigger_t *trig = (crm_trigger_t *) source; /* cluster-glue's FD and IPC related sources make use of * g_source_add_poll() but do not set a timeout in their prepare * functions * * This means mainloop's poll() will block until an e...
0
[ "CWE-399" ]
pacemaker
564f7cc2a51dcd2f28ab12a13394f31be5aa3c93
206,020,037,803,096,880,000,000,000,000,000,000,000
25
High: core: Internal tls api improvements for reuse with future LRMD tls backend.
tsize_t t2p_write_pdf_xobject_cs(T2P* t2p, TIFF* output){ tsize_t written=0; char buffer[128]; int buflen=0; float X_W=1.0; float Y_W=1.0; float Z_W=1.0; if( (t2p->pdf_colorspace & T2P_CS_ICCBASED) != 0){ written += t2p_write_pdf_xobject_icccs(t2p, output); return(written); } if( (t2p->pdf_colorspace &...
0
[ "CWE-787" ]
libtiff
7be2e452ddcf6d7abca88f41d3761e6edab72b22
72,803,940,867,195,410,000,000,000,000,000,000,000
73
tiff2pdf.c: properly calculate datasize when saving to JPEG YCbCr fixes #220
void lcdFillRect_ArrayBuffer_flat(struct JsGraphics *gfx, short x1, short y1, short x2, short y2) { short y; for (y=y1;y<=y2;y++) lcdSetPixels_ArrayBuffer_flat(gfx, x1, y, (short)(1+x2-x1), gfx->data.fgColor); }
0
[ "CWE-125" ]
Espruino
8a44b04b584b3d3ab1cb68fed410f7ecb165e50e
85,581,495,687,777,680,000,000,000,000,000,000,000
5
Add height check for Graphics.createArrayBuffer(...vertical_byte:true) (fix #1421)
TEST_P(WasmTest, Segv) { Stats::IsolatedStoreImpl stats_store; Api::ApiPtr api = Api::createApiForTest(stats_store); Upstream::MockClusterManager cluster_manager; Event::DispatcherPtr dispatcher(api->allocateDispatcher()); auto scope = Stats::ScopeSharedPtr(stats_store.createScope("wasm.")); NiceMock<LocalI...
0
[ "CWE-476" ]
envoy
8788a3cf255b647fd14e6b5e2585abaaedb28153
149,283,646,644,928,650,000,000,000,000,000,000,000
36
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...
static void put_int16(QEMUFile *f, void *pv, size_t size) { int16_t *v = pv; qemu_put_sbe16s(f, v); }
0
[ "CWE-119" ]
qemu
d2ef4b61fe6d33d2a5dcf100a9b9440de341ad62
309,113,002,471,692,400,000,000,000,000,000,000,000
5
vmstate: fix buffer overflow in target-arm/machine.c CVE-2013-4531 cpreg_vmstate_indexes is a VARRAY_INT32. A negative value for cpreg_vmstate_array_len will cause a buffer overflow. VMSTATE_INT32_LE was supposed to protect against this but doesn't because it doesn't validate that input is non-negative. Fix this ma...
static void hid_pointer_event(DeviceState *dev, QemuConsole *src, InputEvent *evt) { static const int bmap[INPUT_BUTTON__MAX] = { [INPUT_BUTTON_LEFT] = 0x01, [INPUT_BUTTON_RIGHT] = 0x02, [INPUT_BUTTON_MIDDLE] = 0x04, }; HIDState *hs = (HIDState *)dev;...
0
[ "CWE-772" ]
qemu
51dbea77a29ea46173373a6dad4ebd95d4661f42
121,921,706,885,833,890,000,000,000,000,000,000,000
55
hid: Reset kbd modifiers on reset When resetting the keyboard, we need to reset not just the pending keystrokes, but also any pending modifiers. Otherwise there's a race when we're getting reset while running an escape sequence (modifier 0x100). Cc: qemu-stable@nongnu.org Signed-off-by: Alexander Graf <agraf@suse.de>...
static void perf_event_exit_task_context(struct task_struct *child, int ctxn) { struct perf_event *child_event, *tmp; struct perf_event_context *child_ctx; unsigned long flags; if (likely(!child->perf_event_ctxp[ctxn])) { perf_event_task(child, NULL, 0); return; } local_irq_save(flags); /* * We can't res...
0
[ "CWE-703", "CWE-189" ]
linux
8176cced706b5e5d15887584150764894e94e02f
51,784,074,277,499,720,000,000,000,000,000,000,000
78
perf: Treat attr.config as u64 in perf_swevent_init() Trinity discovered that we fail to check all 64 bits of attr.config passed by user space, resulting to out-of-bounds access of the perf_swevent_enabled array in sw_perf_event_destroy(). Introduced in commit b0a873ebb ("perf: Register PMU implementations"). Signed...
void CWebServer::DisplaySwitchTypesCombo(std::string & content_part) { char szTmp[200]; std::map<std::string, int> _switchtypes; for (int ii = 0; ii < STYPE_END; ii++) { _switchtypes[Switch_Type_Desc((_eSwitchType)ii)] = ii; } //return a sorted list for (const auto & itt : _switchtypes) ...
0
[ "CWE-89" ]
domoticz
ee70db46f81afa582c96b887b73bcd2a86feda00
220,480,988,747,716,900,000,000,000,000,000,000,000
17
Fixed possible SQL Injection Vulnerability (Thanks to Fabio Carretto!)
static bool fix_slave_net_timeout(sys_var *self, THD *thd, enum_var_type type) { mysql_mutex_lock(&LOCK_active_mi); DBUG_PRINT("info", ("slave_net_timeout=%u mi->heartbeat_period=%.3f", slave_net_timeout, (active_mi? active_mi->heartbeat_period : 0.0))); if (active_mi && ...
0
[ "CWE-264" ]
mysql-server
48bd8b16fe382be302c6f0b45931be5aa6f29a0e
163,913,059,381,284,700,000,000,000,000,000,000,000
13
Bug#24388753: PRIVILEGE ESCALATION USING MYSQLD_SAFE [This is the 5.5/5.6 version of the bugfix]. The problem was that it was possible to write log files ending in .ini/.cnf that later could be parsed as an options file. This made it possible for users to specify startup options without the permissions to do so. Thi...
static int check_good_user(sd_bus_message *m, uid_t good_user) { _cleanup_(sd_bus_creds_unrefp) sd_bus_creds *creds = NULL; uid_t sender_uid; int r; assert(m); if (good_user == UID_INVALID) return 0; r = sd_bus_query_sender_creds(m, SD_BUS_CREDS_EUID, &...
0
[ "CWE-416" ]
systemd
637486261528e8aa3da9f26a4487dc254f4b7abb
329,369,636,039,752,500,000,000,000,000,000,000,000
23
polkit: when authorizing via PK let's re-resolve callback/userdata instead of caching it Previously, when doing an async PK query we'd store the original callback/userdata pair and call it again after the PK request is complete. This is problematic, since PK queries might be slow and in the meantime the userdata might...
static void BenchmarkOpenCLDevices(MagickCLEnv clEnv) { MagickCLDevice device; MagickCLEnv testEnv; size_t i, j; testEnv=AcquireMagickCLEnv(); testEnv->library=openCL_library; testEnv->devices=(MagickCLDevice *) AcquireCriticalMemory( sizeof(MagickCLDevice)); testEnv->number_devices...
0
[ "CWE-476" ]
ImageMagick
d2b87b403059af21db3002db95f4603f32b492ef
245,788,237,359,640,440,000,000,000,000,000,000,000
49
https://github.com/ImageMagick/ImageMagick/issues/792
DeepTiledInputFile::dataWindowForTile (int dx, int dy, int lx, int ly) const { try { if (!isValidTile (dx, dy, lx, ly)) throw IEX_NAMESPACE::ArgExc ("Arguments not in valid range."); return OPENEXR_IMF_INTERNAL_NAMESPACE::dataWindowForTile ( _data->tileDesc, ...
0
[ "CWE-125" ]
openexr
e79d2296496a50826a15c667bf92bdc5a05518b4
247,955,743,575,306,780,000,000,000,000,000,000,000
20
fix memory leaks and invalid memory accesses Signed-off-by: Peter Hillman <peterh@wetafx.co.nz>
static void l2cap_conf_rfc_get(struct l2cap_chan *chan, void *rsp, int len) { int type, olen; unsigned long val; /* Use sane default values in case a misbehaving remote device * did not send an RFC or extended window size option. */ u16 txwin_ext = chan->ack_win; struct l2cap_conf_rfc rfc = { .mode = chan->m...
0
[ "CWE-787" ]
linux
e860d2c904d1a9f38a24eb44c9f34b8f915a6ea3
310,728,823,584,289,800,000,000,000,000,000,000,000
50
Bluetooth: Properly check L2CAP config option output buffer length Validate the output buffer length for L2CAP config requests and responses to avoid overflowing the stack buffer used for building the option blocks. Cc: stable@vger.kernel.org Signed-off-by: Ben Seri <ben@armis.com> Signed-off-by: Marcel Holtmann <mar...
static int cirrus_bitblt_videotovideo_patterncopy(CirrusVGAState * s) { return cirrus_bitblt_common_patterncopy(s); }
0
[ "CWE-119" ]
qemu
ffaf857778286ca54e3804432a2369a279e73aa7
93,651,253,666,780,300,000,000,000,000,000,000,000
4
cirrus: stop passing around src pointers in the blitter Does basically the same as "cirrus: stop passing around dst pointers in the blitter", just for the src pointer instead of the dst pointer. For the src we have to care about cputovideo blits though and fetch the data from s->cirrus_bltbuf instead of vga memory. ...
Mutex_info() { for (unsigned int i = 0; i<32; ++i) mutex[i] = CreateMutex(0,FALSE,0); }
0
[ "CWE-125" ]
CImg
10af1e8c1ad2a58a0a3342a856bae63e8f257abb
83,376,375,585,029,460,000,000,000,000,000,000,000
1
Fix other issues in 'CImg<T>::load_bmp()'.
Fetches the next row and returns it as an object. */ static PHP_METHOD(PDOStatement, fetchObject) { long how = PDO_FETCH_CLASS; long ori = PDO_FETCH_ORI_NEXT; long off = 0; char *class_name = NULL; int class_name_len; zend_class_entry *old_ce; zval *old_ctor_args, *ctor_args = NULL; int error = 0, old_arg_co...
0
[ "CWE-476" ]
php-src
6045de69c7dedcba3eadf7c4bba424b19c81d00d
60,713,340,392,970,845,000,000,000,000,000,000,000
64
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).
SYSCALL_DEFINE(fallocate)(int fd, int mode, loff_t offset, loff_t len) { struct file *file; int error = -EBADF; file = fget(fd); if (file) { error = do_fallocate(file, mode, offset, len); fput(file); } return error; }
0
[ "CWE-732" ]
linux-stable
e57712ebebbb9db7d8dcef216437b3171ddcf115
284,173,470,621,466,300,000,000,000,000,000,000,000
13
merge fchmod() and fchmodat() guts, kill ancient broken kludge The kludge in question is undocumented and doesn't work for 32bit binaries on amd64, sparc64 and s390. Passing (mode_t)-1 as mode had (since 0.99.14v and contrary to behaviour of any other Unix, prescriptions of POSIX, SuS and our own manpages) was kinda-...
static ssize_t show_model(struct device *cd, struct device_attribute *attr, char *buf) { struct video_device *vdev = container_of(cd, struct video_device, dev); struct usb_usbvision *usbvision = video_get_drvdata(vdev); return sprintf(buf, "%s\n", usbvision_device_data[usbvision->dev_model].model_str...
0
[ "CWE-17" ]
media_tree
fa52bd506f274b7619955917abfde355e3d19ffe
303,037,956,963,610,050,000,000,000,000,000,000,000
9
[media] usbvision: fix crash on detecting device with invalid configuration The usbvision driver crashes when a specially crafted usb device with invalid number of interfaces or endpoints is detected. This fix adds checks that the device has proper configuration expected by the driver. Reported-by: Ralf Spenneberg <r...