func
string
target
int64
cwe
list
project
string
commit_id
string
hash
float64
size
int64
message
string
Item_func_sp::make_field(THD *thd, Send_field *tmp_field) { DBUG_ENTER("Item_func_sp::make_field"); DBUG_ASSERT(sp_result_field); sp_result_field->make_field(tmp_field); if (name) tmp_field->col_name= name; DBUG_VOID_RETURN; }
0
[ "CWE-120" ]
server
eca207c46293bc72dd8d0d5622153fab4d3fccf1
321,071,732,885,454,170,000,000,000,000,000,000,000
9
MDEV-25317 Assertion `scale <= precision' failed in decimal_bin_size And Assertion `scale >= 0 && precision > 0 && scale <= precision' failed in decimal_bin_size_inline/decimal_bin_size. Precision should be kept below DECIMAL_MAX_SCALE for computations. It can be bigger in Item_decimal. I'd fix this too but it changes...
static __be32 nf_expect_get_id(const struct nf_conntrack_expect *exp) { static __read_mostly siphash_key_t exp_id_seed; unsigned long a, b, c, d; net_get_random_once(&exp_id_seed, sizeof(exp_id_seed)); a = (unsigned long)exp; b = (unsigned long)exp->helper; c = (unsigned long)exp->master; d = (unsigned long)si...
0
[ "CWE-120" ]
linux
1cc5ef91d2ff94d2bf2de3b3585423e8a1051cb6
25,913,175,787,603,637,000,000,000,000,000,000,000
18
netfilter: ctnetlink: add a range check for l3/l4 protonum The indexes to the nf_nat_l[34]protos arrays come from userspace. So check the tuple's family, e.g. l3num, when creating the conntrack in order to prevent an OOB memory access during setup. Here is an example kernel panic on 4.14.180 when userspace passes in ...
_g_path_get_dir_name (const gchar *path) { register gssize base; register gssize last_char; if (path == NULL) return NULL; if (path[0] == '\0') return g_strdup (""); last_char = strlen (path) - 1; if (path[last_char] == G_DIR_SEPARATOR) last_char--; base = last_char; while ((base >= 0) && (path[base] ...
0
[ "CWE-22" ]
file-roller
b147281293a8307808475e102a14857055f81631
63,716,305,890,446,190,000,000,000,000,000,000,000
21
libarchive: sanitize filenames before extracting
diff_buf_delete(buf_T *buf) { int i; tabpage_T *tp; FOR_ALL_TABPAGES(tp) { i = diff_buf_idx_tp(buf, tp); if (i != DB_COUNT) { tp->tp_diffbuf[i] = NULL; tp->tp_diff_invalid = TRUE; if (tp == curtab) diff_redraw(TRUE); } } }
1
[ "CWE-476" ]
vim
cd38bb4d83c942c4bad596835c6766cbf32e5195
5,968,869,359,428,527,000,000,000,000,000,000,000
17
patch 8.2.5163: crash when deleting buffers in diff mode Problem: Crash when deleting buffers in diff mode. Solution: Recompute diffs later. Skip window without a valid buffer.
std::size_t GetTupleBytes(const Tuple& tuple) { return std::accumulate(tuple.begin(), tuple.end(), 0, [](const std::size_t& lhs, const Tensor& rhs) { return lhs + rhs.TotalBytes(); }); }
0
[ "CWE-20", "CWE-703" ]
tensorflow
cebe3c45d76357d201c65bdbbf0dbe6e8a63bbdb
93,477,391,219,645,800,000,000,000,000,000,000,000
6
Fix tf.raw_ops.StagePeek vulnerability with invalid `index`. Check that input is actually a scalar before treating it as such. PiperOrigin-RevId: 445524908
static ssize_t portio_size_show(struct uio_port *port, char *buf) { return sprintf(buf, "0x%lx\n", port->size); }
0
[ "CWE-119", "CWE-189", "CWE-703" ]
linux
7314e613d5ff9f0934f7a0f74ed7973b903315d1
22,263,235,631,616,875,000,000,000,000,000,000,000
4
Fix a few incorrectly checked [io_]remap_pfn_range() calls Nico Golde reports a few straggling uses of [io_]remap_pfn_range() that really should use the vm_iomap_memory() helper. This trivially converts two of them to the helper, and comments about why the third one really needs to continue to use remap_pfn_range(), ...
DECLAREContigPutFunc(put2bitcmaptile) { uint32** PALmap = img->PALmap; (void) x; (void) y; fromskew /= 4; while (h-- > 0) { uint32* bw; UNROLL4(w, bw = PALmap[*pp++], *cp++ = *bw++); cp += toskew; pp += fromskew; } }
0
[ "CWE-119" ]
libtiff
40a5955cbf0df62b1f9e9bd7d9657b0070725d19
201,208,781,415,994,800,000,000,000,000,000,000,000
13
* libtiff/tif_next.c: add new tests to check that we don't read outside of the compressed input stream buffer. * libtiff/tif_getimage.c: in OJPEG case, fix checks on strile width/height
static ssize_t tun_show_flags(struct device *dev, struct device_attribute *attr, char *buf) { struct tun_struct *tun = netdev_priv(to_net_dev(dev)); return sprintf(buf, "0x%x\n", tun_flags(tun)); }
0
[ "CWE-119" ]
linux-2.6
3c8a9c63d5fd738c261bd0ceece04d9c8357ca13
251,972,482,255,297,380,000,000,000,000,000,000,000
6
tun/tap: Fix crashes if open() /dev/net/tun and then poll() it. Fix NULL pointer dereference in tun_chr_pool() introduced by commit 33dccbb050bbe35b88ca8cf1228dcf3e4d4b3554 ("tun: Limit amount of queued packets per device") and triggered by this code: int fd; struct pollfd pfd; fd = open("/dev/net/tun", O_RDWR); ...
static void rb_list_head_clear(struct list_head *list) { unsigned long *ptr = (unsigned long *)&list->next; *ptr &= ~RB_FLAG_MASK; }
0
[ "CWE-190" ]
linux-stable
59643d1535eb220668692a5359de22545af579f6
235,016,511,267,582,800,000,000,000,000,000,000,000
6
ring-buffer: Prevent overflow of size in ring_buffer_resize() If the size passed to ring_buffer_resize() is greater than MAX_LONG - BUF_PAGE_SIZE then the DIV_ROUND_UP() will return zero. Here's the details: # echo 18014398509481980 > /sys/kernel/debug/tracing/buffer_size_kb tracing_entries_write() processes this...
p11_rpc_buffer_get_attribute (p11_buffer *buffer, size_t *offset, CK_ATTRIBUTE *attr) { uint32_t type, length; unsigned char validity; p11_rpc_attribute_serializer *serializer; p11_rpc_value_type value_type; /* The attribute type */ if (!p11_rpc_buffer_get_uint32 (buffer, offset, &type)) retu...
1
[ "CWE-787" ]
p11-kit
2617f3ef888e103324a28811886b99ed0a56346d
23,421,043,781,240,477,000,000,000,000,000,000,000
39
Check attribute length against buffer size If an attribute's length does not match the length of the byte array inside it, one length was used for allocation, and the other was used for memcpy. This additional check will instead return an error on malformed messages.
inline void soonestTimeout(int* timeout, int newTimeout) { if (newTimeout && (!*timeout || newTimeout < *timeout)) *timeout = newTimeout; }
0
[ "CWE-20", "CWE-787" ]
tigervnc
0943c006c7d900dfc0281639e992791d6c567438
130,900,984,274,410,730,000,000,000,000,000,000,000
4
Use size_t for lengths in stream objects Provides safety against them accidentally becoming negative because of bugs in the calculations. Also does the same to CharArray and friends as they were strongly connection to the stream objects.
pixBackgroundNormSimple(PIX *pixs, PIX *pixim, PIX *pixg) { return pixBackgroundNorm(pixs, pixim, pixg, DefaultTileWidth, DefaultTileHeight, DefaultFgThreshold, DefaultMinCount, ...
0
[ "CWE-125" ]
leptonica
3c18c43b6a3f753f0dfff99610d46ad46b8bfac4
226,904,628,252,130,700,000,000,000,000,000,000,000
10
Fixing oss-fuzz issue 22512: Heap-buffer-overflow in rasteropGeneralLow() * Simplified the hole-filling function `
GF_Box *sidx_box_new() { ISOM_DECL_BOX_ALLOC(GF_SegmentIndexBox, GF_ISOM_BOX_TYPE_SIDX); return (GF_Box *)tmp;
0
[ "CWE-787" ]
gpac
388ecce75d05e11fc8496aa4857b91245007d26e
304,044,931,657,692,800,000,000,000,000,000,000,000
5
fixed #1587
EXPORTED strarray_t *mboxlist_sublist(const char *userid) { struct db *subs = NULL; strarray_t *list = strarray_new(); int r; /* open subs DB */ r = mboxlist_opensubs(userid, &subs); if (r) goto done; /* faster to do it all in a single slurp! */ r = cyrusdb_foreach(subs, "", 0, subsadd...
0
[ "CWE-20" ]
cyrus-imapd
6bd33275368edfa71ae117de895488584678ac79
235,044,111,065,818,000,000,000,000,000,000,000,000
22
mboxlist: fix uninitialised memory use where pattern is "Other Users"
explicit C_time_wakeup(AsyncConnectionRef c): conn(c) {}
0
[ "CWE-287", "CWE-284" ]
ceph
5ead97120e07054d80623dada90a5cc764c28468
272,462,693,330,702,420,000,000,000,000,000,000,000
1
auth/cephx: add authorizer challenge Allow the accepting side of a connection to reject an initial authorizer with a random challenge. The connecting side then has to respond with an updated authorizer proving they are able to decrypt the service's challenge and that the new authorizer was produced for this specific ...
QPDFWriter::writePad(int nspaces) { for (int i = 0; i < nspaces; ++i) { writeString(" "); } }
0
[ "CWE-125" ]
qpdf
1868a10f8b06631362618bfc85ca8646da4b4b71
330,813,744,408,101,100,000,000,000,000,000,000,000
7
Replace all atoi calls with QUtil::string_to_int The latter catches underflow/overflow.
void fuse_free_conn(struct fuse_conn *fc) { WARN_ON(!list_empty(&fc->devices)); kfree_rcu(fc, rcu); }
0
[ "CWE-459" ]
linux
5d069dbe8aaf2a197142558b6fb2978189ba3454
137,005,832,304,496,170,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,...
static unsigned char getledstate(void) { return ledstate & 0xff; }
0
[ "CWE-416" ]
linux
6ca03f90527e499dd5e32d6522909e2ad390896b
69,493,857,209,993,680,000,000,000,000,000,000,000
4
vt: keyboard, simplify vt_kdgkbsent Use 'strlen' of the string, add one for NUL terminator and simply do 'copy_to_user' instead of the explicit 'for' loop. This makes the KDGKBSENT case more compact. The only thing we need to take care about is NULL 'func_table[i]'. Use an empty string in that case. The original che...
void onAccept(ConnectionSocketPtr&& socket) override { Network::ConnectionPtr new_connection = dispatcher_.createServerConnection( std::move(socket), Network::Test::createRawBufferSocket(), stream_info_); TestDnsServerQuery* query = new TestDnsServerQuery(std::move(new_connection), hosts_a_, ...
0
[ "CWE-400" ]
envoy
542f84c66e9f6479bc31c6f53157c60472b25240
171,264,359,065,547,900,000,000,000,000,000,000,000
7
overload: Runtime configurable global connection limits (#147) Signed-off-by: Tony Allen <tony@allen.gg>
static int decode_nfs_fh(struct xdr_stream *xdr, struct nfs_fh *fh) { __be32 *p; p = xdr_inline_decode(xdr, 4); if (unlikely(!p)) return -ENOBUFS; fh->size = be32_to_cpup(p++); if (fh->size > sizeof(struct nfs_fh)) { printk(KERN_ERR "NFS flexfiles: Too big fh received %d\n", fh->size); return -EOVE...
1
[ "CWE-787" ]
linux
ed34695e15aba74f45247f1ee2cf7e09d449f925
234,844,035,562,921,140,000,000,000,000,000,000,000
22
pNFS/flexfiles: fix incorrect size check in decode_nfs_fh() We (adam zabrocki, alexander matrosov, alexander tereshkin, maksym bazalii) observed the check: if (fh->size > sizeof(struct nfs_fh)) should not use the size of the nfs_fh struct which includes an extra two bytes from the size field. struct nfs_fh { unsi...
static size_t drbg_test_cb(DRBG_CTX *ctx, unsigned char **pout, int entropy, size_t min_len, size_t max_len) { *pout = dummy_drbg_entropy; /* Round up to multiple of block size */ return (min_len + 0xf) & ~0xf; }
0
[]
openssl
200f249b8c3b6439e0200d01caadc24806f1a983
27,777,522,959,234,046,000,000,000,000,000,000,000
7
Remove Dual EC DRBG from FIPS module.
JSObject *create(JSContext *cx, HandleObject self, Mode mode, HandleObject owner, HandleObject init_headers) { RootedObject headers(cx, create(cx, self, mode, owner)); if (!headers) { return nullptr; } if (!init_headers) { return headers; } if (!delazify(cx, init_headers)) { r...
0
[ "CWE-94" ]
js-compute-runtime
65524ffc962644e9fc39f4b368a326b6253912a9
309,921,176,793,876,450,000,000,000,000,000,000,000
49
use rangom_get instead of arc4random as arc4random does not work correctly with wizer wizer causes the seed in arc4random to be the same between executions which is not random
required number of bytes is too large to store. */ static int yysyntax_error (YYSIZE_T *yymsg_alloc, char **yymsg, yytype_int16 *yyssp, int yytoken) { YYSIZE_T yysize0 = yytnamerr (YY_NULLPTR, yytname[yytoken]); YYSIZE_T yysize = yysize0; enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 }; /* Interna...
0
[ "CWE-674", "CWE-787" ]
yara
10e8bd3071677dd1fa76beeef4bc2fc427cea5e7
128,405,095,556,633,830,000,000,000,000,000,000,000
125
Fix issue #674 for hex strings.
static int contains_pending_extent(struct btrfs_transaction *transaction, struct btrfs_device *device, u64 *start, u64 len) { struct btrfs_fs_info *fs_info = device->fs_info; struct extent_map *em; struct list_head *search_list = &fs_info->pinned_chunks; int ret = 0; u64 physical_start = *start; if...
0
[ "CWE-476", "CWE-284" ]
linux
09ba3bc9dd150457c506e4661380a6183af651c1
65,741,934,293,787,720,000,000,000,000,000,000,000
53
btrfs: merge btrfs_find_device and find_device Both btrfs_find_device() and find_device() does the same thing except that the latter does not take the seed device onto account in the device scanning context. We can merge them. Signed-off-by: Anand Jain <anand.jain@oracle.com> Reviewed-by: David Sterba <dsterba@suse.c...
static __net_init int geneve_init_net(struct net *net) { struct geneve_net *gn = net_generic(net, geneve_net_id); INIT_LIST_HEAD(&gn->geneve_list); INIT_LIST_HEAD(&gn->sock_list); return 0; }
0
[]
net
6c8991f41546c3c472503dff1ea9daaddf9331c2
257,718,537,939,247,260,000,000,000,000,000,000,000
8
net: ipv6_stub: use ip6_dst_lookup_flow instead of ip6_dst_lookup ipv6_stub uses the ip6_dst_lookup function to allow other modules to perform IPv6 lookups. However, this function skips the XFRM layer entirely. All users of ipv6_stub->ip6_dst_lookup use ip_route_output_flow (via the ip_route_output_key and ip_route_o...
xsltWithParamComp(xsltStylesheetPtr style, xmlNodePtr inst) { #ifdef XSLT_REFACTORED xsltStyleItemWithParamPtr comp; #else xsltStylePreCompPtr comp; #endif if ((style == NULL) || (inst == NULL) || (inst->type != XML_ELEMENT_NODE)) return; #ifdef XSLT_REFACTORED comp = (xsltStyleItemWithParamPtr) xslt...
0
[]
libxslt
7ca19df892ca22d9314e95d59ce2abdeff46b617
185,432,135,485,579,900,000,000,000,000,000,000,000
49
Fix for type confusion in preprocessing attributes CVE-2015-7995 http://www.openwall.com/lists/oss-security/2015/10/27/10 We need to check that the parent node is an element before dereferencing its namespace
AcpiNsTerminate ( void) { ACPI_STATUS Status; ACPI_FUNCTION_TRACE (NsTerminate); #ifdef ACPI_EXEC_APP { ACPI_OPERAND_OBJECT *Prev; ACPI_OPERAND_OBJECT *Next; /* Delete any module-level code blocks */ Next = AcpiGbl_ModuleCodeList; while (...
1
[ "CWE-200", "CWE-755" ]
acpica
a23325b2e583556eae88ed3f764e457786bf4df6
123,194,258,670,730,330,000,000,000,000,000,000,000
47
Namespace: fix operand cache leak I found some ACPI operand cache leaks in ACPI early abort cases. Boot log of ACPI operand cache leak is as follows: >[ 0.174332] ACPI: Added _OSI(Module Device) >[ 0.175504] ACPI: Added _OSI(Processor Device) >[ 0.176010] ACPI: Added _OSI(3.0 _SCP Extensions) >[ 0.177032]...
SpoolssSetPrinter_r(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, dcerpc_info *di, guint8 *drep _U_) { /* Parse packet */ offset = dissect_doserror( tvb, offset, pinfo, tree, di, drep, hf_rc, NULL); return offset; }
0
[ "CWE-399" ]
wireshark
b4d16b4495b732888e12baf5b8a7e9bf2665e22b
54,883,110,978,979,000,000,000,000,000,000,000,000
10
SPOOLSS: Try to avoid an infinite loop. Use tvb_reported_length_remaining in dissect_spoolss_uint16uni. Make sure our offset always increments in dissect_spoolss_keybuffer. Change-Id: I7017c9685bb2fa27161d80a03b8fca4ef630e793 Reviewed-on: https://code.wireshark.org/review/14687 Reviewed-by: Gerald Combs <gerald@wires...
static rtnl_dumpit_func rtnl_get_dumpit(int protocol, int msgindex) { struct rtnl_link *tab; if (protocol <= RTNL_FAMILY_MAX) tab = rtnl_msg_handlers[protocol]; else tab = NULL; if (tab == NULL || tab[msgindex].dumpit == NULL) tab = rtnl_msg_handlers[PF_UNSPEC]; return tab[msgindex].dumpit; }
0
[ "CWE-399" ]
linux-2.6
84d73cd3fb142bf1298a8c13fd4ca50fd2432372
115,660,780,185,790,530,000,000,000,000,000,000,000
14
rtnl: fix info leak on RTM_GETLINK request for VF devices Initialize the mac address buffer with 0 as the driver specific function will probably not fill the whole buffer. In fact, all in-kernel drivers fill only ETH_ALEN of the MAX_ADDR_LEN bytes, i.e. 6 of the 32 possible bytes. Therefore we currently leak 26 bytes ...
PHP_METHOD(Phar, interceptFileFuncs) { if (zend_parse_parameters_none() == FAILURE) { return; } phar_intercept_functions(); }
0
[ "CWE-20" ]
php-src
1e9b175204e3286d64dfd6c9f09151c31b5e099a
18,473,666,796,638,108,000,000,000,000,000,000,000
7
Fix bug #71860: Require valid paths for phar filenames
int kill_proc_info(int sig, struct siginfo *info, pid_t pid) { int error; rcu_read_lock(); error = kill_pid_info(sig, info, find_vpid(pid)); rcu_read_unlock(); return error; }
0
[ "CWE-400" ]
linux-stable-rt
bcf6b1d78c0bde228929c388978ed3af9a623463
313,755,822,442,556,100,000,000,000,000,000,000,000
8
signal/x86: Delay calling signals in atomic On x86_64 we must disable preemption before we enable interrupts for stack faults, int3 and debugging, because the current task is using a per CPU debug stack defined by the IST. If we schedule out, another task can come in and use the same stack and cause the stack to be co...
njs_string_offset_map_init(const u_char *start, size_t size) { size_t offset; uint32_t *map; njs_uint_t n; const u_char *p, *end; end = start + size; map = njs_string_map_start(end); p = start; n = 0; offset = NJS_STRING_MAP_STRIDE; do { if (offset == 0)...
0
[]
njs
36f04a3178fcb6da8513cc3dbf35215c2a581b3f
184,958,559,898,998,160,000,000,000,000,000,000,000
26
Fixed String.prototype.replace() with byte strings. This closes #522 issue on Github.
MagickExport void XListBrowserWidget(Display *display,XWindows *windows, XWindowInfo *window_info,const char *const *list,const char *action, const char *query,char *reply) { #define CancelButtonText "Cancel" char primary_selection[MaxTextExtent]; int x; int i; static MagickStatusType m...
1
[]
ImageMagick6
5d33b8df73b0b1e40ee3fb7a334d28d929ae903c
287,874,593,989,167,600,000,000,000,000,000,000,000
873
https://github.com/ImageMagick/ImageMagick/issues/3336
void xwrite(int fd, const void *buf, size_t count) { if (count == 0) return; ssize_t size = full_write(fd, buf, count); if ((size_t)size != count) error_msg_and_die("short write"); }
0
[ "CWE-20" ]
libreport
1951e7282043dfe1268d492aea056b554baedb75
258,007,433,547,099,420,000,000,000,000,000,000,000
8
lib: fix races in dump directory handling code Florian Weimer <fweimer@redhat.com>: dd_opendir() should keep a file handle (opened with O_DIRECTORY) and use openat() and similar functions to access files in it. ... The file system manipulation functions should guard against hard links (check tha...
GF_Err trgr_AddBox(GF_Box *s, GF_Box *a) { GF_TrackGroupBox *ptr = (GF_TrackGroupBox *)s; return gf_list_add(ptr->groups, a); }
0
[ "CWE-125" ]
gpac
bceb03fd2be95097a7b409ea59914f332fb6bc86
117,188,230,859,629,860,000,000,000,000,000,000,000
5
fixed 2 possible heap overflows (inc. #1088)
job_error_callback(__unused struct bufferevent *bufev, __unused short events, void *data) { struct job *job = data; log_debug("job error %p: %s, pid %ld", job, job->cmd, (long) job->pid); if (job->state == JOB_DEAD) { if (job->completecb != NULL) job->completecb(job); job_free(job); } else { bufferev...
0
[]
src
b32e1d34e10a0da806823f57f02a4ae6e93d756e
11,642,209,408,126,088,000,000,000,000,000,000,000
16
evbuffer_new and bufferevent_new can both fail (when malloc fails) and return NULL. GitHub issue 1547.
BPF_CALL_2(bpf_skb_change_type, struct sk_buff *, skb, u32, pkt_type) { /* We only allow a restricted subset to be changed for now. */ if (unlikely(!skb_pkt_type_ok(skb->pkt_type) || !skb_pkt_type_ok(pkt_type))) return -EINVAL; skb->pkt_type = pkt_type; return 0; }
0
[ "CWE-120" ]
linux
050fad7c4534c13c8eb1d9c2ba66012e014773cb
264,670,807,804,275,600,000,000,000,000,000,000,000
10
bpf: fix truncated jump targets on heavy expansions Recently during testing, I ran into the following panic: [ 207.892422] Internal error: Accessing user space memory outside uaccess.h routines: 96000004 [#1] SMP [ 207.901637] Modules linked in: binfmt_misc [...] [ 207.966530] CPU: 45 PID: 2256 Comm: test_ve...
TEST_P(ConnectionLimitIntegrationTest, TestGlobalLimit) { std::function<void()> init_func = [this]() { // Includes twice the number of connections expected because the tracking is performed via a // static variable and the fake upstream has a listener. This causes upstream connections to the // fake upstr...
0
[ "CWE-400" ]
envoy
542f84c66e9f6479bc31c6f53157c60472b25240
143,751,784,458,976,160,000,000,000,000,000,000,000
11
overload: Runtime configurable global connection limits (#147) Signed-off-by: Tony Allen <tony@allen.gg>
void operator()(OpKernelContext* ctx, const CPUDevice& d, const T* rate_flat, int num_rate, int num_samples, const random::PhiloxRandom& rng, U* samples_flat) { // Two different algorithms are employed, depending on the size of // rate. // If rate < 10, we use an algori...
1
[ "CWE-703", "CWE-197" ]
tensorflow
ca8c013b5e97b1373b3bb1c97ea655e69f31a575
337,114,702,926,473,200,000,000,000,000,000,000,000
192
Prevent integer truncation from 64 to 32 bits. The `tensorflow::Shard` functions last argument must be a 2 argument function where both arguments are `int64` (`long long`, 64 bits). However, there are usages where code passes in a function where arguments are `int` or `int32` (32 bits). In these cases, it is possible ...
sound_beep (session *sess) { if (!prefs.hex_gui_focus_omitalerts || fe_gui_info (sess, 0) != 1) { if (sound_files[XP_TE_BEEP] && sound_files[XP_TE_BEEP][0]) /* user defined beep _file_ */ sound_play_event (XP_TE_BEEP); else /* system beep */ fe_beep (sess); } }
0
[ "CWE-22" ]
hexchat
15600f405f2d5bda6ccf0dd73957395716e0d4d3
117,574,604,058,579,880,000,000,000,000,000,000,000
12
Sanitize network name for scrollback files This prevents using invalid chars on Windows or creating directories
static NTSTATUS dcesrv_lsa_GetSystemAccessAccount(struct dcesrv_call_state *dce_call, TALLOC_CTX *mem_ctx, struct lsa_GetSystemAccessAccount *r) { struct dcesrv_handle *h; struct lsa_account_state *astate; int ret; unsigned int i; struct ldb_message **res; const char * const attrs[] = { "privilege", NULL...
0
[ "CWE-200" ]
samba
0a3aa5f908e351201dc9c4d4807b09ed9eedff77
108,603,657,705,041,620,000,000,000,000,000,000,000
48
CVE-2022-32746 ldb: Make use of functions for appending to an ldb_message This aims to minimise usage of the error-prone pattern of searching for a just-added message element in order to make modifications to it (and potentially finding the wrong element). BUG: https://bugzilla.samba.org/show_bug.cgi?id=15009 Signed...
Item *get_tmp_table_item(THD *thd) { return this; }
0
[ "CWE-617" ]
server
2e7891080667c59ac80f788eef4d59d447595772
284,640,536,481,520,440,000,000,000,000,000,000,000
1
MDEV-25635 Assertion failure when pushing from HAVING into WHERE of view This bug could manifest itself after pushing a where condition over a mergeable derived table / view / CTE DT into a grouping view / derived table / CTE V whose item list contained set functions with constant arguments such as MIN(2), SUM(1) etc....
static void mux_chr_close(struct CharDriverState *chr) { MuxDriver *d = chr->opaque; int i; for (i = 0; i < d->mux_cnt; i++) { CharBackend *be = d->backends[i]; if (be) { be->chr = NULL; } } qemu_chr_fe_deinit(&d->chr); g_free(d); }
0
[ "CWE-416" ]
qemu
a4afa548fc6dd9842ed86639b4d37d4d1c4ad480
326,170,672,193,103,000,000,000,000,000,000,000,000
14
char: move front end handlers in CharBackend Since the hanlders are associated with a CharBackend, rather than the CharDriverState, it is more appropriate to store in CharBackend. This avoids the handler copy dance in qemu_chr_fe_set_handlers() then mux_chr_update_read_handler(), by storing the CharBackend pointer dir...
keyeq(KEY s1, KEY s2) { for (; *s1 == *s2; s1++, s2++) if (*s1 == 0) return XML_TRUE; return XML_FALSE; }
0
[ "CWE-611", "CWE-776", "CWE-415", "CWE-125" ]
libexpat
c20b758c332d9a13afbbb276d30db1d183a85d43
131,018,603,172,967,160,000,000,000,000,000,000,000
6
xmlparse.c: Deny internal entities closing the doctype
int net_get(int s, void *arg, int *len) { struct net_hdr nh; int plen; if (net_read_exact(s, &nh, sizeof(nh)) == -1) { return -1; } plen = ntohl(nh.nh_len); if (!(plen <= *len)) printf("PLEN %d type %d len %d\n", plen, nh.nh_type, *len); assert(plen <= *len); /* XXX */ *len = plen; if ...
1
[ "CWE-20", "CWE-787" ]
aircrack-ng
88702a3ce4c28a973bf69023cd0312f412f6193e
146,071,634,568,105,060,000,000,000,000,000,000,000
24
OSdep: Fixed segmentation fault that happens with a malicious server sending a negative length (Closes #16 on GitHub). git-svn-id: http://svn.aircrack-ng.org/trunk@2419 28c6078b-6c39-48e3-add9-af49d547ecab
static ssize_t io_iov_buffer_select(struct io_kiocb *req, struct iovec *iov, unsigned int issue_flags) { if (req->flags & (REQ_F_BUFFER_SELECTED|REQ_F_BUFFER_RING)) { iov[0].iov_base = u64_to_user_ptr(req->rw.addr); iov[0].iov_len = req->rw.len; return 0; } if (req->rw.len != 1) return -EINVAL; #ifd...
0
[ "CWE-416" ]
linux
9cae36a094e7e9d6e5fe8b6dcd4642138b3eb0c7
334,297,024,915,472,400,000,000,000,000,000,000,000
18
io_uring: reinstate the inflight tracking After some debugging, it was realized that we really do still need the old inflight tracking for any file type that has io_uring_fops assigned. If we don't, then trivial circular references will mean that we never get the ctx cleaned up and hence it'll leak. Just bring back t...
TEST(EqOp, MatchesReferencedArrayValue) { BSONObj operand = BSON("a.0" << 5); EqualityMatchExpression eq; eq.init("a.0", operand["a.0"]).transitional_ignore(); ASSERT(eq.matchesBSON(BSON("a" << BSON_ARRAY(5)), NULL)); ASSERT(!eq.matchesBSON(BSON("a" << BSON_ARRAY(BSON_ARRAY(5))), NULL)); }
0
[]
mongo
b0ef26c639112b50648a02d969298650fbd402a4
29,725,215,746,077,240,000,000,000,000,000,000,000
7
SERVER-51083 Reject invalid UTF-8 from $regex match expressions
HTStream *HTMLPresent(HTPresentation *pres GCC_UNUSED, HTParentAnchor *anchor, HTStream *sink GCC_UNUSED) { CTRACE((tfp, "HTMLPresent calling CacheThru_new\n")); return CacheThru_new(anchor, SGML_new(&HTML_dtd, anchor, HTML_new(anchor, WWW_PRESENT, NULL))); }
0
[ "CWE-416" ]
lynx-snapshots
280a61b300a1614f6037efc0902ff7ecf17146e9
14,546,372,281,791,245,000,000,000,000,000,000,000
9
snapshot of project "lynx", label v2-8-9dev_15b
static int jpc_sot_putparms(jpc_ms_t *ms, jpc_cstate_t *cstate, jas_stream_t *out) { jpc_sot_t *sot = &ms->parms.sot; /* Eliminate compiler warning about unused variables. */ cstate = 0; if (jpc_putuint16(out, sot->tileno) || jpc_putuint32(out, sot->len) || jpc_putuint8(out, sot->partno) || jpc_putuint8(...
0
[]
jasper
4031ca321d8cb5798c316ab39c7a5dc88a61fdd7
177,398,706,416,807,330,000,000,000,000,000,000,000
15
Incorporated changes from patch jasper-1.900.3-libjasper-stepsizes-overflow.patch
void bandwidth_set(pid_t pid, const char *dev, int down, int up) { // create bandwidth directory & file in case they are not in the filesystem yet bandwidth_create_run_file(pid); // create the new text entry char *txt; if (asprintf(&txt, "%s: RX %dKB/s, TX %dKB/s", dev, down, up) == -1) errExit("asprintf"); ...
0
[ "CWE-284", "CWE-269" ]
firejail
5d43fdcd215203868d440ffc42036f5f5ffc89fc
173,562,209,543,087,880,000,000,000,000,000,000,000
32
security fix
ipv6_renew_options(struct sock *sk, struct ipv6_txoptions *opt, int newtype, struct ipv6_opt_hdr __user *newopt, int newoptlen) { int tot_len = 0; char *p; struct ipv6_txoptions *opt2; int err; if (opt) { if (newtype != IPV6_HOPOPTS && opt->hopopt) tot_len += CMSG_ALIGN(ipv6_optlen(opt->hopopt)); ...
0
[ "CWE-416", "CWE-284", "CWE-264" ]
linux
45f6fad84cc305103b28d73482b344d7f5b76f39
325,933,007,057,816,680,000,000,000,000,000,000,000
70
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...
spell_find_suggest( char_u *badptr, int badlen, // length of bad word or 0 if unknown suginfo_T *su, int maxcount, int banbadword, // don't include badword in suggestions int need_cap, // word should start with capital int interactive) { hlf_T attr = HLF_COUNT; char_u buf[MAXPA...
0
[ "CWE-457" ]
vim
15d9890eee53afc61eb0a03b878a19cb5672f732
73,524,206,464,143,475,000,000,000,000,000,000,000
131
patch 8.2.3582: reading uninitialized memory when giving spell suggestions Problem: Reading uninitialized memory when giving spell suggestions. Solution: Check that preword is not empty.
static void iwl_fw_dbg_stop_recording(struct iwl_trans *trans, struct iwl_fw_dbg_params *params) { if (trans->trans_cfg->device_family == IWL_DEVICE_FAMILY_7000) { iwl_set_bits_prph(trans, MON_BUFF_SAMPLE_CTL, 0x100); return; } if (params) { params->in_sample = iwl_read_umac_prph(trans, DBGC_IN_SAMP...
0
[ "CWE-400", "CWE-401" ]
linux
b4b814fec1a5a849383f7b3886b654a13abbda7d
104,170,509,733,732,070,000,000,000,000,000,000,000
20
iwlwifi: dbg_ini: fix memory leak in alloc_sgtable In alloc_sgtable if alloc_page fails, the alocated table should be released. Signed-off-by: Navid Emamdoost <navid.emamdoost@gmail.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
static int sh_set_reg_profile(RAnal* anal){ //TODO Add system ( ssr, spc ) + fpu regs const char *p = "=PC pc\n" "=SP r15\n" "=BP r14\n" "gpr r0 .32 0 0\n" "gpr r1 .32 4 0\n" "gpr r2 .32 8 0\n" "gpr r3 .32 12 0\n" "gpr r4 .32 16 0\n" "gpr r5 .32 20 0\n" "gpr r6 .32 24 0\n" "gpr r7 .32 2...
0
[ "CWE-125" ]
radare2
77c47cf873dd55b396da60baa2ca83bbd39e4add
263,543,051,968,831,040,000,000,000,000,000,000,000
30
Fix #9903 - oobread in RAnal.sh
gather_caller_stats (struct cgraph_node *node, void *data) { struct caller_statistics *stats = (struct caller_statistics *) data; struct cgraph_edge *cs; for (cs = node->callers; cs; cs = cs->next_caller) if (!cs->caller->thunk.thunk_p) { if (cs->count.ipa ().initialized_p ()) stats->count_s...
0
[ "CWE-20" ]
gcc
a09ccc22459c565814f79f96586fe4ad083fe4eb
94,018,386,627,640,510,000,000,000,000,000,000,000
18
Avoid segfault when doing IPA-VRP but not IPA-CP (PR 93015) 2019-12-21 Martin Jambor <mjambor@suse.cz> PR ipa/93015 * ipa-cp.c (ipcp_store_vr_results): Check that info exists testsuite/ * gcc.dg/lto/pr93015_0.c: New test. From-SVN: r279695
static inline int valid_irq_stack(unsigned long sp, struct task_struct *p, unsigned long nbytes) { unsigned long stack_page; unsigned long cpu = task_cpu(p); stack_page = (unsigned long)hardirq_ctx[cpu]; if (sp >= stack_page && sp <= stack_page + THREAD_SIZE - nbytes) return 1; stack_page = (unsigned lon...
0
[ "CWE-862" ]
linux
8205d5d98ef7f155de211f5e2eb6ca03d95a5a60
132,858,933,855,506,900,000,000,000,000,000,000,000
16
powerpc/tm: Fix FP/VMX unavailable exceptions inside a transaction When we take an FP unavailable exception in a transaction we have to account for the hardware FP TM checkpointed registers being incorrect. In this case for this process we know the current and checkpointed FP registers must be the same (since FP wasn'...
static int strbuf_set_helper_option(struct helper_data *data, struct strbuf *buf) { int ret; sendline(data, buf); if (recvline(data, buf)) exit(128); if (!strcmp(buf->buf, "ok")) ret = 0; else if (starts_with(buf->buf, "error")) ret = -1; else if (!strcmp(buf->buf, "unsupported")) ret = 1; else...
0
[]
git
68061e3470210703cb15594194718d35094afdc0
140,017,714,512,484,110,000,000,000,000,000,000,000
21
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)...
**/ CImg<T> rotate(const float u, const float v, const float w, const float angle, const unsigned int interpolation, const unsigned int boundary_conditions) { const float nangle = cimg::mod(angle,360.f); if (nangle==0.f) return *this; return get_rotate(u,v,w,nangle,interpola...
0
[ "CWE-119", "CWE-787" ]
CImg
ac8003393569aba51048c9d67e1491559877b1d1
61,167,972,050,753,160,000,000,000,000,000,000,000
6
.
static Image *ReadRLEImage(const ImageInfo *image_info,ExceptionInfo *exception) { #define SkipLinesOp 0x01 #define SetColorOp 0x02 #define SkipPixelsOp 0x03 #define ByteDataOp 0x05 #define RunDataOp 0x06 #define EOFOp 0x07 char magick[12]; Image *image; int opcode, operand, status; ...
0
[ "CWE-119", "CWE-787" ]
ImageMagick
13db820f5e24cd993ee554e99377fea02a904e18
144,888,274,910,804,650,000,000,000,000,000,000,000
531
https://www.imagemagick.org/discourse-server/viewtopic.php?f=3&t=29710
ExprCreateInteger(int ival) { EXPR_CREATE(ExprInteger, expr, EXPR_VALUE, EXPR_TYPE_INT); expr->integer.ival = ival; return expr; }
0
[ "CWE-476" ]
libxkbcommon
e3cacae7b1bfda0d839c280494f23284a1187adf
200,954,614,453,612,040,000,000,000,000,000,000,000
6
xkbcomp: fix crashes in the parser when geometry tokens appear In the XKB format, floats and various keywords can only be used in the xkb_geometry section. xkbcommon removed support xkb_geometry, but still parses it for backward compatibility. As part of ignoring it, the float AST node and various keywords were remove...
IMkvReader::~IMkvReader() {}
1
[ "CWE-20" ]
libvpx
f00890eecdf8365ea125ac16769a83aa6b68792d
139,681,663,261,269,870,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
png_compare_ICC_profile_with_sRGB(png_const_structrp png_ptr, png_const_bytep profile, uLong adler) { /* The quick check is to verify just the MD5 signature and trust the * rest of the data. Because the profile has already been verified for * correctness this is safe. png_colorspace_set_sRGB will check...
0
[ "CWE-476" ]
libpng
812768d7a9c973452222d454634496b25ed415eb
188,068,955,697,814,140,000,000,000,000,000,000,000
119
[libpng16] Fixed a potential null pointer dereference in png_set_text_2() (bug report and patch by Patrick Keshishian).
static void add_tracer_options(struct trace_array *tr, struct tracer *t) { /* Only enable if the directory has been created already. */ if (!tr->dir) return; create_trace_option_files(tr, t); }
0
[ "CWE-415" ]
linux
4397f04575c44e1440ec2e49b6302785c95fd2f8
301,768,794,101,988,200,000,000,000,000,000,000,000
8
tracing: Fix possible double free on failure of allocating trace buffer Jing Xia and Chunyan Zhang reported that on failing to allocate part of the tracing buffer, memory is freed, but the pointers that point to them are not initialized back to NULL, and later paths may try to free the freed memory again. Jing and Chu...
int mingw_mkdir(const char *path, int mode) { int ret; wchar_t wpath[MAX_PATH]; if (!is_valid_win32_path(path)) { errno = EINVAL; return -1; } if (xutftowcs_path(wpath, path) < 0) return -1; ret = _wmkdir(wpath); if (!ret && needs_hiding(path)) return set_hidden_flag(wpath, 1); return ret; }
0
[ "CWE-706" ]
git
f82a97eb9197c1e3768e72648f37ce0ca3233734
140,949,846,935,260,640,000,000,000,000,000,000,000
17
mingw: handle `subst`-ed "DOS drives" Over a decade ago, in 25fe217b86c (Windows: Treat Windows style path names., 2008-03-05), Git was taught to handle absolute Windows paths, i.e. paths that start with a drive letter and a colon. Unbeknownst to us, while drive letters of physical drives are limited to letters of th...
R_API ut64 r_bin_get_boffset(RBin *bin) { RBinObject *o = r_bin_cur_object (bin); return o? o->boffset: UT64_MAX; }
0
[ "CWE-125" ]
radare2
d31c4d3cbdbe01ea3ded16a584de94149ecd31d9
136,817,469,724,102,000,000,000,000,000,000,000,000
4
Fix #8748 - Fix oobread on string search
static int raw_sendmsg(struct sock *sk, struct msghdr *msg, size_t size) { struct net_device *dev; unsigned int mtu; struct sk_buff *skb; int hlen, tlen; int err; if (msg->msg_flags & MSG_OOB) { pr_debug("msg->msg_flags = 0x%x\n", msg->msg_flags); return -EOPNOTSUPP; } lock_sock(sk); if (!sk->sk_bound_de...
0
[ "CWE-276" ]
linux
e69dbd4619e7674c1679cba49afd9dd9ac347eef
181,880,864,261,521,840,000,000,000,000,000,000,000
69
ieee802154: enforce CAP_NET_RAW for raw sockets When creating a raw AF_IEEE802154 socket, CAP_NET_RAW needs to be checked first. Signed-off-by: Ori Nimron <orinimron123@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Acked-by: Stefan Schmidt <stefan@datenfreihafen.org> Signed-off-by: David S...
static int rm_from_queue(unsigned long mask, struct sigpending *s) { struct sigqueue *q, *n; if (!sigtestsetmask(&s->signal, mask)) return 0; sigdelsetmask(&s->signal, mask); list_for_each_entry_safe(q, n, &s->list, list) { if (q->info.si_signo < SIGRTMIN && (mask & sigmask(q->info.si_signo))) { list...
0
[]
linux-2.6
0083fc2c50e6c5127c2802ad323adf8143ab7856
100,111,120,052,845,170,000,000,000,000,000,000,000
17
do_sigaltstack: avoid copying 'stack_t' as a structure to user space Ulrich Drepper correctly points out that there is generally padding in the structure on 64-bit hosts, and that copying the structure from kernel to user space can leak information from the kernel stack in those padding bytes. Avoid the whole issue b...
mz_bool mz_zip_reader_is_file_a_directory(mz_zip_archive *pZip, mz_uint file_index) { mz_uint filename_len, external_attr; const mz_uint8 *p = mz_zip_reader_get_cdh(pZip, file_index); if (!p) return MZ_FALSE; // First see if the filename ends with a '/' character. fi...
0
[ "CWE-20", "CWE-190" ]
tinyexr
a685e3332f61cd4e59324bf3f669d36973d64270
78,630,516,196,195,270,000,000,000,000,000,000,000
24
Make line_no with too large value(2**20) invalid. Fixes #124
dissect_iur_dsch_channel_info(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, int offset, struct fp_info *p_fp_info) { gboolean is_control_frame; /* Header CRC */ proto_tree_add_item(tree, hf_fp_header_crc, tvb, offset, 1, ENC_BIG_ENDIAN); /* Frame Type */ is_con...
0
[ "CWE-20" ]
wireshark
7d7190695ce2ff269fdffb04e87139995cde21f4
334,617,325,416,666,620,000,000,000,000,000,000,000
22
UMTS_FP: fix handling reserved C/T value The spec puts the reserved value at 0xf but our internal table has 'unknown' at 0; since all the other values seem to be offset-by-one, just take the modulus 0xf to avoid running off the end of the table. Bug: 12191 Change-Id: I83c8fb66797bbdee52a2246fb1eea6e37cbc7eb0 Reviewed...
static void __iov_iter_advance_iov(struct iov_iter *i, size_t bytes) { if (likely(i->nr_segs == 1)) { i->iov_offset += bytes; } else { const struct iovec *iov = i->iov; size_t base = i->iov_offset; /* * The !iov->iov_len check ensures we skip over unlikely * zero-length segments. */ while (bytes |...
0
[ "CWE-20" ]
linux
124d3b7041f9a0ca7c43a6293e1cae4576c32fd5
253,123,264,246,260,900,000,000,000,000,000,000,000
26
fix writev regression: pan hanging unkillable and un-straceable Frederik Himpe reported an unkillable and un-straceable pan process. Zero length iovecs can go into an infinite loop in writev, because the iovec iterator does not always advance over them. The sequence required to trigger this is not trivial. I think i...
static int mongo_cursor_bson_valid( mongo_cursor *cursor, const bson *bson ) { if( ! bson->finished ) { cursor->err = MONGO_CURSOR_BSON_ERROR; cursor->conn->err = MONGO_BSON_NOT_FINISHED; return MONGO_ERROR; } if( bson->err & BSON_NOT_UTF8 ) { cursor->err = MONGO_CURSOR_BSON...
0
[ "CWE-190" ]
mongo-c-driver-legacy
1a1f5e26a4309480d88598913f9eebf9e9cba8ca
213,474,429,259,228,220,000,000,000,000,000,000,000
15
don't mix up int and size_t (first pass to fix that)
static void sctp_sock_migrate(struct sock *oldsk, struct sock *newsk, struct sctp_association *assoc, enum sctp_socket_type type) { struct sctp_sock *oldsp = sctp_sk(oldsk); struct sctp_sock *newsp = sctp_sk(newsk); struct sctp_bind_bucket *pp; /* hash list port iterator */ struct sctp_endpoint *n...
0
[ "CWE-416" ]
linux
a0ff660058b88d12625a783ce9e5c1371c87951f
98,163,000,462,450,530,000,000,000,000,000,000,000
130
sctp: return error if the asoc has been peeled off in sctp_wait_for_sndbuf After commit cea0cc80a677 ("sctp: use the right sk after waking up from wait_buf sleep"), it may change to lock another sk if the asoc has been peeled off in sctp_wait_for_sndbuf. However, the asoc's new sk could be already closed elsewhere, a...
int CMS_verify(CMS_ContentInfo *cms, STACK_OF(X509) *certs, X509_STORE *store, BIO *dcont, BIO *out, unsigned int flags) { CMS_SignerInfo *si; STACK_OF(CMS_SignerInfo) *sinfos; STACK_OF(X509) *cms_certs = NULL; STACK_OF(X509_CRL) *crls = NULL; X509 *signer; int i, scount = 0, ret ...
0
[ "CWE-399" ]
openssl
dd90a91d8771fd1ad5083fd46a2b3da16a587757
7,029,807,210,039,591,000,000,000,000,000,000,000
116
Fix infinite loop in CMS Fix loop in do_free_upto if cmsbio is NULL: this will happen when attempting to verify and a digest is not recognised. Reported by Johannes Bauer. CVE-2015-1792 Reviewed-by: Matt Caswell <matt@openssl.org>
static bool nested_vmx_exit_handled_cr(struct kvm_vcpu *vcpu, struct vmcs12 *vmcs12) { unsigned long exit_qualification = vmcs_readl(EXIT_QUALIFICATION); int cr = exit_qualification & 15; int reg = (exit_qualification >> 8) & 15; unsigned long val = kvm_register_readl(vcpu, reg); switch ((exit_qualification >> 4...
0
[ "CWE-284", "CWE-264" ]
linux
3ce424e45411cf5a13105e0386b6ecf6eeb4f66f
97,045,798,639,338,910,000,000,000,000,000,000,000
75
kvm:vmx: more complete state update on APICv on/off The function to update APICv on/off state (in particular, to deactivate it when enabling Hyper-V SynIC) is incomplete: it doesn't adjust APICv-related fields among secondary processor-based VM-execution controls. As a result, Windows 2012 guests get stuck when SynIC...
flatpak_context_merge (FlatpakContext *context, FlatpakContext *other) { GHashTableIter iter; gpointer key, value; context->shares &= ~other->shares_valid; context->shares |= other->shares; context->shares_valid |= other->shares_valid; context->sockets &= ~other->sockets_valid; con...
0
[ "CWE-94", "CWE-74" ]
flatpak
6e5ae7a109cdfa9735ea7ccbd8cb79f9e8d3ae8b
79,472,679,980,228,130,000,000,000,000,000,000,000
53
context: Add --env-fd option This allows environment variables to be added to the context without making their values visible to processes running under a different uid, which might be significant if the variable's value is a token or some other secret value. Signed-off-by: Simon McVittie <smcv@collabora.com> Part-of...
hivex_node_get_child (hive_h *h, hive_node_h node, const char *nname) { hive_node_h *children = NULL; char *name = NULL; hive_node_h ret = 0; children = hivex_node_children (h, node); if (!children) goto error; size_t i; for (i = 0; children[i] != 0; ++i) { name = hivex_node_name (h, children[i]); ...
0
[ "CWE-400" ]
hivex
771728218dac2fbf6997a7e53225e75a4c6b7255
158,121,612,847,386,520,000,000,000,000,000,000,000
25
lib/node.c: Limit recursion in ri-records (CVE-2021-3622) Windows Registry hive "ri"-records are arbitrarily nested B-tree-like structures: +-------------+ | ri | |-------------| | nr_offsets | | offset[0] ------> points to another lf/lh/li/ri block | offset[1] ------> | offset[2] -----...
EntityAuth() : auid(CEPH_AUTH_UID_DEFAULT) {}
0
[ "CWE-287", "CWE-284" ]
ceph
5ead97120e07054d80623dada90a5cc764c28468
85,474,121,270,523,600,000,000,000,000,000,000,000
1
auth/cephx: add authorizer challenge Allow the accepting side of a connection to reject an initial authorizer with a random challenge. The connecting side then has to respond with an updated authorizer proving they are able to decrypt the service's challenge and that the new authorizer was produced for this specific ...
TfLiteStatus SelectPrepare(TfLiteContext* context, TfLiteNode* node) { OpData* data = reinterpret_cast<OpData*>(node->user_data); TF_LITE_ENSURE_EQ(context, NumInputs(node), 3); TF_LITE_ENSURE_EQ(context, NumOutputs(node), 1); const TfLiteTensor* input_condition; TF_LITE_ENSURE_OK(context, GetInputSafe(cont...
0
[ "CWE-125", "CWE-787" ]
tensorflow
1970c2158b1ffa416d159d03c3370b9a462aee35
309,763,385,461,784,300,000,000,000,000,000,000,000
60
[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...
isoent_cmp_node_joliet(const struct archive_rb_node *n1, const struct archive_rb_node *n2) { const struct idrent *e1 = (const struct idrent *)n1; const struct idrent *e2 = (const struct idrent *)n2; return (isoent_cmp_joliet_identifier(e2->isoent, e1->isoent)); }
0
[ "CWE-190" ]
libarchive
3014e19820ea53c15c90f9d447ca3e668a0b76c6
302,732,549,204,087,270,000,000,000,000,000,000,000
8
Issue 711: Be more careful about verifying filename lengths when writing ISO9660 archives * Don't cast size_t to int, since this can lead to overflow on machines where sizeof(int) < sizeof(size_t) * Check a + b > limit by writing it as a > limit || b > limit || a + b > limit to avoid problems when a + b wraps...
static s32 gf_hevc_read_sps_bs_internal(GF_BitStream *bs, HEVCState *hevc, u8 layer_id, u32 *vui_flag_pos) { s32 vps_id, sps_id = -1; u32 i, nb_CTUs, depth; HEVC_SPS *sps; HEVC_VPS *vps; HEVC_ProfileTierLevel ptl; Bool multiLayerExtSpsFlag; u8 sps_ext_or_max_sub_layers_minus1, max_sub_layers_minus1; if (vui_fl...
0
[ "CWE-190", "CWE-787" ]
gpac
51cdb67ff7c5f1242ac58c5aa603ceaf1793b788
15,313,457,567,266,000,000,000,000,000,000,000,000
270
add safety in avc/hevc/vvc sps/pps/vps ID check - cf #1720 #1721 #1722
static inline int show_tags(WriterContext *w, AVDictionary *tags, int section_id) { AVDictionaryEntry *tag = NULL; int ret = 0; if (!tags) return 0; writer_print_section_header(w, section_id); while ((tag = av_dict_get(tags, "", tag, AV_DICT_IGNORE_SUFFIX))) { if ((ret = print_str_...
0
[ "CWE-476" ]
FFmpeg
837cb4325b712ff1aab531bf41668933f61d75d2
266,919,162,271,879,200,000,000,000,000,000,000,000
17
ffprobe: Fix null pointer dereference with color primaries Found-by: AD-lab of venustech Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
static int get_npt_level(void) { #ifdef CONFIG_X86_64 return pgtable_l5_enabled() ? PT64_ROOT_5LEVEL : PT64_ROOT_4LEVEL; #else return PT32E_ROOT_LEVEL; #endif }
0
[ "CWE-703" ]
linux
6cd88243c7e03845a450795e134b488fc2afb736
320,635,529,088,764,400,000,000,000,000,000,000,000
8
KVM: x86: do not report a vCPU as preempted outside instruction boundaries If a vCPU is outside guest mode and is scheduled out, it might be in the process of making a memory access. A problem occurs if another vCPU uses the PV TLB flush feature during the period when the vCPU is scheduled out, and a virtual address ...
static void tfilter_put(struct tcf_proto *tp, void *fh) { if (tp->ops->put && fh) tp->ops->put(tp, fh); }
0
[ "CWE-416" ]
linux
04c2a47ffb13c29778e2a14e414ad4cb5a5db4b5
30,631,568,158,294,997,000,000,000,000,000,000,000
5
net: sched: fix use-after-free in tc_new_tfilter() Whenever tc_new_tfilter() jumps back to replay: label, we need to make sure @q and @chain local variables are cleared again, or risk use-after-free as in [1] For consistency, apply the same fix in tc_ctl_chain() BUG: KASAN: use-after-free in mini_qdisc_pair_swap+0x1...
_write_path_table(struct archive_write *a, int type_m, int depth, struct vdd *vdd) { unsigned char *bp, *wb; struct isoent **ptbl; size_t wbremaining; int i, r, wsize; if (vdd->pathtbl[depth].cnt == 0) return (0); wsize = 0; wb = wb_buffptr(a); wbremaining = wb_remaining(a); bp = wb - 1; ptbl = vdd->p...
0
[ "CWE-190" ]
libarchive
3014e19820ea53c15c90f9d447ca3e668a0b76c6
143,168,824,535,391,930,000,000,000,000,000,000,000
67
Issue 711: Be more careful about verifying filename lengths when writing ISO9660 archives * Don't cast size_t to int, since this can lead to overflow on machines where sizeof(int) < sizeof(size_t) * Check a + b > limit by writing it as a > limit || b > limit || a + b > limit to avoid problems when a + b wraps...
void ExpressionMap::_doAddDependencies(DepsTracker* deps) const { _input->addDependencies(deps); _each->addDependencies(deps); }
0
[ "CWE-835" ]
mongo
0a076417d1d7fba3632b73349a1fd29a83e68816
52,380,106,475,265,800,000,000,000,000,000,000,000
4
SERVER-38070 fix infinite loop in agg expression
static inline int copy_to_user_policy_type(u8 type, struct sk_buff *skb) { return 0; }
0
[ "CWE-264" ]
net
90f62cf30a78721641e08737bda787552428061e
287,281,317,591,695,640,000,000,000,000,000,000,000
4
net: Use netlink_ns_capable to verify the permisions of netlink messages It is possible by passing a netlink socket to a more privileged executable and then to fool that executable into writing to the socket data that happens to be valid netlink message to do something that privileged executable did not intend to do. ...
static void recursive_help(RCore *core, int detail, const char *cmd_prefix) { const ut8 *p; RCmdDescriptor *desc = &core->root_cmd_descriptor; for (p = (const ut8 *)cmd_prefix; *p && *p < R_ARRAY_SIZE (desc->sub); p++) { if (!(desc = desc->sub[*p])) { return; } } recursive_help_go (core, detail, desc); }
0
[ "CWE-78" ]
radare2
dd739f5a45b3af3d1f65f00fe19af1dbfec7aea7
75,983,815,158,188,110,000,000,000,000,000,000,000
10
Fix #14990 - multiple quoted command parsing issue ##core > "?e hello""?e world" hello world" > "?e hello";"?e world" hello world
static void initAppData(AppData* data) { data->shareDesktop=TRUE; data->viewOnly=FALSE; #ifdef LIBVNCSERVER_CONFIG_LIBVA data->encodingsString="h264 tight zrle ultra copyrect hextile zlib corre rre raw"; #else data->encodingsString="tight zrle ultra copyrect hextile zlib corre rre raw"; #endif data->useBGR233=FALS...
0
[ "CWE-189" ]
libvncserver
045a044e8ae79db9244593fbce154cdf6e843273
108,506,004,485,272,000,000,000,000,000,000,000,000
22
Fix integer overflow in MallocFrameBuffer() Promote integers to uint64_t to avoid integer overflow issue during frame buffer allocation for very large screen sizes
my_off_t get_prev_position() { return(before_stmt_pos); }
0
[ "CWE-264" ]
mysql-server
48bd8b16fe382be302c6f0b45931be5aa6f29a0e
12,463,690,117,454,188,000,000,000,000,000,000,000
4
Bug#24388753: PRIVILEGE ESCALATION USING MYSQLD_SAFE [This is the 5.5/5.6 version of the bugfix]. The problem was that it was possible to write log files ending in .ini/.cnf that later could be parsed as an options file. This made it possible for users to specify startup options without the permissions to do so. Thi...
void sax_node_start(void *sax_cbck, const char *node_name, const char *name_space, const GF_XMLAttribute *attributes, u32 nb_attributes) { char szCheck[100]; GF_List *imports = sax_cbck; u32 i=0; /*do not process hyperlinks*/ if (!strcmp(node_name, "a") || !strcmp(node_name, "Anchor")) return; for (i=0; i<nb_at...
0
[ "CWE-787" ]
gpac
da37ec8582266983d0ec4b7550ec907401ec441e
41,322,969,650,792,786,000,000,000,000,000,000,000
19
fixed crashes for very long path - cf #1908
Status EncodePyBytesArray(PyArrayObject* array, tensorflow::int64 nelems, size_t* size, void** buffer) { // Encode all strings. *size = nelems * sizeof(tensorflow::tstring); std::unique_ptr<tensorflow::tstring[]> base_ptr( new tensorflow::tstring[nelems]); tensorflow::tstring* ds...
0
[ "CWE-476", "CWE-843" ]
tensorflow
030af767d357d1b4088c4a25c72cb3906abac489
185,399,263,651,554,760,000,000,000,000,000,000,000
16
Fix `tf.raw_ops.ResourceCountUpTo` null pointer dereference. PiperOrigin-RevId: 368294347 Change-Id: I2c16fbfc9b4966c402c3d8e311f0d665a9c852d8
Opal::Call::emit_retrieved_in_main () { retrieved (); }
0
[]
ekiga
7d09807257963a4f5168a01aec1795a398746372
19,404,424,079,627,647,000,000,000,000,000,000,000
4
Validate UTF-8 strings before showing them Closes bug #653009.
xmlXPathIsInf(double val) { #ifdef isinf return isinf(val) ? (val > 0 ? 1 : -1) : 0; #else if (val >= INFINITY) return 1; if (val <= -INFINITY) return -1; return 0; #endif }
0
[ "CWE-476" ]
libxml2
a436374994c47b12d5de1b8b1d191a098fa23594
259,377,707,220,564,700,000,000,000,000,000,000,000
11
Fix nullptr deref with XPath logic ops If the XPath stack is corrupted, for example by a misbehaving extension function, the "and" and "or" XPath operators could dereference NULL pointers. Check that the XPath stack isn't empty and optimize the logic operators slightly. Closes: https://gitlab.gnome.org/GNOME/libxml2/...
e_ews_connection_get_password_expiration_sync (EEwsConnection *cnc, gint pri, const gchar *mail_id, gchar **exp_date, GCancellable *...
0
[ "CWE-295" ]
evolution-ews
915226eca9454b8b3e5adb6f2fff9698451778de
295,096,265,268,458,350,000,000,000,000,000,000,000
29
I#27 - SSL Certificates are not validated This depends on https://gitlab.gnome.org/GNOME/evolution-data-server/commit/6672b8236139bd6ef41ecb915f4c72e2a052dba5 too. Closes https://gitlab.gnome.org/GNOME/evolution-ews/issues/27
static int check_subprogs(struct bpf_verifier_env *env) { int i, ret, subprog_start, subprog_end, off, cur_subprog = 0; struct bpf_subprog_info *subprog = env->subprog_info; struct bpf_insn *insn = env->prog->insnsi; int insn_cnt = env->prog->len; /* Add entry function. */ ret = add_subprog(env, 0); if (ret < 0...
0
[]
linux
9b00f1b78809309163dda2d044d9e94a3c0248a3
283,184,901,579,825,200,000,000,000,000,000,000,000
78
bpf: Fix truncation handling for mod32 dst reg wrt zero Recently noticed that when mod32 with a known src reg of 0 is performed, then the dst register is 32-bit truncated in verifier: 0: R1=ctx(id=0,off=0,imm=0) R10=fp0 0: (b7) r0 = 0 1: R0_w=inv0 R1=ctx(id=0,off=0,imm=0) R10=fp0 1: (b7) r1 = -1 2: R0_w=inv...
R_API void r_core_fini(RCore *c) { if (!c) { return; } r_core_task_break_all (&c->tasks); r_core_task_join (&c->tasks, NULL, -1); r_core_wait (c); /* TODO: it leaks as shit */ //update_sdb (c); // avoid double free r_list_free (c->ropchain); r_event_free (c->ev); free (c->cmdlog); free (c->lastsearch); R...
1
[ "CWE-415", "CWE-703" ]
radare2
cb8b683758edddae2d2f62e8e63a738c39f92683
307,897,061,826,018,150,000,000,000,000,000,000,000
63
Fix #16303 - c->table_query double free (#16318)
MagickExport void GetDrawInfo(const ImageInfo *image_info,DrawInfo *draw_info) { char *next_token; const char *option; ExceptionInfo *exception; ImageInfo *clone_info; /* Initialize draw attributes. */ (void) LogMagickEvent(TraceEvent,GetMagickModule(),"..."); assert(draw_info !=...
0
[]
ImageMagick
f4cdb3f3aab28273960ffacf1d356312b56ffd27
156,590,847,109,108,880,000,000,000,000,000,000,000
112
https://github.com/ImageMagick/ImageMagick/issues/3338
static int alarmtimer_resume(struct device *dev) { return 0; }
0
[ "CWE-190" ]
linux
5f936e19cc0ef97dbe3a56e9498922ad5ba1edef
308,021,996,182,078,750,000,000,000,000,000,000,000
4
alarmtimer: Prevent overflow for relative nanosleep Air Icy reported: UBSAN: Undefined behaviour in kernel/time/alarmtimer.c:811:7 signed integer overflow: 1529859276030040771 + 9223372036854775807 cannot be represented in type 'long long int' Call Trace: alarm_timer_nsleep+0x44c/0x510 kernel/time/alarmtim...
TEST_F(ExprMatchTest, InitialCollationUsedForComparisons) { auto collator = stdx::make_unique<CollatorInterfaceMock>(CollatorInterfaceMock::MockType::kToLowerString); setCollator(collator.get()); createMatcher(fromjson("{$expr: {$eq: ['$x', 'abc']}}")); ASSERT_TRUE(matches(BSON("x" ...
0
[]
mongo
ee97c0699fd55b498310996ee002328e533681a3
310,546,293,858,985,700,000,000,000,000,000,000,000
12
SERVER-36993 Fix crash due to incorrect $or pushdown for indexed $expr.
mode_out(struct cpio *cpio) { struct archive_entry *entry, *spare; struct lafe_line_reader *lr; const char *p; int r; if (cpio->option_append) lafe_errc(1, 0, "Append mode not yet supported."); cpio->archive_read_disk = archive_read_disk_new(); if (cpio->archive_read_disk == NULL) lafe_errc(1, 0, "Failed t...
0
[ "CWE-703", "CWE-22" ]
libarchive
59357157706d47c365b2227739e17daba3607526
242,625,995,709,904,570,000,000,000,000,000,000,000
124
Add ARCHIVE_EXTRACT_SECURE_NOABSOLUTEPATHS option This fixes a directory traversal in the cpio tool.