func
string
target
int64
cwe
list
project
string
commit_id
string
hash
float64
size
int64
message
string
static int x509v3_add_len_value(const char *name, const char *value, size_t vallen, STACK_OF(CONF_VALUE) **extlist) { CONF_VALUE *vtmp = NULL; char *tname = NULL, *tvalue = NULL; int sk_allocated = (*extlist == NULL); if (name != NULL && (tname = OPENSSL_strdup(name)) ==...
0
[ "CWE-125" ]
openssl
bb4d2ed4091408404e18b3326e3df67848ef63d0
144,805,608,536,196,330,000,000,000,000,000,000,000
41
Fix append_ia5 function to not assume NUL terminated strings ASN.1 strings may not be NUL terminated. Don't assume they are. CVE-2021-3712 Reviewed-by: Viktor Dukhovni <viktor@openssl.org> Reviewed-by: Paul Dale <pauli@openssl.org>
static struct fuse_req *get_reserved_req(struct fuse_conn *fc, struct file *file) { struct fuse_req *req = NULL; struct fuse_file *ff = file->private_data; do { wait_event(fc->reserved_req_waitq, ff->reserved_req); spin_lock(&fc->lock); if (ff->reserved_req) { req = ff->reserved_req; ff->reserved_...
0
[ "CWE-416" ]
linux
15fab63e1e57be9fdb5eec1bbc5916e9825e9acb
100,841,290,887,477,160,000,000,000,000,000,000,000
19
fs: prevent page refcount overflow in pipe_buf_get Change pipe_buf_get() to return a bool indicating whether it succeeded in raising the refcount of the page (if the thing in the pipe is a page). This removes another mechanism for overflowing the page refcount. All callers converted to handle a failure. Reported-by:...
template<> struct type<double> {
0
[ "CWE-125" ]
CImg
10af1e8c1ad2a58a0a3342a856bae63e8f257abb
77,103,032,680,151,090,000,000,000,000,000,000,000
1
Fix other issues in 'CImg<T>::load_bmp()'.
int TS_REQ_set_cert_req(TS_REQ *a, int cert_req) { a->cert_req = cert_req ? 0xFF : 0x00; return 1; }
0
[]
openssl
c7235be6e36c4bef84594aa3b2f0561db84b63d8
183,558,505,233,998,370,000,000,000,000,000,000,000
5
RFC 3161 compliant time stamp request creation, response generation and response verification. Submitted by: Zoltan Glozik <zglozik@opentsa.org> Reviewed by: Ulf Moeller
static int r_bin_dwarf_expand_debug_abbrev(RBinDwarfDebugAbbrev *da) { RBinDwarfAbbrevDecl *tmp; if (!da || da->capacity == 0 || da->capacity != da->length) { return -EINVAL; } tmp = (RBinDwarfAbbrevDecl*)realloc (da->decls, da->capacity * 2 * sizeof (RBinDwarfAbbrevDecl)); if (!tmp) { return -ENOMEM; }...
0
[ "CWE-119", "CWE-125" ]
radare2
d37d2b858ac47f2f108034be0bcecadaddfbc8b3
229,687,333,614,387,740,000,000,000,000,000,000,000
20
Fix #10465 - Avoid string on low addresses (workaround) for corrupted dwarf (#10478)
static int put_v4l2_plane32(struct v4l2_plane __user *up, struct v4l2_plane32 __user *up32, enum v4l2_memory memory) { unsigned long p; if (copy_in_user(up32, up, 2 * sizeof(__u32)) || copy_in_user(&up32->data_offset, &up->data_offset, sizeof(up->data_offset))) return -EFAULT; switch (memory) { ...
1
[ "CWE-787" ]
linux
a1dfb4c48cc1e64eeb7800a27c66a6f7e88d075a
209,766,002,264,431,000,000,000,000,000,000,000,000
32
media: v4l2-compat-ioctl32.c: refactor compat ioctl32 logic The 32-bit compat v4l2 ioctl handling is implemented based on its 64-bit equivalent. It converts 32-bit data structures into its 64-bit equivalents and needs to provide the data to the 64-bit ioctl in user space memory which is commonly allocated using compat...
ves_icall_System_Array_GetLowerBound (MonoArray *this, gint32 dimension) { gint32 rank = ((MonoObject *)this)->vtable->klass->rank; MONO_ARCH_SAVE_REGS; if ((dimension < 0) || (dimension >= rank)) mono_raise_exception (mono_get_exception_index_out_of_range ()); if (this->bounds == NULL) return 0; return ...
0
[ "CWE-264" ]
mono
035c8587c0d8d307e45f1b7171a0d337bb451f1e
263,674,922,774,988,760,000,000,000,000,000,000,000
14
Allow only primitive types/enums in RuntimeHelpers.InitializeArray ().
static gboolean seid_rej_to_err(struct seid_rej *rej, unsigned int size, struct avdtp_error *err) { if (size < sizeof(struct seid_rej)) { error("Too small packet for seid_rej"); return FALSE; } avdtp_error_init(err, 0x00, rej->error); return TRUE; }
0
[ "CWE-703" ]
bluez
7a80d2096f1b7125085e21448112aa02f49f5e9a
95,004,394,301,149,620,000,000,000,000,000,000,000
12
avdtp: Fix accepting invalid/malformed capabilities Check if capabilities are valid before attempting to copy them.
recv_hello(gnutls_session_t session, uint8_t * data, int datalen) { int ret; if (session->security_parameters.entity == GNUTLS_CLIENT) { ret = read_server_hello(session, data, datalen); if (ret < 0) { gnutls_assert(); return ret; } } else { /* Server side reading a client hello */ ret = read_client_...
0
[ "CWE-310" ]
gnutls
db9a7d810f9ee4c9cc49731f5fd9bdeae68d7eaa
331,071,919,358,524,880,000,000,000,000,000,000,000
21
handshake: check for TLS_FALLBACK_SCSV If TLS_FALLBACK_SCSV was sent by the client during the handshake, and the advertised protocol version is lower than GNUTLS_TLS_VERSION_MAX, send the "Inappropriate fallback" fatal alert and abort the handshake. This mechanism was defined in RFC7507.
TEST_P(DownstreamProtocolIntegrationTest, LargeRequestUrlRejected) { // Send one 95 kB URL with limit 60 kB headers. testLargeRequestUrl(95, 60); }
0
[ "CWE-770" ]
envoy
7ca28ff7d46454ae930e193d97b7d08156b1ba59
239,085,509,344,595,040,000,000,000,000,000,000,000
4
[http1] Include request URL in request header size computation, and reject partial headers that exceed configured limits (#145) Signed-off-by: antonio <avd@google.com>
xmlSchemaVReaderWalk(xmlSchemaValidCtxtPtr vctxt) { const int WHTSP = 13, SIGN_WHTSP = 14, END_ELEM = 15; int depth, nodeType, ret = 0, consumed; xmlSchemaNodeInfoPtr ielem; vctxt->depth = -1; ret = xmlTextReaderRead(vctxt->reader); /* * Move to the document element. */ while (ret =...
0
[ "CWE-134" ]
libxml2
4472c3a5a5b516aaf59b89be602fbce52756c3e9
167,681,718,130,640,170,000,000,000,000,000,000,000
189
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.
int rtnl_delete_link(struct net_device *dev) { const struct rtnl_link_ops *ops; LIST_HEAD(list_kill); ops = dev->rtnl_link_ops; if (!ops || !ops->dellink) return -EOPNOTSUPP; ops->dellink(dev, &list_kill); unregister_netdevice_many(&list_kill); return 0; }
0
[ "CWE-200" ]
net
5f8e44741f9f216e33736ea4ec65ca9ac03036e6
194,137,469,461,094,400,000,000,000,000,000,000,000
14
net: fix infoleak in rtnetlink The stack object “map” has a total size of 32 bytes. Its last 4 bytes are padding generated by compiler. These padding bytes are not initialized and sent out via “nla_put”. Signed-off-by: Kangjie Lu <kjlu@gatech.edu> Signed-off-by: David S. Miller <davem@davemloft.net>
ssize_t packet_get(int fd, struct gps_packet_t *lexer) /* grab a packet; return -1=>I/O error, 0=>EOF, BAD_PACKET or a length */ { ssize_t recvd; /*@ -modobserver @*/ errno = 0; recvd = read(fd, lexer->inbuffer + lexer->inbuflen, sizeof(lexer->inbuffer) - (lexer->inbuflen)); /*@ +modobserver @*/...
0
[]
gpsd
dd9c3c2830cb8f8fd8491ce68c82698dc5538f50
148,509,348,971,485,100,000,000,000,000,000,000,000
77
Fix a malformed-packet crash. Under weird circumstances, this line of device input $GPGGA,030130$GPGLL,2638.1728,N,08011.3893,W,030131.000,A,A*41 could core-dump the packet parser. The context had to be exactly right for it to happen. The bug was an incorrect attempt at optimizing recovery from this rare case.
static int jp2_bpcc_getdata(jp2_box_t *box, jas_stream_t *in) { jp2_bpcc_t *bpcc = &box->data.bpcc; unsigned int i; bpcc->numcmpts = box->datalen; if (!(bpcc->bpcs = jas_malloc(bpcc->numcmpts * sizeof(uint_fast8_t)))) { return -1; } for (i = 0; i < bpcc->numcmpts; ++i) { if (jp2_getuint8(in, &bpcc->bpcs[i])) ...
1
[ "CWE-189" ]
jasper
3c55b399c36ef46befcb21e4ebc4799367f89684
174,232,309,941,156,660,000,000,000,000,000,000,000
15
At many places in the code, jas_malloc or jas_recalloc was being invoked with the size argument being computed in a manner that would not allow integer overflow to be detected. Now, these places in the code have been modified to use special-purpose memory allocation functions (e.g., jas_alloc2, jas_alloc3, jas_realloc...
psutil_proc_name(PyObject *self, PyObject *args) { long pid; int ok; PROCESSENTRY32W pentry; HANDLE hSnapShot; if (! PyArg_ParseTuple(args, "l", &pid)) return NULL; hSnapShot = CreateToolhelp32Snapshot(TH32CS_SNAPPROCESS, pid); if (hSnapShot == INVALID_HANDLE_VALUE) return P...
0
[ "CWE-415" ]
psutil
7d512c8e4442a896d56505be3e78f1156f443465
282,220,311,803,831,280,000,000,000,000,000,000,000
31
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...
static MagickBooleanType TraceSVGImage(Image *image,ExceptionInfo *exception) { #if defined(MAGICKCORE_AUTOTRACE_DELEGATE) { at_bitmap_type *trace; at_fitting_opts_type *fitting_options; at_output_opts_type *output_options; at_splines_type *splines; ImageType type...
0
[ "CWE-674" ]
ImageMagick6
6ba5e4b1673d75988d8dde38118b495a342823c8
7,056,007,318,606,287,000,000,000,000,000,000,000
173
[FG-VD-19-136] ImageMagick Convert SVG MacOS Denial Of Service
static __le32 ext4_xattr_block_csum(struct inode *inode, sector_t block_nr, struct ext4_xattr_header *hdr) { struct ext4_sb_info *sbi = EXT4_SB(inode->i_sb); __u32 csum; __le64 dsk_block_nr = cpu_to_le64(block_nr); __u32 dummy_csum = 0; int offset = offsetof(struct ext4_xattr_header, h_checksum); ...
0
[]
linux
54dd0e0a1b255f115f8647fc6fb93273251b01b9
267,906,104,964,882,930,000,000,000,000,000,000,000
20
ext4: add extra checks to ext4_xattr_block_get() Add explicit checks in ext4_xattr_block_get() just in case the e_value_offs and e_value_size fields in the the xattr block are corrupted in memory after the buffer_verified bit is set on the xattr block. Signed-off-by: Theodore Ts'o <tytso@mit.edu> Cc: stable@kernel.or...
u64 __init efi_mem_desc_end(efi_memory_desc_t *md) { u64 size = md->num_pages << EFI_PAGE_SHIFT; u64 end = md->phys_addr + size; return end; }
0
[]
linux
1957a85b0032a81e6482ca4aab883643b8dae06e
224,307,957,624,994,770,000,000,000,000,000,000,000
6
efi: Restrict efivar_ssdt_load when the kernel is locked down efivar_ssdt_load allows the kernel to import arbitrary ACPI code from an EFI variable, which gives arbitrary code execution in ring 0. Prevent that when the kernel is locked down. Signed-off-by: Matthew Garrett <mjg59@google.com> Acked-by: Ard Biesheuvel <...
inline cimg_uint64& rng() { // Used as a shared global number for rng static cimg_uint64 rng = 0xB16B00B5U; return rng; }
0
[ "CWE-770" ]
cimg
619cb58dd90b4e03ac68286c70ed98acbefd1c90
11,992,714,501,056,692,000,000,000,000,000,000,000
4
CImg<>::load_bmp() and CImg<>::load_pandore(): Check that dimensions encoded in file does not exceed file size.
void regulator_set_drvdata(struct regulator *regulator, void *data) { regulator->rdev->reg_data = data; }
0
[ "CWE-416" ]
linux
60a2362f769cf549dc466134efe71c8bf9fbaaba
49,173,029,038,108,230,000,000,000,000,000,000,000
4
regulator: core: Fix regualtor_ena_gpio_free not to access pin after freeing After freeing pin from regulator_ena_gpio_free, loop can access the pin. So this patch fixes not to access pin after freeing. Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com> Signed-off-by: Mark Brown <broonie@kernel.org>
parser_parse_do_while_statement_end (parser_context_t *context_p) /**< context */ { parser_loop_statement_t loop; JERRY_ASSERT (context_p->stack_top_uint8 == PARSER_STATEMENT_DO_WHILE); if (context_p->token.type != LEXER_KEYW_WHILE) { parser_raise_error (context_p, PARSER_ERR_WHILE_EXPECTED); } parse...
0
[ "CWE-416" ]
jerryscript
3bcd48f72d4af01d1304b754ef19fe1a02c96049
244,337,137,192,262,860,000,000,000,000,000,000,000
53
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
R_API bool r_core_init(RCore *core) { core->blocksize = R_CORE_BLOCKSIZE; core->block = (ut8 *)calloc (R_CORE_BLOCKSIZE + 1, 1); if (!core->block) { eprintf ("Cannot allocate %d byte(s)\n", R_CORE_BLOCKSIZE); /* XXX memory leak */ return false; } r_core_setenv (core); core->ev = r_event_new (core); r_event...
0
[ "CWE-415", "CWE-703" ]
radare2
cb8b683758edddae2d2f62e8e63a738c39f92683
65,264,357,371,373,170,000,000,000,000,000,000,000
216
Fix #16303 - c->table_query double free (#16318)
int compat_udp_setsockopt(struct sock *sk, int level, int optname, char __user *optval, int optlen) { if (level == SOL_UDP || level == SOL_UDPLITE) return udp_lib_setsockopt(sk, level, optname, optval, optlen, udp_push_pending_frames); return compat_ip_setsockopt(sk, level, optname, optval, optlen); }
0
[]
linux-2.6
32c1da70810017a98aa6c431a5494a302b6b9a30
153,726,987,684,240,370,000,000,000,000,000,000,000
8
[UDP]: Randomize port selection. This patch causes UDP port allocation to be randomized like TCP. The earlier code would always choose same port (ie first empty list). Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org> Signed-off-by: David S. Miller <davem@davemloft.net>
R_API REgg *r_egg_new() { int i; REgg *egg = R_NEW0 (REgg); if (!egg) { return NULL; } egg->src = r_buf_new (); if (!egg->src) { goto beach; } egg->buf = r_buf_new (); if (!egg->buf) { goto beach; } egg->bin = r_buf_new (); if (!egg->bin) { goto beach; } egg->remit = &emit_x86; egg->syscall = r_s...
0
[ "CWE-125" ]
radare2
e710401ebb4a892a87b0c709d709af8b5dcbbb01
193,379,438,180,694,080,000,000,000,000,000,000,000
47
patch #14211 heap buffer overflow in large ragg2 inputs. this should be refactored to use an RBuffer to enable dynamic resizing, but for now just patching it to bail out if we are about to overwrite the allocated statically sized buffer
static int CheckExternalAddress(pcp_info_t* pcp_msg_info) { /* can contain a IPv4-mapped IPv6 address */ static struct in6_addr external_addr; int af; af = IN6_IS_ADDR_V4MAPPED(pcp_msg_info->mapped_ip) ? AF_INET : AF_INET6; pcp_msg_info->is_fw = af == AF_INET6; if (pcp_msg_info->is_fw) { external_addr = *p...
0
[ "CWE-476" ]
miniupnp
cb8a02af7a5677cf608e86d57ab04241cf34e24f
236,738,844,527,078,600,000,000,000,000,000,000,000
71
pcpserver.c: copyIPv6IfDifferent() check for NULL src argument
static gint conv_anytoutf8(gchar *outbuf, gint outlen, const gchar *inbuf) { gint r = -1; switch (conv_guess_ja_encoding(inbuf)) { case C_ISO_2022_JP: r = conv_jistoutf8(outbuf, outlen, inbuf); break; case C_SHIFT_JIS: r = conv_sjistoutf8(outbuf, outlen, inbuf); break; case C_EUC_JP: r = conv_euctoutf8(o...
0
[ "CWE-119" ]
claws
d390fa07f5548f3173dd9cc13b233db5ce934c82
132,789,026,687,382,060,000,000,000,000,000,000,000
21
Make sure we don't run out of the output buffer. Maybe fixes bug #3557
block_name (gint id) { static const gchar *block_names[] = { "IMAGE", "CREATOR", "COLOR", "LAYER_START", "LAYER", "CHANNEL", "SELECTION", "ALPHA_BANK", "ALPHA_CHANNEL", "THUMBNAIL", "EXTENDED_DATA", "TUBE", "ADJUSTMENT_EXTENSION", "VECTOR_EXTENSION_BLOCK", ...
0
[ "CWE-787" ]
gimp
48ec15890e1751dede061f6d1f469b6508c13439
225,862,292,290,302,580,000,000,000,000,000,000,000
34
file-psp: fix for bogus input data. Fixes bug #639203
int dtls1_enc(SSL *s, int send) { SSL3_RECORD *rec; EVP_CIPHER_CTX *ds; unsigned long l; int bs,i,ii,j,k,n=0; const EVP_CIPHER *enc; if (send) { if (EVP_MD_CTX_md(s->write_hash)) { n=EVP_MD_CTX_size(s->write_hash); if (n < 0) return -1; } ds=s->enc_write_ctx; rec= &(s->s3->wrec); if (s...
1
[ "CWE-310" ]
openssl
e5420be6cd09af2550b128575a675490cfba0483
172,934,052,574,891,960,000,000,000,000,000,000,000
160
Make CBC decoding constant time. This patch makes the decoding of SSLv3 and TLS CBC records constant time. Without this, a timing side-channel can be used to build a padding oracle and mount Vaudenay's attack. This patch also disables the stitched AESNI+SHA mode pending a similar fix to that code. In order to be eas...
u_add_time(char_u *buf, size_t buflen, time_t tt) { #ifdef HAVE_STRFTIME struct tm *curtime; if (vim_time() - tt >= 100) { curtime = localtime(&tt); if (vim_time() - tt < (60L * 60L * 12L)) /* within 12 hours */ (void)strftime((char *)buf, buflen, "%H:%M:%S", curtime); else /* longer ago ...
0
[ "CWE-190" ]
vim
3eb1637b1bba19519885dd6d377bd5596e91d22c
114,628,118,247,252,280,000,000,000,000,000,000,000
20
patch 8.0.0377: possible overflow when reading corrupted undo file Problem: Possible overflow when reading corrupted undo file. Solution: Check if allocated size is not too big. (King)
static void fd_init(FDrive *drv) { /* Drive */ drv->drive = FDRIVE_DRV_NONE; drv->perpendicular = 0; /* Disk */ drv->last_sect = 0; drv->max_track = 0; }
0
[ "CWE-119" ]
qemu
e907746266721f305d67bc0718795fedee2e824c
145,598,442,126,303,430,000,000,000,000,000,000,000
9
fdc: force the fifo access to be in bounds of the allocated buffer During processing of certain commands such as FD_CMD_READ_ID and FD_CMD_DRIVE_SPECIFICATION_COMMAND the fifo memory access could get out of bounds leading to memory corruption with values coming from the guest. Fix this by making sure that the index i...
flatpak_dir_get_remote_state (FlatpakDir *self, const char *remote, gboolean only_cached, GCancellable *cancellable, GError **error) { return _flatpak_dir_get_remote_state (self, remot...
0
[ "CWE-74" ]
flatpak
fb473cad801c6b61706353256cab32330557374a
243,308,081,852,737,200,000,000,000,000,000,000,000
8
dir: Pass environment via bwrap --setenv when running apply_extra This means we can systematically pass the environment variables through bwrap(1), even if it is setuid and thus is filtering out security-sensitive environment variables. bwrap ends up being run with an empty environment instead. As with the previous c...
static void run_script(const char *action, double offset) { char *argv[3]; char *env1, *env2, *env3, *env4; G.last_script_run = G.cur_time; if (!G.script_name) return; argv[0] = (char*) G.script_name; argv[1] = (char*) action; argv[2] = NULL; VERB1 bb_error_msg("executing '%s %s'", G.script_name, action);...
0
[ "CWE-399" ]
busybox
150dc7a2b483b8338a3e185c478b4b23ee884e71
80,980,143,620,741,880,000,000,000,000,000,000,000
44
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...
STBIDEF int stbi_is_hdr_from_memory(stbi_uc const *buffer, int len) { #ifndef STBI_NO_HDR stbi__context s; stbi__start_mem(&s,buffer,len); return stbi__hdr_test(&s); #else STBI_NOTUSED(buffer); STBI_NOTUSED(len); return 0; #endif }
0
[ "CWE-787" ]
stb
5ba0baaa269b3fd681828e0e3b3ac0f1472eaf40
304,809,889,427,628,350,000,000,000,000,000,000,000
12
stb_image: Reject fractional JPEG component subsampling ratios The component resamplers are not written to support this and I've never seen it happen in a real (non-crafted) JPEG file so I'm fine rejecting this as outright corrupt. Fixes issue #1178.
void fix_char_length(size_t max_char_length_arg) { max_length= char_to_byte_length_safe(max_char_length_arg, collation.collation->mbmaxlen); }
0
[ "CWE-617" ]
server
2e7891080667c59ac80f788eef4d59d447595772
128,055,378,885,442,710,000,000,000,000,000,000,000
5
MDEV-25635 Assertion failure when pushing from HAVING into WHERE of view This bug could manifest itself after pushing a where condition over a mergeable derived table / view / CTE DT into a grouping view / derived table / CTE V whose item list contained set functions with constant arguments such as MIN(2), SUM(1) etc....
int TNEFFile_Close(TNEFIOStruct *IO) { TNEFFileInfo *finfo; finfo = (TNEFFileInfo *)IO->data; DEBUG1(finfo->Debug, 3, "Closing file %s", finfo->filename); if (finfo->fptr != NULL) { fclose(finfo->fptr); finfo->fptr = NULL; } return 0; }
0
[ "CWE-399", "CWE-125" ]
ytnef
3cb0f914d6427073f262e1b2b5fd973e3043cdf7
272,789,331,979,927,000,000,000,000,000,000,000,000
11
BugFix - Potential OOB with Fields of Size 0 Thanks to @hannob for contributing a malformed TNEF stream with a Version field of size 0. Now such files will return an error indicating invalid data.
log_rr(dns_name_t *name, dns_rdata_t *rdata, uint32_t ttl) { isc_result_t result; isc_buffer_t buf; char mem[2000]; dns_rdatalist_t rdl; dns_rdataset_t rds; dns_rdata_t rd = DNS_RDATA_INIT; dns_rdatalist_init(&rdl); rdl.type = rdata->type; rdl.rdclass = rdata->rdclass; rdl.ttl = ttl; if (rdata->type == dns_...
0
[ "CWE-732" ]
bind9
34348d9ee4db15307c6c42db294419b4df569f76
134,046,915,364,768,870,000,000,000,000,000,000,000
46
denied axfr requests were not effective for writable DLZ zones (cherry picked from commit d9077cd0038e59726e1956de18b4b7872038a283)
static void nf_tables_table_notify(const struct nft_ctx *ctx, int event) { struct nftables_pernet *nft_net; struct sk_buff *skb; int err; if (!ctx->report && !nfnetlink_has_listeners(ctx->net, NFNLGRP_NFTABLES)) return; skb = nlmsg_new(NLMSG_GOODSIZE, GFP_KERNEL); if (skb == NULL) goto err; err = nf_...
0
[ "CWE-665" ]
linux
ad9f151e560b016b6ad3280b48e42fa11e1a5440
19,346,566,094,892,830,000,000,000,000,000,000,000
27
netfilter: nf_tables: initialize set before expression setup nft_set_elem_expr_alloc() needs an initialized set if expression sets on the NFT_EXPR_GC flag. Move set fields initialization before expression setup. [4512935.019450] ================================================================== [4512935.019456] BUG: ...
Event_db_repository::table_scan_all_for_i_s(THD *thd, TABLE *schema_table, TABLE *event_table) { int ret; READ_RECORD read_record_info; DBUG_ENTER("Event_db_repository::table_scan_all_for_i_s"); if (init_read_record(&read_record_info, thd, event_table, NULL, NULL, 1,...
0
[ "CWE-416", "CWE-703" ]
server
08c7ab404f69d9c4ca6ca7a9cf7eec74c804f917
94,092,303,454,824,920,000,000,000,000,000,000,000
29
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...
ofputil_put_ofp14_port(const struct ofputil_phy_port *pp, struct ofpbuf *b) { struct ofp14_port *op; struct ofp14_port_desc_prop_ethernet *eth; ofpbuf_prealloc_tailroom(b, sizeof *op + sizeof *eth); op = ofpbuf_put_zeros(b, sizeof *op); op->port_no = ofputil_port_to_ofp11(pp->port_no); op->len...
0
[ "CWE-772" ]
ovs
77ad4225d125030420d897c873e4734ac708c66b
117,248,582,716,298,400,000,000,000,000,000,000,000
18
ofp-util: Fix memory leaks on error cases in ofputil_decode_group_mod(). Found by libFuzzer. Reported-by: Bhargava Shastry <bshastry@sec.t-labs.tu-berlin.de> Signed-off-by: Ben Pfaff <blp@ovn.org> Acked-by: Justin Pettit <jpettit@ovn.org>
__acquires(ps->lock) { struct urb *urb; struct async *as; /* Mark all the pending URBs that match bulk_addr, up to but not * including the first one without AS_CONTINUATION. If such an * URB is encountered then a new transfer has already started so * the endpoint doesn't need to be disabled; otherwise it doe...
0
[ "CWE-200" ]
linux
681fef8380eb818c0b845fca5d2ab1dcbab114ee
70,898,308,454,711,360,000,000,000,000,000,000,000
35
USB: usbfs: fix potential infoleak in devio The stack object “ci” has a total size of 8 bytes. Its last 3 bytes are padding bytes which are not initialized and leaked to userland via “copy_to_user”. Signed-off-by: Kangjie Lu <kjlu@gatech.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
static int ems_usb_set_bittiming(struct net_device *netdev) { struct ems_usb *dev = netdev_priv(netdev); struct can_bittiming *bt = &dev->can.bittiming; u8 btr0, btr1; btr0 = ((bt->brp - 1) & 0x3f) | (((bt->sjw - 1) & 0x3) << 6); btr1 = ((bt->prop_seg + bt->phase_seg1 - 1) & 0xf) | (((bt->phase_seg2 - 1) & 0x7)...
0
[ "CWE-415" ]
linux
c70222752228a62135cee3409dccefd494a24646
51,555,105,733,501,475,000,000,000,000,000,000,000
19
can: ems_usb: ems_usb_start_xmit(): fix double dev_kfree_skb() in error path There is no need to call dev_kfree_skb() when usb_submit_urb() fails beacause can_put_echo_skb() deletes the original skb and can_free_echo_skb() deletes the cloned skb. Link: https://lore.kernel.org/all/20220228083639.38183-1-hbh25y@gmail.c...
auto ReferenceHandle::Get(Local<Value> key_handle, MaybeLocal<Object> maybe_options) -> Local<Value> { return ThreePhaseTask::Run<async, GetRunner>(*isolate, *this, key_handle, maybe_options, inherit); }
1
[ "CWE-913" ]
isolated-vm
2646e6c1558bac66285daeab54c7d490ed332b15
270,695,074,599,171,930,000,000,000,000,000,000,000
3
Don't invoke accessors or proxies via Reference functions
QPDFWriter::write() { // Do preliminary setup if (this->linearized) { this->qdf_mode = false; } if (this->qdf_mode) { if (! this->normalize_content_set) { this->normalize_content = true; } if (! this->stream_data_mode_set) { this->stream_data_mode = qpdf_s_uncompress; } } ...
0
[ "CWE-399", "CWE-835" ]
qpdf
8249a26d69f72b9cda584c14cc3f12769985e481
102,295,733,971,096,280,000,000,000,000,000,000,000
160
Fix infinite loop in QPDFWriter (fixes #143)
PointGFp EC_Group::blinded_var_point_multiply(const PointGFp& point, const BigInt& k, RandomNumberGenerator& rng, std::vector<BigInt>& ws) const { PointGFp_Var_Point_Precompute...
0
[ "CWE-200" ]
botan
48fc8df51d99f9d8ba251219367b3d629cc848e3
84,911,756,275,999,680,000,000,000,000,000,000,000
9
Address DSA/ECDSA side channel
GF_Err subs_Size(GF_Box *s) { GF_SubSampleInformationBox *ptr = (GF_SubSampleInformationBox *) s; GF_SubSampleInfoEntry *pSamp; u32 entry_count, i; u16 subsample_count; // add 4 byte for entry_count ptr->size += 4; entry_count = gf_list_count(ptr->Samples); for (i=0; i<entry_count; i++) { pSamp = (GF_SubSam...
0
[ "CWE-400", "CWE-401" ]
gpac
d2371b4b204f0a3c0af51ad4e9b491144dd1225c
193,990,845,025,244,800,000,000,000,000,000,000,000
19
prevent dref memleak on invalid input (#1183)
_vte_terminal_clear_screen (VteTerminal *terminal) { VteRowData *rowdata, *old_row; long i, initial, row; VteScreen *screen; screen = terminal->pvt->screen; initial = screen->insert_delta; row = screen->cursor_current.row - screen->insert_delta; /* Add a new screen's worth of rows. */ old_row = terminal->pvt->f...
0
[]
vte
58bc3a942f198a1a8788553ca72c19d7c1702b74
164,446,319,617,649,550,000,000,000,000,000,000,000
33
fix bug #548272 svn path=/trunk/; revision=2365
cb_runchroot(const union sudo_defs_val *sd_un) { debug_decl(cb_runchroot, SUDOERS_DEBUG_PLUGIN); sudo_debug_printf(SUDO_DEBUG_INFO|SUDO_DEBUG_LINENO, "def_runchroot now %s", sd_un->str); if (user_cmnd != NULL) { /* Update user_cmnd based on the new chroot. */ cmnd_status = set_cmnd_path(sd_un->str); su...
0
[ "CWE-193" ]
sudo
1f8638577d0c80a4ff864a2aad80a0d95488e9a8
21,846,509,076,315,334,000,000,000,000,000,000,000
15
Fix potential buffer overflow when unescaping backslashes in user_args. Also, do not try to unescaping backslashes unless in run mode *and* we are running the command via a shell. Found by Qualys, this fixes CVE-2021-3156.
static bool packet_use_direct_xmit(const struct packet_sock *po) { return po->xmit == packet_direct_xmit; }
0
[ "CWE-416", "CWE-362" ]
linux
84ac7260236a49c79eede91617700174c2c19b0c
259,258,328,954,007,800,000,000,000,000,000,000,000
4
packet: fix race condition in packet_set_ring When packet_set_ring creates a ring buffer it will initialize a struct timer_list if the packet version is TPACKET_V3. This value can then be raced by a different thread calling setsockopt to set the version to TPACKET_V1 before packet_set_ring has finished. This leads to...
int version() const { assert(isValid()); return version_; }
0
[ "CWE-617" ]
exiv2
1647908e00a4df7246d76678e59587e62c690dcd
247,935,980,338,073,840,000,000,000,000,000,000,000
5
fix for crash in bigtiff (issue #208)
__acquires(RCU) { rcu_read_lock(); return igmp6_mc_get_idx(seq, *pos); }
0
[ "CWE-703" ]
linux
2d3916f3189172d5c69d33065c3c21119fe539fc
315,700,188,533,423,800,000,000,000,000,000,000,000
5
ipv6: fix skb drops in igmp6_event_query() and igmp6_event_report() While investigating on why a synchronize_net() has been added recently in ipv6_mc_down(), I found that igmp6_event_query() and igmp6_event_report() might drop skbs in some cases. Discussion about removing synchronize_net() from ipv6_mc_down() will ha...
static int selinux_task_setioprio(struct task_struct *p, int ioprio) { int rc; rc = cap_task_setioprio(p, ioprio); if (rc) return rc; return current_has_perm(p, PROCESS__SETSCHED); }
0
[]
linux-2.6
ee18d64c1f632043a02e6f5ba5e045bb26a5465f
70,706,853,655,759,590,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...
get_user_input( typval_T *argvars, typval_T *rettv, int inputdialog, int secret) { char_u *prompt; char_u *p = NULL; int c; char_u buf[NUMBUFLEN]; int cmd_silent_save = cmd_silent; char_u *defstr = (char_u *)""; int xp_type = EXPAND_NOTHING; char_u *xp_arg = NULL; ...
0
[ "CWE-122", "CWE-787" ]
vim
ef02f16609ff0a26ffc6e20263523424980898fe
220,094,901,755,287,530,000,000,000,000,000,000,000
115
patch 8.2.4899: with latin1 encoding CTRL-W might go before the cmdline Problem: With latin1 encoding CTRL-W might go before the start of the command line. Solution: Check already being at the start of the command line.
void cpu_watchpoint_remove_by_ref(CPUState *cpu, CPUWatchpoint *watchpoint) { QTAILQ_REMOVE(&cpu->watchpoints, watchpoint, entry); tlb_flush_page(cpu, watchpoint->vaddr); g_free(watchpoint); }
0
[]
qemu
c3c1bb99d1c11978d9ce94d1bdcf0705378c1459
292,250,262,373,613,440,000,000,000,000,000,000,000
8
exec: Respect as_tranlsate_internal length clamp address_space_translate_internal will clamp the *plen length argument based on the size of the memory region being queried. The iommu walker logic in addresss_space_translate was ignoring this by discarding the post fn call value of *plen. Fix by just always using *plen...
static inline int task_detached(struct task_struct *p) { return p->exit_signal == -1; }
0
[ "CWE-284", "CWE-264" ]
linux
8141c7f3e7aee618312fa1c15109e1219de784a7
208,426,512,900,327,360,000,000,000,000,000,000,000
4
Move "exit_robust_list" into mm_release() We don't want to get rid of the futexes just at exit() time, we want to drop them when doing an execve() too, since that gets rid of the previous VM image too. Doing it at mm_release() time means that we automatically always do it when we disassociate a VM map from the task. ...
FIFOSampleBuffer::~FIFOSampleBuffer() { delete[] bufferUnaligned; bufferUnaligned = NULL; buffer = NULL; }
0
[ "CWE-617" ]
soundtouch
107f2c5d201a4dfea1b7f15c5957ff2ac9e5f260
229,906,870,764,927,160,000,000,000,000,000,000,000
6
Replaced illegal-number-of-channel assertions with run-time exception
size_t olm_clear_pk_encryption( OlmPkEncryption *encryption ) { /* Clear the memory backing the encryption */ olm::unset(encryption, sizeof(OlmPkEncryption)); /* Initialise a fresh encryption object in case someone tries to use it */ new(encryption) OlmPkEncryption(); return sizeof(OlmPkEncrypti...
0
[ "CWE-787" ]
olm
ccc0d122ee1b4d5e5ca4ec1432086be17d5f901b
267,551,542,917,873,850,000,000,000,000,000,000,000
9
olm_pk_decrypt: Ensure inputs are of correct length.
int dev_addr_del(struct net_device *dev, unsigned char *addr, unsigned char addr_type) { int err; struct netdev_hw_addr *ha; ASSERT_RTNL(); /* * We can not remove the first address from the list because * dev->dev_addr points to that. */ ha = list_first_entry(&dev->dev_addrs.list, struct netdev...
0
[ "CWE-399" ]
linux
6ec82562ffc6f297d0de36d65776cff8e5704867
262,288,621,335,763,100,000,000,000,000,000,000,000
23
veth: Dont kfree_skb() after dev_forward_skb() In case of congestion, netif_rx() frees the skb, so we must assume dev_forward_skb() also consume skb. Bug introduced by commit 445409602c092 (veth: move loopback logic to common location) We must change dev_forward_skb() to always consume skb, and veth to not double fr...
socks_connect_blocking(void *data) { struct connect_arg *arg = data; return (VALUE)Rconnect(arg->fd, arg->sockaddr, arg->len); }
0
[ "CWE-908" ]
ruby
61b7f86248bd121be2e83768be71ef289e8e5b90
202,756,898,264,598,420,000,000,000,000,000,000,000
5
ext/socket/init.c: do not return uninitialized buffer Resize string buffer only if some data is received in BasicSocket#read_nonblock and some methods. Co-Authored-By: Samuel Williams <samuel.williams@oriontransfer.co.nz>
static int kvm_vcpu_ioctl_interrupt(struct kvm_vcpu *vcpu, struct kvm_interrupt *irq) { if (irq->irq < 0 || irq->irq >= 256) return -EINVAL; if (irqchip_in_kernel(vcpu->kvm)) return -ENXIO; kvm_queue_interrupt(vcpu, irq->irq, false); kvm_make_request(KVM_REQ_EVENT, vcpu); return 0; }
0
[ "CWE-200" ]
kvm
831d9d02f9522e739825a51a11e3bc5aa531a905
251,858,638,541,523,700,000,000,000,000,000,000,000
13
KVM: x86: fix information leak to userland Structures kvm_vcpu_events, kvm_debugregs, kvm_pit_state2 and kvm_clock_data are copied to userland with some padding and reserved fields unitialized. It leads to leaking of contents of kernel stack memory. We have to initialize them to zero. In patch v1 Jan Kiszka suggest...
request_method (const struct request *req) { return req->method; }
0
[ "CWE-20" ]
wget
3e25a9817f47fbb8660cc6a3b2f3eea239526c6c
219,260,509,202,358,680,000,000,000,000,000,000,000
4
Introduce --trust-server-names. Close CVE-2010-2252.
TfLiteRegistration* Register_RESHAPE() { static TfLiteRegistration r = {nullptr, nullptr, reshape::Prepare, reshape::Eval}; return &r; }
0
[ "CWE-125", "CWE-787" ]
tensorflow
1970c2158b1ffa416d159d03c3370b9a462aee35
334,219,940,997,533,200,000,000,000,000,000,000,000
5
[tflite]: Insert `nullptr` checks when obtaining tensors. As part of ongoing refactoring, `tflite::GetInput`, `tflite::GetOutput`, `tflite::GetTemporary` and `tflite::GetIntermediates` will return `nullptr` in some cases. Hence, we insert the `nullptr` checks on all usages. We also insert `nullptr` checks on usages o...
static int dwc3_pci_quirks(struct dwc3_pci *dwc) { struct pci_dev *pdev = dwc->pci; if (pdev->vendor == PCI_VENDOR_ID_INTEL) { if (pdev->device == PCI_DEVICE_ID_INTEL_BXT || pdev->device == PCI_DEVICE_ID_INTEL_BXT_M) { guid_parse(PCI_INTEL_BXT_DSM_GUID, &dwc->guid); dwc->has_dsm_for_pm = true; } i...
0
[ "CWE-401" ]
linux
9bbfceea12a8f145097a27d7c7267af25893c060
103,965,562,945,418,930,000,000,000,000,000,000,000
58
usb: dwc3: pci: prevent memory leak in dwc3_pci_probe In dwc3_pci_probe a call to platform_device_alloc allocates a device which is correctly put in case of error except one case: when the call to platform_device_add_properties fails it directly returns instead of going to error handling. This commit replaces return w...
func_beginswith (struct _ESExp *f, gint argc, struct _ESExpResult **argv, gpointer data) { EBookBackendLDAPSExpData *ldap_data = data; ESExpResult *r; if (argc == 2 && argv[0]->type == ESEXP_RES_STRING && argv[1]->type == ESEXP_RES_STRING) { gchar *prop...
0
[]
evolution-data-server
34bad61738e2127736947ac50e0c7969cc944972
40,970,430,403,526,117,000,000,000,000,000,000,000
68
Bug 796174 - strcat() considered unsafe for buffer overflow
static pj_status_t get_name_len(int rec_counter, const pj_uint8_t *pkt, const pj_uint8_t *start, const pj_uint8_t *max, int *parsed_len, int *name_len) { const pj_uint8_t *p; pj_status_t status; /* Limit the number of recursion */ if (rec_counter > 10) { /* Too many name recursion */ return...
1
[ "CWE-120", "CWE-787" ]
pjproject
9fae8f43accef8ea65d4a8ae9cdf297c46cfe29a
230,674,960,946,205,600,000,000,000,000,000,000,000
65
Merge pull request from GHSA-p6g5-v97c-w5q4 * Prevent heap buffer overflow when parsing DNS packets * Make sure packet parsing doesn't advance beyond max/end * Update checks * Remove check Co-authored-by: sauwming <ming@teluu.com>
void PDFDoc::markObject (Object* obj, XRef *xRef, XRef *countRef, unsigned int numOffset, int oldRefNum, int newRefNum, std::set<Dict*> *alreadyMarkedDicts) { Array *array; switch (obj->getType()) { case objArray: array = obj->getArray(); for (int i=0; i<array->getLength(); i++) { Object ob...
0
[ "CWE-20" ]
poppler
9fd5ec0e6e5f763b190f2a55ceb5427cfe851d5f
307,721,980,933,593,600,000,000,000,000,000,000,000
50
PDFDoc::setup: Fix return value At that point xref can have gone wrong since extractPDFSubtype() can have caused a reconstruct that broke stuff so instead of unconditionally returning true, return xref->isOk() Fixes #706
QPDFWriter::pushEncryptionFilter() { if (this->m->encrypted && (! this->m->cur_data_key.empty())) { Pipeline* p = 0; if (this->m->encrypt_use_aes) { p = new Pl_AES_PDF( "aes stream encryption", this->m->pipeline, true, QUtil::unsigned_char_pointer(this->m->cur_data_key), this->m->cur...
0
[ "CWE-787" ]
qpdf
d71f05ca07eb5c7cfa4d6d23e5c1f2a800f52e8e
270,241,418,630,041,200,000,000,000,000,000,000,000
24
Fix sign and conversion warnings (major) This makes all integer type conversions that have potential data loss explicit with calls that do range checks and raise an exception. After this commit, qpdf builds with no warnings when -Wsign-conversion -Wconversion is used with gcc or clang or when -W3 -Wd4800 is used with ...
void jbd2_journal_free_reserved(handle_t *handle) { journal_t *journal = handle->h_journal; /* Get j_state_lock to pin running transaction if it exists */ read_lock(&journal->j_state_lock); __jbd2_journal_unreserve_handle(handle, journal->j_running_transaction); read_unlock(&journal->j_state_lock); jbd2_free_han...
0
[ "CWE-416" ]
linux
cc16eecae687912238ee6efbff71ad31e2bc414e
12,182,377,978,508,533,000,000,000,000,000,000,000
10
jbd2: fix use-after-free of transaction_t race jbd2_journal_wait_updates() is called with j_state_lock held. But if there is a commit in progress, then this transaction might get committed and freed via jbd2_journal_commit_transaction() -> jbd2_journal_free_transaction(), when we release j_state_lock. So check for jou...
static void cgroup_pressure_release(struct kernfs_open_file *of) { struct cgroup_file_ctx *ctx = of->priv; psi_trigger_destroy(ctx->psi.trigger); }
0
[ "CWE-416" ]
linux
a06247c6804f1a7c86a2e5398a4c1f1db1471848
188,024,462,485,419,300,000,000,000,000,000,000,000
6
psi: Fix uaf issue when psi trigger is destroyed while being polled With write operation on psi files replacing old trigger with a new one, the lifetime of its waitqueue is totally arbitrary. Overwriting an existing trigger causes its waitqueue to be freed and pending poll() will stumble on trigger->event_wait which w...
void sock_release(struct socket *sock) { if (sock->ops) { struct module *owner = sock->ops->owner; sock->ops->release(sock); sock->ops = NULL; module_put(owner); } if (rcu_dereference_protected(sock->wq, 1)->fasync_list) printk(KERN_ERR "sock_release: fasync list not empty!\n"); if (test_bit(SOCK_EXTER...
0
[ "CWE-399", "CWE-703" ]
linux
ed6fe9d614fc1bca95eb8c0ccd0e92db00ef9d5d
319,379,368,803,385,950,000,000,000,000,000,000,000
23
Fix order of arguments to compat_put_time[spec|val] Commit 644595f89620 ("compat: Handle COMPAT_USE_64BIT_TIME in net/socket.c") introduced a bug where the helper functions to take either a 64-bit or compat time[spec|val] got the arguments in the wrong order, passing the kernel stack pointer off as a user pointer (and...
static noinline int __push_leaf_right(struct btrfs_path *path, int data_size, int empty, struct extent_buffer *right, int free_space, u32 left_nritems, u32 min_slot) { struct btrfs_fs_info *fs_info = right->fs_info; struct extent_buffer *left = path->nodes[0]; struct extent_bu...
0
[ "CWE-362" ]
linux
dbcc7d57bffc0c8cac9dac11bec548597d59a6a5
90,174,836,139,599,780,000,000,000,000,000,000,000
137
btrfs: fix race when cloning extent buffer during rewind of an old root While resolving backreferences, as part of a logical ino ioctl call or fiemap, we can end up hitting a BUG_ON() when replaying tree mod log operations of a root, triggering a stack trace like the following: ------------[ cut here ]------------ ...
log_done( char *op, char *target, const char *errmsg, gss_buffer_t client, gss_buffer_t server, struct svc_req *rqstp) { size_t tlen, clen, slen; char *tdots, *cdots, *sdots; if (errmsg == NULL) errmsg = _("success"); tlen = strlen(target); trunc_name(&tlen, &tdots);...
0
[ "CWE-119", "CWE-772", "CWE-401" ]
krb5
83ed75feba32e46f736fcce0d96a0445f29b96c2
188,921,377,199,243,740,000,000,000,000,000,000,000
29
Fix leaks in kadmin server stubs [CVE-2015-8631] In each kadmind server stub, initialize the client_name and server_name variables, and release them in the cleanup handler. Many of the stubs will otherwise leak the client and server name if krb5_unparse_name() fails. Also make sure to free the prime_arg variables in...
static inline void ftrace_trace_stack(struct trace_array *tr, struct ring_buffer *buffer, unsigned long flags, int skip, int pc, struct pt_regs *regs) { }
0
[ "CWE-415" ]
linux
4397f04575c44e1440ec2e49b6302785c95fd2f8
12,958,771,922,969,768,000,000,000,000,000,000,000
6
tracing: Fix possible double free on failure of allocating trace buffer Jing Xia and Chunyan Zhang reported that on failing to allocate part of the tracing buffer, memory is freed, but the pointers that point to them are not initialized back to NULL, and later paths may try to free the freed memory again. Jing and Chu...
UINT cliprdr_read_format_data_request(wStream* s, CLIPRDR_FORMAT_DATA_REQUEST* request) { if (Stream_GetRemainingLength(s) < 4) { WLog_ERR(TAG, "not enough data in stream!"); return ERROR_INVALID_DATA; } Stream_Read_UINT32(s, request->requestedFormatId); /* requestedFormatId (4 bytes) */ return CHANNEL_RC_OK;...
0
[ "CWE-125" ]
FreeRDP
b73143cf7ee5fe4cdabcbf56908aa15d8a883821
98,196,123,394,888,820,000,000,000,000,000,000,000
11
Fixed oob read in cliprdr_read_format_list
static int cirrus_bitblt_videotovideo_patterncopy(CirrusVGAState * s) { return cirrus_bitblt_common_patterncopy(s, true); }
1
[ "CWE-119" ]
qemu
ffaf857778286ca54e3804432a2369a279e73aa7
87,016,724,800,987,500,000,000,000,000,000,000,000
4
cirrus: stop passing around src pointers in the blitter Does basically the same as "cirrus: stop passing around dst pointers in the blitter", just for the src pointer instead of the dst pointer. For the src we have to care about cputovideo blits though and fetch the data from s->cirrus_bltbuf instead of vga memory. ...
int PackLinuxElf32::ARM_is_QNX(void) { if (Elf32_Ehdr::EM_ARM==get_te16(&ehdri.e_machine) && Elf32_Ehdr::ELFDATA2MSB== ehdri.e_ident[Elf32_Ehdr::EI_DATA] && Elf32_Ehdr::ELFOSABI_ARM==ehdri.e_ident[Elf32_Ehdr::EI_OSABI] && 0x100000==(page_mask & get_te32(&phdri[0].p_vaddr))) { Elf32_Phdr const...
0
[ "CWE-476" ]
upx
ef336dbcc6dc8344482f8cf6c909ae96c3286317
249,421,539,861,903,430,000,000,000,000,000,000,000
26
Protect against bad crafted input. https://github.com/upx/upx/issues/128 modified: p_lx_elf.cpp
should_skip_file (NautilusDirectory *directory, GFileInfo *info) { static gboolean show_hidden_files_changed_callback_installed = FALSE; /* Add the callback once for the life of our process */ if (!show_hidden_files_changed_callback_installed) { g_signal_connect_swappe...
0
[ "CWE-20" ]
nautilus
1630f53481f445ada0a455e9979236d31a8d3bb0
209,386,725,296,940,920,000,000,000,000,000,000,000
28
mime-actions: use file metadata for trusting desktop files Currently we only trust desktop files that have the executable bit set, and don't replace the displayed icon or the displayed name until it's trusted, which prevents for running random programs by a malicious desktop file. However, the executable permission i...
static struct l2cap_chan *l2cap_get_chan_by_scid(struct l2cap_conn *conn, u16 cid) { struct l2cap_chan *c; mutex_lock(&conn->chan_lock); c = __l2cap_get_chan_by_scid(conn, cid); if (c) l2cap_chan_lock(c); mutex_unlock(&conn->chan_lock); return c; }
0
[ "CWE-787" ]
linux
e860d2c904d1a9f38a24eb44c9f34b8f915a6ea3
6,472,616,051,749,500,000,000,000,000,000,000,000
13
Bluetooth: Properly check L2CAP config option output buffer length Validate the output buffer length for L2CAP config requests and responses to avoid overflowing the stack buffer used for building the option blocks. Cc: stable@vger.kernel.org Signed-off-by: Ben Seri <ben@armis.com> Signed-off-by: Marcel Holtmann <mar...
static u8 mwifiex_get_random_ba_threshold(void) { u64 ns; /* setup ba_packet_threshold here random number between * [BA_SETUP_PACKET_OFFSET, * BA_SETUP_PACKET_OFFSET+BA_SETUP_MAX_PACKET_THRESHOLD-1] */ ns = ktime_get_ns(); ns += (ns >> 32) + (ns >> 16); return ((u8)ns % BA_SETUP_MAX_PACKET_THRESHOLD) + BA_S...
0
[ "CWE-787" ]
linux
3a9b153c5591548612c3955c9600a98150c81875
88,878,594,030,502,570,000,000,000,000,000,000,000
12
mwifiex: Fix possible buffer overflows in mwifiex_ret_wmm_get_status() mwifiex_ret_wmm_get_status() calls memcpy() without checking the destination size.Since the source is given from remote AP which contains illegal wmm elements , this may trigger a heap buffer overflow. Fix it by putting the length check before call...
reiserfs_set_acl(struct inode *inode, struct posix_acl *acl, int type) { int error, error2; struct reiserfs_transaction_handle th; size_t jcreate_blocks; int size = acl ? posix_acl_xattr_size(acl->a_count) : 0; /* * Pessimism: We can't assume that anything from the xattr root up * has been created. */ jc...
0
[ "CWE-862", "CWE-285" ]
linux
073931017b49d9458aa351605b43a7e34598caef
30,172,765,719,294,880,000,000,000,000,000,000,000
30
posix_acl: Clear SGID bit when setting file permissions When file permissions are modified via chmod(2) and the user is not in the owning group or capable of CAP_FSETID, the setgid bit is cleared in inode_change_ok(). Setting a POSIX ACL via setxattr(2) sets the file permissions as well as the new ACL, but doesn't cl...
static Image *ReadTIFFImage(const ImageInfo *image_info, ExceptionInfo *exception) { #define ThrowTIFFException(severity,message) \ { \ if (tiff_pixels != (unsigned char *) NULL) \ tiff_pixels=(unsigned char *) RelinquishMagickMemory(tiff_pixels); \ if (quantum_info != (QuantumInfo *) NULL) \ quantum_info...
1
[ "CWE-401" ]
ImageMagick6
210474b2fac6a661bfa7ed563213920e93e76395
206,560,928,824,680,650,000,000,000,000,000,000,000
1,054
Fix ultra rare but potential memory-leak
parse_WRITE_METADATA(char *arg, struct ofpbuf *ofpacts, enum ofputil_protocol *usable_protocols) { struct ofpact_metadata *om; char *mask = strchr(arg, '/'); *usable_protocols &= OFPUTIL_P_NXM_OF11_UP; om = ofpact_put_WRITE_METADATA(ofpacts); if (mask) { char *error; ...
0
[ "CWE-125" ]
ovs
9237a63c47bd314b807cda0bd2216264e82edbe8
184,802,154,490,981,600,000,000,000,000,000,000,000
23
ofp-actions: Avoid buffer overread in BUNDLE action decoding. Reported-at: https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=9052 Signed-off-by: Ben Pfaff <blp@ovn.org> Acked-by: Justin Pettit <jpettit@ovn.org>
bool kvm_vcpu_wake_up(struct kvm_vcpu *vcpu) { struct rcuwait *waitp; waitp = kvm_arch_vcpu_get_wait(vcpu); if (rcuwait_wake_up(waitp)) { WRITE_ONCE(vcpu->ready, true); ++vcpu->stat.halt_wakeup; return true; } return false; }
0
[ "CWE-401" ]
linux
f65886606c2d3b562716de030706dfe1bea4ed5e
269,927,004,258,019,120,000,000,000,000,000,000,000
13
KVM: fix memory leak in kvm_io_bus_unregister_dev() when kmalloc() fails in kvm_io_bus_unregister_dev(), before removing the bus, we should iterate over all other devices linked to it and call kvm_iodevice_destructor() for them Fixes: 90db10434b16 ("KVM: kvm_io_bus_unregister_dev() should never fail") Cc: stable@vger...
static int get_field_disp_length(MYSQL_FIELD *field) { uint length= column_names ? field->name_length : 0; if (quick) length= max<uint>(length, field->length); else length= max<uint>(length, field->max_length); if (length < 4 && !IS_NOT_NULL(field->flags)) length= 4; /* Room for "NULL" */ re...
0
[ "CWE-284", "CWE-295" ]
mysql-server
3bd5589e1a5a93f9c224badf983cd65c45215390
255,843,684,606,999,000,000,000,000,000,000,000,000
14
WL#6791 : Redefine client --ssl option to imply enforced encryption # Changed the meaning of the --ssl=1 option of all client binaries to mean force ssl, not try ssl and fail over to eunecrypted # Added a new MYSQL_OPT_SSL_ENFORCE mysql_options() option to specify that an ssl connection is required. # Added a new macr...
Item_func_nullif::real_op() { DBUG_ASSERT(fixed == 1); double value; if (!compare()) { null_value=1; return 0.0; } value= args[2]->val_real(); null_value= args[2]->null_value; return value; }
0
[ "CWE-617" ]
server
807945f2eb5fa22e6f233cc17b85a2e141efe2c8
18,362,947,833,122,513,000,000,000,000,000,000,000
13
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 ...
static int rose_release(struct socket *sock) { struct sock *sk = sock->sk; struct rose_sock *rose; if (sk == NULL) return 0; sock_hold(sk); sock_orphan(sk); lock_sock(sk); rose = rose_sk(sk); switch (rose->state) { case ROSE_STATE_0: release_sock(sk); rose_disconnect(sk, 0, -1, -1); lock_sock(sk); r...
0
[ "CWE-200" ]
linux-2.6
17ac2e9c58b69a1e25460a568eae1b0dc0188c25
134,152,957,582,200,340,000,000,000,000,000,000,000
54
rose: Fix rose_getname() leak rose_getname() can leak kernel memory to user. Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
smtp_tx_free(struct smtp_tx *tx) { struct smtp_rcpt *rcpt; rfc5322_free(tx->parser); while ((rcpt = TAILQ_FIRST(&tx->rcpts))) { TAILQ_REMOVE(&tx->rcpts, rcpt, entry); free(rcpt); } if (tx->ofile) fclose(tx->ofile); tx->session->tx = NULL; free(tx); }
0
[ "CWE-78", "CWE-252" ]
src
9dcfda045474d8903224d175907bfc29761dcb45
340,154,638,097,305,750,000,000,000,000,000,000,000
18
Fix a security vulnerability discovered by Qualys which can lead to a privileges escalation on mbox deliveries and unprivileged code execution on lmtp deliveries, due to a logic issue causing a sanity check to be missed. ok eric@, millert@
TfLiteStatus NonMaxSuppressionMultiClass(TfLiteContext* context, TfLiteNode* node, OpData* op_data) { // Get the input tensors const TfLiteTensor* input_box_encodings = GetInput(context, node, kInputTensorBoxEncodings); const TfLiteTensor* input_class_predictions = ...
1
[ "CWE-125", "CWE-787" ]
tensorflow
1970c2158b1ffa416d159d03c3370b9a462aee35
174,900,021,789,738,100,000,000,000,000,000,000,000
42
[tflite]: Insert `nullptr` checks when obtaining tensors. As part of ongoing refactoring, `tflite::GetInput`, `tflite::GetOutput`, `tflite::GetTemporary` and `tflite::GetIntermediates` will return `nullptr` in some cases. Hence, we insert the `nullptr` checks on all usages. We also insert `nullptr` checks on usages o...
int sc_pkcs15emu_sc_hsm_get_public_key(struct sc_context *ctx, sc_cvc_t *cvc, struct sc_pkcs15_pubkey *pubkey) { if (cvc->publicPoint && cvc->publicPointlen) { return sc_pkcs15emu_sc_hsm_get_ec_public_key(ctx, cvc, pubkey); } else { return sc_pkcs15emu_sc_hsm_get_rsa_public_key(ctx, cvc, pubkey); } }
0
[ "CWE-415", "CWE-119" ]
OpenSC
360e95d45ac4123255a4c796db96337f332160ad
208,126,509,653,330,900,000,000,000,000,000,000,000
8
fixed out of bounds writes Thanks to Eric Sesterhenn from X41 D-SEC GmbH for reporting the problems.
ccid_set_progress_cb (ccid_driver_t handle, void (*cb)(void *, const char *, int, int, int), void *cb_arg) { if (!handle || !handle->rid) return CCID_DRIVER_ERR_INV_VALUE; handle->progress_cb = cb; handle->progress_cb_arg = cb_arg; return 0; }
0
[ "CWE-20" ]
gnupg
2183683bd633818dd031b090b5530951de76f392
263,157,091,202,258,460,000,000,000,000,000,000,000
11
Use inline functions to convert buffer data to scalars. * common/host2net.h (buf16_to_ulong, buf16_to_uint): New. (buf16_to_ushort, buf16_to_u16): New. (buf32_to_size_t, buf32_to_ulong, buf32_to_uint, buf32_to_u32): New. -- Commit 91b826a38880fd8a989318585eb502582636ddd8 was not enough to avoid all sign extension on ...
next_setup(Node* node, Node* next_node, regex_t* reg) { int type; retry: type = NTYPE(node); if (type == NT_QTFR) { QtfrNode* qn = NQTFR(node); if (qn->greedy && IS_REPEAT_INFINITE(qn->upper)) { #ifdef USE_QTFR_PEEK_NEXT Node* n = get_head_value_node(next_node, 1, reg); /* '\0': for UTF-16BE...
0
[ "CWE-125" ]
php-src
c6e34d91b88638966662caac62c4d0e90538e317
122,456,443,294,809,090,000,000,000,000,000,000,000
45
Fix bug #77371 (heap buffer overflow in mb regex functions - compile_string_node)
void test_nghttp2_submit_data_read_length_smallest(void) { nghttp2_session *session; nghttp2_session_callbacks callbacks; nghttp2_data_provider data_prd; my_user_data ud; nghttp2_frame *frame; nghttp2_frame_hd hd; nghttp2_active_outbound_item *aob; nghttp2_bufs *framebufs; nghttp2_buf *buf; memset(...
0
[]
nghttp2
0a6ce87c22c69438ecbffe52a2859c3a32f1620f
235,511,089,208,317,760,000,000,000,000,000,000,000
41
Add nghttp2_option_set_max_outbound_ack
int drm_mode_cursor_ioctl(struct drm_device *dev, void *data, struct drm_file *file_priv) { struct drm_mode_cursor *req = data; struct drm_mode_object *obj; struct drm_crtc *crtc; int ret = 0; if (!drm_core_check_feature(dev, DRIVER_MODESET)) return -EINVAL; if (!req->flags) { DRM_ERROR("no operation set...
0
[ "CWE-190", "CWE-189" ]
linux
a5cd335165e31db9dbab636fd29895d41da55dd2
323,955,872,362,540,220,000,000,000,000,000,000,000
49
drm: integer overflow in drm_mode_dirtyfb_ioctl() There is a potential integer overflow in drm_mode_dirtyfb_ioctl() if userspace passes in a large num_clips. The call to kmalloc would allocate a small buffer, and the call to fb->funcs->dirty may result in a memory corruption. Reported-by: Haogang Chen <haogangchen@g...
poly_in(PG_FUNCTION_ARGS) { char *str = PG_GETARG_CSTRING(0); POLYGON *poly; int npts; int size; int isopen; char *s; if ((npts = pair_count(str, ',')) <= 0) ereport(ERROR, (errcode(ERRCODE_INVALID_TEXT_REPRESENTATION), errmsg("invalid input syntax for type polygon: \"%s\"", str))); ...
1
[ "CWE-703", "CWE-189" ]
postgres
31400a673325147e1205326008e32135a78b4d8a
248,445,048,894,692,050,000,000,000,000,000,000,000
30
Predict integer overflow to avoid buffer overruns. Several functions, mostly type input functions, calculated an allocation size such that the calculation wrapped to a small positive value when arguments implied a sufficiently-large requirement. Writes past the end of the inadvertent small allocation followed shortly...
void MonClient::_add_conns(uint64_t global_id) { uint16_t min_priority = std::numeric_limits<uint16_t>::max(); for (const auto& m : monmap.mon_info) { if (m.second.priority < min_priority) { min_priority = m.second.priority; } } vector<unsigned> ranks; for (const auto& m : monmap.mon_info) { ...
0
[ "CWE-294" ]
ceph
2927fd91d41e505237cc73f9700e5c6a63e5cb4f
62,445,845,869,695,580,000,000,000,000,000,000,000
25
mon/MonClient: bring back CEPHX_V2 authorizer challenges Commit c58c5754dfd2 ("msg/async/ProtocolV1: use AuthServer and AuthClient") introduced a backwards compatibility issue into msgr1. To fix it, commit 321548010578 ("mon/MonClient: skip CEPHX_V2 challenge if client doesn't support it") set out to skip authorizer c...
const char * STDCALL mysql_error(MYSQL *mysql) { return mysql ? (mysql)->net.last_error : (char *)""; }
0
[]
mariadb-connector-c
27b2f3d1f1550dfaee0f63a331a406ab31c1b37e
174,292,213,616,629,000,000,000,000,000,000,000,000
4
various checks for corrupted packets in the protocol also: check the return value of unpack_fields()
HandleFileUploadDataRequest(rfbClientPtr cl, rfbTightClientPtr rtcp) { int n = 0; char* pBuf = NULL; rfbClientToServerTightMsg msg; memset(&msg, 0, sizeof(rfbClientToServerTightMsg)); if(cl == NULL) { rfbLog("File [%s]: Method [%s]: Unexpected error: rfbClientPtr is null\n", __FILE__, __FUNCTION__); ret...
0
[ "CWE-416" ]
libvncserver
ca2a5ac02fbbadd0a21fabba779c1ea69173d10b
296,102,063,761,072,800,000,000,000,000,000,000,000
93
tightvnc-filetransfer: fix heap use-after-free One can only guess what the intended semantics were here, but as every other rfbCloseClient() call in this file is followed by an immediate return, let's assume this was forgotton in this case. Anyway, don't forget to clean up to not leak memory. Closes #241
static int gup_pmd_range(pud_t pud, unsigned long addr, unsigned long end, unsigned int flags, struct page **pages, int *nr) { unsigned long next; pmd_t *pmdp; pmdp = pmd_offset(&pud, addr); do { pmd_t pmd = READ_ONCE(*pmdp); next = pmd_addr_end(addr, end); if (!pmd_present(pmd)) return 0; if (unlik...
0
[ "CWE-362" ]
linux
17839856fd588f4ab6b789f482ed3ffd7c403e1f
51,270,997,029,396,320,000,000,000,000,000,000,000
42
gup: document and work around "COW can break either way" issue Doing a "get_user_pages()" on a copy-on-write page for reading can be ambiguous: the page can be COW'ed at any time afterwards, and the direction of a COW event isn't defined. Yes, whoever writes to it will generally do the COW, but if the thread that did...
struct sock *inet_csk_clone_lock(const struct sock *sk, const struct request_sock *req, const gfp_t priority) { struct sock *newsk = sk_clone_lock(sk, priority); if (newsk) { struct inet_connection_sock *newicsk = inet_csk(newsk); newsk->sk_state = TCP_SYN_RECV; newicsk->icsk_bind_hash = NULL; in...
1
[ "CWE-200", "CWE-415" ]
linux
657831ffc38e30092a2d5f03d385d710eb88b09a
52,827,400,975,419,620,000,000,000,000,000,000,000
35
dccp/tcp: do not inherit mc_list from parent syzkaller found a way to trigger double frees from ip_mc_drop_socket() It turns out that leave a copy of parent mc_list at accept() time, which is very bad. Very similar to commit 8b485ce69876 ("tcp: do not inherit fastopen_req from parent") Initial report from Pray3r, c...
bool Krecipes::queryClose() { if ( !m_view->inputPanel->everythingSaved() ) { switch ( KMessageBox::questionYesNoCancel( this, i18n( "A recipe contains unsaved changes.\n" "Do you want to save the changes before exiting?" ), i18n( "Unsaved Changes" ) ) ) { case KMessageBox::Y...
0
[]
krecipes
cd1490fb5fe82cbe9172a43be13298001b446ecd
302,334,472,132,710,050,000,000,000,000,000,000,000
20
Use WebKit instead of KHTML for printing recipes, fixes sourceforge #2990118 and #2960140. svn path=/trunk/extragear/utils/krecipes/; revision=1137824
gnutls_x509_crt_get_pk_algorithm(gnutls_x509_crt_t cert, unsigned int *bits) { int result; if (cert == NULL) { gnutls_assert(); return GNUTLS_E_INVALID_REQUEST; } if (bits) *bits = 0; result = _gnutls_x509_get_pk_algorithm(cert->cert, "tbsCertificate.subjectPublicKeyInfo", bits); ...
0
[ "CWE-295" ]
gnutls
6e76e9b9fa845b76b0b9a45f05f4b54a052578ff
184,232,313,726,805,560,000,000,000,000,000,000,000
26
on certificate import check whether the two signature algorithms match