func
string
target
int64
cwe
list
project
string
commit_id
string
hash
float64
size
int64
message
string
parserInit(XML_Parser parser, const XML_Char *encodingName) { processor = prologInitProcessor; XmlPrologStateInit(&prologState); protocolEncodingName = (encodingName != NULL ? poolCopyString(&tempPool, encodingName) : NULL); curBase = NULL; XmlInitEncoding(&...
0
[ "CWE-119" ]
libexpat
ba0f9c3b40c264b8dd392e02a7a060a8fa54f032
289,578,243,552,329,420,000,000,000,000,000,000,000
71
CVE-2015-1283 Sanity check size calculations. r=peterv, a=abillings https://sourceforge.net/p/expat/bugs/528/
static void php_mcrypt_module_dtor(zend_rsrc_list_entry *rsrc TSRMLS_DC) /* {{{ */ { php_mcrypt *pm = (php_mcrypt *) rsrc->ptr; if (pm) { mcrypt_generic_deinit(pm->td); mcrypt_module_close(pm->td); efree(pm); pm = NULL; }
0
[ "CWE-190" ]
php-src
6c5211a0cef0cc2854eaa387e0eb036e012904d0
289,228,263,847,761,950,000,000,000,000,000,000,000
10
Fix bug #72455: Heap Overflow due to integer overflows
void Statement::GetRow(Row* row, sqlite3_stmt* stmt) { int rows = sqlite3_column_count(stmt); for (int i = 0; i < rows; i++) { int type = sqlite3_column_type(stmt, i); const char* name = sqlite3_column_name(stmt, i); switch (type) { case SQLITE_INTEGER: { row...
0
[]
node-sqlite3
593c9d498be2510d286349134537e3bf89401c4a
310,806,750,283,073,020,000,000,000,000,000,000,000
31
bug: fix segfault of invalid toString() object (#1450) * bug: verify toString() returns valid data * test: faulty toString test
gs_setdevice_no_init(gs_gstate * pgs, gx_device * dev) { /* * Just set the device, possibly changing color space but no other * device parameters. * * Make sure we don't close the device if dev == pgs->device * This could be done by allowing the rc_assign to close the * old 'dev' if th...
0
[]
ghostpdl
79cccf641486a6595c43f1de1cd7ade696020a31
287,183,420,720,207,040,000,000,000,000,000,000,000
25
Bug 699654(2): preserve LockSafetyParams in the nulldevice The nulldevice does not necessarily use the normal setpagedevice machinery, but can be set using the nulldevice operator. In which case, we don't preserve the settings from the original device (in the way setpagedevice does). Since nulldevice does nothing, th...
xmlFACompareAtomTypes(xmlRegAtomType type1, xmlRegAtomType type2) { if ((type1 == XML_REGEXP_EPSILON) || (type1 == XML_REGEXP_CHARVAL) || (type1 == XML_REGEXP_RANGES) || (type1 == XML_REGEXP_SUBREG) || (type1 == XML_REGEXP_STRING) || (type1 == XML_REGEXP_ANYCHAR)) return(1); if ((type2 == XML_REGEX...
0
[ "CWE-119" ]
libxml2
cbb271655cadeb8dbb258a64701d9a3a0c4835b4
53,481,561,381,399,790,000,000,000,000,000,000,000
189
Bug 757711: heap-buffer-overflow in xmlFAParsePosCharGroup <https://bugzilla.gnome.org/show_bug.cgi?id=757711> * xmlregexp.c: (xmlFAParseCharRange): Only advance to the next character if there is no error. Advancing to the next character in case of an error while parsing regexp leads to an out of bounds access.
static int scrub_pages(struct scrub_ctx *sctx, u64 logical, u64 len, u64 physical, struct btrfs_device *dev, u64 flags, u64 gen, int mirror_num, u8 *csum, int force, u64 physical_for_dev_replace) { struct scrub_block *sblock; int index; sblock = kzalloc(sizeof(*sblock), GFP_KERNEL); if (...
0
[ "CWE-476", "CWE-284" ]
linux
09ba3bc9dd150457c506e4661380a6183af651c1
30,975,144,117,832,500,000,000,000,000,000,000,000
89
btrfs: merge btrfs_find_device and find_device Both btrfs_find_device() and find_device() does the same thing except that the latter does not take the seed device onto account in the device scanning context. We can merge them. Signed-off-by: Anand Jain <anand.jain@oracle.com> Reviewed-by: David Sterba <dsterba@suse.c...
static ssize_t nbd_send_reply(QIOChannel *ioc, NBDReply *reply) { uint8_t buf[NBD_REPLY_SIZE]; reply->error = system_errno_to_nbd_errno(reply->error); TRACE("Sending response to client: { .error = %" PRId32 ", handle = %" PRIu64 " }", reply->error, reply->handle); /* Reply ...
0
[ "CWE-20" ]
qemu
2b0bbc4f8809c972bad134bc1a2570dbb01dea0b
155,843,001,216,382,500,000,000,000,000,000,000,000
21
nbd/server: get rid of nbd_negotiate_read and friends Functions nbd_negotiate_{read,write,drop_sync} were introduced in 1a6245a5b, when nbd_rwv (was nbd_wr_sync) was working through qemu_co_sendv_recvv (the path is nbd_wr_sync -> qemu_co_{recv/send} -> qemu_co_send_recv -> qemu_co_sendv_recvv), which just yields, with...
static void mark_reg_known_zero(struct bpf_verifier_env *env, struct bpf_reg_state *regs, u32 regno) { if (WARN_ON(regno >= MAX_BPF_REG)) { verbose(env, "mark_reg_known_zero(regs, %u)\n", regno); /* Something bad happened, let's kill all regs */ for (regno = 0; regno < MAX_BPF_REG; regno++) __mark_reg_not...
0
[ "CWE-119", "CWE-681", "CWE-787" ]
linux
5b9fbeb75b6a98955f628e205ac26689bcb1383e
116,615,299,804,389,930,000,000,000,000,000,000,000
12
bpf: Fix scalar32_min_max_or bounds tracking Simon reported an issue with the current scalar32_min_max_or() implementation. That is, compared to the other 32 bit subreg tracking functions, the code in scalar32_min_max_or() stands out that it's using the 64 bit registers instead of 32 bit ones. This leads to bounds tra...
static int handle_pml_full(struct kvm_vcpu *vcpu) { unsigned long exit_qualification; trace_kvm_pml_full(vcpu->vcpu_id); exit_qualification = vmcs_readl(EXIT_QUALIFICATION); /* * PML buffer FULL happened while executing iret from NMI, * "blocked by NMI" bit has to be set before next VM entry. */ if (!(to_...
0
[ "CWE-284" ]
linux
727ba748e110b4de50d142edca9d6a9b7e6111d8
109,567,242,196,352,440,000,000,000,000,000,000,000
24
kvm: nVMX: Enforce cpl=0 for VMX instructions VMX instructions executed inside a L1 VM will always trigger a VM exit even when executed with cpl 3. This means we must perform the privilege check in software. Fixes: 70f3aac964ae("kvm: nVMX: Remove superfluous VMX instruction fault checks") Cc: stable@vger.kernel.org S...
get_key(krb5_context context, pkinit_identity_crypto_context id_cryptoctx, char *filename, const char *fsname, EVP_PKEY **retkey, const char *password) { EVP_PKEY *pkey = NULL; BIO *tmp = NULL; struct get_key_cb_data cb_data; int code; krb5_error_code retval; if (filename == NUL...
0
[ "CWE-119", "CWE-787" ]
krb5
fbb687db1088ddd894d975996e5f6a4252b9a2b4
126,699,562,885,423,570,000,000,000,000,000,000,000
40
Fix PKINIT cert matching data construction Rewrite X509_NAME_oneline_ex() and its call sites to use dynamic allocation and to perform proper error checking. ticket: 8617 target_version: 1.16 target_version: 1.15-next target_version: 1.14-next tags: pullup
int snd_component_add(struct snd_card *card, const char *component) { char *ptr; int len = strlen(component); ptr = strstr(card->components, component); if (ptr != NULL) { if (ptr[len] == '\0' || ptr[len] == ' ') /* already there */ return 1; } if (strlen(card->components) + 1 + len + 1 > sizeof(card->compo...
0
[ "CWE-416" ]
linux
2a3f7221acddfe1caa9ff09b3a8158c39b2fdeac
299,094,431,591,490,100,000,000,000,000,000,000,000
19
ALSA: core: Fix card races between register and disconnect There is a small race window in the card disconnection code that allows the registration of another card with the very same card id. This leads to a warning in procfs creation as caught by syzkaller. The problem is that we delete snd_cards and snd_cards_lock ...
static int complete_emulated_insn_gp(struct kvm_vcpu *vcpu, int err) { if (err) { kvm_inject_gp(vcpu, 0); return 1; } return kvm_emulate_instruction(vcpu, EMULTYPE_NO_DECODE | EMULTYPE_SKIP | EMULTYPE_COMPLETE_USER_EXIT); }
0
[ "CWE-476" ]
linux
55749769fe608fa3f4a075e42e89d237c8e37637
334,883,691,453,309,030,000,000,000,000,000,000,000
10
KVM: x86: Fix wall clock writes in Xen shared_info not to mark page dirty When dirty ring logging is enabled, any dirty logging without an active vCPU context will cause a kernel oops. But we've already declared that the shared_info page doesn't get dirty tracking anyway, since it would be kind of insane to mark it di...
sys_sigsuspend(old_sigset_t mask, unsigned long r3, unsigned long r4, unsigned long r5, unsigned long r6, unsigned long r7, struct pt_regs * regs) { sigset_t saveset; mask &= _BLOCKABLE; spin_lock_irq(&current->sighand->siglock); saveset = current->blocked; siginitset(&current->blocked, ma...
0
[]
linux-2.6
ee18d64c1f632043a02e6f5ba5e045bb26a5465f
78,691,316,140,670,790,000,000,000,000,000,000,000
27
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...
free_perturb (char *p, size_t n) { if (__glibc_unlikely (perturb_byte)) memset (p, perturb_byte, n); }
0
[ "CWE-787" ]
glibc
d6db68e66dff25d12c3bc5641b60cbd7fb6ab44f
222,252,986,899,606,870,000,000,000,000,000,000,000
5
malloc: Mitigate null-byte overflow attacks * malloc/malloc.c (_int_free): Check for corrupt prev_size vs size. (malloc_consolidate): Likewise.
inline void invert_endianness(unsigned char* const, const cimg_ulong) {}
0
[ "CWE-770" ]
cimg
619cb58dd90b4e03ac68286c70ed98acbefd1c90
323,343,500,884,524,630,000,000,000,000,000,000,000
1
CImg<>::load_bmp() and CImg<>::load_pandore(): Check that dimensions encoded in file does not exceed file size.
do_init (int event_fd, pid_t initial_pid, struct sock_fprog *seccomp_prog) { int initial_exit_status = 1; LockFile *lock; for (lock = lock_files; lock != NULL; lock = lock->next) { int fd = open (lock->path, O_RDONLY | O_CLOEXEC); if (fd == -1) die_with_error ("Unable to open lock file %s...
0
[ "CWE-20", "CWE-269" ]
bubblewrap
efc89e3b939b4bde42c10f065f6b7b02958ed50e
334,976,744,141,613,700,000,000,000,000,000,000,000
71
Don't create our own temporary mount point for pivot_root An attacker could pre-create /tmp/.bubblewrap-$UID and make it a non-directory, non-symlink (in which case mounting our tmpfs would fail, causing denial of service), or make it a symlink under their control (potentially allowing bad things if the protected_syml...
static __exit void hardware_unsetup(void) { int i; for (i = 0; i < VMX_BITMAP_NR; i++) free_page((unsigned long)vmx_bitmap[i]); free_kvm_area(); }
0
[ "CWE-284" ]
linux
727ba748e110b4de50d142edca9d6a9b7e6111d8
23,324,520,328,324,847,000,000,000,000,000,000,000
9
kvm: nVMX: Enforce cpl=0 for VMX instructions VMX instructions executed inside a L1 VM will always trigger a VM exit even when executed with cpl 3. This means we must perform the privilege check in software. Fixes: 70f3aac964ae("kvm: nVMX: Remove superfluous VMX instruction fault checks") Cc: stable@vger.kernel.org S...
beep_print(netdissect_options *ndo, const u_char *bp, u_int length) { if (l_strnstart(ndo, "MSG", 4, (const char *)bp, length)) /* A REQuest */ ND_PRINT((ndo, " BEEP MSG")); else if (l_strnstart(ndo, "RPY ", 4, (const char *)bp, length)) ND_PRINT((ndo, " BEEP RPY")); else if (l_strnstart(ndo, "ERR ", 4, (const ...
0
[ "CWE-125", "CWE-787" ]
tcpdump
877b66b398518d9501513e0860c9f3a8acc70892
207,709,938,637,621,640,000,000,000,000,000,000,000
20
CVE-2017-13010/BEEP: Do bounds checking when comparing strings. This fixes a buffer over-read discovered by Brian 'geeknik' Carpenter. Add a test using the capture file supplied by the reporter(s).
vpnc_watch_cb (GPid pid, gint status, gpointer user_data) { NMVPNCPlugin *plugin = NM_VPNC_PLUGIN (user_data); NMVPNCPluginPrivate *priv = NM_VPNC_PLUGIN_GET_PRIVATE (plugin); guint error = 0; if (WIFEXITED (status)) { error = WEXITSTATUS (status); if (error != 0) _LOGW ("vpnc exited with error code %d", er...
0
[]
NetworkManager-vpnc
07ac18a32b4e361a27ef48ac757d36cbb46e8e12
180,456,258,513,445,000,000,000,000,000,000,000,000
43
service: disallow newlinies in configuration values (CVE-2018-10900) The vpnc configuration format doesn't allow those. vpnc(8): The values start exactly one space after the keywords, and run to the end of line. This lets you put any kind of weird character (except CR, LF and NUL) in your strings We have no ch...
int init_crypto(struct crypt_device *ctx) { struct utsname uts; int r; r = crypt_random_init(ctx); if (r < 0) { log_err(ctx, _("Cannot initialize crypto RNG backend.")); return r; } r = crypt_backend_init(crypt_fips_mode()); if (r < 0) log_err(ctx, _("Cannot initialize crypto backend.")); if (!r && !_c...
0
[ "CWE-345" ]
cryptsetup
0113ac2d889c5322659ad0596d4cfc6da53e356c
210,992,135,015,609,370,000,000,000,000,000,000,000
26
Fix CVE-2021-4122 - LUKS2 reencryption crash recovery attack Fix possible attacks against data confidentiality through LUKS2 online reencryption extension crash recovery. An attacker can modify on-disk metadata to simulate decryption in progress with crashed (unfinished) reencryption step and persistently decrypt par...
cdf_swap_class(cdf_classid_t *d) { d->cl_dword = CDF_TOLE4(d->cl_dword); d->cl_word[0] = CDF_TOLE2(d->cl_word[0]); d->cl_word[1] = CDF_TOLE2(d->cl_word[1]); }
0
[ "CWE-119" ]
file
1859fdb4e67c49c463c4e0078054335cd46ba295
171,918,185,527,301,160,000,000,000,000,000,000,000
6
add more check found by cert's fuzzer.
g_deinit(void) { #if defined(_WIN32) WSACleanup(); #endif g_remove_dir(g_temp_base); }
1
[]
xrdp
cadad6e181d2a67698e5eb7cacd6b233ae29eb97
187,669,739,876,419,030,000,000,000,000,000,000,000
7
/tmp cleanup
TEST(UriSuite, TestQueryListPair) { testQueryListPairHelper("one+two+%26+three=%2B", "one two & three", "+"); testQueryListPairHelper("one=two=three", "one", "two=three", "one=two%3Dthree"); testQueryListPairHelper("one=two=three=four", "one", "two=three=four", "one=two%3Dthree%3Dfour"); }
0
[ "CWE-125" ]
uriparser
cef25028de5ff872c2e1f0a6c562eb3ea9ecbce4
126,650,330,207,058,750,000,000,000,000,000,000,000
5
Fix uriParse*Ex* out-of-bounds read
ngx_http_lua_copy_in_file_request_body(ngx_http_request_t *r) { ngx_temp_file_t *tf; ngx_http_request_body_t *body; tf = r->request_body->temp_file; if (!tf->persistent || !tf->clean) { ngx_log_error(NGX_LOG_ERR, r->connection->log, 0, "the request body was not rea...
0
[ "CWE-444" ]
lua-nginx-module
9ab38e8ee35fc08a57636b1b6190dca70b0076fa
26,189,338,797,684,760,000,000,000,000,000,000,000
34
bugfix: prevented request smuggling in the ngx.location.capture API. Signed-off-by: Yichun Zhang (agentzh) <yichun@openresty.com>
httpServeObject(HTTPConnectionPtr connection) { HTTPRequestPtr request = connection->request; ObjectPtr object = request->object; int i = request->from / CHUNK_SIZE; int j = request->from % CHUNK_SIZE; int n, len, rc; int bufsize = CHUNK_SIZE; int condition_result; object->atime = curre...
0
[ "CWE-617" ]
polipo
0e2b44af619e46e365971ea52b97457bc0778cd3
32,525,539,936,899,580,000,000,000,000,000,000,000
249
Try to read POST requests to local configuration interface correctly.
fep_client_send_text (FepClient *client, const char *text) { FepControlMessage message; message.command = FEP_CONTROL_SEND_TEXT; _fep_control_message_alloc_args (&message, 1); _fep_control_message_write_string_arg (&message, 0, text, strlen (text) + 1); if (client->filter_running) client->messages = _fe...
0
[ "CWE-264" ]
libfep
293d9d3f7565f01a9dc40b53259886832eaa2ace
218,549,732,027,379,980,000,000,000,000,000,000,000
14
Don't use abstract Unix domain sockets
static void FVMenuCondense(GWindow gw, struct gmenuitem *UNUSED(mi), GEvent *UNUSED(e)) { FontView *fv = (FontView *) GDrawGetUserData(gw); CondenseExtendDlg(fv,NULL); }
0
[ "CWE-119", "CWE-787" ]
fontforge
626f751752875a0ddd74b9e217b6f4828713573c
300,598,283,612,231,800,000,000,000,000,000,000,000
4
Warn users before discarding their unsaved scripts (#3852) * Warn users before discarding their unsaved scripts This closes #3846.
getkey_next (getkey_ctx_t ctx, PKT_public_key *pk, kbnode_t *ret_keyblock) { int rc; /* Fixme: Make sure this is proper gpg_error */ rc = lookup (ctx, ret_keyblock, ctx->want_secret); if (!rc && pk && ret_keyblock) pk_from_block (ctx, pk, *ret_keyblock); return rc; }
0
[ "CWE-310" ]
gnupg
4bde12206c5bf199dc6e12a74af8da4558ba41bf
116,907,403,954,047,520,000,000,000,000,000,000,000
10
gpg: Distinguish between missing and cleared key flags. * include/cipher.h (PUBKEY_USAGE_NONE): New. * g10/getkey.c (parse_key_usage): Set new flag. -- We do not want to use the default capabilities (derived from the algorithm) if any key flags are given in a signature. Thus if key flags are used in any way, the def...
p11_dl_close (void *dl) { #ifdef OS_WIN32 FreeLibrary (dl); #else (void) dlclose (dl); #endif }
0
[ "CWE-190" ]
p11-kit
bd670b1d4984b27d6a397b9ddafaf89ab26e4e7f
116,684,648,524,086,540,000,000,000,000,000,000,000
8
Follow-up to arithmetic overflow fix Check if nmemb is zero in p11_rpc_message_alloc_extra_array to avoid a division by zero trap. Additionally, change the reallocarray compatibility shim so that it won't assert when resizing an array to zero, and add the same nmemb != 0 check there.
bool localAddressRestored() const override { return local_address_restored_; }
0
[ "CWE-400" ]
envoy
542f84c66e9f6479bc31c6f53157c60472b25240
84,252,542,206,634,210,000,000,000,000,000,000,000
1
overload: Runtime configurable global connection limits (#147) Signed-off-by: Tony Allen <tony@allen.gg>
MonoArray * mono_reflection_sighelper_get_signature_local (MonoReflectionSigHelper *sig) { g_assert_not_reached (); return NULL;
0
[ "CWE-20" ]
mono
4905ef1130feb26c3150b28b97e4a96752e0d399
195,726,742,713,479,760,000,000,000,000,000,000,000
5
Handle invalid instantiation of generic methods. * verify.c: Add new function to internal verifier API to check method instantiations. * reflection.c (mono_reflection_bind_generic_method_parameters): Check the instantiation before returning it. Fixes #655847
prepare_fk_prelocking_list(THD *thd, Query_tables_list *prelocking_ctx, TABLE_LIST *table_list, bool *need_prelocking, uint8 op) { List <FOREIGN_KEY_INFO> fk_list; List_iterator<FOREIGN_KEY_INFO> fk_list_it(fk_list); FOREIGN_KEY_INFO *fk; Query_arena *arena,...
0
[]
server
0168d1eda30dad4b517659422e347175eb89e923
32,291,134,261,796,070,000,000,000,000,000,000,000
49
MDEV-25766 Unused CTE lead to a crash in find_field_in_tables/find_order_in_list Do not assume that subquery Item always present.
PackLinuxElf64::elf_find_dynamic(unsigned int key) const { Elf64_Dyn const *dynp= dynseg; if (dynp) for (; (unsigned)((char const *)dynp - (char const *)dynseg) < sz_dynseg && Elf64_Dyn::DT_NULL!=dynp->d_tag; ++dynp) if (get_te64(&dynp->d_tag)==key) { upx_uint64_t const t= elf_get_offset...
1
[ "CWE-476", "CWE-190" ]
upx
8be9da8280dfa69d5df4417d4d81bda1cab78010
140,163,033,460,328,620,000,000,000,000,000,000,000
14
Avoid bogus values in PT_DYNAMIC segment. Detect duplicate DT_*. Detect out-of-bounds hashtab and gashtab. Detect missing DT_REL, DT_RELA. Detect out-of-bounds d_val. https://github.com/upx/upx/issues/317 modified: p_lx_elf.cpp
QPDFObjectHandle newName(std::string const& name) { return QPDFObjectHandle::newName(name); }
0
[ "CWE-125" ]
qpdf
1868a10f8b06631362618bfc85ca8646da4b4b71
214,765,649,635,213,500,000,000,000,000,000,000,000
4
Replace all atoi calls with QUtil::string_to_int The latter catches underflow/overflow.
heap_add_entry(struct archive_read *a, struct heap_queue *heap, struct file_info *file, uint64_t key) { uint64_t file_key, parent_key; int hole, parent; /* Expand our pending files list as necessary. */ if (heap->used >= heap->allocated) { struct file_info **new_pending_files; int new_size = heap->allocate...
0
[ "CWE-190" ]
libarchive
3ad08e01b4d253c66ae56414886089684155af22
141,344,770,209,032,780,000,000,000,000,000,000,000
55
Issue 717: Fix integer overflow when computing location of volume descriptor The multiplication here defaulted to 'int' but calculations of file positions should always use int64_t. A simple cast suffices to fix this since the base location is always 32 bits for ISO, so multiplying by the sector size will never over...
static inline void unmap_mapping_range_tree(struct rb_root *root, struct zap_details *details) { struct vm_area_struct *vma; pgoff_t vba, vea, zba, zea; vma_interval_tree_foreach(vma, root, details->first_index, details->last_index) { vba = vma->vm_pgoff; vea = vba + vma_pages(vma) - 1; zba = det...
0
[ "CWE-119" ]
linux
1be7107fbe18eed3e319a6c3e83c78254b693acb
105,888,981,241,522,920,000,000,000,000,000,000,000
24
mm: larger stack guard gap, between vmas Stack guard page is a useful feature to reduce a risk of stack smashing into a different mapping. We have been using a single page gap which is sufficient to prevent having stack adjacent to a different mapping. But this seems to be insufficient in the light of the stack usage ...
static inline void native_write_gdt_entry(struct desc_struct *gdt, int entry, const void *desc, int type) { unsigned int size; switch (type) { case DESC_TSS: size = sizeof(tss_desc); break; case DESC_LDT: size = sizeof(ldt_desc); break; default: size = sizeof(struct desc_struct); break; } memc...
0
[ "CWE-119" ]
linux-2.6
5ac37f87ff18843aabab84cf75b2f8504c2d81fe
13,869,627,748,976,757,000,000,000,000,000,000,000
17
x86: fix ldt limit for 64 bit Fix size of LDT entries. On x86-64, ldt_desc is a double-sized descriptor. Signed-off-by: Michael Karcher <kernel@mkarcher.dialup.fu-berlin.de> Signed-off-by: Ingo Molnar <mingo@elte.hu>
static int uac2_ctl_value_size(int val_type) { switch (val_type) { case USB_MIXER_S32: case USB_MIXER_U32: return 4; case USB_MIXER_S16: case USB_MIXER_U16: return 2; default: return 1; } return 0; /* unreachable */ }
0
[ "CWE-416", "CWE-787" ]
linux
124751d5e63c823092060074bd0abaae61aaa9c4
123,696,349,115,851,480,000,000,000,000,000,000,000
14
ALSA: usb-audio: Kill stray URB at exiting USB-audio driver may leave a stray URB for the mixer interrupt when it exits by some error during probe. This leads to a use-after-free error as spotted by syzkaller like: ================================================================== BUG: KASAN: use-after-free in sn...
int __kvm_set_xcr(struct kvm_vcpu *vcpu, u32 index, u64 xcr) { u64 xcr0 = xcr; u64 old_xcr0 = vcpu->arch.xcr0; u64 valid_bits; /* Only support XCR_XFEATURE_ENABLED_MASK(xcr0) now */ if (index != XCR_XFEATURE_ENABLED_MASK) return 1; if (!(xcr0 & XSTATE_FP)) return 1; if ((xcr0 & XSTATE_YMM) && !(xcr0 & XSTA...
0
[]
kvm
854e8bb1aa06c578c2c9145fa6bfe3680ef63b23
197,823,933,592,469,100,000,000,000,000,000,000,000
33
KVM: x86: Check non-canonical addresses upon WRMSR Upon WRMSR, the CPU should inject #GP if a non-canonical value (address) is written to certain MSRs. The behavior is "almost" identical for AMD and Intel (ignoring MSRs that are not implemented in either architecture since they would anyhow #GP). However, IA32_SYSENTE...
xmlRelaxNGParseImportRefs(xmlRelaxNGParserCtxtPtr ctxt, xmlRelaxNGGrammarPtr grammar) { if ((ctxt == NULL) || (grammar == NULL) || (ctxt->grammar == NULL)) return(-1); if (grammar->refs == NULL) return(0); if (ctxt->grammar->refs == NULL) ctxt->grammar->refs...
0
[ "CWE-134" ]
libxml2
502f6a6d08b08c04b3ddfb1cd21b2f699c1b7f5b
319,046,732,222,633,780,000,000,000,000,000,000,000
16
More format string warnings with possible format string vulnerability For https://bugzilla.gnome.org/show_bug.cgi?id=761029 adds a new xmlEscapeFormatString() function to escape composed format strings
static int rtsx_usb_ms_drv_probe(struct platform_device *pdev) { struct memstick_host *msh; struct rtsx_usb_ms *host; struct rtsx_ucr *ucr; int err; ucr = usb_get_intfdata(to_usb_interface(pdev->dev.parent)); if (!ucr) return -ENXIO; dev_dbg(&(pdev->dev), "Realtek USB Memstick controller found\n"); msh ...
1
[ "CWE-416" ]
linux
42933c8aa14be1caa9eda41f65cde8a3a95d3e39
64,085,819,692,496,640,000,000,000,000,000,000,000
51
memstick: rtsx_usb_ms: fix UAF This patch fixes the following issues: 1. memstick_free_host() will free the host, so the use of ms_dev(host) after it will be a problem. To fix this, move memstick_free_host() after when we are done with ms_dev(host). 2. In rtsx_usb_ms_drv_remove(), pm need to be disabled before we remo...
_cmp_int_strings(const void **_a, const void **_b) { const char *a = *_a, *b = *_b; int ai = (int)tor_parse_long(a, 10, 1, INT_MAX, NULL, NULL); int bi = (int)tor_parse_long(b, 10, 1, INT_MAX, NULL, NULL); if (ai<bi) { return -1; } else if (ai==bi) { if (ai == 0) /* Parsing failed. */ return str...
0
[]
tor
973c18bf0e84d14d8006a9ae97fde7f7fb97e404
268,421,053,895,563,040,000,000,000,000,000,000,000
15
Fix assertion failure in tor_timegm. Fixes bug 6811.
static void gf_m2ts_reset_sections(GF_List *sections) { u32 count; GF_M2TS_Section *section; //GF_LOG(GF_LOG_DEBUG, GF_LOG_CONTAINER, ("[MPEG-2 TS] Deleting sections\n")); count = gf_list_count(sections); while (count) { section = gf_list_get(sections, 0); gf_list_rem(sections, 0); if (section->data) gf_fre...
0
[ "CWE-416", "CWE-125" ]
gpac
1ab4860609f2e7a35634930571e7d0531297e090
200,680,416,727,601,100,000,000,000,000,000,000,000
15
fixed potential crash on PMT IOD parse - cf #1268 #1269
static void kgdb_initial_breakpoint(void) { kgdb_break_asap = 0; pr_crit("Waiting for connection from remote gdb...\n"); kgdb_breakpoint(); }
0
[ "CWE-787" ]
linux
eadb2f47a3ced5c64b23b90fd2a3463f63726066
29,057,374,428,572,710,000,000,000,000,000,000,000
7
lockdown: also lock down previous kgdb use KGDB and KDB allow read and write access to kernel memory, and thus should be restricted during lockdown. An attacker with access to a serial port (for example, via a hypervisor console, which some cloud vendors provide over the network) could trigger the debugger so it is i...
aptcTimerHandler(unsigned long arg) { u32 numbytes; u32 throughput; struct ar6_softc *ar; int status; ar = (struct ar6_softc *)arg; A_ASSERT(ar != NULL); A_ASSERT(!timer_pending(&aptcTimer)); AR6000_SPIN_LOCK(&ar->arLock, 0); /* Get the number of bytes transferred */ numbytes ...
0
[ "CWE-703", "CWE-264" ]
linux
550fd08c2cebad61c548def135f67aba284c6162
246,241,404,853,348,250,000,000,000,000,000,000,000
33
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...
CImg<T>& diffusion_tensors(const float sharpness=0.7f, const float anisotropy=0.6f, const float alpha=0.6f, const float sigma=1.1f, const bool is_sqrt=false) { CImg<Tfloat> res; const float nsharpness = std::max(sharpness,1e-5f), power1 = (is_sqrt?0.5f:1)*n...
0
[ "CWE-770" ]
cimg
619cb58dd90b4e03ac68286c70ed98acbefd1c90
123,784,313,740,204,020,000,000,000,000,000,000,000
60
CImg<>::load_bmp() and CImg<>::load_pandore(): Check that dimensions encoded in file does not exceed file size.
static int kvm_probe_user_return_msr(u32 msr) { u64 val; int ret; preempt_disable(); ret = rdmsrl_safe(msr, &val); if (ret) goto out; ret = wrmsrl_safe(msr, val); out: preempt_enable(); return ret; }
0
[ "CWE-476" ]
linux
55749769fe608fa3f4a075e42e89d237c8e37637
3,186,523,772,328,528,400,000,000,000,000,000,000
14
KVM: x86: Fix wall clock writes in Xen shared_info not to mark page dirty When dirty ring logging is enabled, any dirty logging without an active vCPU context will cause a kernel oops. But we've already declared that the shared_info page doesn't get dirty tracking anyway, since it would be kind of insane to mark it di...
static __exit void hardware_unsetup(void) { free_kvm_area(); }
0
[ "CWE-20" ]
linux-2.6
16175a796d061833aacfbd9672235f2d2725df65
165,060,749,802,121,310,000,000,000,000,000,000,000
4
KVM: VMX: Don't allow uninhibited access to EFER on i386 vmx_set_msr() does not allow i386 guests to touch EFER, but they can still do so through the default: label in the switch. If they set EFER_LME, they can oops the host. Fix by having EFER access through the normal channel (which will check for EFER_LME) even o...
RGWOp *RGWHandler_REST_Obj_S3::op_put() { if (is_acl_op()) { return new RGWPutACLs_ObjStore_S3; } else if (is_tagging_op()) { return new RGWPutObjTags_ObjStore_S3; } if (s->init_state.src_bucket.empty()) return new RGWPutObj_ObjStore_S3; else return new RGWCopyObj_ObjStore_S3; }
0
[ "CWE-79" ]
ceph
ba0790a01ba5252db1ebc299db6e12cd758d0ff9
130,239,386,196,070,580,000,000,000,000,000,000,000
13
rgw: reject unauthenticated response-header actions Signed-off-by: Matt Benjamin <mbenjamin@redhat.com> Reviewed-by: Casey Bodley <cbodley@redhat.com> (cherry picked from commit d8dd5e513c0c62bbd7d3044d7e2eddcd897bd400)
static int tls_construct_cke_srp(SSL *s, unsigned char **p, int *len, int *al) { #ifndef OPENSSL_NO_SRP if (s->srp_ctx.A != NULL) { /* send off the data */ *len = BN_num_bytes(s->srp_ctx.A); s2n(*len, *p); BN_bn2bin(s->srp_ctx.A, *p); *len += 2; } else { SSLerr(SS...
0
[ "CWE-476" ]
openssl
efbe126e3ebb9123ac9d058aa2bb044261342aaa
60,504,933,674,098,870,000,000,000,000,000,000,000
27
Fix missing NULL checks in CKE processing Reviewed-by: Rich Salz <rsalz@openssl.org>
int kvm_emulate_mwait(struct kvm_vcpu *vcpu) { pr_warn_once("kvm: MWAIT instruction emulated as NOP!\n"); return kvm_emulate_as_nop(vcpu); }
0
[ "CWE-476" ]
linux
55749769fe608fa3f4a075e42e89d237c8e37637
210,641,963,107,107,000,000,000,000,000,000,000,000
5
KVM: x86: Fix wall clock writes in Xen shared_info not to mark page dirty When dirty ring logging is enabled, any dirty logging without an active vCPU context will cause a kernel oops. But we've already declared that the shared_info page doesn't get dirty tracking anyway, since it would be kind of insane to mark it di...
local void check_match(s, start, match, length) deflate_state *s; IPos start, match; int length; { /* check that the match is indeed a match */ if (zmemcmp(s->window + match, s->window + start, length) != EQUAL) { fprintf(stderr, " start %u, match %u, length %d\n", ...
0
[ "CWE-284", "CWE-787" ]
zlib
5c44459c3b28a9bd3283aaceab7c615f8020c531
129,085,934,202,529,460,000,000,000,000,000,000,000
20
Fix a bug that can crash deflate on some input when using Z_FIXED. This bug was reported by Danilo Ramos of Eideticom, Inc. It has lain in wait 13 years before being found! The bug was introduced in zlib 1.2.2.2, with the addition of the Z_FIXED option. That option forces the use of fixed Huffman codes. For rare input...
onig_set_capture_num_limit(int num) { if (num < 0) return -1; MaxCaptureNum = num; return 0; }
0
[ "CWE-787" ]
oniguruma
f015fbdd95f76438cd86366467bb2b39870dd7c6
207,765,199,173,373,700,000,000,000,000,000,000,000
7
fix #55 : Byte value expressed in octal must be smaller than 256
static int pcd_detect(void) { char id[18]; int k, unit; struct pcd_unit *cd; printk("%s: %s version %s, major %d, nice %d\n", name, name, PCD_VERSION, major, nice); par_drv = pi_register_driver(name); if (!par_drv) { pr_err("failed to register %s driver\n", name); return -1; } k = 0; if (pcd_dri...
1
[ "CWE-476" ]
linux
f0d1762554014ce0ae347b9f0d088f2c157c8c72
137,177,783,197,349,480,000,000,000,000,000,000,000
55
paride/pcd: Fix potential NULL pointer dereference and mem leak Syzkaller report this: pcd: pcd version 1.07, major 46, nice 0 pcd0: Autoprobe failed pcd: No CD-ROM drive found kasan: CONFIG_KASAN_INLINE enabled kasan: GPF could be caused by NULL-ptr deref or user memory access general protection fault: 0000 [#1] SMP...
static void xudc_ep0_in(struct xusb_udc *udc) { struct xusb_ep *ep0 = &udc->ep[0]; struct xusb_req *req; unsigned int bytes_to_tx; void *buffer; u32 epcfgreg; u16 count = 0; u16 length; u8 *ep0rambase; u8 test_mode = udc->setup.wIndex >> 8; req = list_first_entry(&ep0->queue, struct xusb_req, queue); bytes_...
0
[ "CWE-20", "CWE-129" ]
linux
7f14c7227f342d9932f9b918893c8814f86d2a0d
67,923,076,886,364,090,000,000,000,000,000,000,000
65
USB: gadget: validate endpoint index for xilinx udc Assure that host may not manipulate the index to point past endpoint array. Signed-off-by: Szymon Heidrich <szymon.heidrich@gmail.com> Cc: stable <stable@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
size_t copy_page_to_iter(struct page *page, size_t offset, size_t bytes, struct iov_iter *i) { if (i->type & (ITER_BVEC|ITER_KVEC)) { void *kaddr = kmap_atomic(page); size_t wanted = copy_to_iter(kaddr + offset, bytes, i); kunmap_atomic(kaddr); return wanted; } else if (likely(!(i->type & ITER_PIPE))) r...
0
[ "CWE-200" ]
linux
b9dc6f65bc5e232d1c05fe34b5daadc7e8bbf1fb
281,059,589,077,611,130,000,000,000,000,000,000,000
13
fix a fencepost error in pipe_advance() The logics in pipe_advance() used to release all buffers past the new position failed in cases when the number of buffers to release was equal to pipe->buffers. If that happened, none of them had been released, leaving pipe full. Worse, it was trivial to trigger and we end up ...
int mainwindow_set_statusbar_lines(MAIN_WINDOW_REC *window, int top, int bottom) { int ret; ret = -1; if (top != 0) { ret = window->statusbar_lines_top; window->statusbar_lines_top += top; window->statusbar_lines += top; } if (bottom != 0) { ret = w...
0
[ "CWE-476" ]
irssi
5b5bfef03596d95079c728f65f523570dd7b03aa
227,661,854,212,568,130,000,000,000,000,000,000,000
23
check the error condition of mainwindow_create
pdf14_debug_mask_stack_state(pdf14_ctx *ctx) { return; }
0
[ "CWE-416" ]
ghostpdl
90fd0c7ca3efc1ddff64a86f4104b13b3ac969eb
310,083,210,586,374,630,000,000,000,000,000,000,000
4
Bug 697456. Dont create new ctx when pdf14 device reenabled This bug had yet another weird case where the user created a file that pushed the pdf14 device twice. We were in that case, creating a new ctx and blowing away the original one with out proper clean up. To avoid, only create a new one when we need it.
irqreturn_t ipmi_si_irq_handler(int irq, void *data) { struct smi_info *smi_info = data; unsigned long flags; if (smi_info->io.si_type == SI_BT) /* We need to clear the IRQ flag for the BT interface. */ smi_info->io.outputb(&smi_info->io, IPMI_BT_INTMASK_REG, IPMI_BT_INTMASK_CLEAR_IRQ_BIT | ...
0
[ "CWE-416" ]
linux
401e7e88d4ef80188ffa07095ac00456f901b8c4
294,510,458,971,835,700,000,000,000,000,000,000,000
21
ipmi_si: fix use-after-free of resource->name When we excute the following commands, we got oops rmmod ipmi_si cat /proc/ioports [ 1623.482380] Unable to handle kernel paging request at virtual address ffff00000901d478 [ 1623.482382] Mem abort info: [ 1623.482383] ESR = 0x96000007 [ 1623.482385] Exception class =...
int _gnutls_session_is_psk(gnutls_session_t session) { gnutls_kx_algorithm_t kx; kx = session->security_parameters.cs->kx_algorithm; if (kx == GNUTLS_KX_PSK || kx == GNUTLS_KX_DHE_PSK || kx == GNUTLS_KX_RSA_PSK) return 1; return 0; }
0
[]
gnutls
3d7fae761e65e9d0f16d7247ee8a464d4fe002da
53,296,907,857,597,610,000,000,000,000,000,000,000
11
valgrind: check if session ticket key is used without initialization This adds a valgrind client request for session->key.session_ticket_key to make sure that it is not used without initialization. Signed-off-by: Daiki Ueno <ueno@gnu.org>
static int sctp_apply_peer_addr_params(struct sctp_paddrparams *params, struct sctp_transport *trans, struct sctp_association *asoc, struct sctp_sock *sp, int hb_change, int pmtud_change, int ...
0
[ "CWE-416", "CWE-787" ]
linux
df80cd9b28b9ebaa284a41df611dbf3a2d05ca74
266,104,679,336,253,140,000,000,000,000,000,000,000
140
sctp: do not peel off an assoc from one netns to another one Now when peeling off an association to the sock in another netns, all transports in this assoc are not to be rehashed and keep use the old key in hashtable. As a transport uses sk->net as the hash key to insert into hashtable, it would miss removing these t...
aggregate(struct task_group *tg, struct sched_domain *sd) { return &tg->cfs_rq[sd->first_cpu]->aggregate; }
0
[]
linux-2.6
8f1bc385cfbab474db6c27b5af1e439614f3025c
238,394,624,123,556,720,000,000,000,000,000,000,000
4
sched: fair: weight calculations In order to level the hierarchy, we need to calculate load based on the root view. That is, each task's load is in the same unit. A / \ B 1 / \ 2 3 To compute 1's load we do: weight(1) -------------- rq_weight(A) To ...
void udf_evict_inode(struct inode *inode) { struct udf_inode_info *iinfo = UDF_I(inode); int want_delete = 0; if (!is_bad_inode(inode)) { if (!inode->i_nlink) { want_delete = 1; udf_setsize(inode, 0); udf_update_inode(inode, IS_SYNC(inode)); } if (iinfo->i_alloc_type != ICBTAG_FLAG_AD_IN_ICB && ...
0
[ "CWE-476" ]
linux
7fc3b7c2981bbd1047916ade327beccb90994eee
184,298,838,756,135,840,000,000,000,000,000,000,000
30
udf: Fix NULL ptr deref when converting from inline format udf_expand_file_adinicb() calls directly ->writepage to write data expanded into a page. This however misses to setup inode for writeback properly and so we can crash on inode->i_wb dereference when submitting page for IO like: BUG: kernel NULL pointer dere...
static int do_help(const char *prog) { printf("%s, NPAPI plugin viewer. Version %s\n", NPW_VIEWER, NPW_VERSION); printf("\n"); printf("usage: %s [GTK flags] [flags]\n", prog); printf(" -h --help print this message\n"); printf(" -t --test check plugin is compatible\n"); printf...
0
[ "CWE-264" ]
nspluginwrapper
7e4ab8e1189846041f955e6c83f72bc1624e7a98
299,312,719,975,859,700,000,000,000,000,000,000,000
12
Support all the new variables added
char* crypto_cert_issuer(X509* xcert) { return crypto_print_name(X509_get_issuer_name(xcert)); }
0
[ "CWE-787" ]
FreeRDP
8305349a943c68b1bc8c158f431dc607655aadea
205,497,471,462,574,000,000,000,000,000,000,000,000
4
Fixed GHSL-2020-102 heap overflow (cherry picked from commit 197b16cc15a12813c2e4fa2d6ae9cd9c4a57e581)
smb2_negotiate_rsize(struct cifs_tcon *tcon, struct smb3_fs_context *ctx) { struct TCP_Server_Info *server = tcon->ses->server; unsigned int rsize; /* start with specified rsize, or default */ rsize = ctx->rsize ? ctx->rsize : CIFS_DEFAULT_IOSIZE; rsize = min_t(unsigned int, rsize, server->max_read); if (!(serv...
0
[ "CWE-476" ]
linux
d6f5e358452479fa8a773b5c6ccc9e4ec5a20880
58,088,063,839,937,540,000,000,000,000,000,000,000
14
cifs: fix NULL ptr dereference in smb2_ioctl_query_info() When calling smb2_ioctl_query_info() with invalid smb_query_info::flags, a NULL ptr dereference is triggered when trying to kfree() uninitialised rqst[n].rq_iov array. This also fixes leaked paths that are created in SMB2_open_init() which required SMB2_open_f...
do_notify_resume(struct pt_regs *regs, unsigned int thread_flags, int syscall) { if (thread_flags & _TIF_SIGPENDING) do_signal(&current->blocked, regs, syscall); if (thread_flags & _TIF_NOTIFY_RESUME) { clear_thread_flag(TIF_NOTIFY_RESUME); tracehook_notify_resume(regs); } }
1
[]
linux-2.6
ee18d64c1f632043a02e6f5ba5e045bb26a5465f
43,731,854,912,297,120,000,000,000,000,000,000,000
10
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...
link_info_got_data (NautilusDirectory *directory, NautilusFile *file, gboolean result, goffset bytes_read, char *file_contents) { char *link_uri, *uri, *name, *icon; gboolean is_launcher; gboolean is_foreign; nautilus_directory_ref (directory); uri = NULL; name = NULL; icon = NULL; is_...
0
[]
nautilus
7632a3e13874a2c5e8988428ca913620a25df983
161,893,264,456,971,590,000,000,000,000,000,000,000
39
Check for trusted desktop file launchers. 2009-02-24 Alexander Larsson <alexl@redhat.com> * libnautilus-private/nautilus-directory-async.c: Check for trusted desktop file launchers. * libnautilus-private/nautilus-file-private.h: * libnautilus-private/nautilus-file.c: * libnautilus-...
read_cups_files_conf(cups_file_t *fp) /* I - File to read from */ { int linenum; /* Current line number */ char line[HTTP_MAX_BUFFER], /* Line from file */ *value; /* Value from line */ struct group *group; /* Group */ /* * Loop through each line in the file... */ linenum = 0; while (cupsFil...
1
[]
cups
d47f6aec436e0e9df6554436e391471097686ecc
134,273,984,066,564,700,000,000,000,000,000,000,000
173
Fix local privilege escalation to root and sandbox bypasses in scheduler (rdar://37836779, rdar://37836995, rdar://37837252, rdar://37837581)
static struct blkcg_gq *blkg_create(struct blkcg *blkcg, struct request_queue *q, struct blkcg_gq *new_blkg) { struct blkcg_gq *blkg; struct bdi_writeback_congested *wb_congested; int i, ret; WARN_ON_ONCE(!rcu_read_lock_held()); lockdep_assert_held(q->queue_lock); /* blkg holds a reference to bl...
0
[ "CWE-415" ]
linux
9b54d816e00425c3a517514e0d677bb3cec49258
180,498,343,183,135,400,000,000,000,000,000,000,000
86
blkcg: fix double free of new_blkg in blkcg_init_queue If blkg_create fails, new_blkg passed as an argument will be freed by blkg_create, so there is no need to free it again. Signed-off-by: Hou Tao <houtao1@huawei.com> Signed-off-by: Jens Axboe <axboe@fb.com>
return SUCCESS; } static PHP_MINIT_FUNCTION(tidy) { REGISTER_INI_ENTRIES(); REGISTER_TIDY_CLASS(tidy, doc, NULL, 0); REGISTER_TIDY_CLASS(tidyNode, node, NULL, ZEND_ACC_FINAL_CLASS); tidy_object_handlers_doc.cast_object = tidy_doc_cast_handler; tidy_object_handlers_node.cast_object = tidy_node_cast_handler; _p...
0
[]
php-src
ce96fd6b0761d98353761bf78d5bfb55291179fd
14,869,540,238,980,655,000,000,000,000,000,000,000
14
- 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
TEST_P(Http2CodecImplTest, PriorityFlood) { priorityFlood(); EXPECT_THROW(client_->sendPendingFrames(), ServerCodecError); }
0
[ "CWE-400" ]
envoy
0e49a495826ea9e29134c1bd54fdeb31a034f40c
320,037,149,223,144,480,000,000,000,000,000,000,000
4
http/2: add stats and stream flush timeout (#139) This commit adds a new stream flush timeout to guard against a remote server that does not open window once an entire stream has been buffered for flushing. Additional stats have also been added to better understand the codecs view of active streams as well as amount o...
static unsigned long get_sb_block(void **data) { unsigned long sb_block; char *options = (char *) *data; if (!options || strncmp(options, "sb=", 3) != 0) return 1; /* Default location */ options += 3; sb_block = simple_strtoul(options, &options, 0); if (*options && *options != ',') { printk("EXT2-fs: Inva...
0
[ "CWE-241", "CWE-19" ]
linux
be0726d33cb8f411945884664924bed3cb8c70ee
228,779,041,997,005,900,000,000,000,000,000,000,000
19
ext2: convert to mbcache2 The conversion is generally straightforward. We convert filesystem from a global cache to per-fs one. Similarly to ext4 the tricky part is that xattr block corresponding to found mbcache entry can get freed before we get buffer lock for that block. So we have to check whether the entry is sti...
GF_Err pasp_Read(GF_Box *s, GF_BitStream *bs) { GF_PixelAspectRatioBox *ptr = (GF_PixelAspectRatioBox*)s; ptr->hSpacing = gf_bs_read_u32(bs); ptr->vSpacing = gf_bs_read_u32(bs); ISOM_DECREASE_SIZE(ptr, 8); return GF_OK; }
0
[ "CWE-125" ]
gpac
bceb03fd2be95097a7b409ea59914f332fb6bc86
54,777,020,291,323,330,000,000,000,000,000,000,000
8
fixed 2 possible heap overflows (inc. #1088)
static void nvme_compare_mdata_cb(void *opaque, int ret) { NvmeRequest *req = opaque; NvmeNamespace *ns = req->ns; NvmeCtrl *n = nvme_ctrl(req); NvmeRwCmd *rw = (NvmeRwCmd *)&req->cmd; uint8_t prinfo = NVME_RW_PRINFO(le16_to_cpu(rw->control)); uint16_t apptag = le16_to_cpu(rw->apptag); uint1...
0
[]
qemu
736b01642d85be832385063f278fe7cd4ffb5221
113,327,137,796,586,310,000,000,000,000,000,000,000
85
hw/nvme: fix CVE-2021-3929 This fixes CVE-2021-3929 "locally" by denying DMA to the iomem of the device itself. This still allows DMA to MMIO regions of other devices (e.g. doing P2P DMA to the controller memory buffer of another NVMe device). Fixes: CVE-2021-3929 Reported-by: Qiuhao Li <Qiuhao.Li@outlook.com> Review...
void PSOutputDev::writeXpdfProcset() { GBool lev1, lev2, lev3, sep, nonSep; char **p; char *q; writePSFmt("%%BeginResource: procset xpdf {0:s} 0\n", "3.00"); writePSFmt("%%Copyright: {0:s}\n", xpdfCopyright); lev1 = lev2 = lev3 = sep = nonSep = gTrue; for (p = prolog; *p; ++p) { if ((*p)[0] == '~') {...
0
[]
poppler
abf167af8b15e5f3b510275ce619e6fdb42edd40
169,190,468,809,389,240,000,000,000,000,000,000,000
37
Implement tiling/patterns in SplashOutputDev Fixes bug 13518
static void MagickPNGWarningHandler(png_struct *ping,png_const_charp message) { ExceptionInfo *exception; Image *image; PNGErrorInfo *error_info; if (LocaleCompare(message, "Missing PLTE before tRNS") == 0) png_error(ping, message); error_info=(PNGErrorInfo *) png_get_error_ptr(ping); im...
0
[ "CWE-476" ]
ImageMagick
816ecab6c532ae086ff4186b3eaf4aa7092d536f
155,862,348,082,870,360,000,000,000,000,000,000,000
23
https://github.com/ImageMagick/ImageMagick/issues/58
xmlIsLetter(int c) { return(IS_BASECHAR(c) || IS_IDEOGRAPHIC(c)); }
0
[ "CWE-119" ]
libxml2
23f05e0c33987d6605387b300c4be5da2120a7ab
162,438,645,702,244,370,000,000,000,000,000,000,000
3
Detect excessive entities expansion upon replacement If entities expansion in the XML parser is asked for, it is possble to craft relatively small input document leading to excessive on-the-fly content generation. This patch accounts for those replacement and stop parsing after a given threshold. it can be bypassed as...
void mlsd_fact(char fact, char *buf, size_t len, char *name, char *perms, struct stat *st) { char size[20]; switch (fact) { case 'm': strlcat(buf, "modify=", len); strlcat(buf, mlsd_time(st->st_mtime), len); break; case 'p': strlcat(buf, "perm=", len); strlcat(buf, perms, len); break; case 't': st...
0
[ "CWE-120", "CWE-787" ]
uftpd
0fb2c031ce0ace07cc19cd2cb2143c4b5a63c9dd
269,265,994,209,335,030,000,000,000,000,000,000,000
34
FTP: Fix buffer overflow in PORT parser, reported by Aaron Esau Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
int cli_matchmeta(cli_ctx *ctx, const char *fname, size_t fsizec, size_t fsizer, int encrypted, unsigned int filepos, int res1, void *res2) { const struct cli_cdb *cdb; unsigned int viruses_found = 0; int ret = CL_CLEAN; cli_dbgmsg("CDBNAME:%s:%llu:%s:%llu:%llu:%d:%u:%u:%p\n", cli_ftname(cli_get_...
1
[]
clamav-devel
167c0079292814ec5523d0b97a9e1b002bf8819b
117,389,727,780,499,880,000,000,000,000,000,000,000
61
fix 0.99.3 false negative of virus Pdf.Exploit.CVE_2016_1046-1.
set_unix_port(edge_connection_t *conn, rend_service_port_config_t *p) { tor_assert(conn); tor_assert(p); tor_assert(p->is_unix_addr); conn->base_.socket_family = AF_UNIX; tor_addr_make_unspec(&conn->base_.addr); conn->base_.port = 1; conn->base_.address = tor_strdup(p->unix_addr); return 0; }
0
[ "CWE-532" ]
tor
09ea89764a4d3a907808ed7d4fe42abfe64bd486
172,730,866,335,438,560,000,000,000,000,000,000,000
12
Fix log-uninitialized-stack bug in rend_service_intro_established. Fixes bug 23490; bugfix on 0.2.7.2-alpha. TROVE-2017-008 CVE-2017-0380
bool isRoutable() const override { return false; }
0
[ "CWE-400" ]
envoy
dfddb529e914d794ac552e906b13d71233609bf7
185,242,985,801,624,460,000,000,000,000,000,000,000
1
listener: Add configurable accepted connection limits (#153) Add support for per-listener limits on accepted connections. Signed-off-by: Tony Allen <tony@allen.gg>
static void ipa_region_frame(wmfAPI * API, wmfPolyRectangle_t * poly_rect) { /* Save graphic wand */ (void) PushDrawingWand(WmfDrawingWand); if (TO_FILL(poly_rect) || TO_DRAW(poly_rect)) { long i; draw_fill_color_string(WmfDrawingWand,"none"); util_set_brush(API, poly_rect->dc, Bru...
0
[ "CWE-772" ]
ImageMagick
b2b48d50300a9fbcd0aa0d9230fd6d7a08f7671e
36,851,430,811,751,483,000,000,000,000,000,000,000
24
https://github.com/ImageMagick/ImageMagick/issues/544
static int sctp_setsockopt_default_sndinfo(struct sock *sk, struct sctp_sndinfo *info, unsigned int optlen) { struct sctp_sock *sp = sctp_sk(sk); struct sctp_association *asoc; if (optlen != sizeof(*info)) return -EINVAL; if (info->snd_flags & ~(SCTP_UNORDERED | SCTP_ADDR_OVER | SCTP_...
0
[ "CWE-362" ]
linux
b166a20b07382b8bc1dcee2a448715c9c2c81b5b
15,348,127,749,340,300,000,000,000,000,000,000,000
51
net/sctp: fix race condition in sctp_destroy_sock If sctp_destroy_sock is called without sock_net(sk)->sctp.addr_wq_lock held and sp->do_auto_asconf is true, then an element is removed from the auto_asconf_splist without any proper locking. This can happen in the following functions: 1. In sctp_accept, if sctp_sock_m...
TEST_P(RBACIntegrationTest, HeaderMatchCondition) { config_helper_.addFilter(fmt::format(RBAC_CONFIG_HEADER_MATCH_CONDITION, "yyy")); initialize(); codec_client_ = makeHttpConnection(lookupPort("http")); auto response = codec_client_->makeRequestWithBody( Http::TestRequestHeaderMapImpl{ {":met...
0
[]
envoy
2c60632d41555ec8b3d9ef5246242be637a2db0f
60,391,297,392,304,760,000,000,000,000,000,000,000
22
http: header map security fixes for duplicate headers (#197) Previously header matching did not match on all headers for non-inline headers. This patch changes the default behavior to always logically match on all headers. Multiple individual headers will be logically concatenated with ',' similar to what is done with...
static void *rose_neigh_next(struct seq_file *seq, void *v, loff_t *pos) { ++*pos; return (v == SEQ_START_TOKEN) ? rose_neigh_list : ((struct rose_neigh *)v)->next; }
0
[]
linux
148ca04518070910739dfc4eeda765057856403d
259,345,453,213,798,800,000,000,000,000,000,000,000
7
net: rose: fix UAF bug caused by rose_t0timer_expiry There are UAF bugs caused by rose_t0timer_expiry(). The root cause is that del_timer() could not stop the timer handler that is running and there is no synchronization. One of the race conditions is shown below: (thread 1) | (thread 2) ...
ProcQueueInit(PROC_QUEUE *queue) { SHMQueueInit(&(queue->links)); queue->size = 0; }
0
[ "CWE-89" ]
postgres
2b3a8b20c2da9f39ffecae25ab7c66974fbc0d3b
11,231,703,852,939,038,000,000,000,000,000,000,000
5
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...
static bool cmd_read_dma(IDEState *s, uint8_t cmd) { bool lba48 = (cmd == WIN_READDMA_EXT); if (!s->blk) { ide_abort_command(s); return true; } ide_cmd_lba48_transform(s, lba48); ide_sector_start_dma(s, IDE_DMA_READ); return false; }
0
[ "CWE-399" ]
qemu
3251bdcf1c67427d964517053c3d185b46e618e8
105,715,145,536,075,750,000,000,000,000,000,000,000
14
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...
static int dec(struct cstate *g, int c) { if (c >= '0' && c <= '9') return c - '0'; die(g, "invalid quantifier"); return 0; }
0
[ "CWE-703", "CWE-674" ]
mujs
160ae29578054dc09fd91e5401ef040d52797e61
35,942,881,872,111,996,000,000,000,000,000,000,000
6
Issue #162: Check stack overflow during regexp compilation. Only bother checking during the first compilation pass that counts the size of the program.
Item_cache_real(THD *thd, const Type_handler *h) :Item_cache(thd, h), value(0) {}
0
[ "CWE-617" ]
server
807945f2eb5fa22e6f233cc17b85a2e141efe2c8
135,494,014,456,997,300,000,000,000,000,000,000,000
4
MDEV-26402: A SEGV in Item_field::used_tables/update_depend_map_for_order... When doing condition pushdown from HAVING into WHERE, Item_equal::create_pushable_equalities() calls item->set_extraction_flag(IMMUTABLE_FL) for constant items. Then, Item::cleanup_excluding_immutables_processor() checks for this flag to see ...
RateLimiter(qqueue_t *pThis) { DEFiRet; int iDelay; int iHrCurr; time_t tCurr; struct tm m; ISOBJ_TYPE_assert(pThis, qqueue); iDelay = 0; if(pThis->iDeqtWinToHr != 25) { /* 25 means disabled */ /* time calls are expensive, so only do them when needed */ datetime.GetTime(&tCurr); localtime_r(&tCurr, &m);...
0
[ "CWE-772" ]
rsyslog
dfa88369d4ca4290db56b843f9eabdae1bfe0fd5
294,661,340,683,307,440,000,000,000,000,000,000,000
55
bugfix: memory leak when $RepeatedMsgReduction on was used bug tracker: http://bugzilla.adiscon.com/show_bug.cgi?id=225
static inline funcid_t readAPIFuncID(struct cli_bc *bc, unsigned char *p, unsigned *off, unsigned len, char *ok) { funcid_t id = readNumber(p, off, len, ok)-1; if (*ok && !cli_bitset_test(bc->uses_apis, id)) { cli_errmsg("Called undeclared API function: %u\n", id); *ok = 0; return ~0; } retu...
0
[ "CWE-189" ]
clamav-devel
3d664817f6ef833a17414a4ecea42004c35cc42f
64,849,602,926,787,330,000,000,000,000,000,000,000
11
fix recursion level crash (bb #3706). Thanks to Stephane Chazelas for the analysis.
static void gf_dom_refresh_event_filter(GF_SceneGraph *sg) { GF_SceneGraph *par; u32 prev_flags = sg->dom_evt_filter; sg->dom_evt_filter = 0; if (sg->nb_evts_mouse) sg->dom_evt_filter |= GF_DOM_EVENT_MOUSE; if (sg->nb_evts_focus) sg->dom_evt_filter |= GF_DOM_EVENT_FOCUS; if (sg->nb_evts_key) sg->dom_evt_filter |...
0
[ "CWE-416" ]
gpac
9723dd0955894f2cb7be13b94cf7a47f2754b893
257,349,062,215,749,200,000,000,000,000,000,000,000
25
fixed #2109
void CIRCSock::PutIRC(const CString& sLine) { PutIRC(CMessage(sLine)); }
0
[ "CWE-20", "CWE-284" ]
znc
d22fef8620cdd87490754f607e7153979731c69d
67,614,457,566,072,690,000,000,000,000,000,000,000
3
Better cleanup lines coming from network. Thanks for Jeriko One <jeriko.one@gmx.us> for finding and reporting this.
static void xennet_tx_setup_grant(unsigned long gfn, unsigned int offset, unsigned int len, void *data) { struct xennet_gnttab_make_txreq *info = data; unsigned int id; struct xen_netif_tx_request *tx; grant_ref_t ref; /* convenient aliases */ struct page *page = info->page; struct netfront_queue *queue = ...
0
[]
linux
f63c2c2032c2e3caad9add3b82cc6e91c376fd26
339,929,557,758,556,150,000,000,000,000,000,000,000
41
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 OPJ_BOOL opj_tcd_t1_encode ( opj_tcd_t *p_tcd ) { opj_t1_t * l_t1; const OPJ_FLOAT64 * l_mct_norms; OPJ_UINT32 l_mct_numcomps = 0U; opj_tcp_t * l_tcp = p_tcd->tcp; l_t1 = opj_t1_create(OPJ_TRUE); if (l_t1 == 00) { return OPJ_FALSE; } ...
0
[ "CWE-369" ]
openjpeg
8f9cc62b3f9a1da9712329ddcedb9750d585505c
207,684,976,924,986,400,000,000,000,000,000,000,000
36
Fix division by zero Fix uclouvain/openjpeg#733
e1000e_intmgr_timer_resume(E1000IntrDelayTimer *timer) { if (timer->running) { e1000e_intrmgr_rearm_timer(timer); } }
0
[ "CWE-835" ]
qemu
4154c7e03fa55b4cf52509a83d50d6c09d743b77
298,381,396,430,473,070,000,000,000,000,000,000,000
6
net: e1000e: fix an infinite loop issue This issue is like the issue in e1000 network card addressed in this commit: e1000: eliminate infinite loops on out-of-bounds transfer start. Signed-off-by: Li Qiang <liqiang6-s@360.cn> Reviewed-by: Dmitry Fleytman <dmitry@daynix.com> Signed-off-by: Jason Wang <jasowang@redhat....
scroll_cursor_top(int min_scroll, int always) { int scrolled = 0; int extra = 0; int used; int i; linenr_T top; // just above displayed lines linenr_T bot; // just below displayed lines linenr_T old_topline = curwin->w_topline; #ifdef FEAT_DIFF linenr_T old_topfill = curwin->w_topf...
0
[ "CWE-122" ]
vim
777e7c21b7627be80961848ac560cb0a9978ff43
150,651,827,368,098,730,000,000,000,000,000,000,000
130
patch 8.2.3564: invalid memory access when scrolling without valid screen Problem: Invalid memory access when scrolling without a valid screen. Solution: Do not set VALID_BOTLINE in w_valid.
static int nfs4_xdr_enc_setclientid(struct rpc_rqst *req, __be32 *p, struct nfs4_setclientid *sc) { struct xdr_stream xdr; struct compound_hdr hdr = { .nops = 1, }; xdr_init_encode(&xdr, &req->rq_snd_buf, p); encode_compound_hdr(&xdr, &hdr); return encode_setclientid(&xdr, sc); }
0
[ "CWE-703" ]
linux
dc0b027dfadfcb8a5504f7d8052754bf8d501ab9
329,678,407,054,629,000,000,000,000,000,000,000,000
11
NFSv4: Convert the open and close ops to use fmode Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
static void parse_feature(const char *feature) { if (seen_data_command) die("Got feature command '%s' after data command", feature); if (parse_one_feature(feature, 1)) return; die("This version of fast-import does not support feature %s.", feature); }
0
[]
git
68061e3470210703cb15594194718d35094afdc0
278,093,642,077,259,200,000,000,000,000,000,000,000
10
fast-import: disallow "feature export-marks" by default The fast-import stream command "feature export-marks=<path>" lets the stream write marks to an arbitrary path. This may be surprising if you are running fast-import against an untrusted input (which otherwise cannot do anything except update Git objects and refs)...