func
string
target
int64
cwe
list
project
string
commit_id
string
hash
float64
size
int64
message
string
static MagickBooleanType WriteGIFImage(const ImageInfo *image_info,Image *image, ExceptionInfo *exception) { int c; ImageInfo *write_info; MagickBooleanType status; MagickOffsetType scene; RectangleInfo page; register ssize_t i; register unsigned char *q; size_t ...
0
[ "CWE-119", "CWE-703", "CWE-787" ]
ImageMagick
61135001a625364e29bdce83832f043eebde7b5a
8,431,788,649,478,003,000,000,000,000,000,000,000
441
https://github.com/ImageMagick/ImageMagick/issues/1595
copy_data(void *dst_data, struct vhost_crypto_data_req *vc_req, struct vring_desc **cur_desc, uint32_t size, uint32_t *nb_descs, uint32_t vq_size) { struct vring_desc *desc = *cur_desc; uint64_t remain, addr, dlen, len; uint32_t to_copy; uint8_t *data = dst_data; uint8_t *src; int left = size; to_copy = RTE...
0
[ "CWE-125" ]
dpdk
acd4c92fa693bbea695f2bb42bb93fb8567c3ca5
241,705,549,738,532,060,000,000,000,000,000,000,000
102
vhost/crypto: validate keys lengths transform_cipher_param() and transform_chain_param() handle the payload data for the VHOST_USER_CRYPTO_CREATE_SESS message. These payloads have to be validated, since it could come from untrusted sources. Two buffers and their lengths are defined in this payload, one the the auth k...
void visit(Repetition &ope) override { if (ope.min_ == 0) { set_error(); } else { ope.ope_->accept(*this); } }
0
[ "CWE-125" ]
cpp-peglib
b3b29ce8f3acf3a32733d930105a17d7b0ba347e
115,307,791,642,847,540,000,000,000,000,000,000,000
7
Fix #122
static ssize_t systab_show(struct kobject *kobj, struct kobj_attribute *attr, char *buf) { char *str = buf; if (!kobj || !buf) return -EINVAL; if (efi.mps != EFI_INVALID_TABLE_ADDR) str += sprintf(str, "MPS=0x%lx\n", efi.mps); if (efi.acpi20 != EFI_INVALID_TABLE_ADDR) str += sprintf(str, "ACPI20=0x%lx...
0
[]
linux
1957a85b0032a81e6482ca4aab883643b8dae06e
306,679,649,584,199,740,000,000,000,000,000,000,000
32
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 <...
int ecryptfs_decrypt_page(struct page *page) { struct inode *ecryptfs_inode; struct ecryptfs_crypt_stat *crypt_stat; char *enc_extent_virt; struct page *enc_extent_page = NULL; unsigned long extent_offset; int rc = 0; ecryptfs_inode = page->mapping->host; crypt_stat = &(ecryptfs_inode_to_private(ecryptfs_ino...
0
[ "CWE-189" ]
linux-2.6
8faece5f906725c10e7a1f6caf84452abadbdc7b
240,630,533,125,729,300,000,000,000,000,000,000,000
63
eCryptfs: Allocate a variable number of pages for file headers When allocating the memory used to store the eCryptfs header contents, a single, zeroed page was being allocated with get_zeroed_page(). However, the size of an eCryptfs header is either PAGE_CACHE_SIZE or ECRYPTFS_MINIMUM_HEADER_EXTENT_SIZE (8192), whiche...
struct b43_dmaring *parse_cookie(struct b43_wldev *dev, u16 cookie, int *slot) { struct b43_dma *dma = &dev->dma; struct b43_dmaring *ring = NULL; switch (cookie & 0xF000) { case 0x1000: ring = dma->tx_ring_AC_BK; break; case 0x2000: ring = dma->tx_ring_AC_BE; break; case 0x3000: ring = dma->tx_ring_AC...
0
[ "CWE-119", "CWE-787" ]
linux
c85ce65ecac078ab1a1835c87c4a6319cf74660a
203,196,602,189,669,070,000,000,000,000,000,000,000
31
b43: allocate receive buffers big enough for max frame len + offset Otherwise, skb_put inside of dma_rx can fail... https://bugzilla.kernel.org/show_bug.cgi?id=32042 Signed-off-by: John W. Linville <linville@tuxdriver.com> Acked-by: Larry Finger <Larry.Finger@lwfinger.net> Cc: stable@kernel.org
void GrpcStreamClientHandler::onReceiveTrailingMetadata(Http::HeaderMapPtr&& metadata) { context->onGrpcReceiveTrailingMetadata(token, std::move(metadata)); }
0
[ "CWE-476" ]
envoy
8788a3cf255b647fd14e6b5e2585abaaedb28153
159,035,094,206,134,200,000,000,000,000,000,000,000
3
1.4 - Do not call into the VM unless the VM Context has been created. (#24) * Ensure that the in VM Context is created before onDone is called. Signed-off-by: John Plevyak <jplevyak@gmail.com> * Update as per offline discussion. Signed-off-by: John Plevyak <jplevyak@gmail.com> * Set in_vm_context_created_ in onNet...
explicit TfDlManagedTensorCtx(const TensorReference& ref) : reference(ref) {}
0
[ "CWE-20", "CWE-476", "CWE-908" ]
tensorflow
22e07fb204386768e5bcbea563641ea11f96ceb8
177,589,089,632,050,380,000,000,000,000,000,000,000
1
Fix multiple vulnerabilities in `tf.experimental.dlpack.to_dlpack`. We have a use after free caused by memory coruption, a segmentation fault caused by memory corruption, several memory leaks and an undefined behavior when taking the reference of a nullptr. PiperOrigin-RevId: 332568894 Change-Id: Ife0fc05e103b3532509...
int vp78_decode_frame(AVCodecContext *avctx, void *data, int *got_frame, AVPacket *avpkt, int is_vp7) { VP8Context *s = avctx->priv_data; int ret, i, referenced, num_jobs; enum AVDiscard skip_thresh; VP8Frame *av_uninit(curframe), *prev_frame; if (is_vp7) ret = vp7_dec...
1
[ "CWE-119", "CWE-787" ]
FFmpeg
6b5d3fb26fb4be48e4966e4b1d97c2165538d4ef
207,494,053,381,225,100,000,000,000,000,000,000,000
157
avcodec/webp: Always set pix_fmt Fixes: out of array access Fixes: 1434/clusterfuzz-testcase-minimized-6314998085189632 Fixes: 1435/clusterfuzz-testcase-minimized-6483783723253760 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/targets/ffmpeg Reviewed-by: "Ronald S. Bultje" <rsbult...
static int compat_x25_subscr_ioctl(unsigned int cmd, struct compat_x25_subscrip_struct __user *x25_subscr32) { struct compat_x25_subscrip_struct x25_subscr; struct x25_neigh *nb; struct net_device *dev; int rc = -EINVAL; rc = -EFAULT; if (copy_from_user(&x25_subscr, x25_subscr32, sizeof(*x25_subscr32))) goto...
0
[]
net
7781607938c8371d4c2b243527430241c62e39c2
256,578,881,325,786,820,000,000,000,000,000,000,000
47
net/x25: Fix null-ptr-deref caused by x25_disconnect When the link layer is terminating, x25->neighbour will be set to NULL in x25_disconnect(). As a result, it could cause null-ptr-deref bugs in x25_sendmsg(),x25_recvmsg() and x25_connect(). One of the bugs is shown below. (Thread 1) | (Thread 2...
void JSObject::allocateNewSlotStorage( Handle<JSObject> selfHandle, Runtime *runtime, SlotIndex newSlotIndex, Handle<> valueHandle) { // If it is a direct property, just store the value and we are done. if (LLVM_LIKELY(newSlotIndex < DIRECT_PROPERTY_SLOTS)) { selfHandle->directProps()[newSlotInd...
0
[ "CWE-843", "CWE-125" ]
hermes
fe52854cdf6725c2eaa9e125995da76e6ceb27da
209,039,212,030,881,900,000,000,000,000,000,000,000
48
[CVE-2020-1911] Look up HostObject computed properties on the right object in the prototype chain. Summary: The change in the hermes repository fixes the security vulnerability CVE-2020-1911. This vulnerability only affects applications which allow evaluation of uncontrolled, untrusted JavaScript code not shipped wit...
nosy_ioctl(struct file *file, unsigned int cmd, unsigned long arg) { struct client *client = file->private_data; spinlock_t *client_list_lock = &client->lynx->client_list_lock; struct nosy_stats stats; int ret; switch (cmd) { case NOSY_IOC_GET_STATS: spin_lock_irq(client_list_lock); stats.total_packet_count ...
0
[ "CWE-416" ]
linux
829933ef05a951c8ff140e814656d73e74915faf
228,155,701,602,816,500,000,000,000,000,000,000,000
49
firewire: nosy: Fix a use-after-free bug in nosy_ioctl() For each device, the nosy driver allocates a pcilynx structure. A use-after-free might happen in the following scenario: 1. Open nosy device for the first time and call ioctl with command NOSY_IOC_START, then a new client A will be malloced and added to ...
static void test_bug9992() { MYSQL *mysql1; MYSQL_RES* res ; int rc; myheader("test_bug9992"); if (!opt_silent) printf("Establishing a connection with option CLIENT_MULTI_STATEMENTS..\n"); mysql1= mysql_client_init(NULL); if (!mysql_real_connect(mysql1, opt_host, opt_user, opt_password, ...
0
[ "CWE-284", "CWE-295" ]
mysql-server
3bd5589e1a5a93f9c224badf983cd65c45215390
16,385,866,937,351,580,000,000,000,000,000,000,000
46
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...
int meth_put(struct transaction_t *txn, void *params) { struct meth_params *pparams = (struct meth_params *) params; int ret, r, precond, rights, reqd_rights; const char **hdr, *etag; struct mime_type_t *mime = NULL; struct mailbox *mailbox = NULL; struct dav_data *ddata; struct index_record...
1
[]
cyrus-imapd
6703ff881b6056e0c045a7b795ce8ba1bbb87027
301,784,555,688,605,740,000,000,000,000,000,000,000
256
http_dav.c: add 'private' Cache-Control directive for cacheable responses that require authentication
void reset_buffer() { m_string.set(buffer, buffer_size, &my_charset_bin); }
0
[ "CWE-617" ]
server
807945f2eb5fa22e6f233cc17b85a2e141efe2c8
245,217,378,160,728,850,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 ...
static int bmp_read_4bit(gdImagePtr im, gdIOCtxPtr infile, bmp_info_t *info, bmp_hdr_t *header) { int ypos = 0, xpos = 0, row = 0, index = 0; int padding = 0, current_byte = 0; if (info->enctype != BMP_BI_RGB && info->enctype != BMP_BI_RLE4) { return 1; } if (!info->numcolors) { info->numcolors = 16; } else...
0
[ "CWE-415" ]
libgd
ac16bdf2d41724b5a65255d4c28fb0ec46bc42f5
326,109,254,809,571,600,000,000,000,000,000,000,000
86
bmp: check return value in gdImageBmpPtr Closes #447.
Item_bool_rowready_func2* Ge_creator::create_swap(THD *thd, Item *a, Item *b) const { return new(thd->mem_root) Item_func_le(thd, b, a); }
0
[ "CWE-617" ]
server
807945f2eb5fa22e6f233cc17b85a2e141efe2c8
213,049,455,758,819,180,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 ...
static ssize_t poison_store(struct kmem_cache *s, const char *buf, size_t length) { if (any_slab_objects(s)) return -EBUSY; s->flags &= ~SLAB_POISON; if (buf[0] == '1') { s->flags |= SLAB_POISON; } calculate_sizes(s, -1); return length; }
0
[]
linux
fd4d9c7d0c71866ec0c2825189ebd2ce35bd95b8
323,482,901,904,561,000,000,000,000,000,000,000,000
13
mm: slub: add missing TID bump in kmem_cache_alloc_bulk() When kmem_cache_alloc_bulk() attempts to allocate N objects from a percpu freelist of length M, and N > M > 0, it will first remove the M elements from the percpu freelist, then call ___slab_alloc() to allocate the next element and repopulate the percpu freelis...
PHP_FUNCTION(odbc_gettypeinfo) { zval *pv_conn; long pv_data_type = SQL_ALL_TYPES; odbc_result *result = NULL; odbc_connection *conn; RETCODE rc; SQLSMALLINT data_type; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "r|l", &pv_conn, &pv_data_type) == FAILURE) { return; } data_type = (SQLSMALLINT) pv...
0
[ "CWE-20" ]
php-src
16db4d1462bf3eacb93c0cd940f799160a284b24
128,633,780,114,806,630,000,000,000,000,000,000,000
55
Fix #69975: PHP segfaults when accessing nvarchar(max) defined columns The SQL Server Native Client 11.0 and maybe other ODBC drivers report NVARCHAR(MAX) columns as SQL_WVARCHAR with size 0. This causes too small a buffer to be emalloc'd, likely causing a segfault in the following. As we don't know the real size of t...
v3d_invalidate_slices(struct v3d_dev *v3d, int core) { V3D_CORE_WRITE(core, V3D_CTL_SLCACTL, V3D_SET_FIELD(0xf, V3D_SLCACTL_TVCCS) | V3D_SET_FIELD(0xf, V3D_SLCACTL_TDCCS) | V3D_SET_FIELD(0xf, V3D_SLCACTL_UCC) | V3D_SET_FIELD(0xf, V3D_SLCACTL_ICC)); }
0
[ "CWE-400", "CWE-401" ]
linux
29cd13cfd7624726d9e6becbae9aa419ef35af7f
156,998,152,593,200,570,000,000,000,000,000,000,000
8
drm/v3d: Fix memory leak in v3d_submit_cl_ioctl In the impelementation of v3d_submit_cl_ioctl() there are two memory leaks. One is when allocation for bin fails, and the other is when bin initialization fails. If kcalloc fails to allocate memory for bin then render->base should be put. Also, if v3d_job_init() fails to...
bool InstanceKlass::link_class_impl(TRAPS) { if (DumpSharedSpaces && SystemDictionaryShared::has_class_failed_verification(this)) { // This is for CDS dumping phase only -- we use the in_error_state to indicate that // the class has failed verification. Throwing the NoClassDefFoundError here is just // a ...
0
[]
jdk17u
f8eb9abe034f7c6bea4da05a9ea42017b3f80730
157,957,897,959,623,870,000,000,000,000,000,000,000
141
8270386: Better verification of scan methods Reviewed-by: coleenp Backport-of: ac329cef45979bd0159ecd1347e36f7129bb2ce4
uint64_t e1000e_core_read(E1000ECore *core, hwaddr addr, unsigned size) { uint64_t val; uint16_t index = e1000e_get_reg_index_with_offset(mac_reg_access, addr); if (index < E1000E_NREADOPS && e1000e_macreg_readops[index]) { if (mac_reg_access[index] & MAC_ACCESS_PARTIAL) { trace_e1000e_...
0
[ "CWE-835" ]
qemu
4154c7e03fa55b4cf52509a83d50d6c09d743b77
164,974,756,909,070,270,000,000,000,000,000,000,000
17
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....
SDL_DitherColors(SDL_Color * colors, int bpp) { int i; if (bpp != 8) return; /* only 8bpp supported right now */ for (i = 0; i < 256; i++) { int r, g, b; /* map each bit field to the full [0, 255] interval, so 0 is mapped to (0, 0, 0) and 255 to (255, 255,...
0
[ "CWE-703", "CWE-787" ]
SDL
8c91cf7dba5193f5ce12d06db1336515851c9ee9
126,017,706,229,122,430,000,000,000,000,000,000,000
23
Always create a full 256-entry map in case color values are out of range Fixes https://github.com/libsdl-org/SDL/issues/5042
INST_HANDLER (sts) { // STS k, Rr int r = ((buf[0] >> 4) & 0xf) | ((buf[1] & 0x1) << 4); int k = (buf[3] << 8) | buf[2]; op->ptr = k; ESIL_A ("r%d,", r); __generic_ld_st (op, "ram", 0, 1, 0, k, 1); op->cycles = 2; }
1
[ "CWE-125" ]
radare2
d04c78773f6959bcb427453f8e5b9824d5ba9eff
64,577,354,453,485,360,000,000,000,000,000,000,000
10
Fix #10091 - crash in AVR analysis
void DL_Dxf::writeDimLinear(DL_WriterA& dw, const DL_DimensionData& data, const DL_DimLinearData& edata, const DL_Attributes& attrib) { dw.entity("DIMENSION"); if (version==DL_VERSION_2000) { dw.dxfString(100, "AcDbEnt...
0
[ "CWE-191" ]
qcad
1eeffc5daf5a06cf6213ffc19e95923cdebb2eb8
340,090,043,445,243,460,000,000,000,000,000,000,000
58
check vertexIndex which might be -1 for broken DXF
void CoreUserInputHandler::issueAway(const QString &msg, bool autoCheck) { QString awayMsg = msg; IrcUser *me = network()->me(); // if there is no message supplied we have to check if we are already away or not if (autoCheck && msg.isEmpty()) { if (me && !me->isAway()) { Identity *i...
0
[ "CWE-399" ]
quassel
b5e38970ffd55e2dd9f706ce75af9a8d7730b1b8
93,613,164,941,118,310,000,000,000,000,000,000,000
22
Improve the message-splitting algorithm for PRIVMSG and CTCP This introduces a new message splitting algorithm based on QTextBoundaryFinder. It works by first starting with the entire message to be sent, encoding it, and checking to see if it is over the maximum message length. If it is, it uses QTBF to find the wor...
static Image *ReadMIFFImage(const ImageInfo *image_info, ExceptionInfo *exception) { #define BZipMaxExtent(x) ((x)+((x)/100)+600) #define LZMAMaxExtent(x) ((x)+((x)/3)+128) #define ThrowMIFFException(exception,message) \ { \ if (quantum_info != (QuantumInfo *) NULL) \ quantum_info=DestroyQuantumInfo(quantum_i...
0
[ "CWE-772" ]
ImageMagick6
ae3eecad2f59e27123c1a6c891be75d06fc03656
46,396,000,491,935,240,000,000,000,000,000,000,000
1,305
https://github.com/ImageMagick/ImageMagick/issues/1191
t2p_write_advance_directory(T2P* t2p, TIFF* output) { t2p_disable(output); if(!TIFFWriteDirectory(output)){ TIFFError(TIFF2PDF_MODULE, "Error writing virtual directory to output PDF %s", TIFFFileName(output)); t2p->t2p_error = T2P_ERR_ERROR; return; } t2p_enable(output); return; }
0
[ "CWE-787" ]
libtiff
7be2e452ddcf6d7abca88f41d3761e6edab72b22
286,256,393,321,516,600,000,000,000,000,000,000,000
13
tiff2pdf.c: properly calculate datasize when saving to JPEG YCbCr fixes #220
int show_line(FILE *stream, struct name_list **acl_names, acl_t acl, acl_entry_t *acl_ent, const char *acl_mask, struct name_list **dacl_names, acl_t dacl, acl_entry_t *dacl_ent, const char *dacl_mask) { acl_tag_t tag_type; const char *tag, *name; char acl_perm[ACL_PERMS+1], dacl_...
0
[]
acl
63451a06b7484d220750ed8574d3ee84e156daf5
161,065,813,611,095,890,000,000,000,000,000,000,000
72
Make sure that getfacl -R only calls stat(2) on symlinks when it needs to This fixes http://oss.sgi.com/bugzilla/show_bug.cgi?id=790 "getfacl follows symlinks, even without -L".
static xmlNodePtr to_xml_union(encodeTypePtr enc, zval *data, int style, xmlNodePtr parent TSRMLS_DC) { /*FIXME*/ return to_xml_list(enc,data,style, parent TSRMLS_CC); }
0
[ "CWE-19" ]
php-src
c8eaca013a3922e8383def6158ece2b63f6ec483
1,821,425,754,009,914,300,000,000,000,000,000,000
4
Added type checks
FizzHandshakeParam(bool argCHLOSync, bool argCFINSync, bool argAcceptZeroRtt) : chloSync(argCHLOSync), cfinSync(argCFINSync), acceptZeroRtt(argAcceptZeroRtt) {}
0
[ "CWE-617", "CWE-703" ]
mvfst
a67083ff4b8dcbb7ee2839da6338032030d712b0
158,212,539,899,513,860,000,000,000,000,000,000,000
4
Close connection if we derive an extra 1-rtt write cipher Summary: Fixes CVE-2021-24029 Reviewed By: mjoras, lnicco Differential Revision: D26613890 fbshipit-source-id: 19bb2be2c731808144e1a074ece313fba11f1945
static void get_socket_name( char* buf, int len ) { char* dpy = g_strdup(g_getenv("DISPLAY")); if(dpy && *dpy) { char* p = strchr(dpy, ':'); for(++p; *p && *p != '.' && *p != '\n';) ++p; if(*p) *p = '\0'; } g_snprintf( buf, len, "%s/.menu-cached-%s-%s"...
1
[ "CWE-20" ]
menu-cache
56f66684592abf257c4004e6e1fff041c64a12ce
276,299,611,376,421,900,000,000,000,000,000,000,000
15
Fix potential access violation, use runtime user dir instead of tmp dir. Note: it limits libmenu-cache compatibility to menu-cached >= 0.7.0.
static GPtrArray *textview_scan_header(TextView *textview, FILE *fp) { gchar buf[BUFFSIZE]; GPtrArray *headers, *sorted_headers; GSList *disphdr_list; Header *header; gint i; cm_return_val_if_fail(fp != NULL, NULL); if (prefs_common.show_all_headers) { headers = procheader_get_header_array_asis(fp); sorted...
0
[ "CWE-601" ]
claws
ac286a71ed78429e16c612161251b9ea90ccd431
119,301,333,339,070,880,000,000,000,000,000,000,000
71
harden link checker before accepting click
CopyFileToDirectory(const char* srcPath, const char* destPath, const char* fileName) { char command[1024]; int forkExecResult; snprintf(command, sizeof(command), "/bin/cp %s/%s %s/%s.tmp", srcPath, fileName, destPath, fileName); command[sizeof(command) - 1] = '\0'; forkExe...
0
[ "CWE-362" ]
open-vm-tools
22e58289f71232310d30cf162b83b5151a937bac
26,039,836,255,867,295,000,000,000,000,000,000,000
26
randomly generate tmp directory name
static struct fwnet_peer *fwnet_peer_find_by_guid(struct fwnet_device *dev, u64 guid) { struct fwnet_peer *peer; list_for_each_entry(peer, &dev->peer_list, peer_link) if (peer->guid == guid) return peer; return NULL; }
0
[ "CWE-119", "CWE-284", "CWE-787" ]
linux
667121ace9dbafb368618dbabcf07901c962ddac
65,577,800,922,772,640,000,000,000,000,000,000,000
11
firewire: net: guard against rx buffer overflows The IP-over-1394 driver firewire-net lacked input validation when handling incoming fragmented datagrams. A maliciously formed fragment with a respectively large datagram_offset would cause a memcpy past the datagram buffer. So, drop any packets carrying a fragment wi...
RuntimeShape() : size_(0) {}
0
[ "CWE-125", "CWE-787" ]
tensorflow
8ee24e7949a203d234489f9da2c5bf45a7d5157d
124,986,740,443,484,130,000,000,000,000,000,000,000
1
[tflite] Ensure `MatchingDim` does not allow buffer overflow. We check in `MatchingDim` that both arguments have the same dimensionality, however that is a `DCHECK` only enabled if building in debug mode. Hence, it could be possible to cause buffer overflows by passing in a tensor with larger dimensions as the second ...
QPDF_Stream::getLength() const { return this->length; }
0
[ "CWE-787" ]
qpdf
d71f05ca07eb5c7cfa4d6d23e5c1f2a800f52e8e
89,361,748,551,688,240,000,000,000,000,000,000,000
4
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 ...
static ssize_t queue_logical_block_size_show(struct request_queue *q, char *page) { return queue_var_show(queue_logical_block_size(q), page); }
0
[ "CWE-416" ]
linux
c3e2219216c92919a6bd1711f340f5faa98695e6
200,538,897,225,175,930,000,000,000,000,000,000,000
4
block: free sched's request pool in blk_cleanup_queue In theory, IO scheduler belongs to request queue, and the request pool of sched tags belongs to the request queue too. However, the current tags allocation interfaces are re-used for both driver tags and sched tags, and driver tags is definitely host wide, and doe...
static int kvm_init_mmu_notifier(struct kvm *kvm) { kvm->mmu_notifier.ops = &kvm_mmu_notifier_ops; return mmu_notifier_register(&kvm->mmu_notifier, current->mm);
0
[ "CWE-459" ]
linux
683412ccf61294d727ead4a73d97397396e69a6b
131,229,651,083,134,550,000,000,000,000,000,000,000
5
KVM: SEV: add cache flush to solve SEV cache incoherency issues Flush the CPU caches when memory is reclaimed from an SEV guest (where reclaim also includes it being unmapped from KVM's memslots). Due to lack of coherency for SEV encrypted memory, failure to flush results in silent data corruption if userspace is mal...
PHP_FUNCTION(openssl_pkey_export) { struct php_x509_request req; zval ** zpkey, * args = NULL, *out; char * passphrase = NULL; int passphrase_len = 0; long key_resource = -1; int pem_write = 0; EVP_PKEY * key; BIO * bio_out = NULL; const EVP_CIPHER * cipher; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS...
0
[ "CWE-754" ]
php-src
89637c6b41b510c20d262c17483f582f115c66d6
55,147,275,155,091,310,000,000,000,000,000,000,000
72
Fix bug #74651 - check EVP_SealInit as it can return -1
define_destination_uri (WebKitDownload *download, gboolean temporary) { char *tmp_dir; char *destination_filename; char *destination_uri; const char *suggested_filename; suggested_filename = webkit_download_get_suggested_filename (download); /* If we are not doing an automatic down...
0
[]
epiphany
3e0f7dea754381c5ad11a06ccc62eb153382b498
61,713,900,972,051,760,000,000,000,000,000,000,000
69
Report broken certs through the padlock icon This uses a new feature in libsoup that reports through a SoupMessageFlag whether the message is talking to a server that has a trusted server. Bug #600663
static int test_root(unsigned int a, unsigned int b) { while (1) { if (a < b) return 0; if (a == b) return 1; if (a % b) return 0; a = a / b; } }
0
[]
e2fsprogs
f66e6ce4446738c2c7f43d41988a3eb73347e2f5
26,556,227,739,448,324,000,000,000,000,000,000,000
12
libext2fs: avoid buffer overflow if s_first_meta_bg is too big If s_first_meta_bg is greater than the of number block group descriptor blocks, then reading or writing the block group descriptors will end up overruning the memory buffer allocated for the descriptors. Fix this by limiting first_meta_bg to no more than ...
GF_Err trak_box_write(GF_Box *s, GF_BitStream *bs) { return gf_isom_box_write_header(s, bs); }
0
[ "CWE-787" ]
gpac
77510778516803b7f7402d7423c6d6bef50254c3
328,952,545,733,833,000,000,000,000,000,000,000,000
4
fixed #2255
R_API void r_bin_java_interface_free(void /*RBinJavaInterfaceInfo*/ *o) { RBinJavaInterfaceInfo *obj = o; if (obj) { free (obj->name); free (obj); } }
0
[ "CWE-119", "CWE-788" ]
radare2
6c4428f018d385fc80a33ecddcb37becea685dd5
31,851,381,158,874,505,000,000,000,000,000,000,000
7
Improve boundary checks to fix oobread segfaults ##crash * Reported by Cen Zhang via huntr.dev * Reproducer: bins/fuzzed/javaoob-havoc.class
ImagingPcdDecode(Imaging im, ImagingCodecState state, UINT8* buf, int bytes) { int x; int chunk; UINT8* out; UINT8* ptr; ptr = buf; chunk = 3 * state->xsize; for (;;) { /* We need data for two full lines before we can do anything */ if (bytes < chunk) return ptr - buf; /* Unpack...
0
[ "CWE-119", "CWE-787" ]
Pillow
ae453aa18b66af54e7ff716f4ccb33adca60afd4
166,336,336,821,992,650,000,000,000,000,000,000,000
52
PCD decoder overruns the shuffle buffer, Fixes #568
static int asn1_item_embed_d2i(ASN1_VALUE **pval, const unsigned char **in, long len, const ASN1_ITEM *it, int tag, int aclass, char opt, ASN1_TLC *ctx) { const ASN1_TEMPLATE *tt, *errtt = NULL; const ASN1_EXTERN_FUNCS *ef; const ASN1_AUX *aux = ...
1
[ "CWE-400", "CWE-674", "CWE-787" ]
openssl
2ac4c6f7b2b2af20c0e2b0ba05367e454cd11b33
143,637,508,639,147,210,000,000,000,000,000,000,000
289
Limit ASN.1 constructed types recursive definition depth Constructed types with a recursive definition (such as can be found in PKCS7) could eventually exceed the stack given malicious input with excessive recursion. Therefore we limit the stack depth. CVE-2018-0739 Credit to OSSFuzz for finding this issue. Reviewe...
static struct inode *btrfs_iget_locked(struct super_block *s, u64 objectid, struct btrfs_root *root) { struct inode *inode; struct btrfs_iget_args args; args.ino = objectid; args.root = root; inode = iget5_locked(s, objectid, btrfs_find_actor, btrfs_init_locked_inode, (void *...
0
[ "CWE-310" ]
linux-2.6
9c52057c698fb96f8f07e7a4bcf4801a092bda89
324,541,657,793,216,100,000,000,000,000,000,000,000
14
Btrfs: fix hash overflow handling The handling for directory crc hash overflows was fairly obscure, split_leaf returns EOVERFLOW when we try to extend the item and that is supposed to bubble up to userland. For a while it did so, but along the way we added better handling of errors and forced the FS readonly if we hi...
TEST_P(ProtocolIntegrationTest, ConnDurationInflightRequest) { config_helper_.setDownstreamMaxConnectionDuration(std::chrono::milliseconds(500)); config_helper_.addConfigModifier( [](envoy::extensions::filters::network::http_connection_manager::v3::HttpConnectionManager& hcm) { hcm.mutable_drain_...
0
[ "CWE-22" ]
envoy
5333b928d8bcffa26ab19bf018369a835f697585
260,938,444,497,631,830,000,000,000,000,000,000,000
26
Implement handling of escaped slash characters in URL path Fixes: CVE-2021-29492 Signed-off-by: Yan Avlasov <yavlasov@google.com>
Pdata_clear(Pdata *self, Py_ssize_t clearto) { Py_ssize_t i = Py_SIZE(self); assert(clearto >= self->fence); if (clearto >= i) return 0; while (--i >= clearto) { Py_CLEAR(self->data[i]); } Py_SIZE(self) = clearto; return 0; }
0
[ "CWE-190", "CWE-369" ]
cpython
a4ae828ee416a66d8c7bf5ee71d653c2cc6a26dd
309,452,513,297,025,130,000,000,000,000,000,000,000
14
closes bpo-34656: Avoid relying on signed overflow in _pickle memos. (GH-9261)
int SSH_Access::HandleSSHMessage() { int m=STALL; const char *b; int s; pty_recv_buf->Get(&b,&s); const char *eol=find_char(b,s,'\n'); if(!eol) { const char *p="password:"; const char *p_for="password for "; const char *y="(yes/no)?"; int p_len=strlen(p); int p_for_len...
1
[]
lftp
bc7b476e782d77839765f56bbdb4cee9f36b54ec
64,728,998,944,453,620,000,000,000,000,000,000,000
78
add settings fish:auto-confirm and sftp:auto-confirm New host keys are now not confirmed by default, this should improve security. Suggested by Marcin Szewczyk <Marcin.Szewczyk@wodny.org>
__kprobes void *perf_trace_buf_prepare(int size, unsigned short type, struct pt_regs *regs, int *rctxp) { struct trace_entry *entry; unsigned long flags; char *raw_data; int pc; BUILD_BUG_ON(PERF_MAX_TRACE_SIZE % sizeof(unsigned long)); pc = preempt_count(); *rctxp = perf_swevent_get_recursion_cont...
0
[]
linux
ced39002f5ea736b716ae233fb68b26d59783912
265,084,978,050,255,020,000,000,000,000,000,000,000
28
ftrace, perf: Add support to use function tracepoint in perf Adding perf registration support for the ftrace function event, so it is now possible to register it via perf interface. The perf_event struct statically contains ftrace_ops as a handle for function tracer. The function tracer is registered/unregistered in ...
__nfp_flower_non_repr_priv_put(struct nfp_flower_non_repr_priv *non_repr_priv) { if (--non_repr_priv->ref_count) return; list_del(&non_repr_priv->list); kfree(non_repr_priv); }
0
[ "CWE-400", "CWE-401" ]
linux
8572cea1461a006bce1d06c0c4b0575869125fa4
115,477,004,547,988,770,000,000,000,000,000,000,000
8
nfp: flower: prevent memory leak in nfp_flower_spawn_phy_reprs In nfp_flower_spawn_phy_reprs, in the for loop over eth_tbl if any of intermediate allocations or initializations fail memory is leaked. requiered releases are added. Fixes: b94524529741 ("nfp: flower: add per repr private data for LAG offload") Signed-of...
evdev_phys_rect_to_units(const struct evdev_device *device, const struct phys_rect *mm) { struct device_coord_rect units = {0}; const struct input_absinfo *absx, *absy; if (device->abs.absinfo_x == NULL || device->abs.absinfo_y == NULL) { log_bug_libinput(evdev_libinput_context(device), "%s: is not ...
0
[ "CWE-134" ]
libinput
a423d7d3269dc32a87384f79e29bb5ac021c83d1
176,177,809,137,742,330,000,000,000,000,000,000,000
24
evdev: strip the device name of format directives This fixes a format string vulnerabilty. evdev_log_message() composes a format string consisting of a fixed prefix (including the rendered device name) and the passed-in format buffer. This format string is then passed with the arguments to the actual log handler, whi...
static inline int do_seccomp(struct pt_regs *regs) { return 0; }
0
[ "CWE-119", "CWE-787" ]
linux
c1fa0768a8713b135848f78fd43ffc208d8ded70
240,290,174,087,164,860,000,000,000,000,000,000,000
1
powerpc/tm: Flush TM only if CPU has TM feature Commit cd63f3c ("powerpc/tm: Fix saving of TM SPRs in core dump") added code to access TM SPRs in flush_tmregs_to_thread(). However flush_tmregs_to_thread() does not check if TM feature is available on CPU before trying to access TM SPRs in order to copy live state to th...
ext4_ext_shift_extents(struct inode *inode, handle_t *handle, ext4_lblk_t start, ext4_lblk_t shift, enum SHIFT_DIRECTION SHIFT) { struct ext4_ext_path *path; int ret = 0, depth; struct ext4_extent *extent; ext4_lblk_t stop, *iterator, ex_start, ex_end; /* Let path point to the last extent */ pa...
0
[ "CWE-362" ]
linux
ea3d7209ca01da209cda6f0dea8be9cc4b7a933b
103,345,500,764,660,580,000,000,000,000,000,000,000
105
ext4: fix races between page faults and hole punching Currently, page faults and hole punching are completely unsynchronized. This can result in page fault faulting in a page into a range that we are punching after truncate_pagecache_range() has been called and thus we can end up with a page mapped to disk blocks that...
~Projection() { delete[] private_data_; }
0
[ "CWE-20" ]
libvpx
f00890eecdf8365ea125ac16769a83aa6b68792d
338,561,504,129,547,530,000,000,000,000,000,000,000
1
update libwebm to libwebm-1.0.0.27-352-g6ab9fcf https://chromium.googlesource.com/webm/libwebm/+log/af81f26..6ab9fcf Change-Id: I9d56e1fbaba9b96404b4fbabefddc1a85b79c25d
GfxPattern *GfxResources::lookupPattern(char *name, Gfx *gfx) { GfxResources *resPtr; GfxPattern *pattern; Object obj; for (resPtr = this; resPtr; resPtr = resPtr->next) { if (resPtr->patternDict.isDict()) { if (!resPtr->patternDict.dictLookup(name, &obj)->isNull()) { pattern = GfxPattern::parse(&ob...
0
[]
poppler
abf167af8b15e5f3b510275ce619e6fdb42edd40
43,796,297,857,006,465,000,000,000,000,000,000,000
18
Implement tiling/patterns in SplashOutputDev Fixes bug 13518
test_bson_count_keys (void) { bson_t b; bson_init (&b); BSON_ASSERT (bson_append_int32 (&b, "0", -1, 0)); BSON_ASSERT (bson_append_int32 (&b, "1", -1, 1)); BSON_ASSERT (bson_append_int32 (&b, "2", -1, 2)); ASSERT_CMPINT (bson_count_keys (&b), ==, 3); bson_destroy (&b); }
0
[ "CWE-125" ]
mongo-c-driver
0d9a4d98bfdf4acd2c0138d4aaeb4e2e0934bd84
332,561,379,899,874,200,000,000,000,000,000,000,000
11
Fix for CVE-2018-16790 -- Verify bounds before binary length read. As reported here: https://jira.mongodb.org/browse/CDRIVER-2819, a heap overread occurs due a failure to correctly verify data bounds. In the original check, len - o returns the data left including the sizeof(l) we just read. Instead, the comparison sh...
static inline uint64_t address_space_ldq_internal(AddressSpace *as, hwaddr addr, MemTxAttrs attrs, MemTxResult *result, enum device_endian endian) { uint8_t *ptr; ...
0
[]
qemu
e4a511f8cc6f4a46d409fb5c9f72c38ba45f8d83
252,439,795,014,991,400,000,000,000,000,000,000,000
51
exec: clamp accesses against the MemoryRegionSection Because the clamping was done against the MemoryRegion, address_space_rw was effectively broken if a write spanned multiple sections that are not linear in underlying memory (with the memory not being under an IOMMU). This is visible with the MIPS rc4030 IOMMU, whi...
xmlSchemaCheckDerivationOKRestriction2to4(xmlSchemaParserCtxtPtr pctxt, int action, xmlSchemaBasicItemPtr item, xmlSchemaBasicItemPtr baseItem, xmlSchemaItemListPtr uses, xmlSchemaItemListPtr baseUses, xmlSchemaWildcardPtr wild, xmlSchemaWildc...
0
[ "CWE-134" ]
libxml2
4472c3a5a5b516aaf59b89be602fbce52756c3e9
250,318,259,251,418,040,000,000,000,000,000,000,000
280
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.
nautilus_create_templates_directory (void) { char *dir; dir = nautilus_get_templates_directory (); if (!g_file_test (dir, G_FILE_TEST_EXISTS)) { g_mkdir (dir, DEFAULT_NAUTILUS_DIRECTORY_MODE); } g_free (dir); }
0
[]
nautilus
a0f7bb5f2e9af8ecb463b13da834fa8559b0a481
307,217,498,022,684,180,000,000,000,000,000,000,000
10
Use $XDG_DATA_HOME/.converted-launchers as marker for one-time desktop 2009-02-25 Alexander Larsson <alexl@redhat.com> * src/nautilus-application.c: Use $XDG_DATA_HOME/.converted-launchers as marker for one-time desktop file trust operation. * libnautilus-private/nautilus-file-utilities.[ch]: Ad...
static inline void add_mm_rss(struct mm_struct *mm, int file_rss, int anon_rss) { if (file_rss) add_mm_counter(mm, file_rss, file_rss); if (anon_rss) add_mm_counter(mm, anon_rss, anon_rss); }
0
[ "CWE-20" ]
linux-2.6
89f5b7da2a6bad2e84670422ab8192382a5aeb9f
15,547,307,601,400,600,000,000,000,000,000,000,000
7
Reinstate ZERO_PAGE optimization in 'get_user_pages()' and fix XIP KAMEZAWA Hiroyuki and Oleg Nesterov point out that since the commit 557ed1fa2620dc119adb86b34c614e152a629a80 ("remove ZERO_PAGE") removed the ZERO_PAGE from the VM mappings, any users of get_user_pages() will generally now populate the VM with real emp...
long kvm_arch_vcpu_ioctl(struct file *filp, unsigned int ioctl, unsigned long arg) { struct kvm_vcpu *vcpu = filp->private_data; void __user *argp = (void __user *)arg; int r; union { struct kvm_lapic_state *lapic; struct kvm_xsave *xsave; struct kvm_xcrs *xcrs; void *buffer; } u; u.buffer = NULL; s...
0
[]
linux
6d1068b3a98519247d8ba4ec85cd40ac136dbdf9
268,009,639,568,670,240,000,000,000,000,000,000,000
287
KVM: x86: invalid opcode oops on SET_SREGS with OSXSAVE bit set (CVE-2012-4461) On hosts without the XSAVE support unprivileged local user can trigger oops similar to the one below by setting X86_CR4_OSXSAVE bit in guest cr4 register using KVM_SET_SREGS ioctl and later issuing KVM_RUN ioctl. invalid opcode: 0000 [#2]...
static void hns_init_mac_addr(struct net_device *ndev) { struct hns_nic_priv *priv = netdev_priv(ndev); if (!device_get_mac_address(priv->dev, ndev->dev_addr, ETH_ALEN)) { eth_hw_addr_random(ndev); dev_warn(priv->dev, "No valid mac, use random mac %pM", ndev->dev_addr); } }
0
[ "CWE-416" ]
linux
27463ad99f738ed93c7c8b3e2e5bc8c4853a2ff2
275,204,573,084,110,050,000,000,000,000,000,000,000
10
net: hns: Fix a skb used after free bug skb maybe freed in hns_nic_net_xmit_hw() and return NETDEV_TX_OK, which cause hns_nic_net_xmit to use a freed skb. BUG: KASAN: use-after-free in hns_nic_net_xmit_hw+0x62c/0x940... [17659.112635] alloc_debug_processing+0x18c/0x1a0 [17659.117208] __slab_alloc+0x52c/0x...
struct sock *mroute6_socket(struct net *net, struct sk_buff *skb) { struct mr6_table *mrt; struct flowi6 fl6 = { .flowi6_iif = skb->skb_iif ? : LOOPBACK_IFINDEX, .flowi6_oif = skb->dev->ifindex, .flowi6_mark = skb->mark, }; if (ip6mr_fib_lookup(net, &fl6, &mrt) < 0) return NULL; return mrt->mroute6_sk; }
0
[ "CWE-20" ]
linux
99253eb750fda6a644d5188fb26c43bad8d5a745
198,293,666,267,501,650,000,000,000,000,000,000,000
14
ipv6: check sk sk_type and protocol early in ip_mroute_set/getsockopt Commit 5e1859fbcc3c ("ipv4: ipmr: various fixes and cleanups") fixed the issue for ipv4 ipmr: ip_mroute_setsockopt() & ip_mroute_getsockopt() should not access/set raw_sk(sk)->ipmr_table before making sure the socket is a raw socket, and prot...
test_bson_append_symbol (void) { bson_t *b; bson_t *b2; b = bson_new (); b2 = get_bson ("test32.bson"); BSON_ASSERT (bson_append_symbol (b, "hello", -1, "world", -1)); BSON_ASSERT_BSON_EQUAL (b, b2); bson_destroy (b); bson_destroy (b2); }
0
[ "CWE-125" ]
libbson
42900956dc461dfe7fb91d93361d10737c1602b3
32,852,721,634,362,780,000,000,000,000,000,000,000
12
CDRIVER-2269 Check for zero string length in codewscope
int RGWDeleteLC::verify_permission() { bool perm; perm = verify_bucket_permission(s, rgw::IAM::s3PutLifecycleConfiguration); if (!perm) return -EACCES; return 0; }
0
[ "CWE-770" ]
ceph
ab29bed2fc9f961fe895de1086a8208e21ddaddc
292,399,781,942,518,860,000,000,000,000,000,000,000
9
rgw: fix issues with 'enforce bounds' patch The patch to enforce bounds on max-keys/max-uploads/max-parts had a few issues that would prevent us from compiling it. Instead of changing the code provided by the submitter, we're addressing them in a separate commit to maintain the DCO. Signed-off-by: Joao Eduardo Luis <...
bool IsTailOfShape(Type type1, Type type2) { auto tail_type = type1.dyn_cast<ShapedType>(); auto full_type = type2.dyn_cast<ShapedType>(); if (!tail_type || !full_type || !tail_type.hasRank() || !full_type.hasRank() || tail_type.getRank() > full_type.getRank()) return false; auto i1 = tail_type.getSha...
0
[ "CWE-476", "CWE-125" ]
tensorflow
d6b57f461b39fd1aa8c1b870f1b974aac3554955
243,087,348,272,814,100,000,000,000,000,000,000,000
10
Prevent nullptr dereference in MLIR TFLite dialect/optimizer. PiperOrigin-RevId: 387220762 Change-Id: Id136ef04bb3d36123b4685d316ae81a9ec924d6b
dissect_80211n_mac_phy(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, int offset, int data_len, guint32 *n_mac_flags, guint32 *ampdu_id, struct ieee_802_11_phdr *phdr) { proto_tree *ftree; proto_item *ti; ptvcursor_t *csr; guint8 mcs; guint8 ness; guint16 ext_frequency; ...
0
[ "CWE-20" ]
wireshark
2c13e97d656c1c0ac4d76eb9d307664aae0e0cf7
246,540,774,878,459,570,000,000,000,000,000,000,000
82
The WTAP_ENCAP_ETHERNET dissector needs to be passed a struct eth_phdr. We now require that. Make it so. Bug: 12440 Change-Id: Iffee520976b013800699bde3c6092a3e86be0d76 Reviewed-on: https://code.wireshark.org/review/15424 Reviewed-by: Guy Harris <guy@alum.mit.edu>
static void do_interrupt_requests(struct kvm_vcpu *vcpu, struct kvm_run *kvm_run) { vmx_update_window_states(vcpu); if (vcpu->guest_debug & KVM_GUESTDBG_SINGLESTEP) vmcs_clear_bits(GUEST_INTERRUPTIBILITY_INFO, GUEST_INTR_STATE_STI | GUEST_INTR_STATE_MOV_SS); if (vcpu->arch.nmi_pending && !vcpu...
0
[ "CWE-20" ]
linux-2.6
16175a796d061833aacfbd9672235f2d2725df65
44,928,085,267,741,750,000,000,000,000,000,000,000
42
KVM: VMX: Don't allow uninhibited access to EFER on i386 vmx_set_msr() does not allow i386 guests to touch EFER, but they can still do so through the default: label in the switch. If they set EFER_LME, they can oops the host. Fix by having EFER access through the normal channel (which will check for EFER_LME) even o...
static inline bool io_req_multi_free(struct req_batch *rb, struct io_kiocb *req) { if ((req->flags & REQ_F_LINK) || io_is_fallback_req(req)) return false; if (!(req->flags & REQ_F_FIXED_FILE) || req->io) rb->need_iter++; rb->reqs[rb->to_free++] = req; if (unlikely(rb->to_free == ARRAY_SIZE(rb->reqs))) io_fr...
0
[]
linux
ff002b30181d30cdfbca316dadd099c3ca0d739c
108,305,199,665,547,610,000,000,000,000,000,000,000
13
io_uring: grab ->fs as part of async preparation This passes it in to io-wq, so it assumes the right fs_struct when executing async work that may need to do lookups. Cc: stable@vger.kernel.org # 5.3+ Signed-off-by: Jens Axboe <axboe@kernel.dk>
static ssize_t snd_timer_user_read(struct file *file, char __user *buffer, size_t count, loff_t *offset) { struct snd_timer_user *tu; long result = 0, unit; int qhead; int err = 0; tu = file->private_data; unit = tu->tread ? sizeof(struct snd_timer_tread) : sizeof(struct snd_timer_read); mutex_lock(&tu->...
0
[ "CWE-200" ]
linux
d11662f4f798b50d8c8743f433842c3e40fe3378
229,826,661,617,771,630,000,000,000,000,000,000,000
69
ALSA: timer: Fix race between read and ioctl The read from ALSA timer device, the function snd_timer_user_tread(), may access to an uninitialized struct snd_timer_user fields when the read is concurrently performed while the ioctl like snd_timer_user_tselect() is invoked. We have already fixed the races among ioctls ...
g_tcp_select(int sck1, int sck2) { fd_set rfds; struct timeval time; int max = 0; int rv = 0; g_memset(&rfds,0,sizeof(fd_set)); g_memset(&time,0,sizeof(struct timeval)); time.tv_sec = 0; time.tv_usec = 0; FD_ZERO(&rfds); if (sck1 > 0) { FD_SET(((unsigned int)sck1), &rfds); } if (sck2 > 0...
0
[]
xrdp
d8f9e8310dac362bb9578763d1024178f94f4ecc
156,828,684,955,436,360,000,000,000,000,000,000,000
45
move temp files from /tmp to /tmp/.xrdp
grub_disk_cache_invalidate_all (void) { unsigned i; for (i = 0; i < GRUB_DISK_CACHE_NUM; i++) { struct grub_disk_cache *cache = grub_disk_cache_table + i; if (cache->data && ! cache->lock) { grub_free (cache->data); cache->data = 0; } } }
0
[ "CWE-20", "CWE-119" ]
radare2
c57997e76ec70862174a1b3b3aeb62a6f8570e85
281,739,857,702,911,350,000,000,000,000,000,000,000
15
Fix r2_hbo_grub_memmove ext2 crash
passIsComma () { pass_Codes passCode = passGetScriptToken (); if (passCode != pass_comma) { compileError (passNested, "',' expected"); return 0; } return 1; }
0
[]
liblouis
dc97ef791a4fae9da11592c79f9f79e010596e0c
330,091,689,744,546,200,000,000,000,000,000,000,000
10
Merge branch 'table_resolver'
static bool tipc_crypto_key_try_align(struct tipc_crypto *rx, u8 new_pending) { struct tipc_aead *tmp1, *tmp2 = NULL; struct tipc_key key; bool aligned = false; u8 new_passive = 0; int x; spin_lock(&rx->lock); key = rx->key; if (key.pending == new_pending) { aligned = true; goto exit; } if (key.active) ...
0
[ "CWE-20" ]
linux
fa40d9734a57bcbfa79a280189799f76c88f7bb0
145,291,035,129,984,400,000,000,000,000,000,000,000
48
tipc: fix size validations for the MSG_CRYPTO type The function tipc_crypto_key_rcv is used to parse MSG_CRYPTO messages to receive keys from other nodes in the cluster in order to decrypt any further messages from them. This patch verifies that any supplied sizes in the message body are valid for the received message...
static void ax88179_get_mac_addr(struct usbnet *dev) { u8 mac[ETH_ALEN]; memset(mac, 0, sizeof(mac)); /* Maybe the boot loader passed the MAC address via device tree */ if (!eth_platform_get_mac_address(&dev->udev->dev, mac)) { netif_dbg(dev, ifup, dev->net, "MAC address read from device tree"); } else { ...
0
[ "CWE-787" ]
linux
57bc3d3ae8c14df3ceb4e17d26ddf9eeab304581
212,105,987,553,433,800,000,000,000,000,000,000,000
27
net: usb: ax88179_178a: Fix out-of-bounds accesses in RX fixup ax88179_rx_fixup() contains several out-of-bounds accesses that can be triggered by a malicious (or defective) USB device, in particular: - The metadata array (hdr_off..hdr_off+2*pkt_cnt) can be out of bounds, causing OOB reads and (on big-endian syst...
static struct hlist_head *policy_hash_bysel(struct net *net, const struct xfrm_selector *sel, unsigned short family, int dir) { unsigned int hmask = net->xfrm.policy_bydst[dir].hmask; unsigned int hash; u8 dbits; u8 sbits; __get_hash_thresh(net, family, dir, &dbits, &sbits); hash = __sel_hash(s...
0
[ "CWE-125" ]
ipsec
7bab09631c2a303f87a7eb7e3d69e888673b9b7e
293,990,017,060,900,100,000,000,000,000,000,000,000
18
xfrm: policy: check policy direction value The 'dir' parameter in xfrm_migrate() is a user-controlled byte which is used as an array index. This can lead to an out-of-bound access, kernel lockup and DoS. Add a check for the 'dir' value. This fixes CVE-2017-11600. References: https://bugzilla.redhat.com/show_bug.cgi?...
static int run_userns_fn(void *data) { struct userns_fn_data *d = data; char c; // we're not sharing with the parent any more, if it was a thread close(d->p[1]); if (read(d->p[0], &c, 1) != 1) return -1; close(d->p[0]); return d->fn(d->arg); }
0
[ "CWE-59", "CWE-61" ]
lxc
592fd47a6245508b79fe6ac819fe6d3b2c1289be
8,982,434,736,011,185,000,000,000,000,000,000,000
12
CVE-2015-1335: Protect container mounts against symlinks When a container starts up, lxc sets up the container's inital fstree by doing a bunch of mounting, guided by the container configuration file. The container config is owned by the admin or user on the host, so we do not try to guard against bad entries. Howev...
int qcow2_decompress_cluster(BlockDriverState *bs, uint64_t cluster_offset) { BDRVQcowState *s = bs->opaque; int ret, csize, nb_csectors, sector_offset; uint64_t coffset; coffset = cluster_offset & s->cluster_offset_mask; if (s->cluster_cache_offset != coffset) { nb_csectors = ((cluster_off...
0
[ "CWE-190" ]
qemu
cab60de930684c33f67d4e32c7509b567f8c445b
139,648,111,931,561,520,000,000,000,000,000,000,000
24
qcow2: Fix new L1 table size check (CVE-2014-0143) The size in bytes is assigned to an int later, so check that instead of the number of entries. Signed-off-by: Kevin Wolf <kwolf@redhat.com> Reviewed-by: Max Reitz <mreitz@redhat.com> Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
dnp3_udp_check_header_heur(packet_info *pinfo _U_, tvbuff_t *tvb, int offset _U_, void *data _U_) { return check_dnp3_header(tvb, TRUE); }
0
[ "CWE-835" ]
wireshark
618661b22e34a59b21117db723d8ff91e064d4ba
275,614,165,649,614,100,000,000,000,000,000,000,000
4
dnp: plug a memory leak. If we're throwing away the data, *throw away the data* - free it, as we're not using it as the backing data for a tvbuff.
UniqueChars normalize_header_value(JSContext *cx, MutableHandleValue value_val, size_t *value_len, const char *fun_name) { RootedString value_str(cx, JS::ToString(cx, value_val)); if (!value_str) return nullptr; size_t len; UniqueChars value = encode(cx, value_str, &len);...
0
[ "CWE-94" ]
js-compute-runtime
65524ffc962644e9fc39f4b368a326b6253912a9
158,038,104,199,597,700,000,000,000,000,000,000,000
56
use rangom_get instead of arc4random as arc4random does not work correctly with wizer wizer causes the seed in arc4random to be the same between executions which is not random
void t_cpp_generator::generate_local_reflection_pointer(std::ofstream& out, t_type* ttype) { if (!gen_dense_) { return; } indent(out) << "::apache::thrift::reflection::local::TypeSpec* " << ttype->get_name() << "::local_reflection = " << endl << indent() << " &" << local_reflectio...
0
[ "CWE-20" ]
thrift
cfaadcc4adcfde2a8232c62ec89870b73ef40df1
65,200,413,231,775,310,000,000,000,000,000,000,000
8
THRIFT-3231 CPP: Limit recursion depth to 64 Client: cpp Patch: Ben Craig <bencraig@apache.org>
void tcp_release_cb(struct sock *sk) { unsigned long flags, nflags; /* perform an atomic operation only if at least one flag is set */ do { flags = sk->sk_tsq_flags; if (!(flags & TCP_DEFERRED_ALL)) return; nflags = flags & ~TCP_DEFERRED_ALL; } while (cmpxchg(&sk->sk_tsq_flags, flags, nflags) != flags); ...
0
[ "CWE-190" ]
net
3b4929f65b0d8249f19a50245cd88ed1a2f78cff
105,522,381,306,104,990,000,000,000,000,000,000,000
40
tcp: limit payload size of sacked skbs Jonathan Looney reported that TCP can trigger the following crash in tcp_shifted_skb() : BUG_ON(tcp_skb_pcount(skb) < pcount); This can happen if the remote peer has advertized the smallest MSS that linux TCP accepts : 48 An skb can hold 17 fragments, and each fragment can ho...
std::istream *istream_file(const std::string &fname, bool treat_failure_as_error) { LOG_FS << "Streaming " << fname << " for reading.\n"; if (fname.empty()) { ERR_FS << "Trying to open file with empty name.\n"; bfs::ifstream *s = new bfs::ifstream(); s->clear(std::ios_base::failbit); return s; } //mingw do...
0
[ "CWE-200" ]
wesnoth
f8914468182e8d0a1551b430c0879ba236fe4d6d
318,817,834,109,049,200,000,000,000,000,000,000,000
32
Disallow inclusion of .pbl files from WML (bug #23504) Note that this will also cause Lua wesnoth.have_file() to return false on .pbl files.
void ComputeAsync(OpKernelContext* c, DoneCallback done) override { auto col_params = new CollectiveParams(); auto done_with_cleanup = [col_params, done = std::move(done)]() { done(); col_params->Unref(); }; OP_REQUIRES_OK_ASYNC(c, FillCollectiveParams(col_params, ...
0
[ "CWE-416" ]
tensorflow
ca38dab9d3ee66c5de06f11af9a4b1200da5ef75
168,870,774,202,321,490,000,000,000,000,000,000,000
30
Fix undefined behavior in CollectiveReduceV2 and others We should not call done after it's moved. PiperOrigin-RevId: 400838185 Change-Id: Ifc979740054b8f8c6f4d50acc89472fe60c4fdb1
void notrace __ppc64_runlatch_on(void) { struct thread_info *ti = current_thread_info(); if (cpu_has_feature(CPU_FTR_ARCH_206)) { /* * Least significant bit (RUN) is the only writable bit of * the CTRL register, so we can avoid mfspr. 2.06 is not the * earliest ISA where this is the case, but it's conveni...
0
[ "CWE-862" ]
linux
8205d5d98ef7f155de211f5e2eb6ca03d95a5a60
168,660,922,547,426,400,000,000,000,000,000,000,000
25
powerpc/tm: Fix FP/VMX unavailable exceptions inside a transaction When we take an FP unavailable exception in a transaction we have to account for the hardware FP TM checkpointed registers being incorrect. In this case for this process we know the current and checkpointed FP registers must be the same (since FP wasn'...
static void cap_release_secctx(char *secdata, u32 seclen) { }
0
[]
linux-2.6
ee18d64c1f632043a02e6f5ba5e045bb26a5465f
270,904,130,318,859,240,000,000,000,000,000,000,000
3
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...
GF_Err ohdr_box_size(GF_Box *s) { GF_OMADRMCommonHeaderBox *ptr = (GF_OMADRMCommonHeaderBox *)s; ptr->size += 1+1+8+2+2+2; if (ptr->ContentID) ptr->size += strlen(ptr->ContentID); if (ptr->RightsIssuerURL) ptr->size += strlen(ptr->RightsIssuerURL); if (ptr->TextualHeadersLen) ptr->size += ptr->TextualHeadersLen; ...
0
[ "CWE-703" ]
gpac
f19668964bf422cf5a63e4dbe1d3c6c75edadcbb
85,305,255,761,790,840,000,000,000,000,000,000,000
9
fixed #1879
static inline void msg_init(struct uffd_msg *msg) { BUILD_BUG_ON(sizeof(struct uffd_msg) != 32); /* * Must use memset to zero out the paddings or kernel data is * leaked to userland. */ memset(msg, 0, sizeof(struct uffd_msg)); }
0
[ "CWE-416" ]
linux
384632e67e0829deb8015ee6ad916b180049d252
261,395,609,925,486,440,000,000,000,000,000,000,000
9
userfaultfd: non-cooperative: fix fork use after free When reading the event from the uffd, we put it on a temporary fork_event list to detect if we can still access it after releasing and retaking the event_wqh.lock. If fork aborts and removes the event from the fork_event all is fine as long as we're still in the u...
BSONObj spec() { return BSON("$eq" << BSON_ARRAY(BSON("$and" << BSON_ARRAY("$a")) << 1)); }
0
[ "CWE-835" ]
mongo
0a076417d1d7fba3632b73349a1fd29a83e68816
316,172,949,424,793,120,000,000,000,000,000,000,000
3
SERVER-38070 fix infinite loop in agg expression
SSL_CTX *SSL_CTX_new(const SSL_METHOD *meth) { SSL_CTX *ret=NULL; if (meth == NULL) { SSLerr(SSL_F_SSL_CTX_NEW,SSL_R_NULL_SSL_METHOD_PASSED); return(NULL); } if (SSL_get_ex_data_X509_STORE_CTX_idx() < 0) { SSLerr(SSL_F_SSL_CTX_NEW,SSL_R_X509_VERIFICATION_SETUP_PROBLEMS); goto err; } ret=(SSL_CTX ...
0
[]
openssl
7587347bc48e7e8a1e800e48bb0a658f1557c424
26,942,308,240,376,180,000,000,000,000,000,000,000
181
Fix memory leak.
BOOL wf_cliprdr_uninit(wfContext* wfc, CliprdrClientContext* cliprdr) { wfClipboard* clipboard; if (!wfc || !cliprdr) return FALSE; clipboard = wfc->clipboard; if (!clipboard) return FALSE; cliprdr->custom = NULL; if (clipboard->hwnd) PostMessage(clipboard->hwnd, WM_QUIT, 0, 0); if (clipboard->thread...
0
[ "CWE-20" ]
FreeRDP
0d79670a28c0ab049af08613621aa0c267f977e9
150,794,869,970,758,970,000,000,000,000,000,000,000
35
Fixed missing input checks for file contents request reported by Valentino Ricotta (Thalium)
void PingStats::init() { boost::array<double, 3> probs = {{0.75, 0.80, 0.95 }}; asQuantile = new asQuantileType(boost::accumulators::tag::extended_p_square::probabilities = probs); dPing = 0.0; uiPing = 0; uiPingSort = 0; uiUsers = 0; uiMaxUsers = 0; uiBandwidth = 0; uiSent = 0; uiRecv = 0; uiVersion = 0; }
0
[ "CWE-59", "CWE-61" ]
mumble
e59ee87abe249f345908c7d568f6879d16bfd648
314,456,827,345,230,200,000,000,000,000,000,000,000
14
FIX(client): Only allow "http"/"https" for URLs in ConnectDialog Our public server list registration script doesn't have an URL scheme whitelist for the website field. Turns out a malicious server can register itself with a dangerous URL in an attempt to attack a user's machine. User interaction is required, as the ...
static uint32_t phar_tar_number(char *buf, int len) /* {{{ */ { uint32_t num = 0; int i = 0; while (i < len && buf[i] == ' ') { ++i; } while (i < len && buf[i] >= '0' && buf[i] <= '7') { num = num * 8 + (buf[i] - '0'); ++i; } return num; }
0
[ "CWE-119" ]
php-src
e0f5d62bd6690169998474b62f92a8c5ddf0e699
64,057,427,243,023,280,000,000,000,000,000,000,000
16
Fix bug #77586 - phar_tar_writeheaders_int() buffer overflow
ciKlass* ciEnv::get_klass_by_name_impl(ciKlass* accessing_klass, const constantPoolHandle& cpool, ciSymbol* name, bool require_local) { ASSERT_IN_VM; EXCEPTION_CONTEXT; // Now we need to check the...
0
[]
jdk11u
6c0ba0785a2f0900be301f72764cf4dcfa720991
394,340,420,668,522,400,000,000,000,000,000,000
107
8281859: Improve class compilation Reviewed-by: mbaesken Backport-of: 3ac62a66efd05d0842076dd4cfbea0e53b12630f
TRIO_PUBLIC_STRING int trio_contains TRIO_ARGS2((string, substring), TRIO_CONST char* string, TRIO_CONST char* substring) { assert(string); assert(substring); return (0 != strstr(string, substring)); }
0
[ "CWE-190", "CWE-125" ]
FreeRDP
05cd9ea2290d23931f615c1b004d4b2e69074e27
182,713,925,492,319,200,000,000,000,000,000,000,000
8
Fixed TrioParse and trio_length limts. CVE-2020-4030 thanks to @antonio-morales for finding this.
static Window XSelectWindow(Display *display,RectangleInfo *crop_info) { #define MinimumCropArea (unsigned int) 9 Cursor target_cursor; GC annotate_context; int presses, x_offset, y_offset; Status status; Window root_window, target_window; XEvent event; XGCValue...
0
[ "CWE-401" ]
ImageMagick6
13801f5d0bd7a6fdb119682d34946636afdb2629
124,095,154,954,425,870,000,000,000,000,000,000,000
144
https://github.com/ImageMagick/ImageMagick/issues/1531
static inline int keepalive_time_when(const struct tcp_sock *tp) { return tp->keepalive_time ? : sysctl_tcp_keepalive_time; }
0
[]
linux
7bced397510ab569d31de4c70b39e13355046387
269,785,835,579,204,040,000,000,000,000,000,000,000
4
net_dma: simple removal Per commit "77873803363c net_dma: mark broken" net_dma is no longer used and there is no plan to fix it. This is the mechanical removal of bits in CONFIG_NET_DMA ifdef guards. Reverting the remainder of the net_dma induced changes is deferred to subsequent patches. Marked for stable due to Ro...
GF_Box *mhap_box_new() { ISOM_DECL_BOX_ALLOC(GF_MHACompatibleProfilesBox, GF_ISOM_BOX_TYPE_MHAP); return (GF_Box *)tmp;
0
[ "CWE-476", "CWE-787" ]
gpac
b8f8b202d4fc23eb0ab4ce71ae96536ca6f5d3f8
45,770,181,798,366,430,000,000,000,000,000,000,000
5
fixed #1757