func
string
target
int64
cwe
list
project
string
commit_id
string
hash
float64
size
int64
message
string
int __connman_dnsproxy_set_mdns(int index, bool enabled) { return -ENOTSUP; }
0
[ "CWE-787" ]
connman
e4079a20f617a4b076af503f6e4e8b0304c9f2cb
27,613,479,439,864,800,000,000,000,000,000,000,000
4
dnsproxy: Add length checks to prevent buffer overflow Fixes: CVE-2021-26675
void iov_iter_xarray(struct iov_iter *i, unsigned int direction, struct xarray *xarray, loff_t start, size_t count) { BUG_ON(direction & ~1); *i = (struct iov_iter) { .iter_type = ITER_XARRAY, .data_source = direction, .xarray = xarray, .xarray_start = start, .count = count, .iov_offset = 0 }; }
0
[ "CWE-665", "CWE-284" ]
linux
9d2231c5d74e13b2a0546fee6737ee4446017903
205,260,072,879,571,130,000,000,000,000,000,000,000
13
lib/iov_iter: initialize "flags" in new pipe_buffer The functions copy_page_to_iter_pipe() and push_pipe() can both allocate a new pipe_buffer, but the "flags" member initializer is missing. Fixes: 241699cd72a8 ("new iov_iter flavour: pipe-backed") To: Alexander Viro <viro@zeniv.linux.org.uk> To: linux-fsdevel@vger.k...
port::Status CudnnSupport::DoBatchNormalizationBackwardImpl( Stream* stream, int cudnn_input_type, int cudnn_scale_type, const DeviceMemory<T>& y_backprop, const DeviceMemory<T>& x, const DeviceMemory<U>& scale, const DeviceMemory<U>& mean, const DeviceMemory<U>& inv_var, const dnn::BatchDescriptor& x_d...
0
[ "CWE-20" ]
tensorflow
14755416e364f17fb1870882fa778c7fec7f16e3
164,931,153,465,952,420,000,000,000,000,000,000,000
76
Prevent CHECK-fail in LSTM/GRU with zero-length input. PiperOrigin-RevId: 346239181 Change-Id: I5f233dbc076aab7bb4e31ba24f5abd4eaf99ea4f
static int f2fs_remount(struct super_block *sb, int *flags, char *data) { struct f2fs_sb_info *sbi = F2FS_SB(sb); struct f2fs_mount_info org_mount_opt; int err, active_logs; bool need_restart_gc = false; bool need_stop_gc = false; bool no_extent_cache = !test_opt(sbi, EXTENT_CACHE); sync_filesystem(sb); /* ...
0
[ "CWE-787" ]
linux
9a59b62fd88196844cee5fff851bee2cfd7afb6e
62,824,526,756,533,620,000,000,000,000,000,000,000
88
f2fs: do more integrity verification for superblock Do more sanity check for superblock during ->mount. Signed-off-by: Chao Yu <chao2.yu@samsung.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
fork_exec(char **argv) { pid_t pid; int status; struct sigaction act, old_act; int res = 0; act.sa_handler = SIG_DFL; sigemptyset(&act.sa_mask); act.sa_flags = 0; sigaction(SIGCHLD, &act, &old_act); #ifdef ENABLE_LOG_TO_FILE if (log_file_name) flush_log_file(); #endif pid = local_fork(); if (pid < 0) ...
0
[ "CWE-200" ]
keepalived
26c8d6374db33bcfcdcd758b1282f12ceef4b94f
17,604,105,396,193,423,000,000,000,000,000,000,000
41
Disable fopen_safe() append mode by default If a non privileged user creates /tmp/keepalived.log and has it open for read (e.g. tail -f), then even though keepalived will change the owner to root and remove all read/write permissions from non owners, the application which already has the file open will be able to read...
static bool unit_test_condition(Unit *u) { assert(u); dual_timestamp_get(&u->condition_timestamp); u->condition_result = condition_test_list(u->conditions, condition_type_to_string, log_unit_internal, u); unit_add_to_dbus_queue(u); return u->condition_result; }
0
[ "CWE-269" ]
systemd
bf65b7e0c9fc215897b676ab9a7c9d1c688143ba
11,611,976,258,442,800,000,000,000,000,000,000,000
10
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...
int is_hwpoison_pfn(pfn_t pfn) { return pfn == hwpoison_pfn; }
0
[ "CWE-399" ]
kvm
5b40572ed5f0344b9dbee486a17c589ce1abe1a3
294,823,644,102,835,640,000,000,000,000,000,000,000
4
KVM: Ensure all vcpus are consistent with in-kernel irqchip settings If some vcpus are created before KVM_CREATE_IRQCHIP, then irqchip_in_kernel() and vcpu->arch.apic will be inconsistent, leading to potential NULL pointer dereferences. Fix by: - ensuring that no vcpus are installed when KVM_CREATE_IRQCHIP is called ...
assegment_count_asns (struct assegment *seg, int from) { int count = 0; while (seg) { if (!from) count += seg->length; else { count += (seg->length - from); from = 0; } seg = seg->next; } return count; }
0
[ "CWE-20" ]
quagga
7a42b78be9a4108d98833069a88e6fddb9285008
283,647,108,945,460,930,000,000,000,000,000,000,000
16
bgpd: Fix AS_PATH size calculation for long paths If you have an AS_PATH with more entries than what can be written into a single AS_SEGMENT_MAX it needs to be broken up. The code that noticed that the AS_PATH needs to be broken up was not correctly calculating the size of the resulting message. This patch addresses...
static unsigned int CRC32(const unsigned char *message,const size_t length) { register ssize_t i; static MagickBooleanType crc_initial = MagickFalse; static unsigned int crc_xor[256]; unsigned int crc; /* Generate a 32-bit cyclic redundancy check for the message. */ if (crc_initial...
0
[ "CWE-190", "CWE-189", "CWE-703" ]
ImageMagick
0f6fc2d5bf8f500820c3dbcf0d23ee14f2d9f734
163,394,968,985,219,070,000,000,000,000,000,000,000
42
flatpak_dir_system_helper_call_remove_local_ref (FlatpakDir *self, guint arg_flags, const gchar *arg_remote, const gchar *arg_ref, ...
0
[ "CWE-74" ]
flatpak
fb473cad801c6b61706353256cab32330557374a
76,164,106,347,446,230,000,000,000,000,000,000,000
22
dir: Pass environment via bwrap --setenv when running apply_extra This means we can systematically pass the environment variables through bwrap(1), even if it is setuid and thus is filtering out security-sensitive environment variables. bwrap ends up being run with an empty environment instead. As with the previous c...
static int unix_listen(struct socket *sock, int backlog) { int err; struct sock *sk = sock->sk; struct unix_sock *u = unix_sk(sk); struct pid *old_pid = NULL; const struct cred *old_cred = NULL; err = -EOPNOTSUPP; if (sock->type != SOCK_STREAM && sock->type != SOCK_SEQPACKET) goto out; /* Only stream/seqpacke...
0
[]
linux-2.6
16e5726269611b71c930054ffe9b858c1cea88eb
211,284,881,918,890,200,000,000,000,000,000,000,000
33
af_unix: dont send SCM_CREDENTIALS by default Since commit 7361c36c5224 (af_unix: Allow credentials to work across user and pid namespaces) af_unix performance dropped a lot. This is because we now take a reference on pid and cred in each write(), and release them in read(), usually done from another process, eventua...
static int jp2_find_codestream(Jpeg2000DecoderContext *s) { uint32_t atom_size, atom, atom_end; int search_range = 10; while (search_range && bytestream2_get_bytes_left(&s->g) >= 8) { atom_size = bytestream2_get_be32u(&s->g); atom = bytestream2_get_be32u(&s->g); ...
0
[ "CWE-119", "CWE-787" ]
FFmpeg
9a271a9368eaabf99e6c2046103acb33957e63b7
301,399,380,894,213,970,000,000,000,000,000,000,000
99
jpeg2000: check log2_cblk dimensions Fixes out of array access Fixes Ticket2895 Found-by: Piotr Bandurski <ami_stuff@o2.pl> Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
static unsigned int matchpoint(unsigned int side, unsigned int *x1, unsigned int *y1, unsigned int *avg1, const unsigned int *x2, const unsigned int *y2, const unsigned int *avg2, unsigned int max) { unsigned int i, j, best, match = 0, ksize = side / 4; for(i=0; i<3; i++) { best = 0; for(j=0; j<3; j++) { ...
0
[ "CWE-189" ]
clamav-devel
3cbd8b5668bd0f262a8c00b1fd57eb03c117b00a
19,223,509,460,367,130,000,000,000,000,000,000,000
21
libclamav/pe_icons.c: introduce LOGPARSEICONDETAILS define to reduce parseicon logging in default build
qf_parse_fmt_r(regmatch_T *rmp, int midx, char_u **tail) { if (rmp->startp[midx] == NULL) return QF_FAIL; *tail = rmp->startp[midx]; return QF_OK; }
0
[ "CWE-416" ]
vim
4f1b083be43f351bc107541e7b0c9655a5d2c0bb
183,409,718,475,287,200,000,000,000,000,000,000,000
7
patch 9.0.0322: crash when no errors and 'quickfixtextfunc' is set Problem: Crash when no errors and 'quickfixtextfunc' is set. Solution: Do not handle errors if there aren't any.
allocset(p) register struct parse *p; { register int no = p->g->ncsets++; register size_t nc; register size_t nbytes; register cset *cs; register size_t css = (size_t)p->g->csetsize; register int i; if (no >= p->ncsalloc) { /* need another column of space */ p->ncsalloc += CHAR_BIT; nc = p->ncsalloc; asse...
0
[]
php-src
124fb22a13fafa3648e4e15b4f207c7096d8155e
25,937,093,881,490,336,000,000,000,000,000,000,000
49
Fixed bug #68739 #68740 #68741
void MainWindow::onCaptureStateChanged(bool started) { if (started && (MLT.resource().startsWith("x11grab:") || MLT.resource().startsWith("gdigrab:") || MLT.resource().startsWith("avfoundation")) && !MLT.producer()->get_int(kBackgroundCaptureProperty)) ...
0
[ "CWE-89", "CWE-327", "CWE-295" ]
shotcut
f008adc039642307f6ee3378d378cdb842e52c1d
96,731,112,813,221,800,000,000,000,000,000,000,000
8
fix upgrade check is not using TLS correctly
GF_Err fiin_AddBox(GF_Box *s, GF_Box *a) { FDItemInformationBox *ptr = (FDItemInformationBox *)s; switch(a->type) { case GF_ISOM_BOX_TYPE_PAEN: if (!ptr->partition_entries) ptr->partition_entries = gf_list_new(); return gf_list_add(ptr->partition_entries, a); case GF_ISOM_BOX_TYPE_SEGR: if (ptr->session_info...
0
[ "CWE-400", "CWE-401" ]
gpac
d2371b4b204f0a3c0af51ad4e9b491144dd1225c
106,794,553,785,384,290,000,000,000,000,000,000,000
20
prevent dref memleak on invalid input (#1183)
**/ const CImg<T>& save_graphicsmagick_external(const char *const filename, const unsigned int quality=100) const { if (!filename) throw CImgArgumentException(_cimg_instance "save_graphicsmagick_external(): Specified filename is (null).", ...
0
[ "CWE-125" ]
CImg
10af1e8c1ad2a58a0a3342a856bae63e8f257abb
201,074,855,433,032,400,000,000,000,000,000,000,000
48
Fix other issues in 'CImg<T>::load_bmp()'.
static inline bool guest_cpuid_has_fsgsbase(struct kvm_vcpu *vcpu) { struct kvm_cpuid_entry2 *best; best = kvm_find_cpuid_entry(vcpu, 7, 0); return best && (best->ebx & bit(X86_FEATURE_FSGSBASE)); }
0
[]
linux
6d1068b3a98519247d8ba4ec85cd40ac136dbdf9
195,822,869,986,016,920,000,000,000,000,000,000,000
7
KVM: x86: invalid opcode oops on SET_SREGS with OSXSAVE bit set (CVE-2012-4461) On hosts without the XSAVE support unprivileged local user can trigger oops similar to the one below by setting X86_CR4_OSXSAVE bit in guest cr4 register using KVM_SET_SREGS ioctl and later issuing KVM_RUN ioctl. invalid opcode: 0000 [#2]...
do_sub_msg( int count_only) // used 'n' flag for ":s" { /* * Only report substitutions when: * - more than 'report' substitutions * - command was typed by user, or number of changed lines > 'report' * - giving messages is not disabled by 'lazyredraw' */ if (((sub_nsubs > p_repo...
0
[ "CWE-416" ]
vim
37f47958b8a2a44abc60614271d9537e7f14e51a
216,634,366,675,795,340,000,000,000,000,000,000,000
48
patch 8.2.4253: using freed memory when substitute with function call Problem: Using freed memory when substitute uses a recursive function call. Solution: Make a copy of the substitute text.
mysql_ssl_set(MYSQL *mysql __attribute__((unused)) , const char *key __attribute__((unused)), const char *cert __attribute__((unused)), const char *ca __attribute__((unused)), const char *capath __attribute__((unused)), const char *cipher __attribute__((unused))) { DBUG_ENTER("mysql...
0
[]
server
f5369faf5bbfb56b5e945836eb3f7c7ee88b4079
217,410,717,587,538,130,000,000,000,000,000,000,000
23
don't disable SSL when connecting via libmysqld
static inline void nfsd4_increment_op_stats(u32 opnum) { if (opnum >= FIRST_NFS4_OP && opnum <= LAST_NFS4_OP) nfsdstats.nfs4_opcount[opnum]++; }
0
[ "CWE-20", "CWE-129" ]
linux
b550a32e60a4941994b437a8d662432a486235a5
36,696,089,712,592,990,000,000,000,000,000,000,000
5
nfsd: fix undefined behavior in nfsd4_layout_verify UBSAN: Undefined behaviour in fs/nfsd/nfs4proc.c:1262:34 shift exponent 128 is too large for 32-bit type 'int' Depending on compiler+architecture, this may cause the check for layout_type to succeed for overly large values (which seems to be the case with amd64)...
static inline int compute_score(struct sock *sk, struct net *net, __be32 saddr, unsigned short hnum, __be16 sport, __be32 daddr, __be16 dport, int dif) { int score = -1; if (net_eq(sock_net(sk), net) && udp_sk(sk)->udp_port_hash == hnum && !ipv6_only_sock(sk)) { struct inet_sock *inet = inet_sk(sk); ...
0
[ "CWE-20" ]
net
bceaa90240b6019ed73b49965eac7d167610be69
244,408,050,630,489,550,000,000,000,000,000,000,000
34
inet: prevent leakage of uninitialized memory to user in recv syscalls Only update *addr_len when we actually fill in sockaddr, otherwise we can return uninitialized memory from the stack to the caller in the recvfrom, recvmmsg and recvmsg syscalls. Drop the the (addr_len == NULL) checks because we only get called wit...
int ext4_writepage_trans_blocks(struct inode *inode) { int bpp = ext4_journal_blocks_per_page(inode); int ret; ret = ext4_meta_trans_blocks(inode, bpp, 0); /* Account for data blocks for journalled mode */ if (ext4_should_journal_data(inode)) ret += bpp; return ret; }
0
[ "CWE-399" ]
linux-2.6
06a279d636734da32bb62dd2f7b0ade666f65d7c
111,015,188,839,776,420,000,000,000,000,000,000,000
12
ext4: only use i_size_high for regular files Directories are not allowed to be bigger than 2GB, so don't use i_size_high for anything other than regular files. E2fsck should complain about these inodes, but the simplest thing to do for the kernel is to only use i_size_high for regular files. This prevents an intenti...
peer_unfit( struct peer *peer /* peer structure pointer */ ) { int rval = 0; /* * A stratum error occurs if (1) the server has never been * synchronized, (2) the server stratum is below the floor or * greater than or equal to the ceiling. */ if ( peer->leap == LEAP_NOTINSYNC || peer->stratum < sys_...
0
[ "CWE-287" ]
ntp
71a962710bfe066f76da9679cf4cfdeffe34e95e
332,153,690,555,502,400,000,000,000,000,000,000,000
46
[Sec 2936] Skeleton Key: Any trusted key system can serve time. HStenn.
void setupServiceValidationWithAdditionalHeaders() { std::string yaml = R"EOF( timeout: 1s interval: 1s interval_jitter: 1s unhealthy_threshold: 2 healthy_threshold: 2 http_health_check: service_name_matcher: prefix: locations path: /healthcheck host: "www.envoypr...
0
[ "CWE-476" ]
envoy
9b1c3962172a972bc0359398af6daa3790bb59db
269,060,872,905,398,070,000,000,000,000,000,000,000
120
healthcheck: fix grpc inline removal crashes (#749) Signed-off-by: Matt Klein <mklein@lyft.com> Signed-off-by: Pradeep Rao <pcrao@google.com>
void item_stats_sizes_disable(ADD_STAT add_stats, void *c) { mutex_lock(&stats_sizes_lock); if (stats_sizes_hist != NULL) { free(stats_sizes_hist); stats_sizes_hist = NULL; } APPEND_STAT("sizes_status", "disabled", ""); mutex_unlock(&stats_sizes_lock); }
0
[ "CWE-190" ]
memcached
bd578fc34b96abe0f8d99c1409814a09f51ee71c
53,314,442,575,639,080,000,000,000,000,000,000,000
9
CVE reported by cisco talos
static void free_ppnode(huff_t* huff, node_t **ppnode) { *ppnode = (node_t *)huff->freelist; huff->freelist = ppnode; }
0
[ "CWE-119" ]
ioq3
d2b1d124d4055c2fcbe5126863487c52fd58cca1
317,521,268,503,872,100,000,000,000,000,000,000,000
4
Fix/improve buffer overflow in MSG_ReadBits/MSG_WriteBits Prevent reading past end of message in MSG_ReadBits. If read past end of msg->data buffer (16348 bytes) the engine could SEGFAULT. Make MSG_WriteBits use an exact buffer overflow check instead of possibly failing with a few bytes left.
PJ_DEF(pj_status_t) pj_file_setpos( pj_oshandle_t fd, pj_off_t offset, enum pj_file_seek_type whence) { int mode; if ((sizeof(pj_off_t) > sizeof(long)) && (offset > PJ_MAXLONG || offset < PJ_MINLONG)) { return PJ_ENOTS...
0
[ "CWE-703", "CWE-835" ]
pjproject
947bc1ee6d05be10204b918df75a503415fd3213
301,138,265,525,459,000,000,000,000,000,000,000,000
29
Merge pull request from GHSA-rwgw-vwxg-q799 * Prevent potential infinite loop when parsing WAV format file * Check if subchunk is negative. * Fix and add checks * Change data type from pj_ssize_t to long. * Modify check * Fix leak file descriptor and modify check on wav_playlist * Move overflow/underflow check t...
static bool io_timeout_remove_link(struct io_ring_ctx *ctx, struct io_kiocb *req) { struct io_kiocb *preq; bool found = false; spin_lock_irq(&ctx->completion_lock); list_for_each_entry(preq, &ctx->timeout_list, timeout.list) { found = io_match_link(preq, req); if (found) { __io_timeout_cancel(preq); ...
0
[]
linux
0f2122045b946241a9e549c2a76cea54fa58a7ff
285,047,573,941,098,280,000,000,000,000,000,000,000
17
io_uring: don't rely on weak ->files references Grab actual references to the files_struct. To avoid circular references issues due to this, we add a per-task note that keeps track of what io_uring contexts a task has used. When the tasks execs or exits its assigned files, we cancel requests based on this tracking. W...
static inline uint64_t ldq_phys_internal(AddressSpace *as, hwaddr addr, enum device_endian endian) { uint8_t *ptr; uint64_t val; MemoryRegion *mr; hwaddr l = 8; hwaddr addr1; mr = address_space_translate(as, addr, &addr1, &l, ...
0
[]
qemu
c3c1bb99d1c11978d9ce94d1bdcf0705378c1459
271,102,736,994,634,280,000,000,000,000,000,000,000
42
exec: Respect as_tranlsate_internal length clamp address_space_translate_internal will clamp the *plen length argument based on the size of the memory region being queried. The iommu walker logic in addresss_space_translate was ignoring this by discarding the post fn call value of *plen. Fix by just always using *plen...
errfinish(int dummy,...) { ErrorData *edata = &errordata[errordata_stack_depth]; int elevel; bool save_ImmediateInterruptOK; MemoryContext oldcontext; ErrorContextCallback *econtext; recursion_depth++; CHECK_STACK_DEPTH(); elevel = edata->elevel; /* * Ensure we can't get interrupted while performing er...
0
[ "CWE-89" ]
postgres
2b3a8b20c2da9f39ffecae25ab7c66974fbc0d3b
249,587,674,642,078,200,000,000,000,000,000,000,000
177
Be more careful to not lose sync in the FE/BE protocol. If any error occurred while we were in the middle of reading a protocol message from the client, we could lose sync, and incorrectly try to interpret a part of another message as a new protocol message. That will usually lead to an "invalid frontend message" erro...
static bool ip6_parse_tlv(const struct tlvtype_proc *procs, struct sk_buff *skb) { const struct tlvtype_proc *curr; const unsigned char *nh = skb_network_header(skb); int off = skb_network_header_len(skb); int len = (skb_transport_header(skb)[1] + 1) << 3; int padlen = 0; if (skb_transport_offset(skb) + len > sk...
0
[ "CWE-416", "CWE-284", "CWE-264" ]
linux
45f6fad84cc305103b28d73482b344d7f5b76f39
303,830,486,125,432,620,000,000,000,000,000,000,000
75
ipv6: add complete rcu protection around np->opt This patch addresses multiple problems : UDP/RAW sendmsg() need to get a stable struct ipv6_txoptions while socket is not locked : Other threads can change np->opt concurrently. Dmitry posted a syzkaller (http://github.com/google/syzkaller) program desmonstrating use-a...
static int cac_parse_cardurl(sc_card_t *card, cac_private_data_t *priv, cac_card_url_t *val, int len) { cac_object_t new_object; const cac_object_t *obj; unsigned short object_id; int r; r = cac_path_from_cardurl(card, &new_object.path, val, len); if (r != SC_SUCCESS) { return r; } switch (val->cardApplicati...
0
[ "CWE-415", "CWE-119" ]
OpenSC
360e95d45ac4123255a4c796db96337f332160ad
217,119,470,605,852,650,000,000,000,000,000,000,000
45
fixed out of bounds writes Thanks to Eric Sesterhenn from X41 D-SEC GmbH for reporting the problems.
void imap_mdata_cache_reset(struct ImapMboxData *mdata) { mutt_hash_free(&mdata->uid_hash); imap_msn_free(&mdata->msn); mutt_bcache_close(&mdata->bcache); }
0
[ "CWE-125" ]
neomutt
fa1db5785e5cfd9d3cd27b7571b9fe268d2ec2dc
236,557,647,544,556,840,000,000,000,000,000,000,000
6
Fix seqset iterator when it ends in a comma If the seqset ended with a comma, the substr_end marker would be just before the trailing nul. In the next call, the loop to skip the marker would iterate right past the end of string too. The fix is simple: place the substr_end marker and skip past it immediately.
static inline uint32_t readLE32(const uint8_t *data) { return (((uint32_t)data[3] << 24) | ((uint32_t)data[2] << 16) | ((uint32_t)data[1] << 8) | ((uint32_t)data[0] << 0)); }
0
[ "CWE-787" ]
ok-file-formats
a9cc1711dd4ed6a215038f1c5c03af0ef52c3211
291,326,898,437,322,600,000,000,000,000,000,000,000
6
ok_jpg: Fix invalid DHT (#11)
void apparmor_bprm_committed_creds(struct linux_binprm *bprm) { /* TODO: cleanup signals - ipc mediation */ return; }
0
[ "CWE-264" ]
linux
259e5e6c75a910f3b5e656151dc602f53f9d7548
89,367,418,602,831,800,000,000,000,000,000,000,000
5
Add PR_{GET,SET}_NO_NEW_PRIVS to prevent execve from granting privs With this change, calling prctl(PR_SET_NO_NEW_PRIVS, 1, 0, 0, 0) disables privilege granting operations at execve-time. For example, a process will not be able to execute a setuid binary to change their uid or gid if this bit is set. The same is t...
static void V2_minix_read_inode(struct inode * inode) { struct buffer_head * bh; struct minix2_inode * raw_inode; struct minix_inode_info *minix_inode = minix_i(inode); int i; raw_inode = minix_V2_raw_inode(inode->i_sb, inode->i_ino, &bh); if (!raw_inode) { make_bad_inode(inode); return; } inode->i_mode = ...
0
[ "CWE-189" ]
linux-2.6
f5fb09fa3392ad43fbcfc2f4580752f383ab5996
120,395,935,722,537,760,000,000,000,000,000,000,000
29
[PATCH] Fix for minix crash Mounting a (corrupt) minix filesystem with zero s_zmap_blocks gives a spectacular crash on my 2.6.17.8 system, no doubt because minix/inode.c does an unconditional minix_set_bit(0,sbi->s_zmap[0]->b_data); [akpm@osdl.org: make labels conistent while we're there] Signed-off-by: Andrew Mort...
inline void add_where_field(st_select_lex *sel) { DBUG_ASSERT(this != sel); select_n_where_fields+= sel->select_n_where_fields; }
0
[ "CWE-703" ]
server
39feab3cd31b5414aa9b428eaba915c251ac34a2
171,448,958,100,178,580,000,000,000,000,000,000,000
5
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...
static int sctp_getsockopt_peer_addrs_num_old(struct sock *sk, int len, char __user *optval, int __user *optlen) { sctp_assoc_t id; struct sctp_association *asoc; struct list_head *pos; int cnt = 0; if (len < sizeof(sctp_assoc_t)) return -EINVAL; if (copy_from_user(&id, optval, sizeof(sc...
0
[]
linux-2.6
5e739d1752aca4e8f3e794d431503bfca3162df4
27,283,270,152,900,576,000,000,000,000,000,000,000
28
sctp: fix potential panics in the SCTP-AUTH API. All of the SCTP-AUTH socket options could cause a panic if the extension is disabled and the API is envoked. Additionally, there were some additional assumptions that certain pointers would always be valid which may not always be the case. This patch hardens the API a...
bool is_sameXYZ(const unsigned int size_x, const unsigned int size_y, const unsigned int size_z) const { return is_sameXY(size_x,size_y) && _depth==size_z; }
0
[ "CWE-770" ]
cimg
619cb58dd90b4e03ac68286c70ed98acbefd1c90
319,710,828,449,114,000,000,000,000,000,000,000,000
3
CImg<>::load_bmp() and CImg<>::load_pandore(): Check that dimensions encoded in file does not exceed file size.
static NO_INLINE bool jspeCheckBreakContinue() { if (execInfo.execute & EXEC_CONTINUE) execInfo.execute = (execInfo.execute & ~EXEC_RUN_MASK) | EXEC_YES; else if (execInfo.execute & EXEC_BREAK) { execInfo.execute = (execInfo.execute & ~EXEC_RUN_MASK) | EXEC_YES; return true; } return false; }
0
[ "CWE-787" ]
Espruino
e069be2ecc5060ef47391716e4de94999595b260
117,152,249,400,583,150,000,000,000,000,000,000,000
9
Fix potential corruption issue caused by `delete [].__proto__` (fix #2142)
static void conn_to_str(const conn *c, char *addr, char *svr_addr) { if (!c) { strcpy(addr, "<null>"); } else if (c->state == conn_closed) { strcpy(addr, "<closed>"); } else { struct sockaddr_in6 local_addr; struct sockaddr *sock_addr = (void *)&c->request_addr; /* F...
0
[ "CWE-125" ]
memcached
554b56687a19300a75ec24184746b5512580c819
239,254,385,785,581,630,000,000,000,000,000,000,000
32
fix strncpy call to avoid ASAN violation Ensure we're only reading to the size of the smallest buffer, since they're both on the stack and could potentially overlap. Overlapping is defined as ... undefined behavior. I've looked through all available implementations of strncpy and they still only copy from the first \0...
static void fuse_invalidate_entry(struct dentry *entry) { d_invalidate(entry); fuse_invalidate_entry_cache(entry); }
0
[ "CWE-459" ]
linux
5d069dbe8aaf2a197142558b6fb2978189ba3454
10,166,185,306,595,712,000,000,000,000,000,000,000
5
fuse: fix bad inode Jan Kara's analysis of the syzbot report (edited): The reproducer opens a directory on FUSE filesystem, it then attaches dnotify mark to the open directory. After that a fuse_do_getattr() call finds that attributes returned by the server are inconsistent, and calls make_bad_inode() which,...
get_progress_error (const GError *update_error) { g_autofree gchar *name = NULL; name = g_dbus_error_encode_gerror (update_error); /* Don't return weird dbus wrapped things from the portal */ if (g_str_has_prefix (name, "org.gtk.GDBus.UnmappedGError.Quark")) return g_strdup ("org.freedesktop.DBus.Error.Fa...
0
[ "CWE-94", "CWE-74" ]
flatpak
aeb6a7ab0abaac4a8f4ad98b3df476d9de6b8bd4
113,668,737,510,385,510,000,000,000,000,000,000,000
11
portal: Convert --env in extra-args into --env-fd This hides overridden variables from the command-line, which means processes running under other uids can't see them in /proc/*/cmdline, which might be important if they contain secrets. Signed-off-by: Simon McVittie <smcv@collabora.com> Part-of: https://github.com/fl...
int nft_chain_validate(const struct nft_ctx *ctx, const struct nft_chain *chain) { struct nft_expr *expr, *last; const struct nft_data *data; struct nft_rule *rule; int err; if (ctx->level == NFT_JUMP_STACK_SIZE) return -EMLINK; list_for_each_entry(rule, &chain->rules, list) { if (!nft_is_active_next(ctx->n...
0
[ "CWE-665" ]
linux
ad9f151e560b016b6ad3280b48e42fa11e1a5440
216,960,729,364,716,900,000,000,000,000,000,000,000
26
netfilter: nf_tables: initialize set before expression setup nft_set_elem_expr_alloc() needs an initialized set if expression sets on the NFT_EXPR_GC flag. Move set fields initialization before expression setup. [4512935.019450] ================================================================== [4512935.019456] BUG: ...
static int init_ssl_connection(SSL *con) { int i; const char *str; X509 *peer; long verify_err; char buf[BUFSIZ]; #if !defined(OPENSSL_NO_NEXTPROTONEG) const unsigned char *next_proto_neg; unsigned next_proto_neg_len; #endif unsigned char *exportedkeymat; #ifndef OPENSSL_NO_DTLS if(...
1
[ "CWE-399" ]
openssl
380f18ed5f140e0ae1b68f3ab8f4f7c395658d9e
191,396,508,933,140,700,000,000,000,000,000,000,000
163
CVE-2016-0798: avoid memory leak in SRP The SRP user database lookup method SRP_VBASE_get_by_user had confusing memory management semantics; the returned pointer was sometimes newly allocated, and sometimes owned by the callee. The calling code has no way of distinguishing these two cases. Specifically, SRP servers t...
static void do_cpuid_ent(struct kvm_cpuid_entry2 *entry, u32 function, u32 index, int *nent, int maxnent) { const u32 kvm_supported_word0_x86_features = bit(X86_FEATURE_FPU) | bit(X86_FEATURE_VME) | bit(X86_FEATURE_DE) | bit(X86_FEATURE_PSE) | bit(X86_FEATURE_TSC) | bit(X86_FEATURE_MSR) | bit(X86_FEATURE_PAE...
0
[ "CWE-476" ]
linux-2.6
59839dfff5eabca01cc4e20b45797a60a80af8cb
84,197,382,445,962,200,000,000,000,000,000,000,000
108
KVM: x86: check for cr3 validity in ioctl_set_sregs Matt T. Yourst notes that kvm_arch_vcpu_ioctl_set_sregs lacks validity checking for the new cr3 value: "Userspace callers of KVM_SET_SREGS can pass a bogus value of cr3 to the kernel. This will trigger a NULL pointer access in gfn_to_rmap() when userspace next tries...
MagickExport int LocaleCompare(const char *p,const char *q) { if (p == (char *) NULL) { if (q == (char *) NULL) return(0); return(-1); } if (q == (char *) NULL) return(1); #if defined(MAGICKCORE_HAVE_STRCASECMP) return(strcasecmp(p,q)); #else { register int c, d; ...
0
[ "CWE-125" ]
ImageMagick
07eebcd72f45c8fd7563d3f9ec5d2bed48f65f36
212,372,235,052,342,280,000,000,000,000,000,000,000
31
...
static int whiteheat_port_probe(struct usb_serial_port *port) { struct whiteheat_private *info; info = kzalloc(sizeof(*info), GFP_KERNEL); if (!info) return -ENOMEM; usb_set_serial_port_data(port, info); return 0; }
0
[ "CWE-399" ]
linux
cbb4be652d374f64661137756b8f357a1827d6a4
105,634,519,727,521,830,000,000,000,000,000,000,000
12
USB: whiteheat: fix potential null-deref at probe Fix potential null-pointer dereference at probe by making sure that the required endpoints are present. The whiteheat driver assumes there are at least five pairs of bulk endpoints, of which the final pair is used for the "command port". An attempt to bind to an inter...
sec_to_pub_keyblock (kbnode_t sec_keyblock) { kbnode_t pub_keyblock = NULL; kbnode_t ctx = NULL; kbnode_t secnode, pubnode; while ((secnode = walk_kbnode (sec_keyblock, &ctx, 0))) { if (secnode->pkt->pkttype == PKT_SECRET_KEY || secnode->pkt->pkttype == PKT_SECRET_SUBKEY) { /* Make a pu...
0
[ "CWE-20" ]
gnupg
f0b33b6fb8e0586e9584a7a409dcc31263776a67
110,279,247,746,240,840,000,000,000,000,000,000,000
44
gpg: Import only packets which are allowed in a keyblock. * g10/import.c (valid_keyblock_packet): New. (read_block): Store only valid packets. -- A corrupted key, which for example included a mangled public key encrypted packet, used to corrupt the keyring. This change skips all packets which are not allowed in a ke...
GF_Box *strk_box_new() { ISOM_DECL_BOX_ALLOC(GF_SubTrackBox, GF_ISOM_BOX_TYPE_STRK); return (GF_Box *)tmp; }
0
[ "CWE-787" ]
gpac
77510778516803b7f7402d7423c6d6bef50254c3
261,834,491,326,463,060,000,000,000,000,000,000,000
5
fixed #2255
static int netns_monitor(int argc, char **argv) { char buf[4096]; struct inotify_event *event; int fd; fd = inotify_init(); if (fd < 0) { fprintf(stderr, "inotify_init failed: %s\n", strerror(errno)); return -1; } if (create_netns_dir()) return -1; if (inotify_add_watch(fd, NETNS_RUN_DIR, IN_CREATE ...
0
[ "CWE-416" ]
iproute2
9bf2c538a0eb10d66e2365a655bf6c52f5ba3d10
302,045,830,500,779,200,000,000,000,000,000,000,000
40
ipnetns: use-after-free problem in get_netnsid_from_name func Follow the following steps: # ip netns add net1 # export MALLOC_MMAP_THRESHOLD_=0 # ip netns list then Segmentation fault (core dumped) will occur. In get_netnsid_from_name func, answer is freed before rta_getattr_u32(tb[NETNSA_NSID]), where tb[] refers...
BSONObj spec() { return BSON("$or" << BSON_ARRAY(0 << "$a")); }
0
[ "CWE-835" ]
mongo
0a076417d1d7fba3632b73349a1fd29a83e68816
114,988,947,532,694,380,000,000,000,000,000,000,000
3
SERVER-38070 fix infinite loop in agg expression
Status TensorToNdarray(const Tensor& t, PyObject** ret) { Status status; Safe_TF_TensorPtr tf_tensor = make_safe(TF_TensorFromTensor(t, &status)); if (!status.ok()) { return status; } return TF_TensorToPyArray(std::move(tf_tensor), ret); }
0
[ "CWE-476", "CWE-843" ]
tensorflow
030af767d357d1b4088c4a25c72cb3906abac489
269,074,879,990,336,500,000,000,000,000,000,000,000
8
Fix `tf.raw_ops.ResourceCountUpTo` null pointer dereference. PiperOrigin-RevId: 368294347 Change-Id: I2c16fbfc9b4966c402c3d8e311f0d665a9c852d8
iobuf_print_chain (iobuf_t a) { print_chain (a); return 0; }
0
[ "CWE-20" ]
gnupg
2183683bd633818dd031b090b5530951de76f392
248,408,513,867,267,450,000,000,000,000,000,000,000
5
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 void _mix_pool_bytes(struct entropy_store *r, const void *in, int nbytes) { unsigned long i, tap1, tap2, tap3, tap4, tap5; int input_rotate; int wordmask = r->poolinfo->poolwords - 1; const char *bytes = in; __u32 w; tap1 = r->poolinfo->tap1; tap2 = r->poolinfo->tap2; tap3 = r->poolinfo->tap3; t...
0
[ "CWE-200", "CWE-330" ]
linux
f227e3ec3b5cad859ad15666874405e8c1bbc1d4
172,597,046,756,029,830,000,000,000,000,000,000,000
46
random32: update the net random state on interrupt and activity This modifies the first 32 bits out of the 128 bits of a random CPU's net_rand_state on interrupt or CPU activity to complicate remote observations that could lead to guessing the network RNG's internal state. Note that depending on some network devices'...
gst_qtdemux_sync_streams (GstQTDemux * demux) { gint i; if (demux->n_streams <= 1) return; for (i = 0; i < demux->n_streams; i++) { QtDemuxStream *stream; GstClockTime end_time; stream = demux->streams[i]; if (!stream->pad) continue; /* TODO advance time on subtitle streams here...
0
[ "CWE-125" ]
gst-plugins-good
d0949baf3dadea6021d54abef6802fed5a06af75
312,893,087,212,001,240,000,000,000,000,000,000,000
58
qtdemux: Fix out of bounds read in tag parsing code We can't simply assume that the length of the tag value as given inside the stream is correct but should also check against the amount of data we have actually available. https://bugzilla.gnome.org/show_bug.cgi?id=775451
static CURLcode formdata_add_filename(const struct curl_httppost *file, struct FormData **form, curl_off_t *size) { CURLcode result = CURLE_OK; char *filename = file->showfilename; char *filebasename = NULL; char *filename_escaped = NUL...
0
[ "CWE-200" ]
curl
b3875606925536f82fc61f3114ac42f29eaf6945
162,657,082,093,017,500,000,000,000,000,000,000,000
42
curl_easy_duphandle: CURLOPT_COPYPOSTFIELDS read out of bounds When duplicating a handle, the data to post was duplicated using strdup() when it could be binary and contain zeroes and it was not even zero terminated! This caused read out of bounds crashes/segfaults. Since the lib/strdup.c file no longer is easily sha...
static void *qemu_ram_ptr_length(RAMBlock *ram_block, ram_addr_t addr, hwaddr *size) { RAMBlock *block = ram_block; if (*size == 0) { return NULL; } if (block == NULL) { block = qemu_get_ram_block(addr); addr -= block->offset; } *size = M...
0
[ "CWE-125" ]
qemu
04bf2526ce87f21b32c9acba1c5518708c243ad0
59,047,323,683,429,355,000,000,000,000,000,000,000
28
exec: use qemu_ram_ptr_length to access guest ram When accessing guest's ram block during DMA operation, use 'qemu_ram_ptr_length' to get ram block pointer. It ensures that DMA operation of given length is possible; And avoids any OOB memory access situations. Reported-by: Alex <broscutamaker@gmail.com> Signed-off-by...
void test_nghttp2_session_repeated_priority_submission(void) { nghttp2_session *session; nghttp2_session_callbacks callbacks; nghttp2_priority_spec pri_spec; int32_t stream_id, last_stream_id; uint32_t max_streams = NGHTTP2_MIN_IDLE_STREAMS; memset(&callbacks, 0, sizeof(callbacks)); callbacks.send_callb...
0
[]
nghttp2
0a6ce87c22c69438ecbffe52a2859c3a32f1620f
222,280,753,537,329,870,000,000,000,000,000,000,000
47
Add nghttp2_option_set_max_outbound_ack
static void rbd_osd_format_read(struct ceph_osd_request *osd_req) { struct rbd_obj_request *obj_request = osd_req->r_priv; struct rbd_device *rbd_dev = obj_request->img_request->rbd_dev; struct ceph_options *opt = rbd_dev->rbd_client->client->options; osd_req->r_flags = CEPH_OSD_FLAG_READ | opt->read_from_replica;...
0
[ "CWE-863" ]
linux
f44d04e696feaf13d192d942c4f14ad2e117065a
204,061,903,616,445,000,000,000,000,000,000,000,000
9
rbd: require global CAP_SYS_ADMIN for mapping and unmapping It turns out that currently we rely only on sysfs attribute permissions: $ ll /sys/bus/rbd/{add*,remove*} --w------- 1 root root 4096 Sep 3 20:37 /sys/bus/rbd/add --w------- 1 root root 4096 Sep 3 20:37 /sys/bus/rbd/add_single_major --w------- 1 ro...
CCHAR GetReceiveQueueForCurrentCPU(PARANDIS_ADAPTER *pContext) { #if PARANDIS_SUPPORT_RSS return ParaNdis6_RSSGetCurrentCpuReceiveQueue(&pContext->RSSParameters); #else UNREFERENCED_PARAMETER(pContext); return PARANDIS_RECEIVE_QUEUE_UNCLASSIFIED; #endif }
0
[ "CWE-20" ]
kvm-guest-drivers-windows
723416fa4210b7464b28eab89cc76252e6193ac1
259,788,489,561,084,800,000,000,000,000,000,000,000
10
NetKVM: BZ#1169718: Checking the length only on read Signed-off-by: Joseph Hindin <yhindin@rehat.com>
void netdev_class_remove_file_ns(const struct class_attribute *class_attr, const void *ns) { class_remove_file_ns(&net_class, class_attr, ns);
0
[ "CWE-401" ]
linux
895a5e96dbd6386c8e78e5b78e067dcc67b7f0ab
188,850,533,259,908,940,000,000,000,000,000,000,000
5
net-sysfs: Fix mem leak in netdev_register_kobject syzkaller report this: BUG: memory leak unreferenced object 0xffff88837a71a500 (size 256): comm "syz-executor.2", pid 9770, jiffies 4297825125 (age 17.843s) hex dump (first 32 bytes): 00 00 00 00 ad 4e ad de ff ff ff ff 00 00 00 00 .....N.......... ff ff ...
int sqliteAuthorizer(void* userData, int code, const char* arg3, const char* arg4, const char* arg5, const char* arg6) { if (kAllowedSQLiteActionCodes.count(code) > 0) { return SQLITE_OK; } LOG(ERROR) << "...
0
[ "CWE-77", "CWE-295" ]
osquery
c3f9a3dae22d43ed3b4f6a403cbf89da4cba7c3c
285,230,585,545,270,360,000,000,000,000,000,000,000
14
Merge pull request from GHSA-4g56-2482-x7q8 * Proposed fix for attach tables vulnerability * Add authorizer to ATC tables and cleanups - Add unit test for authorizer function
int qcow2_grow_l1_table(BlockDriverState *bs, uint64_t min_size, bool exact_size) { BDRVQcowState *s = bs->opaque; int new_l1_size2, ret, i; uint64_t *new_l1_table; int64_t old_l1_table_offset, old_l1_size; int64_t new_l1_table_offset, new_l1_size; uint8_t data[12]; ...
0
[ "CWE-190" ]
qemu
cab60de930684c33f67d4e32c7509b567f8c445b
236,378,819,902,191,670,000,000,000,000,000,000,000
92
qcow2: Fix new L1 table size check (CVE-2014-0143) The size in bytes is assigned to an int later, so check that instead of the number of entries. Signed-off-by: Kevin Wolf <kwolf@redhat.com> Reviewed-by: Max Reitz <mreitz@redhat.com> Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
static int power_pmu_commit_txn(struct pmu *pmu) { struct cpu_hw_events *cpuhw; long i, n; if (!ppmu) return -EAGAIN; cpuhw = this_cpu_ptr(&cpu_hw_events); WARN_ON_ONCE(!cpuhw->txn_flags); /* no txn in flight */ if (cpuhw->txn_flags & ~PERF_PMU_TXN_ADD) { cpuhw->txn_flags = 0; return 0; } n = cpuhw->n...
0
[ "CWE-476" ]
linux
60b7ed54a41b550d50caf7f2418db4a7e75b5bdc
186,589,214,117,544,430,000,000,000,000,000,000,000
30
powerpc/perf: Fix crash in perf_instruction_pointer() when ppmu is not set On systems without any specific PMU driver support registered, running perf record causes Oops. The relevant portion from call trace: BUG: Kernel NULL pointer dereference on read at 0x00000040 Faulting instruction address: 0xc0021f0c Oo...
do_ipt_get_ctl(struct sock *sk, int cmd, void __user *user, int *len) { int ret; if (!ns_capable(sock_net(sk)->user_ns, CAP_NET_ADMIN)) return -EPERM; switch (cmd) { case IPT_SO_GET_INFO: ret = get_info(sock_net(sk), user, len); break; case IPT_SO_GET_ENTRIES: #ifdef CONFIG_COMPAT if (in_compat_syscall(...
0
[ "CWE-787" ]
linux
b29c457a6511435960115c0f548c4360d5f4801d
14,675,527,476,906,768,000,000,000,000,000,000,000
54
netfilter: x_tables: fix compat match/target pad out-of-bound write xt_compat_match/target_from_user doesn't check that zeroing the area to start of next rule won't write past end of allocated ruleset blob. Remove this code and zero the entire blob beforehand. Reported-by: syzbot+cfc0247ac173f597aaaa@syzkaller.appsp...
static int ati_remote2_get_mode_mask(char *buffer, const struct kernel_param *kp) { pr_debug("%s()\n", __func__); return sprintf(buffer, "0x%02x", *(unsigned int *)kp->arg); }
0
[ "CWE-703" ]
linux
950336ba3e4a1ffd2ca60d29f6ef386dd2c7351d
79,386,894,919,688,225,000,000,000,000,000,000,000
7
Input: ati_remote2 - fix crashes on detecting device with invalid descriptor The ati_remote2 driver expects at least two interfaces with one endpoint each. If given malicious descriptor that specify one interface or no endpoints, it will crash in the probe function. Ensure there is at least two interfaces and one endp...
void trgt_box_del(GF_Box *s) { GF_TrackGroupTypeBox *ptr = (GF_TrackGroupTypeBox *)s; if (ptr == NULL) return; gf_free(ptr);
0
[ "CWE-787" ]
gpac
388ecce75d05e11fc8496aa4857b91245007d26e
155,441,252,454,554,420,000,000,000,000,000,000,000
6
fixed #1587
pk_transaction_get_details_local (PkTransaction *transaction, GVariant *params, GDBusMethodInvocation *context) { gboolean ret; gchar **full_paths; GError *error_local = NULL; GError *error = NULL; guint i; guint length; _cleanup_free_ gchar *content_type = NULL; _cleanup_free_ gchar *files_temp = N...
0
[ "CWE-287" ]
PackageKit
f176976e24e8c17b80eff222572275517c16bdad
19,743,519,084,754,518,000,000,000,000,000,000,000
99
Reinstallation and downgrade require authorization Added new policy actions: * org.freedesktop.packagekit.package-reinstall * org.freedesktop.packagekit.package-downgrade The first does not depend or require any other actions to be authorized except for org.freedesktop.packagekit.package-install-untrusted in case o...
static void ConvertRGBToYPbPr(const double red,const double green, const double blue,double *Y,double *Pb,double *Pr) { *Y=QuantumScale*(0.298839*red+0.586811*green+0.114350*blue); *Pb=QuantumScale*((-0.1687367)*red-0.331264*green+0.5*blue)+0.5; *Pr=QuantumScale*(0.5*red-0.418688*green-0.081312*blue)+0.5; }
0
[ "CWE-369" ]
ImageMagick
75f6f5032690077cae3eaeda3c0165cc765eaeb5
26,011,061,633,713,993,000,000,000,000,000,000,000
7
https://github.com/ImageMagick/ImageMagick/issues/3295
static bool is_suppressed_warning(int severity) { /* Might be a warning but suppresed explicitly */ if (is_valid_warning(severity) && !(severity & ERR_USAGE)) return !(warning_state[WARN_IDX(severity)] & WARN_ST_ENABLED); else return false; }
0
[ "CWE-476" ]
nasm
e996d28c70d45008085322b442b44a9224308548
323,222,341,808,328,100,000,000,000,000,000,000,000
8
labels: Don't nil dereference if no label provided An equ without label may cause nil dereference | equ 0x100 Fixes 98578071b9d71ecaa2344dd9c185237c1765041e Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
static __net_init int dccp_net_init(struct net *net) { int ret = 0; ret = nf_ct_l4proto_pernet_register(net, &dccp_proto4); if (ret < 0) { pr_err("nf_conntrack_dccp4: pernet registration failed.\n"); goto out; } ret = nf_ct_l4proto_pernet_register(net, &dccp_proto6); if (ret < 0) { pr_err("nf_conntrack_dccp...
0
[ "CWE-20" ]
linux
b22f5126a24b3b2f15448c3f2a254fc10cbc2b92
164,695,115,181,387,580,000,000,000,000,000,000,000
19
netfilter: nf_conntrack_dccp: fix skb_header_pointer API usages Some occurences in the netfilter tree use skb_header_pointer() in the following way ... struct dccp_hdr _dh, *dh; ... skb_header_pointer(skb, dataoff, sizeof(_dh), &dh); ... where dh itself is a pointer that is being passed as the copy buffer. Ins...
static void tulip_tx(TULIPState *s, struct tulip_descriptor *desc) { if (s->tx_frame_len) { if ((s->csr[6] >> CSR6_OM_SHIFT) & CSR6_OM_MASK) { /* Internal or external Loopback */ tulip_receive(s, s->tx_frame, s->tx_frame_len); } else { qemu_send_packet(qemu_get_qu...
1
[ "CWE-787" ]
qemu
8ffb7265af64ec81748335ec8f20e7ab542c3850
304,554,006,793,262,900,000,000,000,000,000,000,000
17
net: tulip: check frame size and r/w data length Tulip network driver while copying tx/rx buffers does not check frame size against r/w data length. This may lead to OOB buffer access. Add check to avoid it. Limit iterations over descriptors to avoid potential infinite loop issue in tulip_xmit_list_update. Reported-...
static int do_raw_getsockopt(struct sock *sk, int level, int optname, char __user *optval, int __user *optlen) { if (optname == ICMP_FILTER) { if (inet_sk(sk)->inet_num != IPPROTO_ICMP) return -EOPNOTSUPP; else return raw_geticmpfilter(sk, optval, optlen); } return -ENOPROTOOPT; }
0
[ "CWE-362" ]
linux-2.6
f6d8bd051c391c1c0458a30b2a7abcd939329259
191,647,136,786,226,460,000,000,000,000,000,000,000
11
inet: add RCU protection to inet->opt We lack proper synchronization to manipulate inet->opt ip_options Problem is ip_make_skb() calls ip_setup_cork() and ip_setup_cork() possibly makes a copy of ipc->opt (struct ip_options), without any protection against another thread manipulating inet->opt. Another thread can ch...
static void destroy_raw_packet_qp(struct mlx5_ib_dev *dev, struct mlx5_ib_qp *qp) { struct mlx5_ib_raw_packet_qp *raw_packet_qp = &qp->raw_packet_qp; struct mlx5_ib_sq *sq = &raw_packet_qp->sq; struct mlx5_ib_rq *rq = &raw_packet_qp->rq; if (qp->rq.wqe_cnt) { destroy_raw_packet_qp_tir(dev, rq); destroy_r...
0
[ "CWE-119", "CWE-787" ]
linux
0625b4ba1a5d4703c7fb01c497bd6c156908af00
60,568,563,620,750,820,000,000,000,000,000,000,000
17
IB/mlx5: Fix leaking stack memory to userspace mlx5_ib_create_qp_resp was never initialized and only the first 4 bytes were written. Fixes: 41d902cb7c32 ("RDMA/mlx5: Fix definition of mlx5_ib_create_qp_resp") Cc: <stable@vger.kernel.org> Acked-by: Leon Romanovsky <leonro@mellanox.com> Signed-off-by: Jason Gunthorpe <...
QPDF::parse_xrefFirst(std::string const& line, int& obj, int& num, int& bytes) { // is_space and is_digit both return false on '\0', so this will // not overrun the null-terminated buffer. char const* p = line.c_str(); char const* start = line.c_str(); // Skip zero or more spa...
0
[ "CWE-787" ]
qpdf
d71f05ca07eb5c7cfa4d6d23e5c1f2a800f52e8e
266,325,900,851,107,440,000,000,000,000,000,000,000
55
Fix sign and conversion warnings (major) This makes all integer type conversions that have potential data loss explicit with calls that do range checks and raise an exception. After this commit, qpdf builds with no warnings when -Wsign-conversion -Wconversion is used with gcc or clang or when -W3 -Wd4800 is used with ...
static void selinux_sb_free_security(struct super_block *sb) { superblock_free_security(sb); }
0
[]
linux-2.6
ee18d64c1f632043a02e6f5ba5e045bb26a5465f
178,805,993,135,972,530,000,000,000,000,000,000,000
4
KEYS: Add a keyctl to install a process's session keyring on its parent [try #6] Add a keyctl to install a process's session keyring onto its parent. This replaces the parent's session keyring. Because the COW credential code does not permit one process to change another process's credentials directly, the change is...
static int vfswrap_fsetxattr(struct vfs_handle_struct *handle, struct files_struct *fsp, const char *name, const void *value, size_t size, int flags) { return fsetxattr(fsp->fh->fd, name, value, size, flags); }
0
[ "CWE-665" ]
samba
30e724cbff1ecd90e5a676831902d1e41ec1b347
260,556,560,360,808,200,000,000,000,000,000,000,000
4
FSCTL_GET_SHADOW_COPY_DATA: Initialize output array to zero Otherwise num_volumes and the end marker can return uninitialized data to the client. Signed-off-by: Christof Schmitt <christof.schmitt@us.ibm.com> Reviewed-by: Jeremy Allison <jra@samba.org> Reviewed-by: Simo Sorce <idra@samba.org>
htmlDtdDumpOutput(xmlOutputBufferPtr buf, xmlDocPtr doc, const char *encoding ATTRIBUTE_UNUSED) { xmlDtdPtr cur = doc->intSubset; if (cur == NULL) { htmlSaveErr(XML_SAVE_NO_DOCTYPE, (xmlNodePtr) doc, NULL); return; } xmlOutputBufferWriteString(buf, "<!DOCTYPE "); xmlOutputBufferWriteSt...
0
[ "CWE-79" ]
libxml2
c1ba6f54d32b707ca6d91cb3257ce9de82876b6f
316,744,052,661,139,200,000,000,000,000,000,000,000
24
Revert "Do not URI escape in server side includes" This reverts commit 960f0e275616cadc29671a218d7fb9b69eb35588. This commit introduced - an infinite loop, found by OSS-Fuzz, which could be easily fixed. - an algorithm with quadratic runtime - a security issue, see https://bugzilla.gnome.org/show_bug.cgi?id=769760...
static inline void wdec16(uint16_t l, uint16_t h, uint16_t *a, uint16_t *b) { int m = l; int d = h; int bb = (m - (d >> 1)) & MOD_MASK; int aa = (d + bb - A_OFFSET) & MOD_MASK; *b = bb; *a = aa; }
0
[ "CWE-787" ]
FFmpeg
b0a8b40294ea212c1938348ff112ef1b9bf16bb3
174,250,486,981,747,200,000,000,000,000,000,000,000
9
avcodec/exr: skip bottom clearing loop when its outside the image Fixes: signed integer overflow: 1633771809 * 32960 cannot be represented in type 'int' Fixes: 26532/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_EXR_fuzzer-5613925708857344 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tr...
static void delete_name_run_file(pid_t pid) { char *fname; if (asprintf(&fname, "%s/%d", RUN_FIREJAIL_NAME_DIR, pid) == -1) errExit("asprintf"); int rv = unlink(fname); (void) rv; free(fname); }
0
[ "CWE-269", "CWE-94" ]
firejail
27cde3d7d1e4e16d4190932347c7151dc2a84c50
125,454,047,123,307,130,000,000,000,000,000,000,000
8
fixing CVE-2022-31214
TfLiteStatus Subgraph::ResizeInputTensorStrict(int tensor_index, const std::vector<int>& dims) { TF_LITE_ENSURE(&context_, tensor_index < context_.tensors_size && tensor_index >= 0); TfLiteTensor* tensor = &context_.tensors[tensor_index]; // Ensure ...
0
[ "CWE-20", "CWE-787" ]
tensorflow
d58c96946b2880991d63d1dacacb32f0a4dfa453
334,994,342,773,925,550,000,000,000,000,000,000,000
29
[tflite] Ensure inputs and outputs don't overlap. If a model uses the same tensor for both an input and an output then this can result in data loss and memory corruption. This should not happen. PiperOrigin-RevId: 332522916 Change-Id: If0905b142415a9dfceaf2d181872f2a8fb88f48a
static void coroutine_fn v9fs_rename(void *opaque) { int32_t fid; ssize_t err = 0; size_t offset = 7; V9fsString name; int32_t newdirfid; V9fsFidState *fidp; V9fsPDU *pdu = opaque; V9fsState *s = pdu->s; v9fs_string_init(&name); err = pdu_unmarshal(pdu, offset, "dds", &fid, &new...
0
[ "CWE-362" ]
qemu
89fbea8737e8f7b954745a1ffc4238d377055305
308,092,262,420,166,530,000,000,000,000,000,000,000
53
9pfs: Fully restart unreclaim loop (CVE-2021-20181) Depending on the client activity, the server can be asked to open a huge number of file descriptors and eventually hit RLIMIT_NOFILE. This is currently mitigated using a reclaim logic : the server closes the file descriptors of idle fids, based on the assumption that...
static int ecryptfs_init_global_auth_toks( struct ecryptfs_mount_crypt_stat *mount_crypt_stat) { struct ecryptfs_global_auth_tok *global_auth_tok; struct ecryptfs_auth_tok *auth_tok; int rc = 0; list_for_each_entry(global_auth_tok, &mount_crypt_stat->global_auth_tok_list, mount_crypt_stat_list) { ...
0
[ "CWE-284", "CWE-264" ]
linux
69c433ed2ecd2d3264efd7afec4439524b319121
5,422,313,193,370,164,000,000,000,000,000,000,000
27
fs: limit filesystem stacking depth Add a simple read-only counter to super_block that indicates how deep this is in the stack of filesystems. Previously ecryptfs was the only stackable filesystem and it explicitly disallowed multiple layers of itself. Overlayfs, however, can be stacked recursively and also may be s...
virtio_find_modern_cr(int offset) { return virtio_find_cr(modern_config_regs, sizeof(modern_config_regs) / sizeof(*modern_config_regs), offset); }
0
[ "CWE-476" ]
acrn-hypervisor
154fe59531c12b82e26d1b24b5531f5066d224f5
331,684,578,717,023,600,000,000,000,000,000,000,000
5
dm: validate inputs in vq_endchains inputs shall be validated to avoid NULL pointer access. Tracked-On: #6129 Signed-off-by: Yonghua Huang <yonghua.huang@intel.com>
static void on_state_invalid(h2_stream *stream) { if (stream->monitor && stream->monitor->on_state_invalid) { stream->monitor->on_state_invalid(stream->monitor->ctx, stream); } /* stream got an event/frame invalid in its state */ ap_log_cerror(APLOG_MARK, APLOG_TRACE1, 0, stream->session->c, ...
0
[ "CWE-770" ]
mod_h2
dd05d49abe0f67512ce9ed5ba422d7711effecfb
185,356,688,631,192,900,000,000,000,000,000,000,000
20
* fixes Timeout vs. KeepAliveTimeout behaviour, see PR 63534 (for trunk now, mpm event backport to 2.4.x up for vote). * Fixes stream cleanup when connection throttling is in place. * Counts stream resets by client on streams initiated by client as cause for connection throttling. * Header length checks are no...
bool bindToPort() override { return true; }
0
[ "CWE-400" ]
envoy
dfddb529e914d794ac552e906b13d71233609bf7
288,694,014,631,063,280,000,000,000,000,000,000,000
1
listener: Add configurable accepted connection limits (#153) Add support for per-listener limits on accepted connections. Signed-off-by: Tony Allen <tony@allen.gg>
TEST_P(Security, BuiltinAuthenticationAndAccessAndCryptoPlugin_PermissionsEnableDiscoveryDisableAccessNone_validation_ok_disable_discovery_disable_access_none) // *INDENT-ON* { PubSubReader<HelloWorldType> reader(TEST_TOPIC_NAME); PubSubWriter<HelloWorldType> writer(TEST_TOPIC_NAME); std::string governance_...
0
[ "CWE-284" ]
Fast-DDS
d2aeab37eb4fad4376b68ea4dfbbf285a2926384
198,375,789,264,349,600,000,000,000,000,000,000,000
9
check remote permissions (#1387) * Refs 5346. Blackbox test Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 5346. one-way string compare Signed-off-by: Iker Luengo <ikerluengo@eprosima.com> * Refs 5346. Do not add partition separator on last partition Signed-off-by: Iker Luengo <ikerluengo@e...
convert_protocol_address(struct sockaddr* saddr, unsigned int saddrlen) { PyObject *res_obj = NULL; switch (saddr->sa_family) { case AF_INET: { struct sockaddr_in* sin = (struct sockaddr_in*)saddr; char *addr_str = (char *)PyMem_Malloc(INET_ADDRSTRLEN); ...
0
[]
pycurl
2a743674dcf152beaaf6adaddb1ef51b18d1fffe
245,498,878,118,925,460,000,000,000,000,000,000,000
53
Fix use after free in Curl object's HTTPPOST setopt with unicode FORM_BUFFERPTR. Fixes use after free in the Curl object's HTTPPOST setopt when a unicode value is passed as a value with a FORM_BUFFERPTR. The str object created from the passed in unicode object would have its buffer used but the unicode object would be...
static int open_group(char *name, int has_prefix, struct backend **ret, int *postable /* used for LIST ACTIVE only */) { char mailboxname[MAX_MAILBOX_BUFFER]; int r = 0; char *acl, *newserver; struct backend *backend_next = NULL; /* close local group */ if (group_state) index_close(&g...
1
[ "CWE-287" ]
cyrus-imapd
77903669e04c9788460561dd0560b9c916519594
101,058,133,821,341,030,000,000,000,000,000,000,000
59
Secunia SA46093 - make sure nntp authentication completes Discovered by Stefan Cornelius, Secunia Research The vulnerability is caused due to the access restriction for certain commands only checking whether or not variable "nntp_userid" is non-NULL, without performing additional checks to verify that a complete, suc...
static const char *ifsection(cmd_parms *cmd, void *mconfig, const char *arg) { const char *errmsg; const char *endp = ap_strrchr_c(arg, '>'); int old_overrides = cmd->override; char *old_path = cmd->path; core_dir_config *conf; const command_rec *thiscmd = cmd->cmd; ap_conf_vector_t *new_if_...
0
[ "CWE-416", "CWE-284" ]
httpd
4cc27823899e070268b906ca677ee838d07cf67a
290,134,282,784,031,350,000,000,000,000,000,000,000
82
core: Disallow Methods' registration at run time (.htaccess), they may be used only if registered at init time (httpd.conf). Calling ap_method_register() in children processes is not the right scope since it won't be shared for all requests. git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1807655 13f7...
static int add_subprog_and_kfunc(struct bpf_verifier_env *env) { struct bpf_subprog_info *subprog = env->subprog_info; struct bpf_insn *insn = env->prog->insnsi; int i, ret, insn_cnt = env->prog->len; /* Add entry function. */ ret = add_subprog(env, 0); if (ret) return ret; for (i = 0; i < insn_cnt; i++, ins...
0
[ "CWE-125" ]
bpf
049c4e13714ecbca567b4d5f6d563f05d431c80e
37,304,835,148,617,760,000,000,000,000,000,000,000
47
bpf: Fix alu32 const subreg bound tracking on bitwise operations Fix a bug in the verifier's scalar32_min_max_*() functions which leads to incorrect tracking of 32 bit bounds for the simulation of and/or/xor bitops. When both the src & dst subreg is a known constant, then the assumption is that scalar_min_max_*() will...
dissect_kafka_sasl_handshake_response(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, int offset, kafka_api_version_t api_version) { proto_item *subti; proto_tree *subtree; /* error_code */ offset = dissect_kafka_error(tvb, pinfo, tree, offset); /* [enabl...
0
[ "CWE-401" ]
wireshark
f4374967bbf9c12746b8ec3cd54dddada9dd353e
203,601,803,154,628,400,000,000,000,000,000,000,000
19
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...
std::pair<int, int> TileOneDimension(const TfLiteIntArray& in_dimensions, const T* in_data, const M* multipliers, T* out_data, int dimension) { const int dimension_size = in_dimensions.data[dimension]; if (dimension == in_dimensions.size - 1)...
0
[ "CWE-125", "CWE-787" ]
tensorflow
1970c2158b1ffa416d159d03c3370b9a462aee35
92,664,435,452,451,450,000,000,000,000,000,000,000
31
[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...
ssize_t enc_untrusted_write(int fd, const void *buf, size_t count) { return static_cast<ssize_t>(EnsureInitializedAndDispatchSyscall( asylo::system_call::kSYS_write, fd, buf, count)); }
0
[ "CWE-125" ]
asylo
b1d120a2c7d7446d2cc58d517e20a1b184b82200
152,638,674,881,805,950,000,000,000,000,000,000,000
4
Check for return size in enc_untrusted_read Check return size does not exceed requested. The returned result and content still cannot be trusted, but it's expected behavior when not using a secure file system. PiperOrigin-RevId: 333827386 Change-Id: I0bdec0aec9356ea333dc8c647eba5d2772875f29
inline uint8x16x2_t CalculateUnsignedClampingWithRangeBitMasks( int16x8x2_t input_val, int16x8_t range_radius_dup, int16x8_t neg_range_radius_dup) { const uint16x8_t mask_rightclamp_0 = vcgtq_s16(input_val.val[0], range_radius_dup); const uint16x8_t mask_rightclamp_1 = vcgtq_s16(input_val.val[1]...
0
[ "CWE-476", "CWE-369" ]
tensorflow
15691e456c7dc9bd6be203b09765b063bf4a380c
141,938,204,460,605,000,000,000,000,000,000,000,000
20
Prevent dereferencing of null pointers in TFLite's `add.cc`. PiperOrigin-RevId: 387244946 Change-Id: I56094233327fbd8439b92e1dbb1262176e00eeb9
void logerr(const char *msg) { if (!arg_debug) return; openlog("firejail", LOG_NDELAY | LOG_PID, LOG_USER); syslog(LOG_ERR, "%s\n", msg); closelog(); }
0
[ "CWE-269", "CWE-94" ]
firejail
27cde3d7d1e4e16d4190932347c7151dc2a84c50
214,452,986,880,464,040,000,000,000,000,000,000,000
8
fixing CVE-2022-31214
_rsvg_io_get_file_path (const gchar * filename, const gchar * base_uri) { gchar *absolute_filename; if (g_path_is_absolute (filename)) { absolute_filename = g_strdup (filename); } else { gchar *tmpcdir; gchar *base_filename; if (base_uri) { ...
0
[ "CWE-522" ]
librsvg
f9d69eadd2b16b00d1a1f9f286122123f8e547dd
179,709,246,503,967,980,000,000,000,000,000,000,000
27
Fixed possible credentials leaking reported by Alex Birsan.