func
string
target
int64
cwe
list
project
string
commit_id
string
hash
float64
size
int64
message
string
void NumberFormatTest::Test10468ApplyPattern() { // Padding char of fmt is now 'a' UErrorCode status = U_ZERO_ERROR; DecimalFormat fmt("'I''ll'*a###.##", status); if (U_FAILURE(status)) { errcheckln(status, "DecimalFormat constructor failed - %s", u_errorName(status)); return; } ...
0
[ "CWE-190" ]
icu
53d8c8f3d181d87a6aa925b449b51c4a2c922a51
53,196,260,287,816,900,000,000,000,000,000,000,000
19
ICU-20246 Fixing another integer overflow in number parsing.
h2_del_req(struct worker *wrk, const struct h2_req *r2) { struct h2_sess *h2; struct sess *sp; CHECK_OBJ_NOTNULL(r2, H2_REQ_MAGIC); AZ(r2->scheduled); h2 = r2->h2sess; CHECK_OBJ_NOTNULL(h2, H2_SESS_MAGIC); ASSERT_RXTHR(h2); sp = h2->sess; Lck_Lock(&sp->mtx); assert(h2->refcnt > 0); --h2->refcnt; /* XXX: PR...
0
[ "CWE-444" ]
varnish-cache
d4c67d2a1a05304598895c24663c58a2e2932708
156,003,159,908,937,780,000,000,000,000,000,000,000
21
Take content length into account on H/2 request bodies When receiving H/2 data frames, make sure to take the advertised content length into account, and fail appropriately if the combined sum of the data frames does not match the content length.
int btrfs_init_acl(struct btrfs_trans_handle *trans, struct inode *inode, struct inode *dir) { struct posix_acl *default_acl, *acl; int ret = 0; /* this happens with subvols */ if (!dir) return 0; ret = posix_acl_create(dir, &inode->i_mode, &default_acl, &acl); if (ret) return ret; if (default_acl) {...
0
[ "CWE-862", "CWE-285" ]
linux
073931017b49d9458aa351605b43a7e34598caef
305,759,324,259,037,100,000,000,000,000,000,000,000
31
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...
GF_Err gf_isom_open_progressive(const char *fileName, u64 start_range, u64 end_range, Bool enable_frag_bounds, GF_ISOFile **the_file, u64 *BytesMissing) { return gf_isom_open_progressive_ex(fileName, start_range, end_range, enable_frag_bounds, the_file, BytesMissing, NULL); }
0
[ "CWE-476" ]
gpac
ebfa346eff05049718f7b80041093b4c5581c24e
136,660,704,202,298,250,000,000,000,000,000,000,000
4
fixed #1706
static int accept(struct socket *sock, struct socket *new_sock, int flags) { struct sock *new_sk, *sk = sock->sk; struct sk_buff *buf; struct tipc_sock *new_tsock; struct tipc_port *new_tport; struct tipc_msg *msg; u32 new_ref; int res; lock_sock(sk); if (sock->state != SS_LISTENING) { res = -EINVAL; go...
0
[ "CWE-200" ]
linux
60085c3d009b0df252547adb336d1ccca5ce52ec
179,273,611,459,303,600,000,000,000,000,000,000,000
84
tipc: fix info leaks via msg_name in recv_msg/recv_stream The code in set_orig_addr() does not initialize all of the members of struct sockaddr_tipc when filling the sockaddr info -- namely the union is only partly filled. This will make recv_msg() and recv_stream() -- the only users of this function -- leak kernel st...
static int do_shared_fault(struct vm_fault *vmf) { struct vm_area_struct *vma = vmf->vma; int ret, tmp; ret = __do_fault(vmf); if (unlikely(ret & (VM_FAULT_ERROR | VM_FAULT_NOPAGE | VM_FAULT_RETRY))) return ret; /* * Check if the backing address space wants to know that the page is * about to become writab...
0
[ "CWE-119" ]
linux
1be7107fbe18eed3e319a6c3e83c78254b693acb
267,356,404,914,672,530,000,000,000,000,000,000,000
34
mm: larger stack guard gap, between vmas Stack guard page is a useful feature to reduce a risk of stack smashing into a different mapping. We have been using a single page gap which is sufficient to prevent having stack adjacent to a different mapping. But this seems to be insufficient in the light of the stack usage ...
_richacl_mode_to_mask(short mode) { int mask = 0; if (mode & S_IROTH) mask |= RICHACE_POSIX_MODE_READ; if (mode & S_IWOTH) mask |= RICHACE_POSIX_MODE_WRITE; if (mode & S_IXOTH) mask |= RICHACE_POSIX_MODE_EXEC; return (mask); }
0
[ "CWE-59", "CWE-61" ]
libarchive
fba4f123cc456d2b2538f811bb831483bf336bad
3,043,010,081,575,436,000,000,000,000,000,000,000
13
Fix handling of symbolic link ACLs On Linux ACLs on symbolic links are not supported. We must avoid calling acl_set_file() on symbolic links as their targets are modified instead. While here, do not try to set default ACLs on non-directories. Fixes #1565
virNodeDeviceCapUSBInterfaceDefFormat(virBufferPtr buf, const virNodeDevCapData *data) { virBufferAsprintf(buf, "<number>%d</number>\n", data->usb_if.number); virBufferAsprintf(buf, "<class>%d</class>\n", data->usb_if.klass); ...
0
[ "CWE-119" ]
libvirt
4c4d0e2da07b5a035b26a0ff13ec27070f7c7b1a
217,013,897,134,913,500,000,000,000,000,000,000,000
16
conf: Fix segfault when parsing mdev types Commit f1b0890 introduced a potential crash due to incorrect operator precedence when accessing an element from a pointer to an array. Backtrace below: #0 virNodeDeviceGetMdevTypesCaps (sysfspath=0x7fff801661e0 "/sys/devices/pci0000:00/0000:00:02.0", mdev_types=0x7fff801...
ConnectionSocketImpl(IoHandlePtr&& io_handle, const Address::InstanceConstSharedPtr& local_address, const Address::InstanceConstSharedPtr& remote_address) : SocketImpl(std::move(io_handle), local_address), remote_address_(remote_address), direct_remote_addre...
0
[ "CWE-400" ]
envoy
542f84c66e9f6479bc31c6f53157c60472b25240
14,946,524,733,213,288,000,000,000,000,000,000,000
5
overload: Runtime configurable global connection limits (#147) Signed-off-by: Tony Allen <tony@allen.gg>
static char *swiftField(const char *dn, const char *cn) { char *p = strstr (dn, ".getter_"); if (!p) { p = strstr (dn, ".setter_"); if (!p) { p = strstr (dn, ".method_"); } } if (p) { char *q = strstr (dn, cn); if (q && q[strlen (cn)] == '.') { q = strdup (q + strlen (cn) + 1); char *r = strchr (...
0
[ "CWE-125" ]
radare2
3fcf41ed96ffa25b38029449520c8d0a198745f3
273,197,402,918,312,860,000,000,000,000,000,000,000
21
Fix #9902 - Fix oobread in RBin.string_scan_range
R_API bool r_socket_spawn (RSocket *s, const char *cmd, unsigned int timeout) { return -1; }
0
[ "CWE-78" ]
radare2
04edfa82c1f3fa2bc3621ccdad2f93bdbf00e4f9
32,216,086,741,149,754,000,000,000,000,000,000,000
3
Fix command injection on PDB download (#16966) * Fix r_sys_mkdirp with absolute path on Windows * Fix build with --with-openssl * Use RBuffer in r_socket_http_answer() * r_socket_http_answer: Fix read for big responses * Implement r_str_escape_sh() * Cleanup r_socket_connect() on Windows * Fix socket being creat...
static void vga_draw_graphic(VGACommonState *s, int full_update) { DisplaySurface *surface = qemu_console_surface(s->con); int y1, y, update, linesize, y_start, double_scan, mask, depth; int width, height, shift_control, line_offset, bwidth, bits; ram_addr_t page0, page1, page_min, page_max; int dis...
0
[ "CWE-200" ]
qemu
c1b886c45dc70f247300f549dce9833f3fa2def5
233,377,516,465,568,950,000,000,000,000,000,000,000
219
vbe: rework sanity checks Plug a bunch of holes in the bochs dispi interface parameter checking. Add a function doing verification on all registers. Call that unconditionally on every register write. That way we should catch everything, even changing one register affecting the valid range of another register. Some ...
int wav_parse(wav_reader_t *reader, int64_t *data_length) { uint32_t container, fcc, chunk_size; int fmt_seen = 0; *data_length = 0; container = riff_next_chunk(reader, &chunk_size); ENSURE(container == RIFF_FOURCC('R','I','F','F') || container == RIFF_FOURCC('R','F','6','4')); TRY_I...
0
[ "CWE-703" ]
fdkaac
4ec1422bd951a137225ffa4052da120e2ab0a0f4
67,508,813,868,983,070,000,000,000,000,000,000,000
33
wav/caf parser: ensure fmt/desc chunk fixes https://github.com/nu774/fdkaac/issues/52
Status ConvBackpropComputeDimensionsV2( StringPiece label, int num_spatial_dims, const TensorShape& input_shape, const TensorShape& filter_shape, const TensorShape& out_backprop_shape, const gtl::ArraySlice<int32>& dilations, const std::vector<int32>& strides, Padding padding, absl::Span<const int64> ex...
0
[ "CWE-369" ]
tensorflow
fca9874a9b42a2134f907d2fb46ab774a831404a
287,077,448,679,940,440,000,000,000,000,000,000,000
64
Prevent another division by zero. PiperOrigin-RevId: 369338598 Change-Id: I55471d363e401fdcf8d259670ad4eef672b731e2
gnutls_x509_crt_get_key_usage(gnutls_x509_crt_t cert, unsigned int *key_usage, unsigned int *critical) { int result; gnutls_datum_t keyUsage; if (cert == NULL) { gnutls_assert(); return GNUTLS_E_INVALID_REQUEST; } if ((result = _gnutls_x509_crt_get_extension(cert, "2.5.29.15", 0, ...
0
[ "CWE-295" ]
gnutls
6e76e9b9fa845b76b0b9a45f05f4b54a052578ff
228,933,198,173,861,500,000,000,000,000,000,000,000
33
on certificate import check whether the two signature algorithms match
static bool __io_cqring_overflow_flush(struct io_ring_ctx *ctx, bool force, struct task_struct *tsk, struct files_struct *files) { struct io_rings *rings = ctx->rings; struct io_kiocb *req, *tmp; struct io_uring_cqe *cqe; unsigned long flags; bool all_flushed, posted; LIST_HEAD(list); if (...
0
[ "CWE-667" ]
linux
3ebba796fa251d042be42b929a2d916ee5c34a49
297,078,325,968,878,600,000,000,000,000,000,000,000
58
io_uring: ensure that SQPOLL thread is started for exit If we create it in a disabled state because IORING_SETUP_R_DISABLED is set on ring creation, we need to ensure that we've kicked the thread if we're exiting before it's been explicitly disabled. Otherwise we can run into a deadlock where exit is waiting go park t...
void *umm_calloc( size_t num, size_t item_size ) { void *ret; size_t size = item_size * num; /* check poison of each blocks, if poisoning is enabled */ if (!CHECK_POISON_ALL_BLOCKS()) { return NULL; } /* check full integrity of the heap, if this check is enabled */ if (!INTEGRITY_CHECK()) { retu...
1
[ "CWE-190" ]
mongoose-os
b338266c0492cccdb8d8a93ee0b9217bc5a04036
154,104,052,841,136,470,000,000,000,000,000,000,000
24
Fix umm_malloc()
pdf14_pop_transparency_mask(pdf14_ctx *ctx, gs_gstate *pgs, gx_device *dev) { pdf14_buf *tos = ctx->stack; byte *new_data_buf; int icc_match; cmm_profile_t *des_profile = tos->parent_color_info_procs->icc_profile; /* If set, this should be a gray profile */ cmm_profile_t *src_profile; gsicc_rend...
0
[ "CWE-416" ]
ghostpdl
90fd0c7ca3efc1ddff64a86f4104b13b3ac969eb
214,852,342,977,520,450,000,000,000,000,000,000,000
182
Bug 697456. Dont create new ctx when pdf14 device reenabled This bug had yet another weird case where the user created a file that pushed the pdf14 device twice. We were in that case, creating a new ctx and blowing away the original one with out proper clean up. To avoid, only create a new one when we need it.
void DL_Dxf::writeBlockRecord(DL_WriterA& dw, const std::string& name) { dw.dxfString( 0, "BLOCK_RECORD"); if (version==DL_VERSION_2000) { dw.handle(); } //dw->dxfHex(330, 1); if (version==DL_VERSION_2000) { dw.dxfString(100, "AcDbSymbolTableRecord"); dw.dxfString(100, "AcDb...
0
[ "CWE-191" ]
qcad
1eeffc5daf5a06cf6213ffc19e95923cdebb2eb8
53,141,462,657,892,940,000,000,000,000,000,000,000
13
check vertexIndex which might be -1 for broken DXF
cr_tknzr_parse_token (CRTknzr * a_this, enum CRTokenType a_type, enum CRTokenExtraType a_et, gpointer a_res, gpointer a_extra_res) { enum CRStatus status = CR_OK; CRToken *token = NULL; g_return_val_if_fail (a_this && PRIVATE (a_this) ...
0
[ "CWE-119" ]
libcroco
9ad72875e9f08e4c519ef63d44cdbd94aa9504f7
19,390,246,316,816,377,000,000,000,000,000,000,000
109
tknzr: support only max long rgb values This fixes a possible out of bound when reading rgbs which are longer than the support MAXLONG
attempt_to_load_user_settings (GdmSessionWorker *worker, const char *username) { g_debug ("GdmSessionWorker: attempting to load user settings"); gdm_session_settings_load (worker->priv->user_settings, username); }
0
[ "CWE-362" ]
gdm
dcdbaaa04012541ad2813cf83559d91d52f208b9
323,110,502,557,815,200,000,000,000,000,000,000,000
7
session-worker: Don't switch back VTs until session is fully exited There's a race condition on shutdown where the session worker is switching VTs back to the initial VT at the same time as the session exit is being processed. This means that manager may try to start a login screen (because of the VT switch) when aut...
R_API bool r_str_range_in(const char *r, ut64 addr) { const char *p = r; ut64 min = UT64_MAX; ut64 max = 0; if (!r) { return false; } for (; *r; r++) { if (*r == ',') { if (max == 0) { if (addr == r_num_get (NULL, p)) { return true; } } else { if (addr >= min && addr <= r_num_get (NULL,...
0
[ "CWE-78" ]
radare2
04edfa82c1f3fa2bc3621ccdad2f93bdbf00e4f9
178,837,186,789,201,700,000,000,000,000,000,000,000
43
Fix command injection on PDB download (#16966) * Fix r_sys_mkdirp with absolute path on Windows * Fix build with --with-openssl * Use RBuffer in r_socket_http_answer() * r_socket_http_answer: Fix read for big responses * Implement r_str_escape_sh() * Cleanup r_socket_connect() on Windows * Fix socket being creat...
static void l2cap_chan_connect_reject(struct l2cap_chan *chan) { struct l2cap_conn *conn = chan->conn; struct l2cap_conn_rsp rsp; u16 result; if (test_bit(FLAG_DEFER_SETUP, &chan->flags)) result = L2CAP_CR_SEC_BLOCK; else result = L2CAP_CR_BAD_PSM; l2cap_state_change(chan, BT_DISCONN); rsp.scid = cpu_to...
0
[ "CWE-787" ]
linux
e860d2c904d1a9f38a24eb44c9f34b8f915a6ea3
115,631,549,488,782,440,000,000,000,000,000,000,000
20
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 MemTxResult gic_thiscpu_hyp_write(void *opaque, hwaddr addr, uint64_t value, unsigned size, MemTxAttrs attrs) { GICState *s = (GICState *)opaque; return gic_hyp_write(s, gic_get_current_cpu(s), addr, value, attrs); }
0
[ "CWE-787" ]
qemu
edfe2eb4360cde4ed5d95bda7777edcb3510f76a
296,227,585,542,280,480,000,000,000,000,000,000,000
8
hw/intc/arm_gic: Fix interrupt ID in GICD_SGIR register Per the ARM Generic Interrupt Controller Architecture specification (document "ARM IHI 0048B.b (ID072613)"), the SGIINTID field is 4 bit, not 10: - 4.3 Distributor register descriptions - 4.3.15 Software Generated Interrupt Register, GICD_SG - Table 4-2...
static void helpf(const char *fmt, ...) { va_list ap; if(fmt) { va_start(ap, fmt); fputs("curl: ", stderr); /* prefix it */ vfprintf(stderr, fmt, ap); va_end(ap); } fprintf(stderr, "curl: try 'curl --help' " #ifdef USE_MANUAL "or 'curl --manual' " #endif "for more information...
0
[ "CWE-125" ]
curl
70b1900dd13d16f2e83f571407a614541d5ac9ba
56,765,259,975,533,060,000,000,000,000,000,000,000
15
'mytx' in bug report #1723194 (http://curl.haxx.se/bug/view.cgi?id=1723194) pointed out that the warnf() function in the curl tool didn't properly deal with the cases when excessively long words were used in the string to chop up.
call_func( char_u *funcname, // name of the function int len, // length of "name" or -1 to use strlen() typval_T *rettv, // return value goes here int argcount_in, // number of "argvars" typval_T *argvars_in, // vars for arguments, must have "argcount" // PLUS ONE elements! funcexe_T *fu...
0
[ "CWE-416" ]
vim
9c23f9bb5fe435b28245ba8ac65aa0ca6b902c04
259,847,098,024,337,400,000,000,000,000,000,000,000
223
patch 8.2.3902: Vim9: double free with nested :def function Problem: Vim9: double free with nested :def function. Solution: Pass "line_to_free" from compile_def_function() and make sure cmdlinep is valid.
int usb_set_interface(struct usb_device *dev, int interface, int alternate) { struct usb_interface *iface; struct usb_host_interface *alt; struct usb_hcd *hcd = bus_to_hcd(dev->bus); int i, ret, manual = 0; unsigned int epaddr; unsigned int pipe; if (dev->state == USB_STATE_SUSPENDED) return -EHOSTUNREACH; ...
0
[ "CWE-119", "CWE-787" ]
linux
2e1c42391ff2556387b3cb6308b24f6f65619feb
189,780,555,857,491,730,000,000,000,000,000,000,000
130
USB: core: harden cdc_parse_cdc_header Andrey Konovalov reported a possible out-of-bounds problem for the cdc_parse_cdc_header function. He writes: It looks like cdc_parse_cdc_header() doesn't validate buflen before accessing buffer[1], buffer[2] and so on. The only check present is while (buflen > 0). So fix thi...
DeepTiledInputFile::initialize () { if (_data->partNumber == -1) if (_data->header.type() != DEEPTILE) throw IEX_NAMESPACE::ArgExc ("Expected a deep tiled file but the file is not deep tiled."); if(_data->header.version()!=1) { THROW(IEX_NAMESPACE::ArgExc, "Version " << _data->heade...
0
[ "CWE-125" ]
openexr
467be80b75642efbbe6bdace558079f68c16acb1
1,799,634,449,804,198,000,000,000,000,000,000,000
91
Fix overflow computing deeptile sample table size (#861) Signed-off-by: Peter Hillman <peterh@wetafx.co.nz>
static void init_dirty_segmap(struct f2fs_sb_info *sbi) { struct dirty_seglist_info *dirty_i = DIRTY_I(sbi); struct free_segmap_info *free_i = FREE_I(sbi); unsigned int segno = 0, offset = 0; unsigned short valid_blocks; while (1) { /* find dirty segment based on free segmap */ segno = find_next_inuse(free_i,...
0
[ "CWE-20" ]
linux
638164a2718f337ea224b747cf5977ef143166a4
179,388,382,180,755,500,000,000,000,000,000,000,000
25
f2fs: fix potential panic during fstrim As Ju Hyung Park reported: "When 'fstrim' is called for manual trim, a BUG() can be triggered randomly with this patch. I'm seeing this issue on both x86 Desktop and arm64 Android phone. On x86 Desktop, this was caused during Ubuntu boot-up. I have a cronjob installed which c...
static void svm_get_exit_info(struct kvm_vcpu *vcpu, u32 *reason, u64 *info1, u64 *info2, u32 *intr_info, u32 *error_code) { struct vmcb_control_area *control = &to_svm(vcpu)->vmcb->control; *reason = control->exit_code; *info1 = control->exit_info_1; *info2 = control->exit_info_2; *intr_info = ...
0
[ "CWE-703" ]
linux
6cd88243c7e03845a450795e134b488fc2afb736
304,338,209,574,691,430,000,000,000,000,000,000,000
16
KVM: x86: do not report a vCPU as preempted outside instruction boundaries If a vCPU is outside guest mode and is scheduled out, it might be in the process of making a memory access. A problem occurs if another vCPU uses the PV TLB flush feature during the period when the vCPU is scheduled out, and a virtual address ...
static GF_Err gf_seng_encode_dims_au(GF_SceneEngine *seng, u16 ESID, GF_List *commands, u8 **data, u32 *size, Bool compress_dims) { #ifndef GPAC_DISABLE_SCENE_DUMP GF_SceneDumper *dumper = NULL; #endif GF_Err e; char rad_name[4096]; char file_name[4096+100]; u32 fsize; u8 *buffer = NULL; GF_BitStream *bs = NULL;...
0
[ "CWE-787" ]
gpac
ea1eca00fd92fa17f0e25ac25652622924a9a6a0
267,448,164,969,398,050,000,000,000,000,000,000,000
155
fixed #2138
cmdline_erase_chars( int c, int indent #ifdef FEAT_SEARCH_EXTRA , incsearch_state_T *isp #endif ) { int i; int j; if (c == K_KDEL) c = K_DEL; /* * Delete current character is the same as backspace on next * character, except at end of line. */ if (c == K_DEL && ccline.cmdpos ...
0
[ "CWE-122", "CWE-787" ]
vim
ef02f16609ff0a26ffc6e20263523424980898fe
127,075,497,425,789,930,000,000,000,000,000,000,000
107
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.
ResetWindow(p) register struct win *p; { register int i; p->w_wrap = nwin_default.wrap; p->w_origin = 0; p->w_insert = 0; p->w_revvid = 0; p->w_mouse = 0; p->w_curinv = 0; p->w_curvvis = 0; p->w_autolf = 0; p->w_keypad = 0; p->w_cursorkeys = 0; p->w_top = 0; p->w_bot = p->w_height - 1; p->w...
0
[]
screen
c5db181b6e017cfccb8d7842ce140e59294d9f62
16,377,883,532,880,983,000,000,000,000,000,000,000
32
ansi: add support for xterm OSC 11 It allows for getting and setting the background color. Notably, Vim uses OSC 11 to learn whether it's running on a light or dark colored terminal and choose a color scheme accordingly. Tested with gnome-terminal and xterm. When called with "?" argument the current background color ...
int i2d_PUBKEY_fp(FILE *fp, EVP_PKEY *pkey) { return ASN1_i2d_fp_of(EVP_PKEY,i2d_PUBKEY,fp,pkey); }
0
[ "CWE-310" ]
openssl
684400ce192dac51df3d3e92b61830a6ef90be3e
293,335,575,338,877,970,000,000,000,000,000,000,000
4
Fix various certificate fingerprint issues. By using non-DER or invalid encodings outside the signed portion of a certificate the fingerprint can be changed without breaking the signature. Although no details of the signed portion of the certificate can be changed this can cause problems with some applications: e.g. t...
compile_length_anchor_node(AnchorNode* node, regex_t* reg) { int len; int tlen = 0; if (IS_NOT_NULL(NODE_ANCHOR_BODY(node))) { tlen = compile_length_tree(NODE_ANCHOR_BODY(node), reg); if (tlen < 0) return tlen; } switch (node->type) { case ANCHOR_PREC_READ: len = SIZE_OP_PREC_READ_START + tlen...
0
[ "CWE-476" ]
oniguruma
410f5916429e7d2920e1d4867388514f605413b8
6,649,565,942,355,078,000,000,000,000,000,000,000
45
fix #87: Read unknown address in onig_error_code_to_str()
static void rds6_conn_message_info(struct socket *sock, unsigned int len, struct rds_info_iterator *iter, struct rds_info_lengths *lens, int want_send) { rds_conn_message_info_cmn(sock, len, iter, lens, want_send, true); }
0
[ "CWE-401" ]
linux
5f9562ebe710c307adc5f666bf1a2162ee7977c0
325,386,716,400,155,670,000,000,000,000,000,000,000
7
rds: memory leak in __rds_conn_create() __rds_conn_create() did not release conn->c_path when loop_trans != 0 and trans->t_prefer_loopback != 0 and is_outgoing == 0. Fixes: aced3ce57cd3 ("RDS tcp loopback connection can hang") Signed-off-by: Hangyu Hua <hbh25y@gmail.com> Reviewed-by: Sharath Srinivasan <sharath.srini...
static inline uint64_t virtio_net_supported_guest_offloads(VirtIONet *n) { VirtIODevice *vdev = VIRTIO_DEVICE(n); return virtio_net_guest_offloads_by_features(vdev->guest_features); }
0
[ "CWE-119" ]
qemu
98f93ddd84800f207889491e0b5d851386b459cf
220,368,781,785,236,800,000,000,000,000,000,000,000
5
virtio-net: out-of-bounds buffer write on load CVE-2013-4149 QEMU 1.3.0 out-of-bounds buffer write in virtio_net_load()@hw/net/virtio-net.c > } else if (n->mac_table.in_use) { > uint8_t *buf = g_malloc0(n->mac_table.in_use); We are allocating buffer of size n->mac_table.in_use > qemu...
static void resume (lua_State *L, void *ud) { int n = *(cast(int*, ud)); /* number of arguments */ StkId firstArg = L->top - n; /* first argument */ CallInfo *ci = L->ci; if (L->status == LUA_OK) { /* starting a coroutine? */ luaD_call(L, firstArg - 1, LUA_MULTRET); } else { /* resuming from previou...
0
[ "CWE-416", "CWE-125", "CWE-787" ]
lua
6298903e35217ab69c279056f925fb72900ce0b7
128,194,778,924,109,440,000,000,000,000,000,000,000
24
Keep minimum size when shrinking a stack When shrinking a stack (during GC), do not make it smaller than the initial stack size.
PeerWrapper(const StreamInfo::StreamInfo& info, bool local) : info_(info), local_(local) {}
0
[]
envoy
2c60632d41555ec8b3d9ef5246242be637a2db0f
49,139,249,923,674,170,000,000,000,000,000,000,000
1
http: header map security fixes for duplicate headers (#197) Previously header matching did not match on all headers for non-inline headers. This patch changes the default behavior to always logically match on all headers. Multiple individual headers will be logically concatenated with ',' similar to what is done with...
status_redraw_all(void) { win_T *wp; FOR_ALL_WINDOWS(wp) if (wp->w_status_height) { wp->w_redr_status = TRUE; redraw_later(VALID); } }
0
[ "CWE-122" ]
vim
826bfe4bbd7594188e3d74d2539d9707b1c6a14b
324,677,510,114,930,250,000,000,000,000,000,000,000
11
patch 8.2.3487: illegal memory access if buffer name is very long Problem: Illegal memory access if buffer name is very long. Solution: Make sure not to go over the end of the buffer.
RETSIGTYPE requestinfo(int signo _U_) { if (infodelay) ++infoprint; else info(0); }
0
[ "CWE-120", "CWE-787" ]
tcpdump
9ba91381954ad325ea4fd26b9c65a8bd9a2a85b6
325,944,686,992,211,870,000,000,000,000,000,000,000
7
(for 4.9.3) CVE-2018-14879/fix -V to fail invalid input safely get_next_file() did not check the return value of strlen() and underflowed an array index if the line read by fgets() from the file started with \0. This caused an out-of-bounds read and could cause a write. Add the missing check. This vulnerability was d...
std::string get_binary_file_location(const std::string& type, const std::string& filename) { DBG_FS << "Looking for '" << filename << "'.\n"; if (filename.empty()) { LOG_FS << " invalid filename (type: " << type <<")\n"; return std::string(); } // Some parts of Wesnoth enjoy putting ".." inside filenames. Th...
0
[ "CWE-200" ]
wesnoth
af61f9fdd15cd439da9e2fe5fa39d174c923eaae
160,651,641,946,602,860,000,000,000,000,000,000,000
36
fs: Use game data path to resolve ./ in the absence of a current_dir Fixes a file content disclosure bug (#22042) affecting functionality relying on the get_wml_location() function and not passing a non-empty value for the current_dir parameter. See <https://gna.org/bugs/?22042> for details. This is a candidate for ...
static int cgroup_init_fs_context(struct fs_context *fc) { struct cgroup_fs_context *ctx; ctx = kzalloc(sizeof(struct cgroup_fs_context), GFP_KERNEL); if (!ctx) return -ENOMEM; ctx->ns = current->nsproxy->cgroup_ns; get_cgroup_ns(ctx->ns); fc->fs_private = &ctx->kfc; if (fc->fs_type == &cgroup2_fs_type) fc...
0
[ "CWE-416" ]
linux
a06247c6804f1a7c86a2e5398a4c1f1db1471848
164,482,233,911,744,430,000,000,000,000,000,000,000
20
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 sum_update(const char *p, int32 len) { switch (cursum_type) { case CSUM_MD5: md5_update(&md, (uchar *)p, len); break; case CSUM_MD4: case CSUM_MD4_OLD: case CSUM_MD4_BUSTED: case CSUM_MD4_ARCHAIC: if (len + sumresidue < CSUM_CHUNK) { memcpy(md.buffer + sumresidue, p, len); sumresidue +=...
0
[ "CWE-354" ]
rsync
c252546ceeb0925eb8a4061315e3ff0a8c55b48b
246,962,539,056,031,100,000,000,000,000,000,000,000
38
Don't forget to tweak sum_update().
static inline unsigned int isonum_723(char *p) { /* Ignore bigendian datum due to broken mastering programs */ return get_unaligned_le16(p); }
0
[ "CWE-20", "CWE-399" ]
linux
410dd3cf4c9b36f27ed4542ee18b1af5e68645a4
215,831,603,636,873,820,000,000,000,000,000,000,000
5
isofs: Fix unbounded recursion when processing relocated directories We did not check relocated directory in any way when processing Rock Ridge 'CL' tag. Thus a corrupted isofs image can possibly have a CL entry pointing to another CL entry leading to possibly unbounded recursion in kernel code and thus stack overflow...
handler *handler::clone(const char *name, MEM_ROOT *mem_root) { handler *new_handler= get_new_handler(table->s, mem_root, ht); if (!new_handler) return NULL; if (new_handler->set_ha_share_ref(ha_share)) goto err; /* TODO: Implement a more efficient way to have more than one index open for the ...
0
[ "CWE-416" ]
server
af810407f78b7f792a9bb8c47c8c532eb3b3a758
306,024,302,116,084,800,000,000,000,000,000,000,000
26
MDEV-28098 incorrect key in "dup value" error after long unique reset errkey after using it, so that it wouldn't affect the next error message in the next statement
composite_glyphs_via_mask (void *_dst, cairo_operator_t op, cairo_surface_t *_src, int src_x, int src_y, int dst_x, int dst_y, cairo_composite_glyphs_info_t *info) { cairo_scaled_glyph_t *glyph_cache[64]; pixman_image_t *white = _pixman_image_for_c...
0
[ "CWE-787" ]
cairo
c986a7310bb06582b7d8a566d5f007ba4e5e75bf
43,391,822,262,770,670,000,000,000,000,000,000,000
160
image: Enable inplace compositing with opacities for general routines On a SNB i5-2500: Speedups ======== firefox-chalkboard 34284.16 -> 19637.40: 1.74x speedup swfdec-giant-steps 778.35 -> 665.37: 1.17x speedup ocitysmap 485.64 -> 431.94: 1.12x speedup Slowdowns ===...
void MonClient::get_version(string map, version_t *newest, version_t *oldest, Context *onfinish) { version_req_d *req = new version_req_d(onfinish, newest, oldest); ldout(cct, 10) << "get_version " << map << " req " << req << dendl; std::lock_guard l(monc_lock); MMonGetVersion *m = new MMonGetVersion(); m->wh...
0
[ "CWE-294" ]
ceph
2927fd91d41e505237cc73f9700e5c6a63e5cb4f
35,151,359,667,833,503,000,000,000,000,000,000,000
11
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...
pango_ot_buffer_destroy (PangoOTBuffer *buffer) { release_buffer (buffer->buffer, buffer->should_free_hb_buffer); g_object_unref (buffer->font); g_slice_free (PangoOTBuffer, buffer); }
0
[]
pango
336bb3201096bdd0494d29926dd44e8cca8bed26
165,611,334,514,650,780,000,000,000,000,000,000,000
6
[HB] Remove all references to the old code!
void pcrb_del(GF_Box *s) { GF_PcrInfoBox *ptr = (GF_PcrInfoBox *) s; if (ptr == NULL) return; if (ptr->pcr_values) gf_free(ptr->pcr_values); gf_free(ptr); }
0
[ "CWE-125" ]
gpac
bceb03fd2be95097a7b409ea59914f332fb6bc86
278,168,137,053,083,940,000,000,000,000,000,000,000
7
fixed 2 possible heap overflows (inc. #1088)
bool ciEnv::system_dictionary_modification_counter_changed() { return _system_dictionary_modification_counter != SystemDictionary::number_of_modifications(); }
0
[]
jdk8u
1dafef08cc922ee85a8e216387100dc681a5484d
142,028,973,914,682,010,000,000,000,000,000,000,000
3
8281859: Improve class compilation Reviewed-by: andrew Backport-of: 3ac62a66efd05d0842076dd4cfbea0e53b12630f
static void cli_multifree(void *f, ...) { void *ff; va_list ap; free(f); va_start(ap, f); while((ff=va_arg(ap, void*))) free(ff); va_end(ap);
0
[ "CWE-703", "CWE-189" ]
clamav-devel
270e368b99e93aa5447d46c797c92c3f9f39f375
4,284,952,996,640,754,600,000,000,000,000,000,000
8
libclamav: bb #7055
ex_undolist(exarg_T *eap UNUSED) { garray_T ga; u_header_T *uhp; int mark; int nomark; int changes = 1; int i; /* * 1: walk the tree to find all leafs, put the info in "ga". * 2: sort the lines * 3: display the list */ mark = ++lastmark; nomark = ++lastmark; ...
0
[ "CWE-190" ]
vim
3eb1637b1bba19519885dd6d377bd5596e91d22c
207,253,068,397,320,970,000,000,000,000,000,000,000
101
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)
void Field_blob::store_length(uchar *i_ptr, uint i_packlength, uint32 i_number) { store_lowendian(i_number, i_ptr, i_packlength); }
0
[ "CWE-416", "CWE-703" ]
server
08c7ab404f69d9c4ca6ca7a9cf7eec74c804f917
42,915,095,566,798,110,000,000,000,000,000,000,000
4
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...
static long btrfs_ioctl_dev_replace(struct btrfs_fs_info *fs_info, void __user *arg) { struct btrfs_ioctl_dev_replace_args *p; int ret; if (!capable(CAP_SYS_ADMIN)) return -EPERM; p = memdup_user(arg, sizeof(*p)); if (IS_ERR(p)) return PTR_ERR(p); switch (p->cmd) { case BTRFS_IOCTL_DEV_REPLACE_CMD...
0
[ "CWE-476", "CWE-284" ]
linux
09ba3bc9dd150457c506e4661380a6183af651c1
15,806,794,321,418,575,000,000,000,000,000,000,000
45
btrfs: merge btrfs_find_device and find_device Both btrfs_find_device() and find_device() does the same thing except that the latter does not take the seed device onto account in the device scanning context. We can merge them. Signed-off-by: Anand Jain <anand.jain@oracle.com> Reviewed-by: David Sterba <dsterba@suse.c...
const char *mutt_make_version (void) { static char vstring[STRING]; snprintf (vstring, sizeof (vstring), "Mutt %s (%s)", MUTT_VERSION, ReleaseDate); return vstring; }
0
[ "CWE-668" ]
mutt
6d0624411a979e2e1d76af4dd97d03f47679ea4a
254,411,087,577,269,950,000,000,000,000,000,000,000
7
use a 64-bit random value in temporary filenames. closes #3158
/* VC-2 13.5.1 - low_delay_transform_data() */ static int encode_slices(VC2EncContext *s) { uint8_t *buf; int slice_x, slice_y, skip = 0; SliceArgs *enc_args = s->slice_args; avpriv_align_put_bits(&s->pb); flush_put_bits(&s->pb); buf = put_bits_ptr(&s->pb); for (slice_y = 0; slice_y < s->n...
0
[ "CWE-125" ]
FFmpeg
94e538aebbc9f9c529e8b1f2eda860cfb8c473b1
241,578,330,729,469,500,000,000,000,000,000,000,000
26
vc2enc_dwt: pad the temporary buffer by the slice size Since non-Haar wavelets need to look into pixels outside the frame, we need to pad the buffer. The old factor of two seemed to be a workaround that fact and only padded to the left and bottom. This correctly pads by the slice size and as such reduces memory usage ...
static int jpc_cox_getcompparms(jpc_ms_t *ms, jpc_cstate_t *cstate, jas_stream_t *in, int prtflag, jpc_coxcp_t *compparms) { uint_fast8_t tmp; int i; /* Eliminate compiler warning about unused variables. */ ms = 0; cstate = 0; if (jpc_getuint8(in, &compparms->numdlvls) || jpc_getuint8(in, &compparms->cblkw...
0
[]
jasper
a10536d5f7f3164b0a1f1ae3e533f4a12ca6f543
338,760,408,916,012,260,000,000,000,000,000,000,000
49
jpc_cs: reject all but JPC_COX_INS and JPC_COX_RFT Fixes assertion failure JPC_NOMINALGAIN() which can be caused by a crafted JP2 file. Closes #50, #142
int unit_watch_bus_name(Unit *u, const char *name) { int r; assert(u); assert(name); /* Watch a specific name on the bus. We only support one unit * watching each name for now. */ if (u->manager->api_bus) { /* If the bus is already available, install t...
0
[ "CWE-269" ]
systemd
bf65b7e0c9fc215897b676ab9a7c9d1c688143ba
243,125,622,253,279,720,000,000,000,000,000,000,000
25
core: imply NNP and SUID/SGID restriction for DynamicUser=yes service Let's be safe, rather than sorry. This way DynamicUser=yes services can neither take benefit of, nor create SUID/SGID binaries. Given that DynamicUser= is a recent addition only we should be able to get away with turning this on, even though this i...
long Cluster::GetIndex() const { return m_index; }
0
[ "CWE-20" ]
libvpx
34d54b04e98dd0bac32e9aab0fbda0bf501bc742
179,647,652,059,137,260,000,000,000,000,000,000,000
1
update libwebm to libwebm-1.0.0.27-358-gdbf1d10 changelog: https://chromium.googlesource.com/webm/libwebm/+log/libwebm-1.0.0.27-351-g9f23fbc..libwebm-1.0.0.27-358-gdbf1d10 Change-Id: I28a6b3ae02a53fb1f2029eee11e9449afb94c8e3
lexer_check_post_primary_exp (parser_context_t *context_p) /**< context */ { if (!(context_p->token.flags & LEXER_NO_SKIP_SPACES)) { lexer_skip_spaces (context_p); context_p->token.flags = (uint8_t) (context_p->token.flags | LEXER_NO_SKIP_SPACES); } if (context_p->source_p >= context_p->source_end_p) ...
0
[ "CWE-288" ]
jerryscript
f3a420b672927037beb4508d7bdd68fb25d2caf6
295,823,052,931,675,680,000,000,000,000,000,000,000
41
Fix class static block opening brace parsing (#4942) The next character should not be consumed after finding the static block opening brace. This patch fixes #4916. JerryScript-DCO-1.0-Signed-off-by: Martin Negyokru negyokru@inf.u-szeged.hu
int __pte_alloc_kernel(pmd_t *pmd, unsigned long address) { pte_t *new = pte_alloc_one_kernel(&init_mm, address); if (!new) return -ENOMEM; smp_wmb(); /* See comment in __pte_alloc */ spin_lock(&init_mm.page_table_lock); if (likely(pmd_none(*pmd))) { /* Has another populated it ? */ pmd_populate_kernel(&init...
0
[ "CWE-119" ]
linux
1be7107fbe18eed3e319a6c3e83c78254b693acb
239,758,201,883,965,470,000,000,000,000,000,000,000
18
mm: larger stack guard gap, between vmas Stack guard page is a useful feature to reduce a risk of stack smashing into a different mapping. We have been using a single page gap which is sufficient to prevent having stack adjacent to a different mapping. But this seems to be insufficient in the light of the stack usage ...
int sm_looptest_show_switch_lfts(p_fm_config_conx_hdlt hdl, fm_mgr_type_t mgr, int argc, char *argv[]) { fm_mgr_config_errno_t res; fm_msg_ret_code_t ret_code; uint8_t data[BUF_SZ]; int index=-1; fm_config_interation_data_t interationData; int start; if (argc > 1) { printf("Error: only 1 a...
0
[ "CWE-362" ]
opa-fm
c5759e7b76f5bf844be6c6641cc1b356bbc83869
95,721,584,007,880,970,000,000,000,000,000,000,000
40
Fix scripts and code that use well-known tmp files.
static CURLcode parse_connect_to_host_port(struct Curl_easy *data, const char *host, char **hostname_result, int *port_result) { char *host_dup; char *hostptr; char *host_portno; char...
0
[ "CWE-416" ]
curl
81d135d67155c5295b1033679c606165d4e28f3f
27,197,014,347,158,550,000,000,000,000,000,000,000
96
Curl_close: clear data->multi_easy on free to avoid use-after-free Regression from b46cfbc068 (7.59.0) CVE-2018-16840 Reported-by: Brian Carpenter (Geeknik Labs) Bug: https://curl.haxx.se/docs/CVE-2018-16840.html
static inline bool nested_cpu_has_virtual_nmis(struct vmcs12 *vmcs12) { return vmcs12->pin_based_vm_exec_control & PIN_BASED_VIRTUAL_NMIS; }
0
[]
kvm
a642fc305053cc1c6e47e4f4df327895747ab485
64,365,014,431,111,060,000,000,000,000,000,000,000
4
kvm: vmx: handle invvpid vm exit gracefully On systems with invvpid instruction support (corresponding bit in IA32_VMX_EPT_VPID_CAP MSR is set) guest invocation of invvpid causes vm exit, which is currently not handled and results in propagation of unknown exit to userspace. Fix this by installing an invvpid vm exit ...
_cairo_image_spans_compositor_get (void) { static cairo_spans_compositor_t spans; static cairo_compositor_t shape; if (spans.base.delegate == NULL) { _cairo_shape_mask_compositor_init (&shape, _cairo_image_traps_compositor_get()); shape.glyphs = NULL; _cairo_spans_compositor_init (&spans, &shap...
0
[ "CWE-787" ]
cairo
c986a7310bb06582b7d8a566d5f007ba4e5e75bf
181,432,266,094,472,930,000,000,000,000,000,000,000
32
image: Enable inplace compositing with opacities for general routines On a SNB i5-2500: Speedups ======== firefox-chalkboard 34284.16 -> 19637.40: 1.74x speedup swfdec-giant-steps 778.35 -> 665.37: 1.17x speedup ocitysmap 485.64 -> 431.94: 1.12x speedup Slowdowns ===...
static int check_stack_boundary(struct bpf_verifier_env *env, int regno, int access_size, bool zero_size_allowed, struct bpf_call_arg_meta *meta) { struct bpf_reg_state *reg = reg_state(env, regno); struct bpf_func_state *state = func(env, reg); int err, min_off, max_off, i, j, slot, spi; if (reg->type != ...
0
[]
linux
294f2fc6da27620a506e6c050241655459ccd6bd
263,552,207,612,001,050,000,000,000,000,000,000,000
124
bpf: Verifer, adjust_scalar_min_max_vals to always call update_reg_bounds() Currently, for all op verification we call __red_deduce_bounds() and __red_bound_offset() but we only call __update_reg_bounds() in bitwise ops. However, we could benefit from calling __update_reg_bounds() in BPF_ADD, BPF_SUB, and BPF_MUL case...
static byte edecrypt(byte cipher) { byte plain; if (t1_pfa) { while (cipher == 10 || cipher == 13) cipher = t1_getbyte(); last_hexbyte = cipher = (hexval(cipher) << 4) + hexval(t1_getbyte()); } plain = (cipher ^ (t1_dr >> 8)); t1_dr = (cipher + t1_dr) * t1_c1 + t1_c2; ...
0
[ "CWE-119" ]
texlive-source
6ed0077520e2b0da1fd060c7f88db7b2e6068e4c
218,832,768,780,785,540,000,000,000,000,000,000,000
12
writet1 protection against buffer overflow git-svn-id: svn://tug.org/texlive/trunk/Build/source@48697 c570f23f-e606-0410-a88d-b1316a301751
TfLiteStatus SparseToDenseImpl(TfLiteContext* context, TfLiteNode* node) { const TfLiteTensor* indices = GetInput(context, node, kIndicesTensor); const TfLiteTensor* output_shape = GetInput(context, node, kOutputShapeTensor); const TfLiteTensor* values = GetInput(context, node, kValueInputTensor); const T...
1
[ "CWE-125", "CWE-787" ]
tensorflow
1970c2158b1ffa416d159d03c3370b9a462aee35
298,217,429,151,866,120,000,000,000,000,000,000,000
27
[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 const SSL_METHOD *ssl3_get_client_method(int ver) { if (ver == SSL3_VERSION) return(SSLv3_client_method()); else return(NULL); }
0
[]
openssl
ee2ffc279417f15fef3b1073c7dc81a908991516
226,605,490,084,549,230,000,000,000,000,000,000,000
7
Add Next Protocol Negotiation.
void unix_notinflight(struct file *fp) { struct sock *s = unix_get_socket(fp); if(s) { atomic_dec(&unix_sk(s)->inflight); atomic_dec(&unix_tot_inflight); } }
1
[]
linux-2.6
1fd05ba5a2f2aa8e7b9b52ef55df850e2e7d54c9
282,904,169,275,275,830,000,000,000,000,000,000,000
8
[AF_UNIX]: Rewrite garbage collector, fixes race. Throw out the old mark & sweep garbage collector and put in a refcounting cycle detecting one. The old one had a race with recvmsg, that resulted in false positives and hence data loss. The old algorithm operated on all unix sockets in the system, so any additional l...
static char *tty_devnode(struct device *dev, umode_t *mode) { if (!mode) return NULL; if (dev->devt == MKDEV(TTYAUX_MAJOR, 0) || dev->devt == MKDEV(TTYAUX_MAJOR, 2)) *mode = 0666; return NULL; }
0
[ "CWE-200", "CWE-362" ]
linux
5c17c861a357e9458001f021a7afa7aab9937439
202,035,551,491,473,270,000,000,000,000,000,000,000
9
tty: Fix unsafe ldisc reference via ioctl(TIOCGETD) ioctl(TIOCGETD) retrieves the line discipline id directly from the ldisc because the line discipline id (c_line) in termios is untrustworthy; userspace may have set termios via ioctl(TCSETS*) without actually changing the line discipline via ioctl(TIOCSETD). However...
static void dp8393x_do_start_timer(dp8393xState *s) { s->regs[SONIC_CR] &= ~SONIC_CR_STP; dp8393x_set_next_tick(s); }
0
[]
qemu
915976bd98a9286efe6f2e573cb4f1360603adf9
103,720,219,779,454,740,000,000,000,000,000,000,000
5
hw/net/dp8393x: fix integer underflow in dp8393x_do_transmit_packets() An integer underflow could occur during packet transmission due to 'tx_len' not being updated if SONIC_TFC register is set to zero. Check for negative 'tx_len' when removing existing FCS. RHBZ: https://bugzilla.redhat.com/show_bug.cgi?id=1899722 S...
inline void set(int offset, T ch) { buffer_[offset] = ch; }
0
[]
envoy
3b5acb2f43548862dadb243de7cf3994986a8e04
223,986,166,662,965,340,000,000,000,000,000,000,000
1
http, url: Bring back chromium_url and http_parser_parse_url (#198) * Revert GURL as HTTP URL parser utility This reverts: 1. commit c9c4709c844b90b9bb2935d784a428d667c9df7d 2. commit d828958b591a6d79f4b5fa608ece9962b7afbe32 3. commit 2d69e30c51f2418faf267aaa6c1126fce9948c62 Signed-off-by: Dhi Aurrahman <dio@tetrat...
bool SSL_METHOD::failNoCert() const { return failNoCert_; }
0
[ "CWE-254" ]
mysql-server
e7061f7e5a96c66cb2e0bf46bec7f6ff35801a69
265,795,348,965,060,280,000,000,000,000,000,000,000
4
Bug #22738607: YASSL FUNCTION X509_NAME_GET_INDEX_BY_NID IS NOT WORKING AS EXPECTED.
static void ext4_ext_show_move(struct inode *inode, struct ext4_ext_path *path, ext4_fsblk_t newblock, int level) { int depth = ext_depth(inode); struct ext4_extent *ex; if (depth != level) { struct ext4_extent_idx *idx; idx = path[level].p_idx; while (idx <= EXT_MAX_INDEX(path[level].p_hdr)) { ext_debu...
0
[ "CWE-362" ]
linux-2.6
dee1f973ca341c266229faa5a1a5bb268bed3531
55,857,324,582,909,870,000,000,000,000,000,000,000
31
ext4: race-condition protection for ext4_convert_unwritten_extents_endio We assumed that at the time we call ext4_convert_unwritten_extents_endio() extent in question is fully inside [map.m_lblk, map->m_len] because it was already split during submission. But this may not be true due to a race between writeback vs fa...
static char *pack_bitmap_filename(struct packed_git *p) { size_t len; if (!strip_suffix(p->pack_name, ".pack", &len)) die("BUG: pack_name does not end in .pack"); return xstrfmt("%.*s.bitmap", (int)len, p->pack_name); }
0
[ "CWE-119", "CWE-787" ]
git
de1e67d0703894cb6ea782e36abb63976ab07e60
103,375,596,610,165,560,000,000,000,000,000,000,000
8
list-objects: pass full pathname to callbacks When we find a blob at "a/b/c", we currently pass this to our show_object_fn callbacks as two components: "a/b/" and "c". Callbacks which want the full value then call path_name(), which concatenates the two. But this is an inefficient interface; the path is a strbuf, and ...
int Field_string::do_save_field_metadata(uchar *metadata_ptr) { DBUG_ASSERT(field_length < 1024); DBUG_ASSERT((real_type() & 0xF0) == 0xF0); DBUG_PRINT("debug", ("field_length: %u, real_type: %u", field_length, real_type())); *metadata_ptr= (real_type() ^ ((field_length & 0x300) >> 4)); ...
0
[ "CWE-120" ]
server
eca207c46293bc72dd8d0d5622153fab4d3fccf1
255,448,602,703,247,300,000,000,000,000,000,000,000
10
MDEV-25317 Assertion `scale <= precision' failed in decimal_bin_size And Assertion `scale >= 0 && precision > 0 && scale <= precision' failed in decimal_bin_size_inline/decimal_bin_size. Precision should be kept below DECIMAL_MAX_SCALE for computations. It can be bigger in Item_decimal. I'd fix this too but it changes...
R_API void r_anal_function_delete_all_vars(RAnalFunction *fcn) { r_return_if_fail (fcn); if (fcn->vars.v.len > 0) { void **it; r_pvector_foreach (&fcn->vars, it) { var_free (*it); } } r_pvector_clear (&fcn->vars); }
0
[ "CWE-416" ]
radare2
a7ce29647fcb38386d7439696375e16e093d6acb
110,499,242,677,787,370,000,000,000,000,000,000,000
10
Fix UAF in aaaa on arm/thumb switching ##crash * Reported by @peacock-doris via huntr.dev * Reproducer tests_65185 * This is a logic fix, but not the fully safe as changes in the code can result on UAF again, to properly protect r2 from crashing we need to break the ABI and add refcounting to RRegItem, which can't...
BGD_DECLARE(void) gdImageAABlend (gdImagePtr im) { (void)im; }
0
[ "CWE-20" ]
libgd
1846f48e5fcdde996e7c27a4bbac5d0aef183e4b
284,844,341,503,329,470,000,000,000,000,000,000,000
4
Fix #340: System frozen gdImageCreate() doesn't check for oversized images and as such is prone to DoS vulnerabilities. We fix that by applying the same overflow check that is already in place for gdImageCreateTrueColor(). CVE-2016-9317
cdf_swap_dir(cdf_directory_t *d) { d->d_namelen = CDF_TOLE2(d->d_namelen); d->d_left_child = CDF_TOLE4(CAST(uint32_t, d->d_left_child)); d->d_right_child = CDF_TOLE4(CAST(uint32_t, d->d_right_child)); d->d_storage = CDF_TOLE4(CAST(uint32_t, d->d_storage)); d->d_storage_uuid[0] = CDF_TOLE8(d->d_storage_uuid[0]); d...
0
[ "CWE-787" ]
file
46a8443f76cec4b41ec736eca396984c74664f84
267,598,963,095,433,800,000,000,000,000,000,000,000
15
Limit the number of elements in a vector (found by oss-fuzz)
bool InferenceContext::RelaxOutputHandleShapesAndMergeTypes( int idx, const std::vector<ShapeAndType>& shapes_and_types) { if (output_handle_shapes_and_types_[idx] == nullptr) { output_handle_shapes_and_types_[idx].reset( new std::vector<ShapeAndType>(shapes_and_types)); return true; } return ...
0
[ "CWE-190" ]
tensorflow
acd56b8bcb72b163c834ae4f18469047b001fadf
291,899,901,464,319,340,000,000,000,000,000,000,000
10
Fix security vulnerability with SpaceToBatchNDOp. PiperOrigin-RevId: 445527615
Link_to_iterator(const Decorator& d, ES_iterator it, Mark m) : D(d), _e(), _v(), _it(it), _m(m) {}
0
[ "CWE-269" ]
cgal
618b409b0fbcef7cb536a4134ae3a424ef5aae45
91,666,605,743,347,200,000,000,000,000,000,000,000
2
Fix Nef_2 and Nef_S2 IO
void write(const char* key, const char* str, bool quote) { char buf[CV_FS_MAX_LEN*4+16]; char* data = (char*)str; int i, len; if( !str ) CV_Error( CV_StsNullPtr, "Null string pointer" ); len = (int)strlen(str); if( len > CV_FS_MAX_LEN ) C...
0
[ "CWE-787" ]
opencv
f42d5399aac80d371b17d689851406669c9b9111
273,567,064,537,009,330,000,000,000,000,000,000,000
43
core(persistence): add more checks for implementation limitations
isoent_free_all(struct isoent *isoent) { struct isoent *np, *np_temp; if (isoent == NULL) return; np = isoent; for (;;) { if (np->dir) { if (np->children.first != NULL) { /* Enter to sub directories. */ np = np->children.first; continue; } } for (;;) { np_temp = np; if (np->chnext =...
0
[ "CWE-190" ]
libarchive
3014e19820ea53c15c90f9d447ca3e668a0b76c6
36,678,687,126,156,014,000,000,000,000,000,000,000
31
Issue 711: Be more careful about verifying filename lengths when writing ISO9660 archives * Don't cast size_t to int, since this can lead to overflow on machines where sizeof(int) < sizeof(size_t) * Check a + b > limit by writing it as a > limit || b > limit || a + b > limit to avoid problems when a + b wraps...
void AuthorizationSession::startRequest(OperationContext* opCtx) { _externalState->startRequest(opCtx); _refreshUserInfoAsNeeded(opCtx); }
0
[ "CWE-613" ]
mongo
db19e7ce84cfd702a4ba9983ee2ea5019f470f82
262,270,057,415,795,740,000,000,000,000,000,000,000
4
SERVER-38984 Validate unique User ID on UserCache hit (cherry picked from commit e55d6e2292e5dbe2f97153251d8193d1cc89f5d7)
static inline unsigned long paravirt_store_tr(void) { return PVOP_CALL0(unsigned long, cpu.store_tr); }
0
[ "CWE-276" ]
linux
cadfad870154e14f745ec845708bc17d166065f2
328,447,944,508,654,800,000,000,000,000,000,000,000
4
x86/ioperm: Fix io bitmap invalidation on Xen PV tss_invalidate_io_bitmap() wasn't wired up properly through the pvop machinery, so the TSS and Xen's io bitmap would get out of sync whenever disabling a valid io bitmap. Add a new pvop for tss_invalidate_io_bitmap() to fix it. This is XSA-329. Fixes: 22fe5b0439dd ("...
static void kvm_free_vcpus(struct kvm *kvm) { unsigned long i; struct kvm_vcpu *vcpu; /* * Unpin any mmu pages first. */ kvm_for_each_vcpu(i, vcpu, kvm) { kvm_clear_async_pf_completion_queue(vcpu); kvm_unload_vcpu_mmu(vcpu); } kvm_destroy_vcpus(kvm); }
0
[ "CWE-476" ]
linux
55749769fe608fa3f4a075e42e89d237c8e37637
97,599,081,146,928,160,000,000,000,000,000,000,000
15
KVM: x86: Fix wall clock writes in Xen shared_info not to mark page dirty When dirty ring logging is enabled, any dirty logging without an active vCPU context will cause a kernel oops. But we've already declared that the shared_info page doesn't get dirty tracking anyway, since it would be kind of insane to mark it di...
static int async_polkit_callback(sd_bus_message *reply, void *userdata, sd_bus_error *error) { _cleanup_(sd_bus_error_free) sd_bus_error error_buffer = SD_BUS_ERROR_NULL; AsyncPolkitQuery *q = userdata; int r; assert(reply); assert(q); q->slot = sd_bus_slot_unref(q->slo...
1
[ "CWE-416" ]
systemd
637486261528e8aa3da9f26a4487dc254f4b7abb
242,633,636,333,358,830,000,000,000,000,000,000,000
25
polkit: when authorizing via PK let's re-resolve callback/userdata instead of caching it Previously, when doing an async PK query we'd store the original callback/userdata pair and call it again after the PK request is complete. This is problematic, since PK queries might be slow and in the meantime the userdata might...
S_regcppop(pTHX_ regexp *rex, U32 *maxopenparen_p) { UV i; U32 paren; GET_RE_DEBUG_FLAGS_DECL; PERL_ARGS_ASSERT_REGCPPOP; /* Pop REGCP_OTHER_ELEMS before the parentheses loop starts. */ i = SSPOPUV; assert((i & SAVE_MASK) == SAVEt_REGCONTEXT); /* Check that the magic cookie is there. */ ...
0
[ "CWE-416" ]
perl5
22b433eff9a1ffa2454e18405a56650f07b385b5
177,493,486,901,837,800,000,000,000,000,000,000,000
66
PATCH [perl #123562] Regexp-matching "hangs" The regex engine got into an infinite loop because of the malformation. It is trying to back-up over a sequence of UTF-8 continuation bytes. But the character just before the sequence should be a start byte. If not, there is a malformation. I added a test to croak if that...
R_API RConfigNode* r_config_node_clone(RConfigNode *n) { RConfigNode *cn = R_NEW0 (RConfigNode); if (!cn) { return NULL; } cn->name = strdup (n->name); cn->desc = n->desc? strdup (n->desc): NULL; cn->value = strdup (n->value? n->value: ""); cn->i_value = n->i_value; cn->flags = n->flags; cn->setter = n->sett...
0
[ "CWE-416" ]
radare2
f85bc674b2a2256a364fe796351bc1971e106005
168,535,156,690,877,120,000,000,000,000,000,000,000
14
Fix #7698 - UAF in r_config_set when loading a dex
int ssl_cert_set_cert_store(CERT *c, X509_STORE *store, int chain, int ref) { X509_STORE **pstore; if (chain) pstore = &c->chain_store; else pstore = &c->verify_store; X509_STORE_free(*pstore); *pstore = store; if (ref && store) X509_STORE_up_ref(store); return 1; }
0
[ "CWE-835" ]
openssl
758754966791c537ea95241438454aa86f91f256
281,774,532,187,969,900,000,000,000,000,000,000,000
13
Fix invalid handling of verify errors in libssl In the event that X509_verify() returned an internal error result then libssl would mishandle this and set rwstate to SSL_RETRY_VERIFY. This subsequently causes SSL_get_error() to return SSL_ERROR_WANT_RETRY_VERIFY. That return code is supposed to only ever be returned i...
TEST_F(QueryPlannerTest, AndHashRequiresKeepMutations) { params.options = QueryPlannerParams::KEEP_MUTATIONS; params.options |= QueryPlannerParams::INDEX_INTERSECTION; addIndex(BSON("a" << 1)); addIndex(BSON("b" << 1)); runQuery(fromjson("{a: {$gte: 0}, b: {$gte: 0}}")); assertNumSolutions(3U)...
0
[]
mongo
64095239f41e9f3841d8be9088347db56d35c891
201,750,723,870,327,360,000,000,000,000,000,000,000
16
SERVER-51083 Reject invalid UTF-8 from $regex match expressions
static size_t __iovec_copy_from_user_inatomic(char *vaddr, const struct iovec *iov, size_t base, size_t bytes) { size_t copied = 0, left = 0; while (bytes) { char __user *buf = iov->iov_base + base; int copy = min(bytes, iov->iov_len - base); base = 0; left = __copy_from_user_inatomic_nocache(vaddr, buf,...
0
[ "CWE-193" ]
linux-2.6
94ad374a0751f40d25e22e036c37f7263569d24c
225,642,014,433,974,750,000,000,000,000,000,000,000
21
Fix off-by-one error in iov_iter_advance() The iov_iter_advance() function would look at the iov->iov_len entry even though it might have iterated over the whole array, and iov was pointing past the end. This would cause DEBUG_PAGEALLOC to trigger a kernel page fault if the allocation was at the end of a page, and th...
int EncodeObjectId(const word16* in, word32 inSz, byte* out, word32* outSz) { int i, x, len; word32 d, t; /* check args */ if (in == NULL || outSz == NULL) { return BAD_FUNC_ARG; } /* compute length of encoded OID */ d = (in[0] * 40) + in[1]; len = 0; for (i = 1; i < (int)i...
0
[ "CWE-125", "CWE-345" ]
wolfssl
f93083be72a3b3d956b52a7ec13f307a27b6e093
72,986,962,351,611,670,000,000,000,000,000,000,000
73
OCSP: improve handling of OCSP no check extension
void ModMatchExpression::serialize(BSONObjBuilder* out) const { out->append(path(), BSON("$mod" << BSON_ARRAY(_divisor << _remainder))); }
0
[]
mongo
b0ef26c639112b50648a02d969298650fbd402a4
239,970,948,575,745,600,000,000,000,000,000,000,000
3
SERVER-51083 Reject invalid UTF-8 from $regex match expressions
static int irda_open_tsap(struct irda_sock *self, __u8 tsap_sel, char *name) { notify_t notify; if (self->tsap) { IRDA_WARNING("%s: busy!\n", __func__); return -EBUSY; } /* Initialize callbacks to be used by the IrDA stack */ irda_notify_init(&notify); notify.connect_confirm = irda_connect_confirm; n...
0
[ "CWE-200" ]
linux-2.6
09384dfc76e526c3993c09c42e016372dc9dd22c
151,399,063,179,959,880,000,000,000,000,000,000,000
32
irda: Fix irda_getname() leak irda_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>
static int unit_ref_uid_internal( Unit *u, uid_t *ref_uid, uid_t uid, bool clean_ipc, int (*_manager_ref_uid)(Manager *m, uid_t uid, bool clean_ipc)) { int r; assert(u); assert(ref_uid); assert(uid_is_valid...
0
[ "CWE-269" ]
systemd
bf65b7e0c9fc215897b676ab9a7c9d1c688143ba
234,799,132,442,282,000,000,000,000,000,000,000,000
37
core: imply NNP and SUID/SGID restriction for DynamicUser=yes service Let's be safe, rather than sorry. This way DynamicUser=yes services can neither take benefit of, nor create SUID/SGID binaries. Given that DynamicUser= is a recent addition only we should be able to get away with turning this on, even though this i...
static void Run(const Tensor& in_x, const Tensor& in_y, bool lower, bool adjoint, const MatMulBCast& bcast, Tensor* out, int start, int limit) { const bool should_bcast = bcast.IsBroadcastingRequired(); const auto& x_batch_indices = bcast.x_batch_indices(); const auto& ...
0
[ "CWE-703", "CWE-197" ]
tensorflow
ca8c013b5e97b1373b3bb1c97ea655e69f31a575
266,483,617,509,961,800,000,000,000,000,000,000,000
99
Prevent integer truncation from 64 to 32 bits. The `tensorflow::Shard` functions last argument must be a 2 argument function where both arguments are `int64` (`long long`, 64 bits). However, there are usages where code passes in a function where arguments are `int` or `int32` (32 bits). In these cases, it is possible ...
kadm5_chpass_principal_3(void *server_handle, krb5_principal principal, krb5_boolean keepold, int n_ks_tuple, krb5_key_salt_tuple *ks_tuple, char *password) { krb5_int32 now; kadm5_policy_ent_rec pol; osa_prin...
0
[ "CWE-703" ]
krb5
c5be6209311d4a8f10fda37d0d3f876c1b33b77b
258,690,910,526,127,400,000,000,000,000,000,000,000
197
Null pointer deref in kadmind [CVE-2012-1013] The fix for #6626 could cause kadmind to dereference a null pointer if a create-principal request contains no password but does contain the KRB5_KDB_DISALLOW_ALL_TIX flag (e.g. "addprinc -randkey -allow_tix name"). Only clients authorized to create principals can trigger ...