func
string
target
int64
cwe
list
project
string
commit_id
string
hash
float64
size
int64
message
string
static int ext4_journalled_write_end(struct file *file, struct address_space *mapping, loff_t pos, unsigned len, unsigned copied, struct page *page, void *fsdata) { handle_t *handle = ext4_journal_current_handle(); struct inode *inode = mapping->host; int ret = 0, ret2; int partial = 0; ...
0
[ "CWE-703" ]
linux
744692dc059845b2a3022119871846e74d4f6e11
273,589,646,016,787,370,000,000,000,000,000,000,000
62
ext4: use ext4_get_block_write in buffer write Allocate uninitialized extent before ext4 buffer write and convert the extent to initialized after io completes. The purpose is to make sure an extent can only be marked initialized after it has been written with new data so we can safely drop the i_mutex lock in ext4 DIO...
png_XYZ_from_xy(png_XYZ *XYZ, const png_xy *xy) { png_fixed_point red_inverse, green_inverse, blue_scale; png_fixed_point left, right, denominator; /* Check xy and, implicitly, z. Note that wide gamut color spaces typically * have end points with 0 tristimulus values (these are impossible end * point...
0
[ "CWE-476" ]
libpng
812768d7a9c973452222d454634496b25ed415eb
56,895,605,861,949,400,000,000,000,000,000,000,000
264
[libpng16] Fixed a potential null pointer dereference in png_set_text_2() (bug report and patch by Patrick Keshishian).
int tm_subscribe( tm_task_id tid, /* in */ char *name, /* in */ void *info, /* out */ int len, /* in */ int *info_len,/* out */ tm_event_t *event) /* out */ { int rc = TM_SUCCESS; task_info *tp; struct tcp_chan *chan = NULL; ...
0
[ "CWE-264" ]
torque
f2f4c950f3d461a249111c8826da3beaafccace9
134,226,000,732,724,550,000,000,000,000,000,000,000
74
TRQ-2885 - limit tm_adopt() to only adopt a session id that is owned by the calling user.
static int prepare_vmcs02(struct kvm_vcpu *vcpu, struct vmcs12 *vmcs12, bool from_vmentry, u32 *entry_failure_code) { struct vcpu_vmx *vmx = to_vmx(vcpu); u32 exec_control, vmcs12_exec_ctrl; vmcs_write16(GUEST_ES_SELECTOR, vmcs12->guest_es_selector); vmcs_write16(GUEST_CS_SELECTOR, vmcs12->guest_cs_selector);...
1
[ "CWE-284" ]
linux
51aa68e7d57e3217192d88ce90fd5b8ef29ec94f
206,765,141,647,073,200,000,000,000,000,000,000,000
350
kvm: nVMX: Don't allow L2 to access the hardware CR8 If L1 does not specify the "use TPR shadow" VM-execution control in vmcs12, then L0 must specify the "CR8-load exiting" and "CR8-store exiting" VM-execution controls in vmcs02. Failure to do so will give the L2 VM unrestricted read/write access to the hardware CR8. ...
nl80211_parse_mcast_rate(struct cfg80211_registered_device *rdev, int mcast_rate[NUM_NL80211_BANDS], int rateval) { struct wiphy *wiphy = &rdev->wiphy; bool found = false; int band, i; for (band = 0; band < NUM_NL80211_BANDS; band++) { struct ieee80211_supported_band *sband; sband = wiphy->bands[band]...
0
[ "CWE-120" ]
linux
f88eb7c0d002a67ef31aeb7850b42ff69abc46dc
71,617,484,936,991,250,000,000,000,000,000,000,000
26
nl80211: validate beacon head We currently don't validate the beacon head, i.e. the header, fixed part and elements that are to go in front of the TIM element. This means that the variable elements there can be malformed, e.g. have a length exceeding the buffer size, but most downstream code from this assumes that thi...
static int megasas_mgmt_compat_ioctl_fw(struct file *file, unsigned long arg) { struct compat_megasas_iocpacket __user *cioc = (struct compat_megasas_iocpacket __user *)arg; struct megasas_iocpacket __user *ioc = compat_alloc_user_space(sizeof(struct megasas_iocpacket)); int i; int error = 0; compat_uptr...
0
[ "CWE-476" ]
linux
bcf3b67d16a4c8ffae0aa79de5853435e683945c
9,754,229,120,966,229,000,000,000,000,000,000,000
64
scsi: megaraid_sas: return error when create DMA pool failed when create DMA pool for cmd frames failed, we should return -ENOMEM, instead of 0. In some case in: megasas_init_adapter_fusion() -->megasas_alloc_cmds() -->megasas_create_frame_pool create DMA pool failed, --> megasas_fre...
write_ready (GObject *source_object, GAsyncResult *result, gpointer user_data) { GOutputStream *stream; GVfsJob *job; GError *error; gssize nwrote; stream = G_OUTPUT_STREAM (source_object); error = NULL; job = G_VFS_JOB (user_data); nwrote ...
0
[]
gvfs
f81ff2108ab3b6e370f20dcadd8708d23f499184
131,126,087,140,049,780,000,000,000,000,000,000,000
29
dav: don't unescape the uri twice path_equal tries to unescape path before comparing. Unfortunately this function is used also for already unescaped paths. Therefore unescaping can fail. This commit reverts changes which was done in commit 50af53d and unescape just uris, which aren't unescaped yet. https://bugzilla.g...
/* {{{ Helper functions */ static char* guess_timezone(const timelib_tzdb *tzdb TSRMLS_DC) { /* Checking configure timezone */ if (DATEG(timezone) && (strlen(DATEG(timezone))) > 0) { return DATEG(timezone); } /* Check config setting for default timezone */ if (!DATEG(default_timezone)) { /* Special case: ext/d...
0
[]
php-src
c377f1a715476934133f3254d1e0d4bf3743e2d2
14,808,005,759,405,166,000,000,000,000,000,000,000
32
Fix bug #68942 (Use after free vulnerability in unserialize() with DateTimeZone)
static int cma_query_ib_route(struct rdma_id_private *id_priv, unsigned long timeout_ms, struct cma_work *work) { struct rdma_dev_addr *dev_addr = &id_priv->id.route.addr.dev_addr; struct sa_path_rec path_rec; ib_sa_comp_mask comp_mask; struct sockaddr_in6 *sin6; struct sockaddr_ib *sib; memset(&path_re...
0
[ "CWE-416" ]
linux
bc0bdc5afaa740d782fbf936aaeebd65e5c2921d
6,209,568,025,718,696,000,000,000,000,000,000,000
52
RDMA/cma: Do not change route.addr.src_addr.ss_family If the state is not idle then rdma_bind_addr() will immediately fail and no change to global state should happen. For instance if the state is already RDMA_CM_LISTEN then this will corrupt the src_addr and would cause the test in cma_cancel_operation(): if (cma...
static int io_copy_iov(struct io_ring_ctx *ctx, struct iovec *dst, void __user *arg, unsigned index) { struct iovec __user *src; #ifdef CONFIG_COMPAT if (ctx->compat) { struct compat_iovec __user *ciovs; struct compat_iovec ciov; ciovs = (struct compat_iovec __user *) arg; if (copy_from_user(&ciov...
0
[ "CWE-667" ]
linux
3ebba796fa251d042be42b929a2d916ee5c34a49
120,568,275,532,603,980,000,000,000,000,000,000,000
24
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...
static void handle_child_exit(int sig) { pid_t pid; int status; time_t uptime; while ((pid = waitpid(-1, &status, WNOHANG)) > 0) { FFServerStream *feed; for (feed = config.first_feed; feed; feed = feed->next) { if (feed->pid != pid) continue; up...
0
[ "CWE-119", "CWE-787" ]
FFmpeg
a5d25faa3f4b18dac737fdb35d0dd68eb0dc2156
206,408,663,488,292,300,000,000,000,000,000,000,000
28
ffserver: Check chunk size Fixes out of array access Fixes: poc_ffserver.py Found-by: Paul Cher <paulcher@icloud.com> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Callback() : called(false) { }
0
[ "CWE-125" ]
qpdf
1868a10f8b06631362618bfc85ca8646da4b4b71
212,241,205,420,389,860,000,000,000,000,000,000,000
4
Replace all atoi calls with QUtil::string_to_int The latter catches underflow/overflow.
_client_protocol_timeout (GsmXSMPClient *client) { g_debug ("GsmXSMPClient: client_protocol_timeout for client '%s' in ICE status %d", client->priv->description, IceConnectionStatus (client->priv->ice_connection)); gsm_client_set_status (GSM_CLIENT (client), GSM_CLIENT...
1
[ "CWE-125", "CWE-835" ]
gnome-session
b0dc999e0b45355314616321dbb6cb71e729fc9d
153,354,473,676,955,930,000,000,000,000,000,000,000
11
[gsm] Delay the creation of the GsmXSMPClient until it really exists We used to create the GsmXSMPClient before the XSMP connection is really accepted. This can lead to some issues, though. An example is: https://bugzilla.gnome.org/show_bug.cgi?id=598211#c19. Quoting: "What is happening is that a new client (probabl...
void mark_join_nest_as_const(JOIN *join, TABLE_LIST *join_nest, table_map *found_const_table_map, uint *const_count) { List_iterator<TABLE_LIST> it(join_nest->nested_join->join_list); TABLE_LIST *tbl; while ((tbl= it++)) { ...
0
[]
server
ff77a09bda884fe6bf3917eb29b9d3a2f53f919b
149,941,698,127,139,960,000,000,000,000,000,000,000
29
MDEV-22464 Server crash on UPDATE with nested subquery Uninitialized ref_pointer_array[] because setup_fields() got empty fields list. mysql_multi_update() for some reason does that by substituting the fields list with empty total_list for the mysql_select() call (looks like wrong merge since total_list is not used a...
new_size(size) int size; { int i; #if 0 for (i=3; i<31; i++) { if ((1<<i) > size) return 1<<i; } return -1; #else int newsize; for (i = 0, newsize = MINSIZE; i < (int )(sizeof(primes)/sizeof(primes[0])); i++, newsize <<= 1) { if (newsize > size) return primes[i]; } /* Ran...
0
[ "CWE-125" ]
oniguruma
65a9b1aa03c9bc2dc01b074295b9603232cb3b78
177,641,576,768,571,680,000,000,000,000,000,000,000
23
onig-5.9.2
d_lite_tuesday_p(VALUE self) { get_d1(self); return f_boolcast(m_wday(dat) == 2); }
0
[]
date
3959accef8da5c128f8a8e2fd54e932a4fb253b0
239,961,435,607,628,250,000,000,000,000,000,000,000
5
Add length limit option for methods that parses date strings `Date.parse` now raises an ArgumentError when a given date string is longer than 128. You can configure the limit by giving `limit` keyword arguments like `Date.parse(str, limit: 1000)`. If you pass `limit: nil`, the limit is disabled. Not only `Date.parse`...
gst_h264_parse_subset_sps (GstH264NalUnit * nalu, GstH264SPS * sps) { NalReader nr; GST_DEBUG ("parsing Subset SPS"); nal_reader_init (&nr, nalu->data + nalu->offset + nalu->header_bytes, nalu->size - nalu->header_bytes); if (!gst_h264_parse_sps_data (&nr, sps)) goto error; if (sps->profile_idc ...
0
[ "CWE-787" ]
gst-plugins-bad
11353b3f6e2f047cc37483d21e6a37ae558896bc
134,943,159,225,602,010,000,000,000,000,000,000,000
27
codecparsers: h264parser: guard against ref_pic_markings overflow Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1703>
int luaRedisDebugCommand(lua_State *lua) { if (!ldb.active) return 0; int argc = lua_gettop(lua); sds log = sdscatprintf(sdsempty(),"<debug> line %d: ", ldb.currentline); while(argc--) { log = ldbCatStackValue(log,lua,-1 - argc); if (argc != 0) log = sdscatlen(log,", ",2); } ldbL...
0
[ "CWE-703", "CWE-125" ]
redis
6ac3c0b7abd35f37201ed2d6298ecef4ea1ae1dd
302,296,378,973,608,700,000,000,000,000,000,000,000
11
Fix protocol parsing on 'ldbReplParseCommand' (CVE-2021-32672) The protocol parsing on 'ldbReplParseCommand' (LUA debugging) Assumed protocol correctness. This means that if the following is given: *1 $100 test The parser will try to read additional 94 unallocated bytes after the client buffer. This commit fixes this ...
void quota_data_sub(quota_ctx_t qctx, struct ext2_inode_large *inode, ext2_ino_t ino EXT2FS_ATTR((unused)), qsize_t space) { struct dquot *dq; dict_t *dict; enum quota_type qtype; if (!qctx) return; log_debug("SUB_DATA: Inode: %u, UID/GID: %u/%u, space: %ld", ino, inode_uid(*inode), inode_gi...
0
[ "CWE-787" ]
e2fsprogs
8dbe7b475ec5e91ed767239f0e85880f416fc384
328,209,106,196,048,860,000,000,000,000,000,000,000
24
libsupport: add checks to prevent buffer overrun bugs in quota code A maliciously corrupted file systems can trigger buffer overruns in the quota code used by e2fsck. To fix this, add sanity checks to the quota header fields as well as to block number references in the quota tree. Addresses: CVE-2019-5094 Addresses:...
GF_Err trep_Write(GF_Box *s, GF_BitStream *bs) { GF_Err e; GF_TrackExtensionPropertiesBox *ptr = (GF_TrackExtensionPropertiesBox *) s; if (!s) return GF_BAD_PARAM; e = gf_isom_full_box_write(s, bs); if (e) return e; gf_bs_write_u32(bs, ptr->trackID); return GF_OK;
0
[ "CWE-400", "CWE-401" ]
gpac
d2371b4b204f0a3c0af51ad4e9b491144dd1225c
19,042,830,160,797,355,000,000,000,000,000,000,000
11
prevent dref memleak on invalid input (#1183)
static void close_all_connections(struct Curl_multi *multi) { struct connectdata *conn; conn = Curl_conncache_find_first_connection(&multi->conn_cache); while(conn) { SIGPIPE_VARIABLE(pipe_st); conn->data = multi->closure_handle; sigpipe_ignore(conn->data, &pipe_st); /* This will remove the conn...
1
[ "CWE-416" ]
curl
75dc096e01ef1e21b6c57690d99371dedb2c0b80
78,993,674,516,772,700,000,000,000,000,000,000,000
17
curl_multi_cleanup: clear connection pointer for easy handles CVE-2016-5421 Bug: https://curl.haxx.se/docs/adv_20160803C.html Reported-by: Marcelo Echeverria and Fernando Muñoz
void Http2Session::Consume(Local<External> external) { StreamBase* stream = static_cast<StreamBase*>(external->Value()); stream->PushStreamListener(this); Debug(this, "i/o stream consumed"); }
0
[ "CWE-416" ]
node
7f178663ebffc82c9f8a5a1b6bf2da0c263a30ed
96,496,268,397,298,120,000,000,000,000,000,000,000
5
src: use unique_ptr for WriteWrap This commit attempts to avoid a use-after-free error by using unqiue_ptr and passing a reference to it. CVE-ID: CVE-2020-8265 Fixes: https://github.com/nodejs-private/node-private/issues/227 PR-URL: https://github.com/nodejs-private/node-private/pull/238 Reviewed-By: Michael Dawson <...
bool is_native_function_with_warn(THD *thd, const LEX_CSTRING *name) { if (!is_native_function(thd, name)) return false; /* This warning will be printed when [1] A client query is parsed, [2] A stored function is loaded by db_load_routine. Printing the warning for [2] is intentional, to cover th...
0
[ "CWE-703" ]
server
39feab3cd31b5414aa9b428eaba915c251ac34a2
219,921,746,181,577,720,000,000,000,000,000,000,000
38
MDEV-26412 Server crash in Item_field::fix_outer_field for INSERT SELECT IF an INSERT/REPLACE SELECT statement contained an ON expression in the top level select and this expression used a subquery with a column reference that could not be resolved then an attempt to resolve this reference as an outer reference caused...
void task_clear_jobctl_pending(struct task_struct *task, unsigned int mask) { BUG_ON(mask & ~JOBCTL_PENDING_MASK); if (mask & JOBCTL_STOP_PENDING) mask |= JOBCTL_STOP_CONSUME | JOBCTL_STOP_DEQUEUED; task->jobctl &= ~mask; if (!(task->jobctl & JOBCTL_PENDING_MASK)) task_clear_jobctl_trapping(task); }
0
[ "CWE-399" ]
linux
b9e146d8eb3b9ecae5086d373b50fa0c1f3e7f0f
328,348,292,526,080,020,000,000,000,000,000,000,000
12
kernel/signal.c: stop info leak via the tkill and the tgkill syscalls This fixes a kernel memory contents leak via the tkill and tgkill syscalls for compat processes. This is visible in the siginfo_t->_sifields._rt.si_sigval.sival_ptr field when handling signals delivered from tkill. The place of the infoleak: int ...
static void exif_iif_add_value(image_info_type *image_info, int section_index, char *name, int tag, int format, int length, void* value, size_t value_len, int motorola_intel) { size_t idex; void *vptr, *vptr_end; image_info_value *info_value; image_info_data *info_data; image_info_data *list; if (length < 0) {...
0
[ "CWE-125" ]
php-src
d348cfb96f2543565691010ade5e0346338be5a7
327,366,969,290,074,800,000,000,000,000,000,000,000
140
Fixed bug #78910
int rdp_recv_data_pdu(rdpRdp* rdp, STREAM* s) { BYTE type; UINT16 length; UINT32 share_id; BYTE compressed_type; UINT16 compressed_len; UINT32 roff; UINT32 rlen; STREAM* comp_stream; if (!rdp_read_share_data_header(s, &length, &type, &share_id, &compressed_type, &compressed_len)) return -1; comp_stream = ...
0
[ "CWE-476" ]
FreeRDP
7d58aac24fe20ffaad7bd9b40c9ddf457c1b06e7
265,984,923,647,481,700,000,000,000,000,000,000,000
146
security: add a NULL pointer check to fix a server crash.
ram_addr_t qemu_ram_addr_from_host(struct uc_struct *uc, void *ptr) { RAMBlock *block; ram_addr_t offset; block = qemu_ram_block_from_host(uc, ptr, false, &offset); if (!block) { return RAM_ADDR_INVALID; } return block->offset + offset; }
0
[ "CWE-476" ]
unicorn
3d3deac5e6d38602b689c4fef5dac004f07a2e63
47,015,815,398,843,960,000,000,000,000,000,000,000
12
Fix crash when mapping a big memory and calling uc_close
const char *xstrerror(int errnum, char *buf, size_t len) { #ifdef HAVE_STRERROR_R # ifdef __USE_GNU /* Annoying linux specific API contract */ return strerror_r(errnum, buf, len); # else strerror_r(errnum, buf, len); return buf; # endif #else int n = snprintf(buf, len, "errno=%d", errnum); retur...
0
[]
augeas
1a66739c3fc14b3257af5d4a32d0a2a714a7b39d
25,107,373,414,991,010,000,000,000,000,000,000,000
15
* src/transform.c (xread_file): catch failed fopen, e.g. EACCES
ly_set_clean(struct ly_set *set) { if (!set) { return EXIT_FAILURE; } set->number = 0; return EXIT_SUCCESS; }
0
[ "CWE-119" ]
libyang
32fb4993bc8bb49e93e84016af3c10ea53964be5
87,220,101,626,120,980,000,000,000,000,000,000,000
9
schema tree BUGFIX do not check features while still resolving schema Fixes #723
void lodepng_decompress_settings_init(LodePNGDecompressSettings* settings) { settings->ignore_adler32 = 0; settings->custom_zlib = 0; settings->custom_inflate = 0; settings->custom_context = 0; }
0
[ "CWE-401" ]
FreeRDP
9fee4ae076b1ec97b97efb79ece08d1dab4df29a
294,776,199,448,099,660,000,000,000,000,000,000,000
8
Fixed #5645: realloc return handling
static int php_openssl_is_private_key(EVP_PKEY* pkey TSRMLS_DC) { assert(pkey != NULL); switch (pkey->type) { #ifndef NO_RSA case EVP_PKEY_RSA: case EVP_PKEY_RSA2: assert(pkey->pkey.rsa != NULL); if (pkey->pkey.rsa != NULL && (NULL == pkey->pkey.rsa->p || NULL == pkey->pkey.rsa->q)) { return 0; } ...
0
[ "CWE-20" ]
php-src
2874696a5a8d46639d261571f915c493cd875897
178,408,477,562,278,600,000,000,000,000,000,000,000
42
Fix CVE-2013-4073 - handling of certs with null bytes
static void hardware_disable(void) { if (vmm_exclusive) { vmclear_local_loaded_vmcss(); kvm_cpu_vmxoff(); } write_cr4(read_cr4() & ~X86_CR4_VMXE); }
0
[]
kvm
a642fc305053cc1c6e47e4f4df327895747ab485
225,889,832,097,625,900,000,000,000,000,000,000,000
8
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 ...
static int is_seq(unsigned char * seq, unsigned int *seq_size, unsigned int *seq_len) { int i,j,k; if (seq[0] != 0x30) return 0; /* not a sequence */ if (seq[1] & 0x80) { i = seq[1] & 0x7f; if (i > 2 || i == 0) return 0; /* cert would be bigger then 65k or zero */ if (seq[2] == 0) return 0; /* DE...
0
[ "CWE-787" ]
OpenSC
ed55fcd2996930bf58b9bb57e9ba7b1f3a753c43
56,321,586,864,031,110,000,000,000,000,000,000,000
27
fixed invalid read fixes https://oss-fuzz.com/testcase-detail/5765246676631552
static bool radeon_atom_apply_quirks(struct drm_device *dev, uint32_t supported_device, int *connector_type, struct radeon_i2c_bus_rec *i2c_bus, uint16_t *line_mux, struct radeon_hpd *hpd) { /* Asus M2A-VM HDMI board lists the DVI port as HDMI */ if ((dev->pdev->device ==...
0
[ "CWE-119", "CWE-193" ]
linux
0031c41be5c529f8329e327b63cde92ba1284842
224,379,371,368,958,400,000,000,000,000,000,000,000
120
drivers/gpu/drm/radeon/radeon_atombios.c: range check issues This change makes the array larger, "MAX_SUPPORTED_TV_TIMING_V1_2" is 3 and the original size "MAX_SUPPORTED_TV_TIMING" is 2. Also there were checks that were off by one. Signed-off-by: Dan Carpenter <error27@gmail.com> Acked-by: Alex Deucher <alexdeucher@...
static int ahash_save_req(struct ahash_request *req, crypto_completion_t cplt) { struct crypto_ahash *tfm = crypto_ahash_reqtfm(req); unsigned long alignmask = crypto_ahash_alignmask(tfm); unsigned int ds = crypto_ahash_digestsize(tfm); struct ahash_request_priv *priv; priv = kmalloc(sizeof(*priv) + ahash_align_b...
0
[ "CWE-835" ]
linux
ef0579b64e93188710d48667cb5e014926af9f1b
206,702,961,922,652,080,000,000,000,000,000,000,000
56
crypto: ahash - Fix EINPROGRESS notification callback The ahash API modifies the request's callback function in order to clean up after itself in some corner cases (unaligned final and missing finup). When the request is complete ahash will restore the original callback and everything is fine. However, when the requ...
int addattr16(struct nlmsghdr *n, int maxlen, int type, __u16 data) { return addattr_l(n, maxlen, type, &data, sizeof(__u16)); }
0
[]
iproute2
8c50b728b226f6254251282697ce38a72639a6fc
273,778,130,126,465,460,000,000,000,000,000,000,000
4
libnetlink: fix use-after-free of message buf In __rtnl_talk_iov() main loop, err is a pointer to memory in dynamically allocated 'buf' that is used to store netlink messages. If netlink message is an error message, buf is deallocated before returning with error code. However, on return err->error code is checked one ...
int mbedtls_ssl_set_client_transport_id( mbedtls_ssl_context *ssl, const unsigned char *info, size_t ilen ) { if( ssl->conf->endpoint != MBEDTLS_SSL_IS_SERVER ) return( MBEDTLS_ERR_SSL_BAD_INPUT_DATA ); mbedtls_free( ssl->cli_id ); ...
0
[ "CWE-20", "CWE-190" ]
mbedtls
83c9f495ffe70c7dd280b41fdfd4881485a3bc28
74,954,998,770,573,880,000,000,000,000,000,000,000
17
Prevent bounds check bypass through overflow in PSK identity parsing The check `if( *p + n > end )` in `ssl_parse_client_psk_identity` is unsafe because `*p + n` might overflow, thus bypassing the check. As `n` is a user-specified value up to 65K, this is relevant if the library happens to be located in the last 65K o...
static int conf__attempt_resolve(const char *host, const char *text, int log, const char *msg) { struct addrinfo gai_hints; struct addrinfo *gai_res; int rc; memset(&gai_hints, 0, sizeof(struct addrinfo)); gai_hints.ai_family = AF_UNSPEC; gai_hints.ai_socktype = SOCK_STREAM; gai_res = NULL; rc = getaddrinfo(ho...
0
[ "CWE-200", "CWE-732", "CWE-254" ]
mosquitto
9097577b49b7fdcf45d30975976dd93808ccc0c4
70,133,727,328,027,750,000,000,000,000,000,000,000
34
Fix acl_file being ignore for default listener if with per_listener_settings Close #1073. Thanks to Jef Driesen. Bug: https://github.com/eclipse/mosquitto/issues/1073
nfs_readdir_page_unlock_and_put_cached(struct nfs_readdir_descriptor *desc) { unlock_page(desc->page); nfs_readdir_page_put(desc); }
0
[ "CWE-909" ]
linux
ac795161c93699d600db16c1a8cc23a65a1eceaf
161,598,882,127,007,540,000,000,000,000,000,000,000
5
NFSv4: Handle case where the lookup of a directory fails If the application sets the O_DIRECTORY flag, and tries to open a regular file, nfs_atomic_open() will punt to doing a regular lookup. If the server then returns a regular file, we will happily return a file descriptor with uninitialised open state. The fix is ...
QString OpenConnectionTask::debugIdentification() const { if (parser) return QString::fromUtf8("OpenConnectionTask: %1").arg(Imap::connectionStateToString(model->accessParser(parser).connState)); else return QLatin1String("OpenConnectionTask: no parser"); }
0
[ "CWE-200" ]
trojita
25fffa3e25cbad85bbca804193ad336b090a9ce1
69,495,561,535,955,410,000,000,000,000,000,000,000
7
IMAP: refuse to work when STARTTLS is required but server sends PREAUTH Oops, we cannot send STARTTLS when the connection is already authenticated. This is serious enough to warrant an error; an attacker might be going after a plaintext of a message we're going to APPEND, etc. Thanks to Arnt Gulbrandsen on the imap-p...
is_string_valid_atr(const char *atr_str) { unsigned char atr[SC_MAX_ATR_SIZE]; size_t atr_len = sizeof(atr); if (sc_hex_to_bin(atr_str, atr, &atr_len)) return 0; if (atr_len < 2) return 0; if (atr[0] != 0x3B && atr[0] != 0x3F) return 0; return 1; }
0
[ "CWE-415", "CWE-119" ]
OpenSC
360e95d45ac4123255a4c796db96337f332160ad
240,270,836,700,753,820,000,000,000,000,000,000,000
13
fixed out of bounds writes Thanks to Eric Sesterhenn from X41 D-SEC GmbH for reporting the problems.
void formats_deinit(void) { signal_remove("setup changed", (SIGNAL_FUNC) read_settings); }
0
[ "CWE-476" ]
irssi
6c6c42e3d1b49d90aacc0b67f8540471cae02a1d
269,476,763,412,949,220,000,000,000,000,000,000,000
4
Merge branch 'security' into 'master' See merge request !7
void init_locator() const { const_cast<Self*>(this)->ptr()->init_locator(); }
0
[ "CWE-269" ]
cgal
618b409b0fbcef7cb536a4134ae3a424ef5aae45
306,995,604,860,826,930,000,000,000,000,000,000,000
2
Fix Nef_2 and Nef_S2 IO
static int add_keyword_int(File fptr, const char *keyword, longlong num) { int err= add_string(fptr, keyword); err+= add_space(fptr); err+= add_equal(fptr); err+= add_space(fptr); err+= add_int(fptr, num); return err + add_space(fptr); }
0
[]
mysql-server
be901b60ae59c93848c829d1b0b2cb523ab8692e
128,206,645,592,943,130,000,000,000,000,000,000,000
10
Bug#26390632: CREATE TABLE CAN CAUSE MYSQL TO EXIT. Analysis ======== CREATE TABLE of InnoDB table with a partition name which exceeds the path limit can cause the server to exit. During the preparation of the partition name, there was no check to identify whether the complete path name for partition exceeds the max ...
pcsc_error_string (long err) { const char *s; if (!err) return "okay"; if ((err & 0x80100000) != 0x80100000) return "invalid PC/SC error code"; err &= 0xffff; switch (err) { case 0x0002: s = "cancelled"; break; case 0x000e: s = "can't dispose"; break; case 0x0008: s = "insufficient bu...
0
[ "CWE-20" ]
gnupg
2183683bd633818dd031b090b5530951de76f392
260,152,196,969,771,950,000,000,000,000,000,000,000
51
Use inline functions to convert buffer data to scalars. * common/host2net.h (buf16_to_ulong, buf16_to_uint): New. (buf16_to_ushort, buf16_to_u16): New. (buf32_to_size_t, buf32_to_ulong, buf32_to_uint, buf32_to_u32): New. -- Commit 91b826a38880fd8a989318585eb502582636ddd8 was not enough to avoid all sign extension on ...
static gboolean connect_server(GCancellable* cancellable) { int fd, rc; struct sockaddr_un addr; int retries = 0; G_LOCK(connect); if(server_fd != -1 || (cancellable && g_cancellable_is_cancelled(cancellable))) { G_UNLOCK(connect); return TRUE; } retry: fd = socket(PF_U...
0
[ "CWE-20" ]
menu-cache
56f66684592abf257c4004e6e1fff041c64a12ce
115,873,281,170,020,950,000,000,000,000,000,000,000
61
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 void virtio_gpu_handle_cursor_cb(VirtIODevice *vdev, VirtQueue *vq) { VirtIOGPU *g = VIRTIO_GPU(vdev); qemu_bh_schedule(g->cursor_bh); }
0
[]
qemu
acfc4846508a02cc4c83aa27799fd74ac280bdb2
116,653,529,855,689,500,000,000,000,000,000,000,000
5
virtio-gpu: use VIRTIO_GPU_MAX_SCANOUTS The value is defined in virtio_gpu.h already (changing from 4 to 16). Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com> Message-id: 1463653560-26958-6-git-send-email-marcandre.lureau@redhat.com Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
PHP_FUNCTION(getenv) { char *ptr, *str; int str_len; zend_bool local_only = 0; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|b", &str, &str_len, &local_only) == FAILURE) { RETURN_FALSE; } if (!local_only) { /* SAPI method returns an emalloc()'d string */ ptr = sapi_getenv(str, str_len TSRMLS_CC)...
0
[ "CWE-601" ]
php-src
98b9dfaec95e6f910f125ed172cdbd25abd006ec
188,061,463,565,677,830,000,000,000,000,000,000,000
56
Fix for HTTP_PROXY issue. The following changes are made: - _SERVER/_ENV only has HTTP_PROXY if the local environment has it, and only one from the environment. - getenv('HTTP_PROXY') only returns one from the local environment - getenv has optional second parameter, telling it to only consider local environment
void CLASS ppm16_thumb() { int i; char *thumb; thumb_length = thumb_width*thumb_height*3; thumb = (char *) calloc (thumb_length,2); merror (thumb, "ppm16_thumb()"); read_shorts ((ushort *) thumb, thumb_length); for (i=0; i < thumb_length; i++) thumb[i] = ((ushort *) thumb)[i] >> 8; fprintf (ofp, "P6...
0
[ "CWE-703" ]
LibRaw
11909cc59e712e09b508dda729b99aeaac2b29ad
272,372,598,355,352,940,000,000,000,000,000,000,000
14
cumulated data checks patch
unsigned long long encoding_scope() const { return encoding_scope_; }
0
[ "CWE-20" ]
libvpx
f00890eecdf8365ea125ac16769a83aa6b68792d
250,978,716,649,458,270,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
static int fdb_vid_parse(struct nlattr *vlan_attr, u16 *p_vid) { u16 vid = 0; if (vlan_attr) { if (nla_len(vlan_attr) != sizeof(u16)) { pr_info("PF_BRIDGE: RTM_NEWNEIGH with invalid vlan\n"); return -EINVAL; } vid = nla_get_u16(vlan_attr); if (!vid || vid >= VLAN_VID_MASK) { pr_info("PF_BRIDGE: RT...
0
[ "CWE-200" ]
net
5f8e44741f9f216e33736ea4ec65ca9ac03036e6
241,564,330,989,878,800,000,000,000,000,000,000,000
21
net: fix infoleak in rtnetlink The stack object “map” has a total size of 32 bytes. Its last 4 bytes are padding generated by compiler. These padding bytes are not initialized and sent out via “nla_put”. Signed-off-by: Kangjie Lu <kjlu@gatech.edu> Signed-off-by: David S. Miller <davem@davemloft.net>
psutil_disk_partitions(PyObject *self, PyObject *args) { FILE *file; struct mnttab mt; PyObject *py_dev = NULL; PyObject *py_mountp = NULL; PyObject *py_tuple = NULL; PyObject *py_retlist = PyList_New(0); if (py_retlist == NULL) return NULL; file = fopen(MNTTAB, "rb"); if (...
1
[ "CWE-415" ]
psutil
7d512c8e4442a896d56505be3e78f1156f443465
46,316,339,490,906,970,000,000,000,000,000,000,000
50
Use Py_CLEAR instead of Py_DECREF to also set the variable to NULL (#1616) These files contain loops that convert system data into python objects and during the process they create objects and dereference their refcounts after they have been added to the resulting list. However, in case of errors during the creat...
static void mmtimer_setup_int_2(int cpu, u64 expires) { u64 val; HUB_S((u64 *)LOCAL_MMR_ADDR(SH_RTC3_INT_ENABLE), 0UL); HUB_S((u64 *)LOCAL_MMR_ADDR(SH_INT_CMPD), -1L); mmtimer_clr_int_pending(2); val = ((u64)SGI_MMTIMER_VECTOR << SH_RTC3_INT_CONFIG_IDX_SHFT) | ((u64)cpu_physical_id(cpu) << SH_RTC3_INT_CON...
0
[ "CWE-189" ]
linux
f8bd2258e2d520dff28c855658bd24bdafb5102d
47,074,893,615,351,180,000,000,000,000,000,000,000
20
remove div_long_long_rem x86 is the only arch right now, which provides an optimized for div_long_long_rem and it has the downside that one has to be very careful that the divide doesn't overflow. The API is a little akward, as the arguments for the unsigned divide are signed. The signed version also doesn't handle ...
int proc_dointvec_ms_jiffies(struct ctl_table *table, int write, void __user *buffer, size_t *lenp, loff_t *ppos) { return -ENOSYS; }
0
[ "CWE-284", "CWE-264" ]
linux
bfdc0b497faa82a0ba2f9dddcf109231dd519fcc
294,764,836,735,925,550,000,000,000,000,000,000,000
5
sysctl: restrict write access to dmesg_restrict When dmesg_restrict is set to 1 CAP_SYS_ADMIN is needed to read the kernel ring buffer. But a root user without CAP_SYS_ADMIN is able to reset dmesg_restrict to 0. This is an issue when e.g. LXC (Linux Containers) are used and complete user space is running without CA...
static MagickBooleanType LoadLocaleCache(SplayTreeInfo *cache,const char *xml, const char *filename,const char *locale,const size_t depth,ExceptionInfo *exception) { char keyword[MagickLocaleExtent], message[MagickLocaleExtent], tag[MagickLocaleExtent], *token; const char *q; FatalErrorHan...
0
[ "CWE-125" ]
ImageMagick
07eebcd72f45c8fd7563d3f9ec5d2bed48f65f36
278,605,427,609,568,700,000,000,000,000,000,000,000
228
...
dissect_kafka_create_topics_request_replica_assignment(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, int offset, kafka_api_version_t api_version) { proto_item *subti; proto_tree *subtree; kafka_partition_t partition; subtree = proto_tree_add...
0
[ "CWE-401" ]
wireshark
f4374967bbf9c12746b8ec3cd54dddada9dd353e
325,845,319,791,221,070,000,000,000,000,000,000,000
28
Kafka: Limit our decompression size. Don't assume that the Internet has our best interests at heart when it gives us the size of our decompression buffer. Assign an arbitrary limit of 50 MB. This fixes #16739 in that it takes care of ** (process:17681): WARNING **: 20:03:07.440: Dissector bug, protocol Kafka, in pac...
static char *ga_get_win_name(OSVERSIONINFOEXW const *os_version, bool id) { DWORD major = os_version->dwMajorVersion; DWORD minor = os_version->dwMinorVersion; int tbl_idx = (os_version->wProductType != VER_NT_WORKSTATION); ga_matrix_lookup_t const *table = WIN_VERSION_MATRIX[tbl_idx]; while (table-...
0
[ "CWE-190" ]
qemu
141b197408ab398c4f474ac1a728ab316e921f2b
92,678,947,270,391,290,000,000,000,000,000,000,000
20
qga: check bytes count read by guest-file-read While reading file content via 'guest-file-read' command, 'qmp_guest_file_read' routine allocates buffer of count+1 bytes. It could overflow for large values of 'count'. Add check to avoid it. Reported-by: Fakhri Zulkifli <mohdfakhrizulkifli@gmail.com> Signed-off-by: Pra...
readconf_one_rewrite(uschar *p, int *existflags, BOOL isglobal) { rewrite_rule *next = store_get(sizeof(rewrite_rule)); next->next = NULL; next->key = string_dequote(&p); while (isspace(*p)) p++; if (*p == 0) log_write(0, LOG_PANIC_DIE|LOG_CONFIG_IN, "missing rewrite replacement string"); next->flags = 0; next...
0
[ "CWE-264" ]
exim
e2f5dc151e2e79058e93924e6d35510557f0535d
330,319,252,440,961,000,000,000,000,000,000,000,000
61
Check configure file permissions even for non-default files if still privileged (Bug 1044, CVE-2010-4345)
String *Item_direct_ref::val_str(String* tmp) { tmp=(*ref)->val_str(tmp); null_value=(*ref)->null_value; return tmp; }
0
[]
server
b000e169562697aa072600695d4f0c0412f94f4f
302,018,307,168,272,200,000,000,000,000,000,000,000
6
Bug#26361149 MYSQL SERVER CRASHES AT: COL IN(IFNULL(CONST, COL), NAME_CONST('NAME', NULL)) based on: commit f7316aa0c9a Author: Ajo Robert <ajo.robert@oracle.com> Date: Thu Aug 24 17:03:21 2017 +0530 Bug#26361149 MYSQL SERVER CRASHES AT: COL IN(IFNULL(CONST, COL), NAME_CONST('NAME'...
static inline int htx_is_not_empty(const struct htx *htx) { return (htx->head != -1); }
0
[ "CWE-190" ]
haproxy
3b69886f7dcc3cfb3d166309018e6cfec9ce2c95
10,173,634,795,031,913,000,000,000,000,000,000,000
4
BUG/MAJOR: htx: fix missing header name length check in htx_add_header/trailer Ori Hollander of JFrog Security reported that htx_add_header() and htx_add_trailer() were missing a length check on the header name. While this does not allow to overwrite any memory area, it results in bits of the header name length to sli...
static void queue_request(struct fuse_conn *fc, struct fuse_req *req) { req->in.h.len = sizeof(struct fuse_in_header) + len_args(req->in.numargs, (struct fuse_arg *) req->in.args); list_add_tail(&req->list, &fc->pending); req->state = FUSE_REQ_PENDING; if (!req->waiting) { req->waiting = 1; atomic_inc(&fc->nu...
0
[ "CWE-120", "CWE-119", "CWE-787" ]
linux
c2183d1e9b3f313dd8ba2b1b0197c8d9fb86a7ae
334,554,107,032,080,600,000,000,000,000,000,000,000
13
fuse: check size of FUSE_NOTIFY_INVAL_ENTRY message FUSE_NOTIFY_INVAL_ENTRY didn't check the length of the write so the message processing could overrun and result in a "kernel BUG at fs/fuse/dev.c:629!" Reported-by: Han-Wen Nienhuys <hanwenn@gmail.com> Signed-off-by: Miklos Szeredi <mszeredi@suse.cz> CC: stable@kern...
bool JOIN::get_best_combination() { uint tablenr; table_map used_tables; JOIN_TAB *j; KEYUSE *keyuse; DBUG_ENTER("get_best_combination"); /* Additional plan nodes for postjoin tmp tables: 1? + // For GROUP BY 1? + // For DISTINCT 1? + // For aggregation functions aggregated in outer ...
0
[]
server
ff77a09bda884fe6bf3917eb29b9d3a2f53f919b
221,901,518,885,302,400,000,000,000,000,000,000,000
177
MDEV-22464 Server crash on UPDATE with nested subquery Uninitialized ref_pointer_array[] because setup_fields() got empty fields list. mysql_multi_update() for some reason does that by substituting the fields list with empty total_list for the mysql_select() call (looks like wrong merge since total_list is not used a...
ComputeSelect(XtermWidget xw, CELL *startc, CELL *endc, Bool extend, Bool normal) { TScreen *screen = TScreenOf(xw); int cclass; CELL first = *startc; CELL last = *endc; Boolean ignored = False; struct { LineData *startSel; LineData *endSel; } ld; LineData...
0
[ "CWE-399" ]
xterm-snapshots
82ba55b8f994ab30ff561a347b82ea340ba7075c
175,918,735,595,342,130,000,000,000,000,000,000,000
205
snapshot of project "xterm", label xterm-365d
gst_h264_sps_mvc_clear (GstH264SPS * sps) { GstH264SPSExtMVC *const mvc = &sps->extension.mvc; guint i, j; g_assert (sps->extension_type == GST_H264_NAL_EXTENSION_MVC); g_free (mvc->view); mvc->view = NULL; for (i = 0; i <= mvc->num_level_values_signalled_minus1; i++) { GstH264SPSExtMVCLevelValue *co...
0
[ "CWE-787" ]
gst-plugins-bad
11353b3f6e2f047cc37483d21e6a37ae558896bc
63,517,739,107,794,090,000,000,000,000,000,000,000
27
codecparsers: h264parser: guard against ref_pic_markings overflow Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1703>
partial_unref(partial_T *pt) { if (pt != NULL) { int done = FALSE; if (--pt->pt_refcount <= 0) partial_free(pt); // If the reference count goes down to one, the funcstack may be the // only reference and can be freed if no other partials reference it. else if (pt->pt_refcount == 1) { // carefu...
0
[ "CWE-476" ]
vim
69082916c8b5d321545d60b9f5facad0a2dd5a4e
13,564,958,888,203,167,000,000,000,000,000,000,000
30
patch 9.0.0552: crash when using NUL in buffer that uses :source Problem: Crash when using NUL in buffer that uses :source. Solution: Don't get a next line when skipping over NL.
njs_generate_cond_expression_false(njs_vm_t *vm, njs_generator_t *generator, njs_parser_node_t *node) { njs_int_t ret; njs_parser_node_t *branch; njs_vmcode_move_t *move; branch = node->right; if (node->index != branch->right->index) { njs_generate_code_move(generator, move,...
0
[ "CWE-703", "CWE-754" ]
njs
404553896792b8f5f429dc8852d15784a59d8d3e
21,232,365,540,250,340,000,000,000,000,000,000,000
24
Fixed break instruction in a try-catch block. Previously, JUMP offset for a break instruction inside a try-catch block was not set to a correct offset during code generation when a return instruction was present in inner try-catch block. The fix is to update the JUMP offset appropriately. This closes #553 issue on G...
void CleanWriters(GF_List *writers) { while (gf_list_count(writers)) { TrackWriter *writer = (TrackWriter*)gf_list_get(writers, 0); gf_isom_box_del(writer->stco); gf_isom_box_del((GF_Box *)writer->stsc); gf_free(writer); gf_list_rem(writers, 0); } }
1
[ "CWE-416" ]
gpac
5aba27604d957e960d8069d85ccaf868f8a7b07a
165,424,775,529,354,580,000,000,000,000,000,000,000
10
fixed #1661
best_effort_strncat_to_utf16(struct archive_string *as16, const void *_p, size_t length, struct archive_string_conv *sc, int bigendian) { const char *s = (const char *)_p; char *utf16; size_t remaining; int ret; (void)sc; /* UNUSED */ /* * Other case, we should do the best effort. * If all character are ...
0
[ "CWE-476" ]
libarchive
42a3408ac7df1e69bea9ea12b72e14f59f7400c0
280,977,731,924,775,030,000,000,000,000,000,000,000
40
archive_strncat_l(): allocate and do not convert if length == 0 This ensures e.g. that archive_mstring_copy_mbs_len_l() does not set aes_set = AES_SET_MBS with aes_mbs.s == NULL. Resolves possible null-pointer dereference reported by OSS-Fuzz. Reported-By: OSS-Fuzz issue 286
GvnBasicBlockState(GvnBasicBlockState* previous, HBasicBlock* block, HValueMap* map, HSideEffectMap* dominators, Zone* zone) : previous_(previous), next_(NULL) { Initialize(block, map, dominators, true, zone); }
0
[]
node
fd80a31e0697d6317ce8c2d289575399f4e06d21
286,446,651,217,796,830,000,000,000,000,000,000,000
8
deps: backport 5f836c from v8 upstream Original commit message: Fix Hydrogen bounds check elimination When combining bounds checks, they must all be moved before the first load/store that they are guarding. BUG=chromium:344186 LOG=y R=svenpanne@chromium.org Review URL: https://coderevie...
has_schema_privilege_id_id(PG_FUNCTION_ARGS) { Oid roleid = PG_GETARG_OID(0); Oid schemaoid = PG_GETARG_OID(1); text *priv_type_text = PG_GETARG_TEXT_P(2); AclMode mode; AclResult aclresult; mode = convert_schema_priv_string(priv_type_text); if (!SearchSysCacheExists1(NAMESPACEOID, ObjectIdGetDatum(sch...
0
[ "CWE-264" ]
postgres
fea164a72a7bfd50d77ba5fb418d357f8f2bb7d0
14,806,783,212,633,170,000,000,000,000,000,000,000
17
Shore up ADMIN OPTION restrictions. Granting a role without ADMIN OPTION is supposed to prevent the grantee from adding or removing members from the granted role. Issuing SET ROLE before the GRANT bypassed that, because the role itself had an implicit right to add or remove members. Plug that hole by recognizing tha...
void L2EvalFloat(TfLiteContext* context, TfLiteNode* node, TfLitePoolParams* params, OpData* data, const TfLiteTensor* input, TfLiteTensor* output) { float activation_min, activation_max; CalculateActivationRange(params->activation, &activation_min, &acti...
0
[ "CWE-703", "CWE-835" ]
tensorflow
dfa22b348b70bb89d6d6ec0ff53973bacb4f4695
51,769,860,942,751,310,000,000,000,000,000,000,000
25
Prevent a division by 0 in average ops. PiperOrigin-RevId: 385184660 Change-Id: I7affd4554f9b336fca29ac68f633232c094d0bd3
static void vmx_set_nmi_mask(struct kvm_vcpu *vcpu, bool masked) { struct vcpu_vmx *vmx = to_vmx(vcpu); if (!cpu_has_virtual_nmis()) { if (vmx->soft_vnmi_blocked != masked) { vmx->soft_vnmi_blocked = masked; vmx->vnmi_blocked_time = 0; } } else { if (masked) vmcs_set_bits(GUEST_INTERRUPTIBILITY_INFO,...
0
[ "CWE-400" ]
linux-2.6
9581d442b9058d3699b4be568b6e5eae38a41493
192,895,730,787,249,930,000,000,000,000,000,000,000
18
KVM: Fix fs/gs reload oops with invalid ldt kvm reloads the host's fs and gs blindly, however the underlying segment descriptors may be invalid due to the user modifying the ldt after loading them. Fix by using the safe accessors (loadsegment() and load_gs_index()) instead of home grown unsafe versions. This is CVE-...
int fscrypt_fname_disk_to_usr(struct inode *inode, u32 hash, u32 minor_hash, const struct fscrypt_str *iname, struct fscrypt_str *oname) { const struct qstr qname = FSTR_TO_QSTR(iname); char buf[24]; if (fscrypt_is_dot_dotdot(&qname)) { oname->name[0] = '.'; oname->name[iname->len - 1] = '.'; oname->...
0
[ "CWE-416", "CWE-476" ]
linux
1b53cf9815bb4744958d41f3795d5d5a1d365e2d
161,456,229,403,913,800,000,000,000,000,000,000,000
37
fscrypt: remove broken support for detecting keyring key revocation Filesystem encryption ostensibly supported revoking a keyring key that had been used to "unlock" encrypted files, causing those files to become "locked" again. This was, however, buggy for several reasons, the most severe of which was that when key r...
void HttpConnection::sendRequest(std::unique_ptr<HttpRequest> httpRequest) { auto req = httpRequest->createRequest(); sendRequest(std::move(httpRequest), std::move(req)); }
0
[ "CWE-532" ]
aria2
37368130ca7de5491a75fd18a20c5c5cc641824a
175,633,086,420,024,100,000,000,000,000,000,000,000
5
Mask headers
dp_packet_batch_reset_cutlen(struct dp_packet_batch *batch) { if (batch->trunc) { struct dp_packet *packet; DP_PACKET_BATCH_FOR_EACH (packet, batch) { dp_packet_reset_cutlen(packet); } batch->trunc = false; } }
0
[ "CWE-400" ]
ovs
48ceca0446b1c2c2c03e7551048c5b19ed23cc97
198,947,956,066,276,160,000,000,000,000,000,000,000
11
flow: Support extra padding length. Although not required, padding can be optionally added until the packet length is MTU bytes. A packet with extra padding currently fails sanity checks. Vulnerability: CVE-2020-35498 Fixes: fa8d9001a624 ("miniflow_extract: Properly handle small IP packets.") Reported-by: Joakim Hind...
void RGWPutMetadataBucket::execute() { op_ret = get_params(); if (op_ret < 0) { return; } op_ret = rgw_get_request_metadata(s->cct, s->info, attrs, false); if (op_ret < 0) { return; } if (!placement_rule.empty() && placement_rule != s->bucket_info.placement_rule) { op_ret = -EEXIST; ...
0
[ "CWE-770" ]
ceph
ab29bed2fc9f961fe895de1086a8208e21ddaddc
73,461,597,279,955,820,000,000,000,000,000,000,000
74
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 <...
static int __init yam_init_driver(void) { struct net_device *dev; int i, err; char name[IFNAMSIZ]; printk(yam_drvinfo); for (i = 0; i < NR_PORTS; i++) { sprintf(name, "yam%d", i); dev = alloc_netdev(sizeof(struct yam_port), name, yam_setup); if (!dev) { pr_err("yam: cannot allocate net device\...
0
[ "CWE-399" ]
linux
8e3fbf870481eb53b2d3a322d1fc395ad8b367ed
45,269,921,285,310,395,000,000,000,000,000,000,000
41
hamradio/yam: fix info leak in ioctl The yam_ioctl() code fails to initialise the cmd field of the struct yamdrv_ioctl_cfg. Add an explicit memset(0) before filling the structure to avoid the 4-byte info leak. Signed-off-by: Salva Peiró <speiro@ai2.upv.es> Signed-off-by: David S. Miller <davem@davemloft.net>
static void rtreeCheckAppendMsg(RtreeCheck *pCheck, const char *zFmt, ...){ va_list ap; va_start(ap, zFmt); if( pCheck->rc==SQLITE_OK && pCheck->nErr<RTREE_CHECK_MAX_ERROR ){ char *z = sqlite3_vmprintf(zFmt, ap); if( z==0 ){ pCheck->rc = SQLITE_NOMEM; }else{ pCheck->zReport = sqlite3_mprin...
0
[ "CWE-125" ]
sqlite
e41fd72acc7a06ce5a6a7d28154db1ffe8ba37a8
187,460,337,156,740,500,000,000,000,000,000,000,000
19
Enhance the rtreenode() function of rtree (used for testing) so that it uses the newer sqlite3_str object for better performance and improved error reporting. FossilOrigin-Name: 90acdbfce9c088582d5165589f7eac462b00062bbfffacdcc786eb9cf3ea5377
static void sca_del_vcpu(struct kvm_vcpu *vcpu) { if (!kvm_s390_use_sca_entries()) return; read_lock(&vcpu->kvm->arch.sca_lock); if (vcpu->kvm->arch.use_esca) { struct esca_block *sca = vcpu->kvm->arch.sca; clear_bit_inv(vcpu->vcpu_id, (unsigned long *) sca->mcn); sca->cpu[vcpu->vcpu_id].sda = 0; } else { ...
0
[ "CWE-416" ]
linux
0774a964ef561b7170d8d1b1bfe6f88002b6d219
150,003,164,932,120,800,000,000,000,000,000,000,000
18
KVM: Fix out of range accesses to memslots Reset the LRU slot if it becomes invalid when deleting a memslot to fix an out-of-bounds/use-after-free access when searching through memslots. Explicitly check for there being no used slots in search_memslots(), and in the caller of s390's approximation variant. Fixes: 369...
d_lite_rshift(VALUE self, VALUE other) { VALUE t, y, nth, rjd2; int m, d, rjd; double sg; get_d1(self); t = f_add3(f_mul(m_real_year(dat), INT2FIX(12)), INT2FIX(m_mon(dat) - 1), other); if (FIXNUM_P(t)) { long it = FIX2LONG(t); y = LONG2NUM(DIV(it, 12)); it = MOD(it, 12); m ...
0
[]
date
3959accef8da5c128f8a8e2fd54e932a4fb253b0
4,759,551,811,077,074,000,000,000,000,000,000,000
37
Add length limit option for methods that parses date strings `Date.parse` now raises an ArgumentError when a given date string is longer than 128. You can configure the limit by giving `limit` keyword arguments like `Date.parse(str, limit: 1000)`. If you pass `limit: nil`, the limit is disabled. Not only `Date.parse`...
static u32 ieee80211_handle_pwr_constr(struct ieee80211_sub_if_data *sdata, struct ieee80211_channel *channel, struct ieee80211_mgmt *mgmt, const u8 *country_ie, u8 country_ie_len, const u8 *pwr_constr_ie, const u8 *cisco_dtpc_ie) { bool has_80211h_pwr = false, ha...
0
[]
linux
79c92ca42b5a3e0ea172ea2ce8df8e125af237da
126,096,686,252,402,810,000,000,000,000,000,000,000
62
mac80211: handle deauthentication/disassociation from TDLS peer When receiving a deauthentication/disassociation frame from a TDLS peer, a station should not disconnect the current AP, but only disable the current TDLS link if it's enabled. Without this change, a TDLS issue can be reproduced by following the steps as...
void sctp_transport_reset(struct sctp_transport *t) { struct sctp_association *asoc = t->asoc; /* RFC 2960 (bis), Section 5.2.4 * All the congestion control parameters (e.g., cwnd, ssthresh) * related to this peer MUST be reset to their initial values * (see Section 6.2.1) */ t->cwnd = min(4*asoc->pathmtu, ...
1
[]
linux
196d67593439b03088913227093e374235596e33
155,432,259,713,019,640,000,000,000,000,000,000,000
32
sctp: Add support to per-association statistics via a new SCTP_GET_ASSOC_STATS call The current SCTP stack is lacking a mechanism to have per association statistics. This is an implementation modeled after OpenSolaris' SCTP_GET_ASSOC_STATS. Userspace part will follow on lksctp if/when there is a general ACK on this. ...
pci_cfgrw(struct vmctx *ctx, int vcpu, int in, int bus, int slot, int func, int coff, int bytes, uint32_t *eax) { struct businfo *bi; struct slotinfo *si; struct pci_vdev *dev; struct pci_vdev_ops *ops; int idx, needcfg; uint64_t addr, bar, mask; bool decode, ignore_reg_unreg = false; bi = pci_businfo[bus];...
1
[ "CWE-617", "CWE-703" ]
acrn-hypervisor
2b3dedfb9ba13f15887f22b935d373f36c9a59fa
12,599,619,082,704,350,000,000,000,000,000,000,000
179
dm: pci: clean up assert() in pci core Tracked-On: #3252 Signed-off-by: Shuo A Liu <shuo.a.liu@intel.com> Reviewed-by: Yonghua Huang <yonghua.huang@intel.com>
init_time (void) { gettime (&initial_time); }
0
[ "CWE-22" ]
patch
685a78b6052f4df6eac6d625a545cfb54a6ac0e1
169,688,459,132,974,080,000,000,000,000,000,000,000
4
Do not let a malicious patch create files above current directory This addresses CVE-2010-4651, reported by Jakub Wilk. https://bugzilla.redhat.com/show_bug.cgi?id=CVE-2010-4651 * src/util.c (strip_leading_slashes): Reject absolute file names and file names containing a component of "..". * tests/bad-filenames: New fi...
DEFINE_TEST(test_read_format_rar5_multiarchive_solid_skip_all) { const char* reffiles[] = { "test_read_format_rar5_multiarchive_solid.part01.rar", "test_read_format_rar5_multiarchive_solid.part02.rar", "test_read_format_rar5_multiarchive_solid.part03.rar", "test_read_format_rar5_multiarchive_solid.part04.rar",...
0
[ "CWE-20", "CWE-125" ]
libarchive
94821008d6eea81e315c5881cdf739202961040a
125,436,249,486,119,300,000,000,000,000,000,000,000
32
RAR5 reader: reject files that declare invalid header flags One of the fields in RAR5's base block structure is the size of the header. Some invalid files declare a 0 header size setting, which can confuse the unpacker. Minimum header size for RAR5 base blocks is 7 bytes (4 bytes for CRC, and 3 bytes for the rest), so...
optional<ARN> ARN::parse(const string& s, bool wildcards) { static const char str_wild[] = "arn:([^:]*):([^:]*):([^:]*):([^:]*):([^:]*)"; static const regex rx_wild(str_wild, sizeof(str_wild) - 1, ECMAScript | optimize); static const char str_no_wild[] = "arn:([^:*]*):([^:*]*):([^:*]*):([^:*]*...
1
[ "CWE-617" ]
ceph
b3118cabb8060a8cc6a01c4e8264cb18e7b1745a
131,706,692,171,212,670,000,000,000,000,000,000,000
42
rgw: Remove assertions in IAM Policy A couple of them could be triggered by user input. Signed-off-by: Adam C. Emerson <aemerson@redhat.com>
sym_content_free (sym_content *sym) { free (sym); }
0
[]
bison
b7aab2dbad43aaf14eebe78d54aafa245a000988
137,852,177,711,955,960,000,000,000,000,000,000,000
4
fix: crash when redefining the EOF token Reported by Agency for Defense Development. https://lists.gnu.org/r/bug-bison/2020-08/msg00008.html On an empty such as %token FOO BAR FOO 0 %% input: %empty we crash because when we find FOO 0, we decrement ntokens (since FOO was discovered...
mlx5_select_tx_function(struct rte_eth_dev *dev) { struct mlx5_priv *priv = dev->data->dev_private; struct mlx5_dev_config *config = &priv->config; uint64_t tx_offloads = dev->data->dev_conf.txmode.offloads; unsigned int diff = 0, olx = 0, i, m; static_assert(MLX5_WQE_SIZE_MAX / MLX5_WSEG_SIZE <= MLX5_DSE...
0
[]
dpdk-stable
ef311075d21b4f68c8ccfc46a00cda7c2a0bf4cc
85,854,683,627,126,250,000,000,000,000,000,000,000
181
net/mlx5: fix Rx queue recovery mechanism The local variables are getting inconsistent in data receiving routines after queue error recovery. Receive queue consumer index is getting wrong, need to reset one to the size of the queue (as RQ was fully replenished in recovery procedure). In MPRQ case, also the local cons...
static int check_capabilities(struct ImapAccountData *adata) { if (imap_exec(adata, "CAPABILITY", IMAP_CMD_NO_FLAGS) != IMAP_EXEC_SUCCESS) { imap_error("check_capabilities", adata->buf); return -1; } if (!((adata->capabilities & IMAP_CAP_IMAP4) || (adata->capabilities & IMAP_CAP_IMAP4REV1))) { mu...
0
[ "CWE-94", "CWE-74" ]
neomutt
fb013ec666759cb8a9e294347c7b4c1f597639cc
309,626,119,943,470,130,000,000,000,000,000,000,000
17
tls: clear data after a starttls acknowledgement After a starttls acknowledgement message, clear the buffers of any incoming data / commands. This will ensure that all future data is handled securely. Co-authored-by: Pietro Cerutti <gahr@gahr.ch>
TEST(IndexBoundsBuilderTest, TranslateEqualityToNonStringWithMockCollator) { CollatorInterfaceMock collator(CollatorInterfaceMock::MockType::kReverseString); auto testIndex = buildSimpleIndexEntry(); testIndex.collator = &collator; BSONObj obj = BSON("a" << 3); auto expr = parseMatchExpression(obj)...
0
[ "CWE-754" ]
mongo
f8f55e1825ee5c7bdb3208fc7c5b54321d172732
137,564,760,509,774,150,000,000,000,000,000,000,000
19
SERVER-44377 generate correct plan for indexed inequalities to null
void *gf_node_get_name_address(GF_Node*node) { NodeIDedItem *reg_node; if (!(node->sgprivate->flags & GF_NODE_IS_DEF)) return NULL; reg_node = node->sgprivate->scenegraph->id_node; while (reg_node) { if (reg_node->node == node) return &reg_node->NodeName; reg_node = reg_node->next; } return NULL; }
0
[ "CWE-416" ]
gpac
9723dd0955894f2cb7be13b94cf7a47f2754b893
193,056,485,104,873,040,000,000,000,000,000,000,000
11
fixed #2109
static struct tree_content *dup_tree_content(struct tree_content *s) { struct tree_content *d; struct tree_entry *a, *b; unsigned int i; if (!s) return NULL; d = new_tree_content(s->entry_count); for (i = 0; i < s->entry_count; i++) { a = s->entries[i]; b = new_tree_entry(); memcpy(b, a, sizeof(*a)); i...
0
[]
git
68061e3470210703cb15594194718d35094afdc0
114,216,343,431,276,850,000,000,000,000,000,000,000
24
fast-import: disallow "feature export-marks" by default The fast-import stream command "feature export-marks=<path>" lets the stream write marks to an arbitrary path. This may be surprising if you are running fast-import against an untrusted input (which otherwise cannot do anything except update Git objects and refs)...
static int unzzip_cat (int argc, char ** argv, int extract) { int done = 0; int argn; ZZIP_DIR* disk; if (argc == 1) { printf (__FILE__" version "ZZIP_PACKAGE" "ZZIP_VERSION"\n"); return EXIT_OK; /* better provide an archive argument */ } disk = zzip_opendir (argv[1...
0
[]
zziplib
931f962ddfec0e00d6f486df2c56d9857b55944e
216,832,220,331,897,300,000,000,000,000,000,000,000
74
fopen may fail for a bad name -> EXIT_ERRORS in that case #17
kdb_send_sig_info(struct task_struct *t, struct siginfo *info) { static struct task_struct *kdb_prev_t; int sig, new_t; if (!spin_trylock(&t->sighand->siglock)) { kdb_printf("Can't do kill command now.\n" "The sigmask lock is held somewhere else in " "kernel, try again later\n"); return; } spin_unl...
0
[]
linux-2.6
da48524eb20662618854bb3df2db01fc65f3070c
250,885,442,275,425,030,000,000,000,000,000,000,000
29
Prevent rt_sigqueueinfo and rt_tgsigqueueinfo from spoofing the signal code Userland should be able to trust the pid and uid of the sender of a signal if the si_code is SI_TKILL. Unfortunately, the kernel has historically allowed sigqueueinfo() to send any si_code at all (as long as it was negative - to distinguish i...
static int ntop_zmq_receive(lua_State* vm) { NetworkInterface *ntop_interface = getCurrentInterface(vm); void *subscriber; int size; struct zmq_msg_hdr h; char *payload; int payload_len; zmq_pollitem_t item; int rc; ntop->getTrace()->traceEvent(TRACE_DEBUG, "%s() called", __FUNCTION__); lua_getglo...
0
[ "CWE-476" ]
ntopng
01f47e04fd7c8d54399c9e465f823f0017069f8f
199,744,213,585,712,200,000,000,000,000,000,000,000
72
Security fix: prevents empty host from being used
zfs_fuid_info_free(zfs_fuid_info_t *fuidp) { zfs_fuid_t *zfuid; zfs_fuid_domain_t *zdomain; while ((zfuid = list_head(&fuidp->z_fuids)) != NULL) { list_remove(&fuidp->z_fuids, zfuid); kmem_free(zfuid, sizeof (zfs_fuid_t)); } if (fuidp->z_domain_table != NULL) kmem_free(fuidp->z_domain_table, (sizeof ...
0
[ "CWE-200", "CWE-732" ]
zfs
716b53d0a14c72bda16c0872565dd1909757e73f
160,255,454,321,147,530,000,000,000,000,000,000,000
21
FreeBSD: Fix UNIX permissions checking Reviewed-by: Ryan Moeller <ryan@iXsystems.com> Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Signed-off-by: Matt Macy <mmacy@FreeBSD.org> Closes #10727
virtual void clear() { null_value= TRUE; value_cached= FALSE; }
0
[]
mysql-server
f7316aa0c9a3909fc7498e7b95d5d3af044a7e21
89,856,674,878,601,070,000,000,000,000,000,000,000
1
Bug#26361149 MYSQL SERVER CRASHES AT: COL IN(IFNULL(CONST, COL), NAME_CONST('NAME', NULL)) Backport of Bug#19143243 fix. NAME_CONST item can return NULL_ITEM type in case of incorrect arguments. NULL_ITEM has special processing in Item_func_in function. In Item_func_in::fix_length_and_dec an a...
static void sony_remove(struct hid_device *hdev) { struct sony_sc *sc = hid_get_drvdata(hdev); hid_hw_close(hdev); if (sc->quirks & DUALSHOCK4_CONTROLLER_BT) device_remove_file(&sc->hdev->dev, &dev_attr_bt_poll_interval); if (sc->fw_version) device_remove_file(&sc->hdev->dev, &dev_attr_firmware_version); i...
0
[ "CWE-787" ]
linux
d9d4b1e46d9543a82c23f6df03f4ad697dab361b
285,208,478,692,999,700,000,000,000,000,000,000,000
23
HID: Fix assumption that devices have inputs The syzbot fuzzer found a slab-out-of-bounds write bug in the hid-gaff driver. The problem is caused by the driver's assumption that the device must have an input report. While this will be true for all normal HID input devices, a suitably malicious device can violate the...
static void on_read(h2o_socket_t *sock, int status) { h2o_http2_conn_t *conn = sock->data; if (status != 0) { h2o_socket_read_stop(conn->sock); close_connection(conn); return; } update_idle_timeout(conn); if (parse_input(conn) != 0) return; /* write immediately...
0
[ "CWE-703" ]
h2o
1c0808d580da09fdec5a9a74ff09e103ea058dd4
92,651,433,123,099,410,000,000,000,000,000,000,000
20
h2: use after free on premature connection close #920 lib/http2/connection.c:on_read() calls parse_input(), which might free `conn`. It does so in particular if the connection preface isn't the expected one in expect_preface(). `conn` is then used after the free in `if (h2o_timeout_is_linked(&conn->_write.timeout_entr...
ar6000_sysfs_bmi_deinit(struct ar6_softc *ar) { AR_DEBUG_PRINTF(ATH_DEBUG_INFO,("BMI: Deleting sysfs entry\n")); sysfs_remove_bin_file(&(((struct device *)ar->osDevInfo.pOSDevice)->kobj), &bmi_attr); }
0
[ "CWE-703", "CWE-264" ]
linux
550fd08c2cebad61c548def135f67aba284c6162
169,340,218,507,241,120,000,000,000,000,000,000,000
6
net: Audit drivers to identify those needing IFF_TX_SKB_SHARING cleared After the last patch, We are left in a state in which only drivers calling ether_setup have IFF_TX_SKB_SHARING set (we assume that drivers touching real hardware call ether_setup for their net_devices and don't hold any state in their skbs. There...