func
string
target
int64
cwe
list
project
string
commit_id
string
hash
float64
size
int64
message
string
hb_set_get_max (const hb_set_t *set) { return set->get_max (); }
0
[ "CWE-787" ]
harfbuzz
d3e09bf4654fe5478b6dbf2b26ebab6271317d81
334,606,342,536,626,100,000,000,000,000,000,000,000
4
[set] Make all operators null-safe again Changed my mind. Also for hb_map_clear(). Part of https://github.com/harfbuzz/harfbuzz/pull/3162
static int ep_insert(struct eventpoll *ep, struct epoll_event *event, struct file *tfile, int fd) { int error, revents, pwake = 0; unsigned long flags; long user_watches; struct epitem *epi; struct ep_pqueue epq; user_watches = atomic_long_read(&ep->user->epoll_watches); if (unlikely(user_watches >= max_...
0
[]
linux-2.6
13d518074a952d33d47c428419693f63389547e9
109,307,612,435,176,940,000,000,000,000,000,000,000
114
epoll: clear the tfile_check_list on -ELOOP An epoll_ctl(,EPOLL_CTL_ADD,,) operation can return '-ELOOP' to prevent circular epoll dependencies from being created. However, in that case we do not properly clear the 'tfile_check_list'. Thus, add a call to clear_tfile_check_list() for the -ELOOP case. Signed-off-by: ...
std::unique_ptr<base::DictionaryValue> CreateFileSystemValue( const FileSystem& file_system) { auto file_system_value = std::make_unique<base::DictionaryValue>(); file_system_value->SetString("type", file_system.type); file_system_value->SetString("fileSystemName", file_system.file_system_name); file_system...
0
[]
electron
e9fa834757f41c0b9fe44a4dffe3d7d437f52d34
259,609,433,550,219,300,000,000,000,000,000,000,000
9
fix: ensure ElectronBrowser mojo service is only bound to appropriate render frames (#33344) * fix: ensure ElectronBrowser mojo service is only bound to authorized render frames Notes: no-notes * refactor: extract electron API IPC to its own mojo interface * fix: just check main frame not primary main frame ...
static size_t __iovec_copy_from_user_inatomic(char *vaddr, const struct iovec *iov, size_t base, size_t bytes) { size_t copied = 0, left = 0; while (bytes) { char __user *buf = iov->iov_base + base; int copy = min(bytes, iov->iov_len - base); base = 0; left = __copy_from_user_inatomic(vaddr, buf, copy); ...
0
[ "CWE-17" ]
linux
f0d1bec9d58d4c038d0ac958c9af82be6eb18045
4,013,928,642,464,240,600,000,000,000,000,000,000
21
new helper: copy_page_from_iter() parallel to copy_page_to_iter(). pipe_write() switched to it (and became ->write_iter()). Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
ZEND_VM_HOT_TYPE_SPEC_HANDLER(ZEND_IS_SMALLER_OR_EQUAL, (op1_info == MAY_BE_LONG && op2_info == MAY_BE_LONG), ZEND_IS_SMALLER_OR_EQUAL_LONG, CONST|TMPVARCV, CONST|TMPVARCV, SPEC(SMART_BRANCH,NO_CONST_CONST)) { USE_OPLINE zval *op1, *op2; int result; op1 = GET_OP1_ZVAL_PTR_UNDEF(BP_VAR_R); op2 = GET_OP2_ZVAL_PTR_U...
0
[ "CWE-787" ]
php-src
f1ce8d5f5839cb2069ea37ff424fb96b8cd6932d
78,114,339,376,514,670,000,000,000,000,000,000,000
13
Fix #73122: Integer Overflow when concatenating strings We must avoid integer overflows in memory allocations, so we introduce an additional check in the VM, and bail out in the rare case of an overflow. Since the recent fix for bug #74960 still doesn't catch all possible overflows, we fix that right away.
psutil_proc_cpu_times(PyObject *self, PyObject *args) { long pid; HANDLE hProcess; FILETIME ftCreate, ftExit, ftKernel, ftUser; if (! PyArg_ParseTuple(args, "l", &pid)) return NULL; hProcess = psutil_handle_from_pid(pid, PROCESS_QUERY_LIMITED_INFORMATION); if (hProcess ...
0
[ "CWE-415" ]
psutil
7d512c8e4442a896d56505be3e78f1156f443465
277,596,628,424,530,940,000,000,000,000,000,000,000
44
Use Py_CLEAR instead of Py_DECREF to also set the variable to NULL (#1616) These files contain loops that convert system data into python objects and during the process they create objects and dereference their refcounts after they have been added to the resulting list. However, in case of errors during the creat...
Error Box_ftyp::write(StreamWriter& writer) const { size_t box_start = reserve_box_header_space(writer); writer.write32(m_major_brand); writer.write32(m_minor_version); for (uint32_t b : m_compatible_brands) { writer.write32(b); } prepend_header(writer, box_start); return Error::Ok; }
0
[ "CWE-703" ]
libheif
2710c930918609caaf0a664e9c7bc3dce05d5b58
295,809,674,861,913,160,000,000,000,000,000,000,000
15
force fraction to a limited resolution to finally solve those pesky numerical edge cases
static int Elf_(fix_symbols)(ELFOBJ *bin, int nsym, int type, RBinElfSymbol **sym) { int count = 0; RBinElfSymbol *ret = *sym; RBinElfSymbol *phdr_symbols = (type == R_BIN_ELF_SYMBOLS) ? Elf_(r_bin_elf_get_phdr_symbols) (bin) : Elf_(r_bin_elf_get_phdr_imports) (bin); RBinElfSymbol *tmp, *p; if (phdr_symbol...
0
[ "CWE-125" ]
radare2
c6d0076c924891ad9948a62d89d0bcdaf965f0cd
205,388,715,154,572,200,000,000,000,000,000,000,000
54
Fix #8731 - Crash in ELF parser with negative 32bit number
struct inode *f2fs_iget(struct super_block *sb, unsigned long ino) { struct f2fs_sb_info *sbi = F2FS_SB(sb); struct inode *inode; int ret = 0; inode = iget_locked(sb, ino); if (!inode) return ERR_PTR(-ENOMEM); if (!(inode->i_state & I_NEW)) { trace_f2fs_iget(inode); return inode; } if (ino == F2FS_NODE_...
0
[ "CWE-125" ]
linux
e34438c903b653daca2b2a7de95aed46226f8ed3
187,267,550,579,770,120,000,000,000,000,000,000,000
61
f2fs: fix to do sanity check with node footer and iblocks This patch adds to do sanity check with below fields of inode to avoid reported panic. - node footer - iblocks https://bugzilla.kernel.org/show_bug.cgi?id=200223 - Overview BUG() triggered in f2fs_truncate_inode_blocks() when un-mounting a mounted f2fs image ...
static int ipmr_mfc_seq_show(struct seq_file *seq, void *v) { int n; if (v == SEQ_START_TOKEN) { seq_puts(seq, "Group Origin Iif Pkts Bytes Wrong Oifs\n"); } else { const struct mfc_cache *mfc = v; const struct ipmr_mfc_iter *it = seq->private; seq_printf(seq, "%08lX %08lX %-3d %8ld %8...
0
[ "CWE-200" ]
linux-2.6
9ef1d4c7c7aca1cd436612b6ca785b726ffb8ed8
224,192,023,859,389,780,000,000,000,000,000,000,000
33
[NETLINK]: Missing initializations in dumped data Mostly missing initialization of padding fields of 1 or 2 bytes length, two instances of uninitialized nlmsgerr->msg of 16 bytes length. Signed-off-by: Patrick McHardy <kaber@trash.net> Signed-off-by: David S. Miller <davem@davemloft.net>
add_document_portal_args (GPtrArray *argv_array, const char *app_id) { g_autoptr(GDBusConnection) session_bus = NULL; g_autofree char *doc_mount_path = NULL; session_bus = g_bus_get_sync (G_BUS_TYPE_SESSION, NULL, NULL); if (session_bus) { g_autoptr(GError) local_error = NU...
0
[ "CWE-20" ]
flatpak
902fb713990a8f968ea4350c7c2a27ff46f1a6c4
130,347,917,465,921,680,000,000,000,000,000,000,000
45
Use seccomp to filter out TIOCSTI ioctl This would otherwise let the sandbox add input to the controlling tty.
int may_umount(struct vfsmount *mnt) { int ret = 1; down_read(&namespace_sem); lock_mount_hash(); if (propagate_mount_busy(real_mount(mnt), 2)) ret = 0; unlock_mount_hash(); up_read(&namespace_sem); return ret; }
0
[ "CWE-269" ]
user-namespace
a6138db815df5ee542d848318e5dae681590fccd
270,074,117,050,143,600,000,000,000,000,000,000,000
11
mnt: Only change user settable mount flags in remount Kenton Varda <kenton@sandstorm.io> discovered that by remounting a read-only bind mount read-only in a user namespace the MNT_LOCK_READONLY bit would be cleared, allowing an unprivileged user to the remount a read-only mount read-write. Correct this by replacing t...
pq_getstring(StringInfo s) { int i; Assert(PqCommReadingMsg); resetStringInfo(s); /* Read until we get the terminating '\0' */ for (;;) { while (PqRecvPointer >= PqRecvLength) { if (pq_recvbuf()) /* If nothing in buffer, then recv some */ return EOF; /* Failed to recv data */ } for (i = PqRe...
0
[ "CWE-89" ]
postgres
2b3a8b20c2da9f39ffecae25ab7c66974fbc0d3b
279,690,430,386,992,200,000,000,000,000,000,000,000
35
Be more careful to not lose sync in the FE/BE protocol. If any error occurred while we were in the middle of reading a protocol message from the client, we could lose sync, and incorrectly try to interpret a part of another message as a new protocol message. That will usually lead to an "invalid frontend message" erro...
decodets( char *str, l_fp *lfp ) { char *cp; char buf[30]; size_t b; /* * If it starts with a 0x, decode as hex. */ if (*str == '0' && (*(str+1) == 'x' || *(str+1) == 'X')) return hextolfp(str+2, lfp); /* * If it starts with a '"', try it as an RT-11 date. */ if (*str == '"') { cp = str + 1; b...
0
[ "CWE-20" ]
ntp
07a5b8141e354a998a52994c3c9cd547927e56ce
230,687,940,889,403,020,000,000,000,000,000,000,000
44
[TALOS-CAN-0063] avoid buffer overrun in ntpq
static int proc_cwd_link(struct dentry *dentry, struct path *path) { struct task_struct *task = get_proc_task(dentry->d_inode); int result = -ENOENT; if (task) { task_lock(task); if (task->fs) { get_fs_pwd(task->fs, path); result = 0; } task_unlock(task); put_task_struct(task); } return result; }
0
[]
linux
0499680a42141d86417a8fbaa8c8db806bea1201
106,597,650,919,289,920,000,000,000,000,000,000,000
16
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...
static int brcmf_enable_bw40_2g(struct brcmf_cfg80211_info *cfg) { struct wiphy *wiphy = cfg_to_wiphy(cfg); struct brcmf_if *ifp = brcmf_get_ifp(cfg->pub, 0); struct ieee80211_supported_band *band; struct brcmf_fil_bwcap_le band_bwcap; struct brcmf_chanspec_list *list; u8 *pbuf; u32 val; int err; struct brcmu_...
0
[ "CWE-787" ]
linux
1b5e2423164b3670e8bc9174e4762d297990deff
177,296,069,623,130,930,000,000,000,000,000,000,000
77
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:...
* %NULL on failure */ struct iscsi_bus_flash_session * iscsi_create_flashnode_sess(struct Scsi_Host *shost, int index, struct iscsi_transport *transport, int dd_size) { struct iscsi_bus_flash_session *fnode_sess; int err; fnode_sess = kzalloc(sizeof(*fnode_sess) + dd_size, GFP_KERNEL); if (!fnode_...
0
[ "CWE-787" ]
linux
ec98ea7070e94cc25a422ec97d1421e28d97b7ee
298,197,815,191,497,340,000,000,000,000,000,000,000
32
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 long btrfs_ioctl_add_dev(struct btrfs_root *root, void __user *arg) { struct btrfs_ioctl_vol_args *vol_args; int ret; if (!capable(CAP_SYS_ADMIN)) return -EPERM; if (atomic_xchg(&root->fs_info->mutually_exclusive_operation_running, 1)) { return BTRFS_ERROR_DEV_EXCL_RUN_IN_PROGRESS; } mutex_lock(&...
0
[ "CWE-200" ]
linux
8039d87d9e473aeb740d4fdbd59b9d2f89b2ced9
13,474,245,797,156,590,000,000,000,000,000,000,000
32
Btrfs: fix file corruption and data loss after cloning inline extents Currently the clone ioctl allows to clone an inline extent from one file to another that already has other (non-inlined) extents. This is a problem because btrfs is not designed to deal with files having inline and regular extents, if a file has an ...
bool __fastcall TRemoteMoveDialog::Execute(UnicodeString & Target, UnicodeString & FileMask) { Combo->Items = CustomWinConfiguration->History[L"RemoteTarget"]; Combo->Text = UnixIncludeTrailingBackslash(Target) + FileMask; bool Result = TCustomDialog::Execute(); if (Result) { Target = UnixExtractFi...
0
[ "CWE-787" ]
winscp
faa96e8144e6925a380f94a97aa382c9427f688d
299,122,003,924,190,260,000,000,000,000,000,000,000
14
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 int __apic_accept_irq(struct kvm_lapic *apic, int delivery_mode, int vector, int level, int trig_mode, struct dest_map *dest_map) { int result = 0; struct kvm_vcpu *vcpu = apic->vcpu; trace_kvm_apic_accept_irq(vcpu->vcpu_id, delivery_mode, trig_mode, vector); switch (delivery_mode) { ...
0
[ "CWE-476" ]
linux
00b5f37189d24ac3ed46cb7f11742094778c46ce
261,355,262,229,064,420,000,000,000,000,000,000,000
95
KVM: x86: Avoid theoretical NULL pointer dereference in kvm_irq_delivery_to_apic_fast() When kvm_irq_delivery_to_apic_fast() is called with APIC_DEST_SELF shorthand, 'src' must not be NULL. Crash the VM with KVM_BUG_ON() instead of crashing the host. Signed-off-by: Vitaly Kuznetsov <vkuznets@redhat.com> Message-Id: <...
static Value performCastDoubleToLong(ExpressionContext* const expCtx, Value inputValue) { double inputDouble = inputValue.getDouble(); validateDoubleValueIsFinite(inputDouble); uassert(ErrorCodes::ConversionFailure, str::stream() << "Conversion would over...
0
[]
mongo
1772b9a0393b55e6a280a35e8f0a1f75c014f301
223,028,947,332,304,100,000,000,000,000,000,000,000
13
SERVER-49404 Enforce additional checks in $arrayToObject
static void usage() { cmdinfo(); fprintf(stderr, "usage:\n"); fprintf(stderr,"%s ", cmdname); fprintf(stderr, "[-f image_file]\n"); exit(EXIT_FAILURE); }
0
[ "CWE-476", "CWE-125" ]
jasper
8f62b4761711d036fd8964df256b938c809b7fca
162,239,402,393,546,230,000,000,000,000,000,000,000
8
Fixed a sanitizer failure in the BMP codec. Also, added a --debug-level command line option to the imginfo command for debugging purposes.
static void __mcheck_cpu_init_timer(void) { struct timer_list *t = this_cpu_ptr(&mce_timer); timer_setup(t, mce_timer_fn, TIMER_PINNED); mce_start_timer(t); }
0
[ "CWE-362" ]
linux
b3b7c4795ccab5be71f080774c45bbbcc75c2aaf
225,455,469,861,365,700,000,000,000,000,000,000,000
7
x86/MCE: Serialize sysfs changes The check_interval file in /sys/devices/system/machinecheck/machinecheck<cpu number> directory is a global timer value for MCE polling. If it is changed by one CPU, mce_restart() broadcasts the event to other CPUs to delete and restart the MCE polling timer and __mcheck_cpu_init_ti...
static void io_submit_flush_completions(struct io_comp_state *cs) { struct io_ring_ctx *ctx = cs->ctx; spin_lock_irq(&ctx->completion_lock); while (!list_empty(&cs->list)) { struct io_kiocb *req; req = list_first_entry(&cs->list, struct io_kiocb, compl.list); list_del(&req->compl.list); __io_cqring_fill_ev...
0
[]
linux
0f2122045b946241a9e549c2a76cea54fa58a7ff
69,433,423,996,166,070,000,000,000,000,000,000,000
26
io_uring: don't rely on weak ->files references Grab actual references to the files_struct. To avoid circular references issues due to this, we add a per-task note that keeps track of what io_uring contexts a task has used. When the tasks execs or exits its assigned files, we cancel requests based on this tracking. W...
ikev1_cr_print(netdissect_options *ndo, u_char tpay _U_, const struct isakmp_gen *ext, u_int item_len, const u_char *ep _U_, uint32_t phase _U_, uint32_t doi0 _U_, uint32_t proto0 _U_, int depth _U_) { const struct ikev1_pl_cert *p; struct ikev1_pl_cert cert; static const char *certstr[] = { ...
1
[ "CWE-125", "CWE-787" ]
tcpdump
8dca25d26c7ca2caf6138267f6f17111212c156e
262,010,346,470,979,620,000,000,000,000,000,000,000
30
CVE-2017-13690/IKEv2: Fix some bounds checks. Use a pointer of the correct type in ND_TCHECK(), or use ND_TCHECK2() and provide the correct length. While we're at it, remove the blank line between some checks and the UNALIGNED_MEMCPY()s they protect. Also, note the places where we print the entire payload. This fix...
void transport_get_fds(rdpTransport* transport, void** rfds, int* rcount) { void* pfd; #ifdef _WIN32 rfds[*rcount] = transport->TcpIn->wsa_event; (*rcount)++; if (transport->SplitInputOutput) { rfds[*rcount] = transport->TcpOut->wsa_event; (*rcount)++; } #else rfds[*rcount] = (void*)(long)(transport->TcpIn...
0
[ "CWE-476", "CWE-125" ]
FreeRDP
0773bb9303d24473fe1185d85a424dfe159aff53
335,441,517,015,292,270,000,000,000,000,000,000,000
43
nla: invalidate sec handle after creation If sec pointer isn't invalidated after creation it is not possible to check if the upper and lower pointers are valid. This fixes a segfault in the server part if the client disconnects before the authentication was finished.
static void evp_cipher_cleanup(struct ssh_cipher_struct *cipher) { if (cipher->ctx != NULL) { EVP_CIPHER_CTX_cleanup(cipher->ctx); EVP_CIPHER_CTX_free(cipher->ctx); } }
0
[ "CWE-476" ]
libssh
b36272eac1b36982598c10de7af0a501582de07a
109,086,525,726,408,300,000,000,000,000,000,000,000
6
CVE-2020-1730: Fix a possible segfault when zeroing AES-CTR key Fixes T213 Signed-off-by: Andreas Schneider <asn@cryptomilk.org> Reviewed-by: Anderson Toshiyuki Sasaki <ansasaki@redhat.com>
getname_kernel(const char * filename) { struct filename *result; int len = strlen(filename) + 1; result = __getname(); if (unlikely(!result)) return ERR_PTR(-ENOMEM); if (len <= EMBEDDED_NAME_MAX) { result->name = (char *)result->iname; } else if (len <= PATH_MAX) { struct filename *tmp; tmp = kmalloc(...
0
[ "CWE-416" ]
linux
f15133df088ecadd141ea1907f2c96df67c729f0
197,278,675,743,077,400,000,000,000,000,000,000,000
33
path_openat(): fix double fput() path_openat() jumps to the wrong place after do_tmpfile() - it has already done path_cleanup() (as part of path_lookupat() called by do_tmpfile()), so doing that again can lead to double fput(). Cc: stable@vger.kernel.org # v3.11+ Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
xmlSchemaPCustomErrExt(xmlSchemaParserCtxtPtr ctxt, xmlParserErrors error, xmlSchemaBasicItemPtr item, xmlNodePtr itemElem, const char *message, const xmlChar *str1, const xmlChar *str2, const xmlChar *str3) { xmlChar *des = NULL, *msg = NULL; xmlSchemaFormatItemForRep...
0
[ "CWE-134" ]
libxml2
4472c3a5a5b516aaf59b89be602fbce52756c3e9
305,164,589,618,281,900,000,000,000,000,000,000,000
22
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.
static int add_partition_to_data(struct ldb_context *ldb, struct partition_private_data *data, struct dsdb_partition *partition) { unsigned int i; int ret; /* Count the partitions */ for (i=0; data->partitions && data->partitions[i]; i++) { /* noop */}; /* Add partition to list of partitions */ data->part...
0
[ "CWE-200" ]
samba
0a3aa5f908e351201dc9c4d4807b09ed9eedff77
189,279,210,399,204,560,000,000,000,000,000,000,000
26
CVE-2022-32746 ldb: Make use of functions for appending to an ldb_message This aims to minimise usage of the error-prone pattern of searching for a just-added message element in order to make modifications to it (and potentially finding the wrong element). BUG: https://bugzilla.samba.org/show_bug.cgi?id=15009 Signed...
static int smack_sb_umount(struct vfsmount *mnt, int flags) { struct superblock_smack *sbp; struct smk_audit_info ad; smk_ad_init(&ad, __func__, LSM_AUDIT_DATA_FS); smk_ad_setfield_u_fs_path_dentry(&ad, mnt->mnt_mountpoint); smk_ad_setfield_u_fs_path_mnt(&ad, mnt); sbp = mnt->mnt_sb->s_security; return smk_cur...
0
[]
linux-2.6
ee18d64c1f632043a02e6f5ba5e045bb26a5465f
197,947,342,287,761,930,000,000,000,000,000,000,000
12
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...
int getGenericCommand(client *c) { robj *o; if ((o = lookupKeyReadOrReply(c,c->argv[1],shared.null[c->resp])) == NULL) return C_OK; if (o->type != OBJ_STRING) { addReply(c,shared.wrongtypeerr); return C_ERR; } else { addReplyBulk(c,o); return C_OK; } }
0
[ "CWE-190" ]
redis
394614a5f91d88380f480c4610926a865b5b0f16
249,750,839,888,082,600,000,000,000,000,000,000,000
14
Fix integer overflow in STRALGO LCS (CVE-2021-29477) An integer overflow bug in Redis version 6.0 or newer could be exploited using the STRALGO LCS command to corrupt the heap and potentially result with remote code execution. (cherry picked from commit f0c5f920d0f88bd8aa376a2c05af4902789d1ef9)
static void suboption(struct Curl_easy *data) { struct curl_slist *v; unsigned char temp[2048]; ssize_t bytes_written; size_t len; int err; char varname[128] = ""; char varval[128] = ""; struct TELNET *tn = data->req.p.telnet; struct connectdata *conn = data->conn; printsub(data, '<', (unsigned cha...
0
[ "CWE-200", "CWE-909" ]
curl
39ce47f219b09c380b81f89fe54ac586c8db6bde
162,263,181,786,713,460,000,000,000,000,000,000,000
69
telnet: check sscanf() for correct number of matches CVE-2021-22898 Bug: https://curl.se/docs/CVE-2021-22898.html
BSONObj CommandHelpers::appendMajorityWriteConcern(const BSONObj& cmdObj) { WriteConcernOptions newWC = kMajorityWriteConcern; if (cmdObj.hasField(kWriteConcernField)) { auto wc = cmdObj.getField(kWriteConcernField); // The command has a writeConcern field and it's majority, so we can /...
0
[ "CWE-20" ]
mongo
722f06f3217c029ef9c50062c8cc775966fd7ead
265,854,605,724,596,630,000,000,000,000,000,000,000
33
SERVER-38275 ban find explain with UUID
Table_check_intact::check(TABLE *table, const TABLE_FIELD_DEF *table_def) { uint i; my_bool error= FALSE; const TABLE_FIELD_TYPE *field_def= table_def->field; DBUG_ENTER("table_check_intact"); DBUG_PRINT("info",("table: %s expected_count: %d", table->alias.c_ptr(), table_def->count)); ...
0
[ "CWE-416" ]
server
4681b6f2d8c82b4ec5cf115e83698251963d80d5
118,895,665,435,070,480,000,000,000,000,000,000,000
188
MDEV-26281 ASAN use-after-poison when complex conversion is involved in blob the bug was that in_vector array in Item_func_in was allocated in the statement arena, not in the table->expr_arena. revert part of the 5acd391e8b2d. Instead, change the arena correctly in fix_all_session_vcol_exprs(). Remove TABLE_ARENA, t...
static enum test_return test_binary_get_impl(const char *key, uint8_t cmd) { union { protocol_binary_request_no_extras request; protocol_binary_response_no_extras response; char bytes[1024]; } send, receive; size_t len = raw_command(send.bytes, sizeof(send.bytes), cmd, ...
0
[ "CWE-20" ]
memcached
75cc83685e103bc8ba380a57468c8f04413033f9
316,899,017,663,320,760,000,000,000,000,000,000,000
46
Issue 102: Piping null to the server will crash it
CJSON_PUBLIC(cJSON *) cJSON_CreateArray(void) { cJSON *item = cJSON_New_Item(&global_hooks); if(item) { item->type=cJSON_Array; } return item; }
0
[ "CWE-754", "CWE-787" ]
cJSON
be749d7efa7c9021da746e685bd6dec79f9dd99b
245,258,329,613,515,130,000,000,000,000,000,000,000
10
Fix crash of cJSON_GetObjectItemCaseSensitive when calling it on arrays
u8 b43_ieee80211_antenna_sanitize(struct b43_wldev *dev, u8 antenna_nr) { u8 antenna_mask; if (antenna_nr == 0) { /* Zero means "use default antenna". That's always OK. */ return 0; } /* Get the mask of available antennas. */ if (dev->phy.gmode) antenna_mask = dev->dev->bus_sprom->ant_available_bg; ...
0
[ "CWE-134" ]
wireless
9538cbaab6e8b8046039b4b2eb6c9d614dc782bd
220,712,353,582,329,100,000,000,000,000,000,000,000
23
b43: stop format string leaking into error msgs The module parameter "fwpostfix" is userspace controllable, unfiltered, and is used to define the firmware filename. b43_do_request_fw() populates ctx->errors[] on error, containing the firmware filename. b43err() parses its arguments as a format string. For systems with...
lt_dlsetsearchpath (const char *search_path) { int errors = 0; FREE (user_search_path); if (!search_path || !LT_STRLEN (search_path)) { return errors; } if (canonicalize_path (search_path, &user_search_path) != 0) ++errors; return errors; }
0
[]
libtool
e91f7b960032074a55fc91273c1917e3082b5338
26,152,265,810,069,126,000,000,000,000,000,000,000
16
Don't load module.la from current directory by default. * libltdl/ltdl.c (try_dlopen): Do not attempt to load an unqualified module.la file from the current directory (by default) since doing so is insecure and is not compliant with the documentation. * tests/testsuite.at: Qualify access to module.la file in current d...
static void handle_invalid_guest_state(struct kvm_vcpu *vcpu, struct kvm_run *kvm_run) { struct vcpu_vmx *vmx = to_vmx(vcpu); enum emulation_result err = EMULATE_DONE; preempt_enable(); local_irq_enable(); while (!guest_state_valid(vcpu)) { err = emulate_instruction(vcpu, kvm_run, 0, 0, 0); if (err == E...
0
[ "CWE-20" ]
linux-2.6
16175a796d061833aacfbd9672235f2d2725df65
72,138,344,135,478,160,000,000,000,000,000,000,000
31
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...
static int ntop_verbose_trace(lua_State* vm) { ntop->getTrace()->traceEvent(TRACE_DEBUG, "%s() called", __FUNCTION__); lua_pushboolean(vm, (ntop->getTrace()->get_trace_level() == MAX_TRACE_LEVEL) ? true : false); return(CONST_LUA_OK); }
0
[ "CWE-476" ]
ntopng
01f47e04fd7c8d54399c9e465f823f0017069f8f
7,600,276,731,693,976,000,000,000,000,000,000,000
6
Security fix: prevents empty host from being used
static int sctp_outq_flush(struct sctp_outq *q, int rtx_timeout) { struct sctp_packet *packet; struct sctp_packet singleton; struct sctp_association *asoc = q->asoc; __u16 sport = asoc->base.bind_addr.port; __u16 dport = asoc->peer.port; __u32 vtag = asoc->peer.i.init_tag; struct sctp_transport *transport = NULL...
1
[]
linux
196d67593439b03088913227093e374235596e33
28,954,651,423,028,803,000,000,000,000,000,000,000
396
sctp: Add support to per-association statistics via a new SCTP_GET_ASSOC_STATS call The current SCTP stack is lacking a mechanism to have per association statistics. This is an implementation modeled after OpenSolaris' SCTP_GET_ASSOC_STATS. Userspace part will follow on lksctp if/when there is a general ACK on this. ...
av_cold void ff_init_scantable(uint8_t *permutation, ScanTable *st, const uint8_t *src_scantable) { int i; int end; st->scantable= src_scantable; for(i=0; i<64; i++){ int j; j = src_scantable[i]; st->permutated[i] = permutation[j]; } end=...
0
[ "CWE-703", "CWE-189" ]
FFmpeg
454a11a1c9c686c78aa97954306fb63453299760
176,643,515,238,679,630,000,000,000,000,000,000,000
22
avcodec/dsputil: fix signedness in sizeof() comparissions Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
static void setup_namespaces(struct lo_data *lo, struct fuse_session *se) { pid_t child; /* * Create a new pid namespace for *child* processes. We'll have to * fork in order to enter the new pid namespace. A new mount namespace * is also needed so that we can remount /proc for the new pid ...
0
[]
qemu
6084633dff3a05d63176e06d7012c7e15aba15be
190,255,656,956,682,740,000,000,000,000,000,000,000
84
tools/virtiofsd: xattr name mappings: Add option Add an option to define mappings of xattr names so that the client and server filesystems see different views. This can be used to have different SELinux mappings as seen by the guest, to run the virtiofsd with less privileges (e.g. in a case where it can't set trusted/...
static void br_ip4_multicast_leave_group(struct net_bridge *br, struct net_bridge_port *port, __be32 group) { struct br_ip br_group; if (ipv4_is_local_multicast(group)) return; br_group.u.ip4 = group; br_group.proto = htons(ETH_P_IP); br_multicast_leave_group(br, port, &br_group); }
0
[ "CWE-399" ]
linux
6b0d6a9b4296fa16a28d10d416db7a770fc03287
140,614,751,852,285,180,000,000,000,000,000,000,000
14
bridge: Fix mglist corruption that leads to memory corruption The list mp->mglist is used to indicate whether a multicast group is active on the bridge interface itself as opposed to one of the constituent interfaces in the bridge. Unfortunately the operation that adds the mp->mglist node to the list neglected to che...
static sctp_disposition_t sctp_sf_violation_paramlen( const struct sctp_endpoint *ep, const struct sctp_association *asoc, const sctp_subtype_t type, void *arg, void *ext, sctp_cmd_seq_t *commands) { struct sctp_chunk *chunk = arg; struct sctp_paramhdr *param = ext; stru...
0
[ "CWE-119" ]
linux-2.6
9fcb95a105758b81ef0131cd18e2db5149f13e95
126,512,961,201,879,580,000,000,000,000,000,000,000
35
sctp: Avoid memory overflow while FWD-TSN chunk is received with bad stream ID If FWD-TSN chunk is received with bad stream ID, the sctp will not do the validity check, this may cause memory overflow when overwrite the TSN of the stream ID. The FORWARD-TSN chunk is like this: FORWARD-TSN chunk Type ...
static u16 xennet_select_queue(struct net_device *dev, struct sk_buff *skb, struct net_device *sb_dev) { unsigned int num_queues = dev->real_num_tx_queues; u32 hash; u16 queue_idx; /* First, check if there is only one queue */ if (num_queues == 1) { queue_idx = 0; } else { hash = skb_get_hash(skb);...
0
[]
linux
f63c2c2032c2e3caad9add3b82cc6e91c376fd26
111,790,671,989,484,200,000,000,000,000,000,000,000
17
xen-netfront: restore __skb_queue_tail() positioning in xennet_get_responses() The commit referenced below moved the invocation past the "next" label, without any explanation. In fact this allows misbehaving backends undue control over the domain the frontend runs in, as earlier detected errors require the skb to not ...
static int pfkey_xfrm_policy2msg(struct sk_buff *skb, const struct xfrm_policy *xp, int dir) { struct sadb_msg *hdr; struct sadb_address *addr; struct sadb_lifetime *lifetime; struct sadb_x_policy *pol; struct sadb_x_sec_ctx *sec_ctx; struct xfrm_sec_ctx *xfrm_ctx; int i; int size; int sockaddr_size = pfkey_so...
0
[]
linux
096f41d3a8fcbb8dde7f71379b1ca85fe213eded
289,397,153,842,632,800,000,000,000,000,000,000,000
154
af_key: Fix sadb_x_ipsecrequest parsing The parsing of sadb_x_ipsecrequest is broken in a number of ways. First of all we're not verifying sadb_x_ipsecrequest_len. This is needed when the structure carries addresses at the end. Worse we don't even look at the length when we parse those optional addresses. The migra...
static UserName extractUserNameFromBSON(const BSONObj& userObj) { std::string name; std::string db; Status status = bsonExtractStringField(userObj, AuthorizationManager::USER_NAME_FIELD_NAME, &name); uassertStatusOK(status); status = bsonExtractStringField(userObj...
0
[ "CWE-613" ]
mongo
e55d6e2292e5dbe2f97153251d8193d1cc89f5d7
83,891,067,801,508,870,000,000,000,000,000,000,000
10
SERVER-38984 Validate unique User ID on UserCache hit
int Field_str::store(longlong nr, bool unsigned_val) { char buff[64]; uint length; length= (uint) (field_charset->cset->longlong10_to_str)(field_charset, buff, sizeof(buff), ...
0
[ "CWE-416", "CWE-703" ]
server
08c7ab404f69d9c4ca6ca7a9cf7eec74c804f917
225,220,348,068,259,840,000,000,000,000,000,000,000
12
MDEV-24176 Server crashes after insert in the table with virtual column generated using date_format() and if() vcol_info->expr is allocated on expr_arena at parsing stage. Since expr item is allocated on expr_arena all its containee items must be allocated on expr_arena too. Otherwise fix_session_expr() will encounter...
_get_user_env(batch_job_launch_msg_t *req) { struct passwd pwd, *pwd_ptr = NULL; char pwd_buf[PW_BUF_SIZE]; char **new_env; int i; static time_t config_update = 0; static bool no_env_cache = false; if (config_update != conf->last_update) { char *sched_params = slurm_get_sched_params(); no_env_cache = (sched...
0
[ "CWE-20" ]
slurm
df545955e4f119974c278bff0c47155257d5afc7
122,162,760,716,756,300,000,000,000,000,000,000,000
48
Validate gid and user_name values provided to slurmd up front. Do not defer until later, and do not potentially miss out on proper validation of the user_name field which can lead to improper authentication handling. CVE-2018-10995.
s16 rssi_compensation_calc(struct ar6_softc *ar, s16 rssi) { if (ar->arBssChannel > 5000) { if (rssi_compensation_param.enable) { AR_DEBUG_PRINTF(ATH_DEBUG_INFO, (">>> 11a\n")); AR_DEBUG_PRINTF(ATH_DEBUG_INFO, ("rssi before compensation = %d\n", rssi)); rssi ...
0
[ "CWE-703", "CWE-264" ]
linux
550fd08c2cebad61c548def135f67aba284c6162
16,538,668,955,919,197,000,000,000,000,000,000,000
27
net: Audit drivers to identify those needing IFF_TX_SKB_SHARING cleared After the last patch, We are left in a state in which only drivers calling ether_setup have IFF_TX_SKB_SHARING set (we assume that drivers touching real hardware call ether_setup for their net_devices and don't hold any state in their skbs. There...
add_durable_v2_context(struct kvec *iov, unsigned int *num_iovec, struct cifs_open_parms *oparms) { struct smb2_create_req *req = iov[0].iov_base; unsigned int num = *num_iovec; iov[num].iov_base = create_durable_v2_buf(oparms); if (iov[num].iov_base == NULL) return -ENOMEM; iov[num].iov_len = sizeof(stru...
0
[ "CWE-416", "CWE-200" ]
linux
6a3eb3360667170988f8a6477f6686242061488a
287,078,085,080,108,840,000,000,000,000,000,000,000
18
cifs: Fix use-after-free in SMB2_write There is a KASAN use-after-free: BUG: KASAN: use-after-free in SMB2_write+0x1342/0x1580 Read of size 8 at addr ffff8880b6a8e450 by task ln/4196 Should not release the 'req' because it will use in the trace. Fixes: eccb4422cf97 ("smb3: Add ftrace tracepoints for improved SMB3 de...
ParseState(PolicyParser* pp, const Keyword* w) : pp(pp), w(w) {}
0
[ "CWE-617" ]
ceph
b3118cabb8060a8cc6a01c4e8264cb18e7b1745a
156,425,447,627,573,610,000,000,000,000,000,000,000
2
rgw: Remove assertions in IAM Policy A couple of them could be triggered by user input. Signed-off-by: Adam C. Emerson <aemerson@redhat.com>
parser_parse_object_initializer (parser_context_t *context_p, /**< context */ parser_pattern_flags_t flags) /**< flags */ { parser_pattern_end_marker_t end_pos = parser_pattern_get_target (context_p, flags); /* 12.14.5.2: ObjectAssignmentPattern : { } */ if (lexer_check_next_cha...
0
[ "CWE-416" ]
jerryscript
3bcd48f72d4af01d1304b754ef19fe1a02c96049
254,709,296,871,445,630,000,000,000,000,000,000,000
149
Improve parse_identifier (#4691) Ascii string length is no longer computed during string allocation. JerryScript-DCO-1.0-Signed-off-by: Daniel Batiz batizjob@gmail.com
size_t jsuGetFreeStack() { #ifdef ARM void *frame = __builtin_frame_address(0); size_t stackPos = (size_t)((char*)frame); size_t stackEnd = (size_t)((char*)&LINKER_END_VAR); if (stackPos < stackEnd) return 0; // should never happen, but just in case of overflow! return stackPos - stackEnd; #elif defined(LINU...
0
[ "CWE-119", "CWE-787" ]
Espruino
0a7619875bf79877907205f6bee08465b89ff10b
86,633,633,545,772,160,000,000,000,000,000,000,000
20
Fix strncat/cpy bounding issues (fix #1425)
alloc_compspace(isc_httpd_t *httpd, unsigned int size) { char *newspace = NULL; isc_region_t r; isc_buffer_region(&httpd->compbuffer, &r); if (size < r.length) { return; } newspace = isc_mem_get(httpd->mgr->mctx, size); isc_buffer_reinit(&httpd->compbuffer, newspace, size); if (r.base != NULL) { isc_mem_...
0
[]
bind9
d4c5d1c650ae0e97a083b0ce7a705c20fc001f07
270,709,720,787,245,800,000,000,000,000,000,000,000
16
Fix statistics channel multiple request processing with non-empty bodies When the HTTP request has a body part after the HTTP headers, it is not getting processed and is being prepended to the next request's data, which results in an error when trying to parse it. Improve the httpd.c:process_request() function with t...
maybe_send_secure(dns_zone_t *zone) { isc_result_t result; /* * We've finished loading, or else failed to load, an inline-signing * 'secure' zone. We now need information about the status of the * 'raw' zone. If we failed to load, then we need it to send a * copy of its database; if we succeeded, we need i...
0
[ "CWE-327" ]
bind9
f09352d20a9d360e50683cd1d2fc52ccedcd77a0
325,477,012,273,263,600,000,000,000,000,000,000,000
28
Update keyfetch_done compute_tag check If in keyfetch_done the compute_tag fails (because for example the algorithm is not supported), don't crash, but instead ignore the key.
static int reg_event_syscall_enter(struct ftrace_event_file *file, struct ftrace_event_call *call) { struct trace_array *tr = file->tr; int ret = 0; int num; num = ((struct syscall_metadata *)call->data)->syscall_nr; if (WARN_ON_ONCE(num < 0 || num >= NR_syscalls)) return -ENOSYS; mutex_lock(&syscall_tr...
0
[ "CWE-125", "CWE-476", "CWE-119", "CWE-264" ]
linux
086ba77a6db00ed858ff07451bedee197df868c9
133,683,009,287,343,340,000,000,000,000,000,000,000
20
tracing/syscalls: Ignore numbers outside NR_syscalls' range ARM has some private syscalls (for example, set_tls(2)) which lie outside the range of NR_syscalls. If any of these are called while syscall tracing is being performed, out-of-bounds array access will occur in the ftrace and perf sys_{enter,exit} handlers. ...
static void cirrus_update_bank_ptr(CirrusVGAState * s, unsigned bank_index) { unsigned offset; unsigned limit; if ((s->vga.gr[0x0b] & 0x01) != 0) /* dual bank */ offset = s->vga.gr[0x09 + bank_index]; else /* single bank */ offset = s->vga.gr[0x09]; if ((s->vga.gr[0x0b] & 0x20) != 0) offset <...
0
[ "CWE-119" ]
qemu
026aeffcb4752054830ba203020ed6eb05bcaba8
114,277,140,663,719,480,000,000,000,000,000,000,000
37
cirrus: stop passing around dst pointers in the blitter Instead pass around the address (aka offset into vga memory). Calculate the pointer in the rop_* functions, after applying the mask to the address, to make sure the address stays within the valid range. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com> Message-i...
static int iowarrior_open(struct inode *inode, struct file *file) { struct iowarrior *dev = NULL; struct usb_interface *interface; int subminor; int retval = 0; mutex_lock(&iowarrior_mutex); subminor = iminor(inode); interface = usb_find_interface(&iowarrior_driver, subminor); if (!interface) { mutex_unlock...
0
[ "CWE-703" ]
linux
4ec0ef3a82125efc36173062a50624550a900ae0
53,843,067,312,119,430,000,000,000,000,000,000,000
52
USB: iowarrior: fix oops with malicious USB descriptors The iowarrior driver expects at least one valid endpoint. If given malicious descriptors that specify 0 for the number of endpoints, it will crash in the probe function. Ensure there is at least one endpoint on the interface before using it. The full report of...
template<typename t> CImg<T>& operator+=(const t value) { if (is_empty()) return *this; cimg_openmp_for(*this,*ptr + value,524288); return *this;
0
[ "CWE-119", "CWE-787" ]
CImg
ac8003393569aba51048c9d67e1491559877b1d1
162,058,484,971,064,710,000,000,000,000,000,000,000
5
.
static int mpage_da_map_blocks(struct mpage_da_data *mpd) { int err, blks, get_blocks_flags; struct buffer_head new; sector_t next = mpd->b_blocknr; unsigned max_blocks = mpd->b_size >> mpd->inode->i_blkbits; loff_t disksize = EXT4_I(mpd->inode)->i_disksize; handle_t *handle = NULL; /* * We consider only non-...
1
[ "CWE-703" ]
linux
744692dc059845b2a3022119871846e74d4f6e11
87,840,566,716,022,190,000,000,000,000,000,000,000
124
ext4: use ext4_get_block_write in buffer write Allocate uninitialized extent before ext4 buffer write and convert the extent to initialized after io completes. The purpose is to make sure an extent can only be marked initialized after it has been written with new data so we can safely drop the i_mutex lock in ext4 DIO...
static void tc_chain_tmplt_del(const struct tcf_proto_ops *tmplt_ops, void *tmplt_priv) { /* If template ops are set, no work to do for us. */ if (!tmplt_ops) return; tmplt_ops->tmplt_destroy(tmplt_priv); module_put(tmplt_ops->owner); }
0
[ "CWE-416" ]
linux
04c2a47ffb13c29778e2a14e414ad4cb5a5db4b5
158,537,608,382,966,400,000,000,000,000,000,000,000
10
net: sched: fix use-after-free in tc_new_tfilter() Whenever tc_new_tfilter() jumps back to replay: label, we need to make sure @q and @chain local variables are cleared again, or risk use-after-free as in [1] For consistency, apply the same fix in tc_ctl_chain() BUG: KASAN: use-after-free in mini_qdisc_pair_swap+0x1...
static int __init pep_register(void) { return phonet_proto_register(PN_PROTO_PIPE, &pep_pn_proto); }
0
[ "CWE-200" ]
net
bcd0f93353326954817a4f9fa55ec57fb38acbb0
316,291,219,715,020,100,000,000,000,000,000,000,000
4
phonet: refcount leak in pep_sock_accep sock_hold(sk) is invoked in pep_sock_accept(), but __sock_put(sk) is not invoked in subsequent failure branches(pep_accept_conn() != 0). Signed-off-by: Hangyu Hua <hbh25y@gmail.com> Link: https://lore.kernel.org/r/20211209082839.33985-1-hbh25y@gmail.com Signed-off-by: Jakub Kic...
static int StreamTcpTest03 (void) { Packet *p = SCMalloc(SIZE_OF_PACKET); if (unlikely(p == NULL)) return 0; Flow f; ThreadVars tv; StreamTcpThread stt; TCPHdr tcph; memset(p, 0, SIZE_OF_PACKET); PacketQueue pq; memset(&pq,0,sizeof(PacketQueue)); memset (&f, 0, sizeof(Flo...
0
[]
suricata
843d0b7a10bb45627f94764a6c5d468a24143345
71,265,576,554,856,060,000,000,000,000,000,000,000
67
stream: support RST getting lost/ignored In case of a valid RST on a SYN, the state is switched to 'TCP_CLOSED'. However, the target of the RST may not have received it, or may not have accepted it. Also, the RST may have been injected, so the supposed sender may not actually be aware of the RST that was sent in it's ...
R_API DsoJsonObj *r_bin_java_get_field_json_definition(RBinJavaObj *bin, RBinJavaField *fm_type) { return r_bin_java_get_fm_type_definition_json (bin, fm_type, 0); }
0
[ "CWE-119", "CWE-788" ]
radare2
6c4428f018d385fc80a33ecddcb37becea685dd5
43,071,057,170,258,710,000,000,000,000,000,000,000
3
Improve boundary checks to fix oobread segfaults ##crash * Reported by Cen Zhang via huntr.dev * Reproducer: bins/fuzzed/javaoob-havoc.class
yang_read_enum(struct ly_ctx *ctx, struct yang_type *typ, struct lys_type_enum *enm, char *value) { int i, j; typ->base = LY_TYPE_ENUM; if (!value[0]) { LOGVAL(ctx, LYE_INARG, LY_VLOG_NONE, NULL, value, "enum name"); LOGVAL(ctx, LYE_SPEC, LY_VLOG_NONE, NULL, "Enum name must not be empty.");...
0
[ "CWE-415" ]
libyang
d9feacc4a590d35dbc1af21caf9080008b4450ed
13,946,486,884,294,074,000,000,000,000,000,000,000
34
yang parser BUGFIX double free Fixes #742
virDomainDefMaybeAddInput(virDomainDefPtr def, int type, int bus) { size_t i; virDomainInputDefPtr input; for (i = 0; i < def->ninputs; i++) { if (def->inputs[i]->type == type && def->inputs[i]->bus == bus) return 0; } ...
0
[ "CWE-212" ]
libvirt
a5b064bf4b17a9884d7d361733737fb614ad8979
11,508,037,350,408,305,000,000,000,000,000,000,000
26
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...
WasmResult Context::getDownstreamDataBufferBytes(uint32_t start, uint32_t length, absl::string_view* data) { if (!network_downstream_data_buffer_) return WasmResult::NotFound; if (network_downstream_data_buffer_->length() < static_cast<uint64_t>(start + length)) ...
0
[ "CWE-476" ]
envoy
8788a3cf255b647fd14e6b5e2585abaaedb28153
159,055,531,158,535,100,000,000,000,000,000,000,000
11
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...
void bdrv_ref(BlockDriverState *bs) { bs->refcnt++; }
0
[ "CWE-190" ]
qemu
8f4754ede56e3f9ea3fd7207f4a7c4453e59285b
276,778,069,617,096,750,000,000,000,000,000,000,000
4
block: Limit request size (CVE-2014-0143) Limiting the size of a single request to INT_MAX not only fixes a direct integer overflow in bdrv_check_request() (which would only trigger bad behaviour with ridiculously huge images, as in close to 2^64 bytes), but can also prevent overflows in all block drivers. Signed-off...
inline uint8_t* WireFormatLite::WriteUInt32NoTagToArray( const RepeatedField<uint32_t>& value, uint8_t* target) { return WritePrimitiveNoTagToArray(value, WriteUInt32NoTagToArray, target); }
0
[ "CWE-703" ]
protobuf
d1635e1496f51e0d5653d856211e8821bc47adc4
150,959,669,774,310,880,000,000,000,000,000,000,000
4
Apply patch
HTTPSession::onEgressMessageFinished(HTTPTransaction* txn, bool withRST) { // If the semantics of the protocol don't permit more messages // to be read or sent on this connection, close the socket in one or // more directions. CHECK(!transactions_.empty()); if (infoCallback_) { infoCallback_->onRequestEn...
0
[ "CWE-20" ]
proxygen
0600ebe59c3e82cd012def77ca9ca1918da74a71
167,973,455,483,119,480,000,000,000,000,000,000,000
46
Check that a secondary auth manager is set before dereferencing. Summary: CVE-2018-6343 Reviewed By: mingtaoy Differential Revision: D12994423 fbshipit-source-id: 9229ec11da8085f1fa153595e8e5353e19d06fb7
bool open_and_set_current(const char *name) { FILE *opened= fopen(name, "rb"); if (!opened) return false; cur_file++; cur_file->file= opened; cur_file->file_name= my_strdup(name, MYF(MY_FAE)); cur_file->lineno=1; return true; }
0
[]
server
01b39b7b0730102b88d8ea43ec719a75e9316a1e
284,848,898,834,695,440,000,000,000,000,000,000,000
13
mysqltest: don't eat new lines in --exec pass them through as is
static MagickBooleanType IsDCM(const unsigned char *magick,const size_t length) { if (length < 132) return(MagickFalse); if (LocaleNCompare((char *) (magick+128),"DICM",4) == 0) return(MagickTrue); return(MagickFalse); }
0
[ "CWE-20", "CWE-476", "CWE-369" ]
ImageMagick
5511ef530576ed18fd636baa3bb4eda3d667665d
132,970,711,497,427,090,000,000,000,000,000,000,000
8
Add additional checks to DCM reader to prevent data-driven faults (bug report from Hanno Böck
static int if6_seq_open(struct inode *inode, struct file *file) { return seq_open_net(inode, file, &if6_seq_ops, sizeof(struct if6_iter_state)); }
0
[]
net
4b08a8f1bd8cb4541c93ec170027b4d0782dab52
52,106,196,926,129,970,000,000,000,000,000,000,000
5
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 CURLcode parse_url_login(struct SessionHandle *data, struct connectdata *conn, char **user, char **passwd, char **options) { CURLcode result = CURLE_OK; char *userp = NULL; char *passwdp = NULL; char *optionsp = NULL; /* At this point, we...
0
[ "CWE-264" ]
curl
31be461c6b659312100c47be6ddd5f0f569290f6
172,558,666,533,662,100,000,000,000,000,000,000,000
97
ConnectionExists: for NTLM re-use, require credentials to match CVE-2015-3143 Bug: http://curl.haxx.se/docs/adv_20150422A.html Reported-by: Paras Sethia
MagickExport void GetNextToken(const char *start,const char **end, const size_t extent,char *token) { double value; register const char *p; register ssize_t i; size_t length; assert(start != (const char *) NULL); assert(token != (char *) NULL); i=0; length=strlen(start); p=start;...
0
[ "CWE-125" ]
ImageMagick
787f9dc99c8d186ae26ed53ddec54bd0a6f90852
132,726,129,514,756,250,000,000,000,000,000,000,000
141
https://github.com/ImageMagick/ImageMagick/issues/539
cachedb_apply_cfg(struct cachedb_env* cachedb_env, struct config_file* cfg) { const char* backend_str = cfg->cachedb_backend; cachedb_env->backend = cachedb_find_backend(backend_str); if(!cachedb_env->backend) { log_err("cachedb: cannot find backend name '%s'", backend_str); return 0; } /* TODO see if more co...
0
[ "CWE-613", "CWE-703" ]
unbound
f6753a0f1018133df552347a199e0362fc1dac68
9,284,840,782,224,979,000,000,000,000,000,000,000
12
- Fix the novel ghost domain issues CVE-2022-30698 and CVE-2022-30699.
receive_check_set_sender(uschar *newsender) { uschar *qnewsender; if (trusted_caller) return TRUE; if (!newsender || !untrusted_set_sender) return FALSE; qnewsender = Ustrchr(newsender, '@') ? newsender : string_sprintf("%s@%s", newsender, qualify_domain_sender); return match_address_list_basic(qnewsender, CUSS &untr...
0
[ "CWE-416" ]
exim
4e6ae6235c68de243b1c2419027472d7659aa2b4
59,958,590,008,539,160,000,000,000,000,000,000,000
9
Avoid release of store if there have been later allocations. Bug 2199
static void sas_print_parent_topology_bug(struct domain_device *child, struct ex_phy *parent_phy, struct ex_phy *child_phy) { static const char *ex_type[] = { [SAS_EDGE_EXPANDER_DEVICE] = "edge", [SAS_FANOUT_EXPANDER_DEVICE] = "fanout", }; struct domain_device *parent = child->parent; sas_printk(...
0
[ "CWE-399", "CWE-772" ]
linux
4a491b1ab11ca0556d2fda1ff1301e862a2d44c4
275,607,837,713,256,700,000,000,000,000,000,000,000
24
scsi: libsas: fix memory leak in sas_smp_get_phy_events() We've got a memory leak with the following producer: while true; do cat /sys/class/sas_phy/phy-1:0:12/invalid_dword_count >/dev/null; done The buffer req is allocated and not freed after we return. Fix it. Fixes: 2908d778ab3e ("[SCSI] aic94xx: new driver") S...
displayBuffer(Buffer *buf, int mode) { Str msg; int ny = 0; if (!buf) return; if (buf->topLine == NULL && readBufferCache(buf) == 0) { /* clear_buffer */ mode = B_FORCE_REDRAW; } if (buf->width == 0) buf->width = INIT_BUFFER_WIDTH; if (buf->height == 0) buf->height = LASTLINE + 1; ...
0
[ "CWE-119" ]
w3m
0c3f5d0e0d9269ad47b8f4b061d7818993913189
226,611,692,398,154,230,000,000,000,000,000,000,000
134
Prevent array index out of bounds for symbol Bug-Debian: https://github.com/tats/w3m/issues/38
xmlParseEntityDecl(xmlParserCtxtPtr ctxt) { const xmlChar *name = NULL; xmlChar *value = NULL; xmlChar *URI = NULL, *literal = NULL; const xmlChar *ndata = NULL; int isParameter = 0; xmlChar *orig = NULL; int skipped; /* GROW; done in the caller */ if (CMP8(CUR_PTR, '<', '!', 'E', '...
0
[ "CWE-119" ]
libxml2
a7dfab7411cbf545f359dd3157e5df1eb0e7ce31
254,152,679,003,082,600,000,000,000,000,000,000,000
247
Stop parsing on entities boundaries errors For https://bugzilla.gnome.org/show_bug.cgi?id=744980 There are times, like on unterminated entities that it's preferable to stop parsing, even if that means less error reporting. Entities are feeding the parser on further processing, and if they are ill defined then it's po...
static int nft_fwd_neigh_init(const struct nft_ctx *ctx, const struct nft_expr *expr, const struct nlattr * const tb[]) { struct nft_fwd_neigh *priv = nft_expr_priv(expr); unsigned int addr_len; int err; if (!tb[NFTA_FWD_SREG_DEV] || !tb[NFTA_FWD_SREG_ADDR] || !tb[NFTA_FWD_NFPROTO]) r...
0
[ "CWE-269" ]
nf
b1a5983f56e371046dcf164f90bfaf704d2b89f6
119,116,992,808,546,170,000,000,000,000,000,000,000
34
netfilter: nf_tables_offload: incorrect flow offload action array size immediate verdict expression needs to allocate one slot in the flow offload action array, however, immediate data expression does not need to do so. fwd and dup expression need to allocate one slot, this is missing. Add a new offload_action inter...
static void *tcp_seq_start(struct seq_file *seq, loff_t *pos) { struct tcp_iter_state *st = seq->private; void *rc; if (*pos && *pos == st->last_pos) { rc = tcp_seek_last_pos(seq); if (rc) goto out; } st->state = TCP_SEQ_STATE_LISTENING; st->num = 0; st->bucket = 0; st->offset = 0; rc = *pos ? tcp_get...
0
[ "CWE-362" ]
linux-2.6
f6d8bd051c391c1c0458a30b2a7abcd939329259
19,255,753,709,105,548,000,000,000,000,000,000,000
21
inet: add RCU protection to inet->opt We lack proper synchronization to manipulate inet->opt ip_options Problem is ip_make_skb() calls ip_setup_cork() and ip_setup_cork() possibly makes a copy of ipc->opt (struct ip_options), without any protection against another thread manipulating inet->opt. Another thread can ch...
static int wsgi_hook_intercept(request_rec *r) { WSGIServerConfig *config = NULL; apr_array_header_t *aliases = NULL; WSGIAliasEntry *entries = NULL; WSGIAliasEntry *entry = NULL; ap_regmatch_t matches[AP_MAX_REG_MATCH]; const char *location = NULL; const char *application = NULL; i...
0
[ "CWE-264" ]
mod_wsgi
d9d5fea585b23991f76532a9b07de7fcd3b649f4
125,228,609,060,686,130,000,000,000,000,000,000,000
89
Local privilege escalation when using daemon mode. (CVE-2014-0240)
static void opj_j2k_tcp_data_destroy(opj_tcp_t *p_tcp) { if (p_tcp->m_data) { opj_free(p_tcp->m_data); p_tcp->m_data = NULL; p_tcp->m_data_size = 0; } }
0
[ "CWE-416", "CWE-787" ]
openjpeg
4241ae6fbbf1de9658764a80944dc8108f2b4154
296,829,233,707,920,100,000,000,000,000,000,000,000
8
Fix assertion in debug mode / heap-based buffer overflow in opj_write_bytes_LE for Cinema profiles with numresolutions = 1 (#985)
gdm_session_answer_query (GdmSession *self, const char *service_name, const char *text) { GdmSessionConversation *conversation; g_return_if_fail (GDM_IS_SESSION (self)); conversation = find_conversation_by_name (self, service_name); ...
0
[]
gdm
5ac224602f1d603aac5eaa72e1760d3e33a26f0a
134,211,993,191,336,130,000,000,000,000,000,000,000
14
session: disconnect signals from worker proxy when conversation is freed We don't want an outstanding reference on the worker proxy to lead to signal handlers getting dispatched after the conversation is freed. https://bugzilla.gnome.org/show_bug.cgi?id=758032
static inline Quantum ClampPixel(const MagickRealType value) { #if !defined(MAGICKCORE_HDRI_SUPPORT) return((Quantum) value); #else if (value < 0.0f) return(0.0); if (value >= (MagickRealType) QuantumRange) return((Quantum) QuantumRange); return(value); #endif }
1
[ "CWE-119", "CWE-787" ]
ImageMagick
450bd716ed3b9186dd10f9e60f630a3d9eeea2a4
166,207,034,266,473,880,000,000,000,000,000,000,000
12
PHP_FUNCTION(chdir) { char *str; int ret, str_len; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &str, &str_len) == FAILURE) { RETURN_FALSE; } if ((PG(safe_mode) && !php_checkuid(str, NULL, CHECKUID_CHECK_FILE_AND_DIR)) || php_check_open_basedir(str TSRMLS_CC)) { RETURN_FALSE; } ret = VCWD_CHD...
1
[]
php-src
ce96fd6b0761d98353761bf78d5bfb55291179fd
159,661,868,390,382,330,000,000,000,000,000,000,000
30
- 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
void dd_create_basic_files(struct dump_dir *dd, uid_t uid, const char *chroot_dir) { char long_str[sizeof(long) * 3 + 2]; char *time_str = dd_load_text_ext(dd, FILENAME_TIME, DD_FAIL_QUIETLY_ENOENT | DD_LOAD_TEXT_RETURN_NULL_ON_FAILURE); if (!time_str) { time_t t = time(NULL...
0
[ "CWE-264" ]
libreport
3bbf961b1884dd32654dd39b360dd78ef294b10a
182,654,921,728,357,670,000,000,000,000,000,000,000
54
never follow symlinks rhbz#887866 - use lchown instead chown and O_NOFOLLOW where we use open
decompression_cleanup(struct archive_read *a) { struct xar *xar; int r; xar = (struct xar *)(a->format->data); r = ARCHIVE_OK; if (xar->stream_valid) { if (inflateEnd(&(xar->stream)) != Z_OK) { archive_set_error(&a->archive, ARCHIVE_ERRNO_MISC, "Failed to clean up zlib decompressor"); r = AR...
0
[ "CWE-125" ]
libarchive
fa7438a0ff4033e4741c807394a9af6207940d71
96,856,908,394,834,760,000,000,000,000,000,000,000
40
Do something sensible for empty strings to make fuzzers happy.
static int sas_get_phy_change_count(struct domain_device *dev, int phy_id, int *pcc) { int res; struct smp_resp *disc_resp; disc_resp = alloc_smp_resp(DISCOVER_RESP_SIZE); if (!disc_resp) return -ENOMEM; res = sas_get_phy_discover(dev, phy_id, disc_resp); if (!res) *pcc = disc_resp->disc.change_coun...
0
[ "CWE-399", "CWE-772" ]
linux
4a491b1ab11ca0556d2fda1ff1301e862a2d44c4
136,404,262,884,464,400,000,000,000,000,000,000,000
17
scsi: libsas: fix memory leak in sas_smp_get_phy_events() We've got a memory leak with the following producer: while true; do cat /sys/class/sas_phy/phy-1:0:12/invalid_dword_count >/dev/null; done The buffer req is allocated and not freed after we return. Fix it. Fixes: 2908d778ab3e ("[SCSI] aic94xx: new driver") S...
#else static inline unsigned char *skb_end_pointer(const struct sk_buff *skb) { return skb->end;
0
[ "CWE-20" ]
linux
2b16f048729bf35e6c28a40cbfad07239f9dcd90
259,928,556,977,425,270,000,000,000,000,000,000,000
4
net: create skb_gso_validate_mac_len() If you take a GSO skb, and split it into packets, will the MAC length (L2 + L3 + L4 headers + payload) of those packets be small enough to fit within a given length? Move skb_gso_mac_seglen() to skbuff.h with other related functions like skb_gso_network_seglen() so we can use it...
fill_body (mu_message_t msg, mu_stream_t instr) { int rc; mu_body_t body = NULL; mu_stream_t stream = NULL; mu_off_t n; rc = mu_message_get_body (msg, &body); if (rc) { mu_error (_("cannot get message body: %s"), mu_strerror (rc)); return 1; } rc = mu_body_get_streamref (body, &stre...
0
[]
mailutils
4befcfd015256c568121653038accbd84820198f
126,786,308,018,188,850,000,000,000,000,000,000,000
44
mail: disable compose escapes in non-interctive mode. * NEWS: Document changes. * doc/texinfo/programs/mail.texi: Document changes. * mail/send.c (mail_compose_send): Recognize escapes only in interactive mode.
HTTPSession::onMessageBegin(HTTPCodec::StreamID streamID, HTTPMessage* msg) { VLOG(4) << "processing new msg streamID=" << streamID << " " << *this; if (infoCallback_) { infoCallback_->onRequestBegin(*this); } HTTPTransaction* txn = findTransaction(streamID); if (txn) { if (isDownstream() && txn->isP...
0
[ "CWE-20" ]
proxygen
0600ebe59c3e82cd012def77ca9ca1918da74a71
154,318,022,484,106,300,000,000,000,000,000,000,000
53
Check that a secondary auth manager is set before dereferencing. Summary: CVE-2018-6343 Reviewed By: mingtaoy Differential Revision: D12994423 fbshipit-source-id: 9229ec11da8085f1fa153595e8e5353e19d06fb7
poolBytesToAllocateFor(int blockSize) { /* Unprotected math would be: ** return offsetof(BLOCK, s) + blockSize * sizeof(XML_Char); ** ** Detect overflow, avoiding _signed_ overflow undefined behavior ** For a + b * c we check b * c in isolation first, so that addition of a ** on top has no chance of making ...
0
[ "CWE-611" ]
libexpat
c4bf96bb51dd2a1b0e185374362ee136fe2c9d7f
273,616,023,796,867,120,000,000,000,000,000,000,000
27
xmlparse.c: Fix external entity infinite loop bug (CVE-2017-9233)
TEST_F(SingleAllowMissingInOrListTest, BadJwt) { EXPECT_CALL(mock_cb_, onComplete(Status::JwtExpired)); auto headers = Http::TestRequestHeaderMapImpl{{kExampleHeader, ExpiredToken}}; context_ = Verifier::createContext(headers, parent_span_, &mock_cb_); verifier_->verify(context_); EXPECT_THAT(headers, JwtOutp...
0
[ "CWE-303", "CWE-703" ]
envoy
ea39e3cba652bcc4b11bb0d5c62b017e584d2e5a
232,355,746,841,532,500,000,000,000,000,000,000,000
7
jwt_authn: fix a bug where JWT with wrong issuer is allowed in allow_missing case (#15194) [jwt] When allow_missing is used inside RequiresAny, the requests with JWT with wrong issuer are accepted. This is a bug, allow_missing should only allow requests without any JWT. This change fixed the above issue by preserving ...
adjust_poll(int count) { G.polladj_count += count; if (G.polladj_count > POLLADJ_LIMIT) { G.polladj_count = 0; if (G.poll_exp < MAXPOLL) { G.poll_exp++; VERB4 bb_error_msg("polladj: discipline_jitter:%f ++poll_exp=%d", G.discipline_jitter, G.poll_exp); } } else if (G.polladj_count < -POLLADJ_LIMIT |...
0
[ "CWE-399" ]
busybox
150dc7a2b483b8338a3e185c478b4b23ee884e71
44,402,456,706,216,170,000,000,000,000,000,000,000
34
ntpd: respond only to client and symmetric active packets The busybox NTP implementation doesn't check the NTP mode of packets received on the server port and responds to any packet with the right size. This includes responses from another NTP server. An attacker can send a packet with a spoofed source address in orde...
e_mail_formatter_format_text_header (EMailFormatter *formatter, GString *buffer, const gchar *label, const gchar *value, guint32 flags) { GtkTextDirection direction; cons...
0
[ "CWE-347" ]
evolution
f66cd3e1db301d264563b4222a3574e2e58e2b85
266,227,403,392,358,940,000,000,000,000,000,000,000
75
eds-I#3 - [GPG] Mails that are not encrypted look encrypted Related to https://gitlab.gnome.org/GNOME/evolution-data-server/issues/3