func string | target int64 | cwe list | project string | commit_id string | hash float64 | size int64 | message string |
|---|---|---|---|---|---|---|---|
headersWithUnderscoresAction() const override {
return headers_with_underscores_action_;
} | 0 | [
"CWE-400"
] | envoy | 0e49a495826ea9e29134c1bd54fdeb31a034f40c | 170,124,882,613,680,470,000,000,000,000,000,000,000 | 3 | http/2: add stats and stream flush timeout (#139)
This commit adds a new stream flush timeout to guard against a
remote server that does not open window once an entire stream has
been buffered for flushing. Additional stats have also been added
to better understand the codecs view of active streams as well as
amount o... |
static int mplsip_rcv(struct sk_buff *skb)
{
return sit_tunnel_rcv(skb, IPPROTO_MPLS);
} | 0 | [
"CWE-703",
"CWE-772",
"CWE-401"
] | linux | 07f12b26e21ab359261bf75cfcb424fdc7daeb6d | 116,428,408,152,350,080,000,000,000,000,000,000,000 | 4 | net: sit: fix memory leak in sit_init_net()
If register_netdev() is failed to register sitn->fb_tunnel_dev,
it will go to err_reg_dev and forget to free netdev(sitn->fb_tunnel_dev).
BUG: memory leak
unreferenced object 0xffff888378daad00 (size 512):
comm "syz-executor.1", pid 4006, jiffies 4295121142 (age 16.115s)
... |
static int mb86a20s_get_blk_error_layer_CNR(struct dvb_frontend *fe)
{
struct mb86a20s_state *state = fe->demodulator_priv;
struct dtv_frontend_properties *c = &fe->dtv_property_cache;
u32 mer, cnr;
int rc, val, layer;
const struct linear_segments *segs;
unsigned segs_len;
dev_dbg(&state->i2c->dev, "%s called.\... | 0 | [
"CWE-119"
] | media_tree | eca2d34b9d2ce70165a50510659838e28ca22742 | 176,984,515,018,826,100,000,000,000,000,000,000,000 | 101 | [media] mb86a20s: apply mask to val after checking for read failure
Appling the mask 0x0f to the immediate return of the call to
mb86a20s_readreg will always result in a positive value, meaning that the
check of ret < 0 will never work. Instead, check for a -ve return value
first, and then mask val with 0x0f.
Kudos ... |
pid_t require_pid(const char *name) {
pid_t pid;
if (read_pid(name,&pid)) {
fprintf(stderr, "Error: cannot find sandbox %s\n", name);
exit(1);
}
return pid;
} | 0 | [
"CWE-269",
"CWE-94"
] | firejail | 27cde3d7d1e4e16d4190932347c7151dc2a84c50 | 10,891,303,796,693,523,000,000,000,000,000,000,000 | 8 | fixing CVE-2022-31214 |
do_mount_syscall (struct mountargs *args) {
int flags = args->flags;
if ((flags & MS_MGC_MSK) == 0)
flags |= MS_MGC_VAL;
if (verbose > 2)
printf("mount: mount(2) syscall: source: \"%s\", target: \"%s\", "
"filesystemtype: \"%s\", mountflags: %d, data: %s\n",
args->spec, args->node, args->type, flags, (ch... | 0 | [
"CWE-200"
] | util-linux | 0377ef91270d06592a0d4dd009c29e7b1ff9c9b8 | 179,839,929,122,445,800,000,000,000,000,000,000,000 | 13 | mount: (deprecated) drop --guess-fstype
The option is undocumented and unnecessary.
Signed-off-by: Karel Zak <kzak@redhat.com> |
server_away_find_message (server *serv, char *nick)
{
struct away_msg *away;
GSList *list = away_list;
while (list)
{
away = (struct away_msg *) list->data;
if (away->server == serv && !serv->p_cmp (nick, away->nick))
return away;
list = list->next;
}
return NULL;
} | 0 | [
"CWE-310"
] | hexchat | c9b63f7f9be01692b03fa15275135a4910a7e02d | 113,506,985,634,873,300,000,000,000,000,000,000,000 | 13 | ssl: Validate hostnames
Closes #524 |
static cache_img_t *read_cache_images(RzBuffer *cache_buf, cache_hdr_t *hdr, ut64 hdr_offset) {
if (!cache_buf || !hdr) {
return NULL;
}
if (!hdr->imagesCount || !hdr->imagesOffset || hdr->imagesOffset == UT32_MAX || hdr->imagesCount == UT32_MAX) {
return NULL;
}
ut64 size = sizeof(cache_img_t) * hdr->imagesC... | 0 | [
"CWE-787"
] | rizin | 556ca2f9eef01ec0f4a76d1fbacfcf3a87a44810 | 247,392,514,212,140,260,000,000,000,000,000,000,000 | 29 | Fix oob write in dyldcache
When the individual n_slide_infos were too high, the sum would overflow
and too few entries would be allocated. |
polkit_system_bus_name_hash (PolkitSubject *subject)
{
PolkitSystemBusName *system_bus_name = POLKIT_SYSTEM_BUS_NAME (subject);
return g_str_hash (system_bus_name->name);
} | 0 | [
"CWE-754"
] | polkit | a04d13affe0fa53ff618e07aa8f57f4c0e3b9b81 | 173,049,270,848,290,330,000,000,000,000,000,000,000 | 6 | GHSL-2021-074: authentication bypass vulnerability in polkit
initial values returned if error caught |
void plugin_unlock_list(THD *thd, plugin_ref *list, uint count)
{
LEX *lex= thd ? thd->lex : 0;
DBUG_ENTER("plugin_unlock_list");
if (count == 0)
DBUG_VOID_RETURN;
DBUG_ASSERT(list);
mysql_mutex_lock(&LOCK_plugin);
while (count--)
intern_plugin_unlock(lex, *list++);
reap_plugins();
mysql_mutex_... | 0 | [
"CWE-416"
] | server | c05fd700970ad45735caed3a6f9930d4ce19a3bd | 75,611,465,782,419,605,000,000,000,000,000,000,000 | 15 | MDEV-26323 use-after-poison issue of MariaDB server |
int setTypeAdd(robj *subject, sds value) {
long long llval;
if (subject->encoding == OBJ_ENCODING_HT) {
dict *ht = subject->ptr;
dictEntry *de = dictAddRaw(ht,value,NULL);
if (de) {
dictSetKey(ht,de,sdsdup(value));
dictSetVal(ht,de,NULL);
return 1;
... | 1 | [
"CWE-190"
] | redis | a30d367a71b7017581cf1ca104242a3c644dec0f | 140,709,149,493,981,100,000,000,000,000,000,000,000 | 35 | Fix Integer overflow issue with intsets (CVE-2021-32687)
The vulnerability involves changing the default set-max-intset-entries
configuration parameter to a very large value and constructing specially
crafted commands to manipulate sets |
dissect_dch_timing_advance(proto_tree *tree, packet_info *pinfo,
tvbuff_t *tvb, int offset, struct fp_info *p_fp_info)
{
guint8 cfn;
guint16 timing_advance;
proto_item *timing_advance_ti;
/* CFN control */
cfn = tvb_get_guint8(tvb, offset);
proto_tree_add_ite... | 0 | [
"CWE-20"
] | wireshark | 7d7190695ce2ff269fdffb04e87139995cde21f4 | 76,444,498,458,734,340,000,000,000,000,000,000,000 | 38 | 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 mem_cgroup_destroy(struct cgroup_subsys *ss,
struct cgroup *cont)
{
struct mem_cgroup *memcg = mem_cgroup_from_cont(cont);
kmem_cgroup_destroy(ss, cont);
mem_cgroup_put(memcg);
} | 0 | [
"CWE-476",
"CWE-415"
] | linux | 371528caec553785c37f73fa3926ea0de84f986f | 300,658,095,005,660,200,000,000,000,000,000,000,000 | 9 | mm: memcg: Correct unregistring of events attached to the same eventfd
There is an issue when memcg unregisters events that were attached to
the same eventfd:
- On the first call mem_cgroup_usage_unregister_event() removes all
events attached to a given eventfd, and if there were no events left,
thresholds->prima... |
QPDFObjectHandle::isReal()
{
dereference();
return QPDFObjectTypeAccessor<QPDF_Real>::check(obj.getPointer());
} | 0 | [
"CWE-835"
] | qpdf | afe0242b263a9e1a8d51dd81e42ab6de2e5127eb | 79,345,317,197,658,210,000,000,000,000,000,000,000 | 5 | Handle object ID 0 (fixes #99)
This is CVE-2017-9208.
The QPDF library uses object ID 0 internally as a sentinel to
represent a direct object, but prior to this fix, was not blocking
handling of 0 0 obj or 0 0 R as a special case. Creating an object in
the file with 0 0 obj could cause various infinite loops. The PDF... |
get_singular_values (const cairo_matrix_t *matrix,
double *major,
double *minor)
{
double xx = matrix->xx, xy = matrix->xy;
double yx = matrix->yx, yy = matrix->yy;
double a = xx*xx+yx*yx;
double b = xy*xy+yy*yy;
double k = xx*xy+yx*yy;
double f = (a+b) * .5;
double g ... | 0 | [] | poppler | abf167af8b15e5f3b510275ce619e6fdb42edd40 | 76,491,197,549,047,840,000,000,000,000,000,000,000 | 20 | Implement tiling/patterns in SplashOutputDev
Fixes bug 13518 |
GF_Err paen_on_child_box(GF_Box *s, GF_Box *a, Bool is_rem)
{
FDPartitionEntryBox *ptr = (FDPartitionEntryBox *)s;
switch(a->type) {
case GF_ISOM_BOX_TYPE_FPAR:
BOX_FIELD_ASSIGN(blocks_and_symbols, FilePartitionBox)
return GF_OK;
case GF_ISOM_BOX_TYPE_FECR:
BOX_FIELD_ASSIGN(FEC_symbol_locations, FECReservoir... | 0 | [
"CWE-476",
"CWE-787"
] | gpac | b8f8b202d4fc23eb0ab4ce71ae96536ca6f5d3f8 | 78,809,495,941,843,640,000,000,000,000,000,000,000 | 16 | fixed #1757 |
static int cr8_write_interception(struct vcpu_svm *svm)
{
struct kvm_run *kvm_run = svm->vcpu.run;
int r;
u8 cr8_prev = kvm_get_cr8(&svm->vcpu);
/* instruction emulation calls kvm_set_cr8() */
r = cr_interception(svm);
if (lapic_in_kernel(&svm->vcpu))
return r;
if (cr8_prev <= kvm_get_cr8(&svm->vcpu))
retur... | 0 | [
"CWE-401"
] | linux | d80b64ff297e40c2b6f7d7abc1b3eba70d22a068 | 69,141,032,292,413,450,000,000,000,000,000,000,000 | 15 | KVM: SVM: Fix potential memory leak in svm_cpu_init()
When kmalloc memory for sd->sev_vmcbs failed, we forget to free the page
held by sd->save_area. Also get rid of the var r as '-ENOMEM' is actually
the only possible outcome here.
Reviewed-by: Liran Alon <liran.alon@oracle.com>
Reviewed-by: Vitaly Kuznetsov <vkuzne... |
read_file(gchar* filepath)
{
FILE * f;
size_t length;
gchar *ret = NULL;
f = fopen(filepath, "rb");
if (f) {
fseek(f, 0, SEEK_END);
length = (size_t)ftell(f);
fseek(f, 0, SEEK_SET);
/* We can't use MALLOC since it isn't thread safe */
ret = MALLOC(length + 1);
if (ret) {
if (fread(ret, length, 1, ... | 1 | [
"CWE-59",
"CWE-61"
] | keepalived | 04f2d32871bb3b11d7dc024039952f2fe2750306 | 291,726,282,331,673,060,000,000,000,000,000,000,000 | 27 | When opening files for write, ensure they aren't symbolic links
Issue #1048 identified that if, for example, a non privileged user
created a symbolic link from /etc/keepalvied.data to /etc/passwd,
writing to /etc/keepalived.data (which could be invoked via DBus)
would cause /etc/passwd to be overwritten.
This commit ... |
static int ntop_interface_engage_release_network_alert(lua_State* vm, bool engage) {
NetworkInterface *ntop_interface = getCurrentInterface(vm);
char *cidr;
int alert_severity;
int alert_type;
char *alert_json, *engaged_alert_id;
AlertsManager *am;
int ret;
ntop->getTrace()->traceEvent(TRACE_DEBUG, "%s... | 0 | [
"CWE-476"
] | ntopng | 01f47e04fd7c8d54399c9e465f823f0017069f8f | 113,998,547,171,392,580,000,000,000,000,000,000,000 | 39 | Security fix: prevents empty host from being used |
parse_auto_key_locate (char *options)
{
char *tok;
while ((tok = optsep (&options)))
{
struct akl *akl, *check, *last = NULL;
int dupe = 0;
if (tok[0] == '\0')
continue;
akl = xmalloc_clear (sizeof (*akl));
if (ascii_strcasecmp (tok, "clear") == 0)
{
xfree (akl);
... | 0 | [
"CWE-20"
] | gnupg | 2183683bd633818dd031b090b5530951de76f392 | 60,273,579,341,708,920,000,000,000,000,000,000,000 | 72 | 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 ... |
account_entity_dequeue(struct cfs_rq *cfs_rq, struct sched_entity *se)
{
update_load_sub(&cfs_rq->load, se->load.weight);
if (!parent_entity(se))
dec_cpu_load(rq_of(cfs_rq), se->load.weight);
if (entity_is_task(se))
add_cfs_task_weight(cfs_rq, -se->load.weight);
cfs_rq->nr_running--;
se->on_rq = 0;
list_del_i... | 0 | [] | linux-2.6 | 8f1bc385cfbab474db6c27b5af1e439614f3025c | 215,251,262,453,860,260,000,000,000,000,000,000,000 | 11 | sched: fair: weight calculations
In order to level the hierarchy, we need to calculate load based on the
root view. That is, each task's load is in the same unit.
A
/ \
B 1
/ \
2 3
To compute 1's load we do:
weight(1)
--------------
rq_weight(A)
To ... |
int __dev_forward_skb(struct net_device *dev, struct sk_buff *skb)
{
int ret = ____dev_forward_skb(dev, skb);
if (likely(!ret)) {
skb->protocol = eth_type_trans(skb, dev);
skb_postpull_rcsum(skb, eth_hdr(skb), ETH_HLEN);
}
return ret; | 0 | [
"CWE-476"
] | linux | 0ad646c81b2182f7fa67ec0c8c825e0ee165696d | 320,788,015,499,150,640,000,000,000,000,000,000,000 | 11 | tun: call dev_get_valid_name() before register_netdevice()
register_netdevice() could fail early when we have an invalid
dev name, in which case ->ndo_uninit() is not called. For tun
device, this is a problem because a timer etc. are already
initialized and it expects ->ndo_uninit() to clean them up.
We could move th... |
void task_clear_group_stop_pending(struct task_struct *task)
{
task->group_stop &= ~(GROUP_STOP_PENDING | GROUP_STOP_CONSUME |
GROUP_STOP_DEQUEUED);
} | 0 | [
"CWE-400"
] | linux-stable-rt | bcf6b1d78c0bde228929c388978ed3af9a623463 | 103,868,336,858,589,440,000,000,000,000,000,000,000 | 5 | 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... |
static void Reduce(CubeInfo *cube_info,const NodeInfo *node_info)
{
register ssize_t
i;
size_t
number_children;
/*
Traverse any children.
*/
number_children=cube_info->associate_alpha == MagickFalse ? 8UL : 16UL;
for (i=0; i < (ssize_t) number_children; i++)
if (node_info->child[i] != (Nod... | 0 | [
"CWE-125"
] | ImageMagick | 5294966898532a6bd54699fbf04edf18902513ac | 220,963,933,277,447,300,000,000,000,000,000,000,000 | 28 | https://github.com/ImageMagick/ImageMagick/issues/1156 |
void packet_parse(struct gps_packet_t *lexer)
/* grab a packet from the input buffer */
{
lexer->outbuflen = 0;
while (packet_buffered_input(lexer) > 0) {
/*@ -modobserver @*/
unsigned char c = *lexer->inbufptr++;
/*@ +modobserver @*/
char *state_table[] = {
#include "packet_names.h"
};
nextstate(lexer, c... | 0 | [] | gpsd | dd9c3c2830cb8f8fd8491ce68c82698dc5538f50 | 115,270,284,537,473,780,000,000,000,000,000,000,000 | 583 | Fix a malformed-packet crash.
Under weird circumstances, this line of device input
$GPGGA,030130$GPGLL,2638.1728,N,08011.3893,W,030131.000,A,A*41
could core-dump the packet parser. The context had to be exactly
right for it to happen. The bug was an incorrect attempt at optimizing
recovery from this rare case. |
epoch_t get_osdmap_epoch() const {
return osdmap ? osdmap->get_epoch() : 0;
} | 0 | [
"CWE-287",
"CWE-284"
] | ceph | 5ead97120e07054d80623dada90a5cc764c28468 | 243,834,434,178,160,000,000,000,000,000,000,000,000 | 3 | 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 ... |
inline CImg<_cimg_Tfloat> operator/(const char *const expression, const CImg<T>& img) {
return expression*img.get_invert();
} | 0 | [
"CWE-770"
] | cimg | 619cb58dd90b4e03ac68286c70ed98acbefd1c90 | 252,675,964,274,102,860,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. |
void color_cmyk_to_rgb(opj_image_t *image)
{
float C, M, Y, K;
float sC, sM, sY, sK;
unsigned int w, h, max, i;
w = image->comps[0].w;
h = image->comps[0].h;
if(image->numcomps < 4) return;
max = w * h;
sC = 1.0F / (float)((1 << image->comps[0].prec) - 1);
sM = 1.0F / (float)((1 << image->comps[1].prec) -... | 1 | [
"CWE-119",
"CWE-284"
] | openjpeg | 162f6199c0cd3ec1c6c6dc65e41b2faab92b2d91 | 173,400,793,659,928,880,000,000,000,000,000,000,000 | 50 | Fix Heap Buffer Overflow in function color_cmyk_to_rgb
Fix uclouvain/openjpeg#774 |
pkinit_C_Decrypt(pkinit_identity_crypto_context id_cryptoctx,
CK_BYTE_PTR pEncryptedData,
CK_ULONG ulEncryptedDataLen,
CK_BYTE_PTR pData,
CK_ULONG_PTR pulDataLen)
{
CK_RV rv = CKR_OK;
rv = id_cryptoctx->p11->C_Decrypt(id_cryptoctx->session, p... | 0 | [
"CWE-476"
] | krb5 | f249555301940c6df3a2cdda13b56b5674eebc2e | 120,500,880,640,302,550,000,000,000,000,000,000,000 | 16 | PKINIT null pointer deref [CVE-2013-1415]
Don't dereference a null pointer when cleaning up.
The KDC plugin for PKINIT can dereference a null pointer when a
malformed packet causes processing to terminate early, leading to
a crash of the KDC process. An attacker would need to have a valid
PKINIT certificate or have ... |
static int check_svme(struct x86_emulate_ctxt *ctxt)
{
u64 efer;
ctxt->ops->get_msr(ctxt, MSR_EFER, &efer);
if (!(efer & EFER_SVME))
return emulate_ud(ctxt);
return X86EMUL_CONTINUE;
} | 0 | [] | kvm | e28ba7bb020f07193bc000453c8775e9d2c0dda7 | 209,153,628,985,425,370,000,000,000,000,000,000,000 | 11 | KVM: x86: fix missing checks in syscall emulation
On hosts without this patch, 32bit guests will crash (and 64bit guests
may behave in a wrong way) for example by simply executing following
nasm-demo-application:
[bits 32]
global _start
SECTION .text
_start: syscall
(I tested it with winxp and linux ... |
static void unloadimage()
{
if (gs.image) {
jas_image_destroy(gs.image);
gs.image = 0;
}
if (gs.altimage) {
jas_image_destroy(gs.altimage);
gs.altimage = 0;
}
} | 0 | [
"CWE-119"
] | jasper | 65536647d380571d1a9a6c91fa03775fb5bbd256 | 268,803,276,666,733,300,000,000,000,000,000,000,000 | 11 | A new experimental memory allocator has been introduced. The allocator
is experimental in the sense that its API is not considered stable and
the allocator may change or disappear entirely in future versions of
the code. This new allocator tracks how much memory is being used by
jas_malloc and friends. A maximum upp... |
void HGraphBuilder::VisitForValue(Expression* expr, ArgumentsAllowedFlag flag) {
ValueContext for_value(this, flag);
Visit(expr);
} | 0 | [] | node | fd80a31e0697d6317ce8c2d289575399f4e06d21 | 174,887,120,831,929,770,000,000,000,000,000,000,000 | 4 | deps: backport 5f836c from v8 upstream
Original commit message:
Fix Hydrogen bounds check elimination
When combining bounds checks, they must all be moved before the first load/store
that they are guarding.
BUG=chromium:344186
LOG=y
R=svenpanne@chromium.org
Review URL: https://coderevie... |
void suhosin_hook_header_handler()
{
if (orig_header_handler == NULL) {
orig_header_handler = sapi_module.header_handler;
sapi_module.header_handler = suhosin_header_handler;
}
} | 0 | [
"CWE-119"
] | suhosin | 73b1968ee30f6d9d2dae497544b910e68e114bfa | 254,212,480,296,477,020,000,000,000,000,000,000,000 | 7 | Fixed stack based buffer overflow in transparent cookie encryption (see separate advisory) |
asmlinkage long SyS_fallocate(long fd, long mode, loff_t offset, loff_t len)
{
return SYSC_fallocate((int)fd, (int)mode, offset, len);
} | 0 | [
"CWE-732"
] | linux-stable | e57712ebebbb9db7d8dcef216437b3171ddcf115 | 209,692,610,520,874,630,000,000,000,000,000,000,000 | 4 | merge fchmod() and fchmodat() guts, kill ancient broken kludge
The kludge in question is undocumented and doesn't work for 32bit
binaries on amd64, sparc64 and s390. Passing (mode_t)-1 as
mode had (since 0.99.14v and contrary to behaviour of any
other Unix, prescriptions of POSIX, SuS and our own manpages)
was kinda-... |
int kvm_arch_interrupt_allowed(struct kvm_vcpu *vcpu)
{
return kvm_x86_ops->interrupt_allowed(vcpu);
} | 0 | [
"CWE-476"
] | linux-2.6 | 59839dfff5eabca01cc4e20b45797a60a80af8cb | 286,280,800,752,257,350,000,000,000,000,000,000,000 | 4 | 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... |
void show_error_as_msgbox(const char *msg)
{
GtkWidget *dialog = gtk_message_dialog_new(GTK_WINDOW(g_wnd_assistant),
GTK_DIALOG_DESTROY_WITH_PARENT,
GTK_MESSAGE_WARNING,
GTK_BUTTONS_CLOSE,
"%s", msg
);
gtk_dialog_run(GTK_DIALOG(dialog));
gt... | 0 | [
"CWE-200"
] | libreport | 257578a23d1537a2d235aaa2b1488ee4f818e360 | 46,663,610,061,334,180,000,000,000,000,000,000,000 | 11 | wizard: fix save users changes after reviewing dump dir files
If the user reviewed the dump dir's files during reporting the crash, the
changes was thrown away and original data was passed to the bugzilla bug
report.
report-gtk saves the first text view buffer and then reloads data from the
reported problem directory... |
GF_Err gf_isom_apple_set_tag(GF_ISOFile *mov, GF_ISOiTunesTag tag, const u8 *data, u32 data_len, u64 int_val, u32 int_val2)
{
GF_Err e;
GF_ItemListBox *ilst;
GF_MetaBox *meta;
GF_ListItemBox *info;
u32 btype, i, itype;
s32 tag_idx;
u32 n=0, d=0;
u8 loc_data[10];
u32 int_flags = 0x15;
GF_DataBox *dbox;
e = C... | 0 | [
"CWE-476"
] | gpac | ebfa346eff05049718f7b80041093b4c5581c24e | 256,779,304,338,689,350,000,000,000,000,000,000,000 | 198 | fixed #1706 |
TfLiteStatus ResizeOutput(TfLiteContext* context, TfLiteNode* node) {
TfLiteIntArray* output_shape = GetOutputShape(context, node);
std::unique_ptr<TfLiteIntArray, void (*)(TfLiteIntArray*)>
scoped_output_shape(output_shape, TfLiteIntArrayFree);
const TfLiteTensor* input;
TF_LITE_ENSURE_OK(context, GetIn... | 0 | [
"CWE-125",
"CWE-787"
] | tensorflow | 1970c2158b1ffa416d159d03c3370b9a462aee35 | 91,897,109,498,158,430,000,000,000,000,000,000,000 | 36 | [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... |
cifs_read_allocate_pages(struct cifs_readdata *rdata, unsigned int nr_pages)
{
int rc = 0;
struct page *page;
unsigned int i;
for (i = 0; i < nr_pages; i++) {
page = alloc_page(GFP_KERNEL|__GFP_HIGHMEM);
if (!page) {
rc = -ENOMEM;
break;
}
rdata->pages[i] = page;
}
if (rc) {
for (i = 0; i < nr_p... | 0 | [
"CWE-119",
"CWE-787"
] | linux | 5d81de8e8667da7135d3a32a964087c0faf5483f | 303,941,271,728,166,650,000,000,000,000,000,000,000 | 23 | cifs: ensure that uncached writes handle unmapped areas correctly
It's possible for userland to pass down an iovec via writev() that has a
bogus user pointer in it. If that happens and we're doing an uncached
write, then we can end up getting less bytes than we expect from the
call to iov_iter_copy_from_user. This is ... |
int x509parse_crtpath( x509_cert *chain, const char *path )
{
int ret = 0;
#if defined(_WIN32)
int w_ret;
WCHAR szDir[MAX_PATH];
char filename[MAX_PATH];
char *p;
int len = strlen( path );
WIN32_FIND_DATAW file_data;
HANDLE hFind;
if( len > MAX_PATH - 3 )
return( POLARSSL_ERR_X50... | 0 | [
"CWE-310"
] | polarssl | 43f9799ce61c6392a014d0a2ea136b4b3a9ee194 | 95,713,359,160,477,270,000,000,000,000,000,000,000 | 96 | RSA blinding on CRT operations to counter timing attacks |
static void ImportCMYKQuantum(const Image *image,QuantumInfo *quantum_info,
const MagickSizeType number_pixels,const unsigned char *magick_restrict p,
Quantum *magick_restrict q,ExceptionInfo *exception)
{
QuantumAny
range;
register ssize_t
x;
unsigned int
pixel;
if (image->colorspace != CMYK... | 0 | [
"CWE-125"
] | ImageMagick | 430403b0029b37decf216d57f810899cab2317dd | 76,463,730,759,413,170,000,000,000,000,000,000,000 | 164 | https://github.com/ImageMagick/ImageMagick/issues/126 |
static Image *ReadPCDImage(const ImageInfo *image_info,ExceptionInfo *exception)
{
#define ThrowPCDException(exception,message) \
{ \
if (header != (unsigned char *) NULL) \
header=(unsigned char *) RelinquishMagickMemory(header); \
if (luma != (unsigned char *) NULL) \
luma=(unsigned char *) RelinquishMagi... | 0 | [
"CWE-772"
] | ImageMagick | 957b6397b958a5881005df27eb97319b3175a3c9 | 10,372,947,593,199,616,000,000,000,000,000,000,000 | 403 | https://github.com/ImageMagick/ImageMagick/issues/1193 |
void CWebServer::Cmd_GetCosts(WebEmSession & session, const request& req, Json::Value &root)
{
std::string idx = request::findValue(&req, "idx");
if (idx.empty())
return;
char szTmp[100];
std::vector<std::vector<std::string> > result;
result = m_sql.safe_query("SELECT Type, SubType, nValue, sValu... | 0 | [
"CWE-89"
] | domoticz | ee70db46f81afa582c96b887b73bcd2a86feda00 | 324,748,693,932,709,270,000,000,000,000,000,000,000 | 76 | Fixed possible SQL Injection Vulnerability (Thanks to Fabio Carretto!) |
xsltParseAttrXSLTVersion(xsltCompilerCtxtPtr cctxt, xmlNodePtr node,
int instrCategory)
{
xmlChar *value;
xmlAttrPtr attr;
if ((cctxt == NULL) || (node == NULL))
return(-1);
if (instrCategory == XSLT_ELEMENT_CATEGORY_XSLT)
attr = xmlHasNsProp(node, BAD_CAST "version", NULL);
else
attr = xml... | 0 | [] | libxslt | e03553605b45c88f0b4b2980adfbbb8f6fca2fd6 | 28,143,738,387,503,127,000,000,000,000,000,000,000 | 61 | Fix security framework bypass
xsltCheckRead and xsltCheckWrite return -1 in case of error but callers
don't check for this condition and allow access. With a specially
crafted URL, xsltCheckRead could be tricked into returning an error
because of a supposedly invalid URL that would still be loaded
succesfully later on... |
static void ov51x_handle_button(struct gspca_dev *gspca_dev, u8 state)
{
struct sd *sd = (struct sd *) gspca_dev;
if (sd->snapshot_pressed != state) {
#if IS_ENABLED(CONFIG_INPUT)
input_report_key(gspca_dev->input_dev, KEY_CAMERA, state);
input_sync(gspca_dev->input_dev);
#endif
if (state)
sd->snapshot_need... | 0 | [
"CWE-476"
] | linux | 998912346c0da53a6dbb71fab3a138586b596b30 | 150,857,478,172,841,990,000,000,000,000,000,000,000 | 27 | media: ov519: add missing endpoint sanity checks
Make sure to check that we have at least one endpoint before accessing
the endpoint array to avoid dereferencing a NULL-pointer on stream
start.
Note that these sanity checks are not redundant as the driver is mixing
looking up altsettings by index and by number, which... |
TfLiteStatus Subgraph::Invoke() {
if (!consistent_) {
ReportError("Invoke called on model that is not consistent.");
return kTfLiteError;
}
TfLiteStatus status = kTfLiteOk;
if (state_ == kStateUninvokable) {
ReportError("Invoke called on model that is not ready.");
return kTfLiteError;
} else... | 1 | [
"CWE-476"
] | tensorflow | f8378920345f4f4604202d4ab15ef64b2aceaa16 | 94,308,303,301,419,500,000,000,000,000,000,000,000 | 97 | Prevent a null pointer dereference in TFLite.
PiperOrigin-RevId: 370800353
Change-Id: Ic9c9712ce5c6e384c954dcd640a5bd9ff05c9a05 |
static void ide_init1(IDEBus *bus, int unit)
{
static int drive_serial = 1;
IDEState *s = &bus->ifs[unit];
s->bus = bus;
s->unit = unit;
s->drive_serial = drive_serial++;
/* we need at least 2k alignment for accessing CDROMs using O_DIRECT */
s->io_buffer_total_len = IDE_DMA_BUF_SECTORS*512... | 0 | [
"CWE-189"
] | qemu | 940973ae0b45c9b6817bab8e4cf4df99a9ef83d7 | 216,956,598,007,673,870,000,000,000,000,000,000,000 | 19 | ide: Correct improper smart self test counter reset in ide core.
The SMART self test counter was incorrectly being reset to zero,
not 1. This had the effect that on every 21st SMART EXECUTE OFFLINE:
* We would write off the beginning of a dynamically allocated buffer
* We forgot the SMART history
Fix this.
Signed-o... |
static void htab_map_free(struct bpf_map *map)
{
struct bpf_htab *htab = container_of(map, struct bpf_htab, map);
int i;
/* bpf_free_used_maps() or close(map_fd) will trigger this map_free callback.
* bpf_free_used_maps() is called after bpf prog is no longer executing.
* There is no need to synchronize_rcu() h... | 0 | [
"CWE-787"
] | bpf | c4eb1f403243fc7bbb7de644db8587c03de36da6 | 294,076,431,745,337,050,000,000,000,000,000,000,000 | 26 | bpf: Fix integer overflow involving bucket_size
In __htab_map_lookup_and_delete_batch(), hash buckets are iterated
over to count the number of elements in each bucket (bucket_size).
If bucket_size is large enough, the multiplication to calculate
kvmalloc() size could overflow, resulting in out-of-bounds write
as repor... |
TEST(UriSuite, TestCrashMakeOwnerBug20080207) {
// Testcase by Adrian Manrique
UriParserStateA state;
UriUriA sourceUri;
state.uri = &sourceUri;
const char * const sourceUriString = "http://user:pass@somehost.com:80/";
if (uriParseUriA(&state, sourceUriString) != 0) {
ASSERT_TRUE(false);
}
if (uriNor... | 0 | [
"CWE-125"
] | uriparser | cef25028de5ff872c2e1f0a6c562eb3ea9ecbce4 | 16,593,077,040,942,599,000,000,000,000,000,000,000 | 15 | Fix uriParse*Ex* out-of-bounds read |
enum AVPixelFormat avpriv_find_pix_fmt(const PixelFormatTag *tags,
unsigned int fourcc)
{
while (tags->pix_fmt >= 0) {
if (tags->fourcc == fourcc)
return tags->pix_fmt;
tags++;
}
return AV_PIX_FMT_NONE;
} | 0 | [
"CWE-787"
] | FFmpeg | 2080bc33717955a0e4268e738acf8c1eeddbf8cb | 39,421,759,287,941,740,000,000,000,000,000,000,000 | 10 | avcodec/utils: correct align value for interplay
Fixes out of array access
Fixes: 452/fuzz-1-ffmpeg_VIDEO_AV_CODEC_ID_INTERPLAY_VIDEO_fuzzer
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/targets/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc> |
process_response(struct module_qstate* qstate, struct iter_qstate* iq,
struct iter_env* ie, int id, struct outbound_entry* outbound,
enum module_ev event)
{
struct msg_parse* prs;
struct edns_data edns;
sldns_buffer* pkt;
verbose(VERB_ALGO, "process_response: new external response event");
iq->response = NULL;... | 0 | [
"CWE-400"
] | unbound | ba0f382eee814e56900a535778d13206b86b6d49 | 161,379,125,925,787,820,000,000,000,000,000,000,000 | 183 | - CVE-2020-12662 Unbound can be tricked into amplifying an incoming
query into a large number of queries directed to a target.
- CVE-2020-12663 Malformed answers from upstream name servers can be
used to make Unbound unresponsive. |
nfsd4_encode_copy(struct nfsd4_compoundres *resp, __be32 nfserr,
struct nfsd4_copy *copy)
{
__be32 *p;
if (!nfserr) {
nfserr = nfsd42_encode_write_res(resp, ©->cp_res);
if (nfserr)
return nfserr;
p = xdr_reserve_space(&resp->xdr, 4 + 4);
*p++ = cpu_to_be32(copy->cp_consecutive);
*p++ = cpu_to_b... | 0 | [
"CWE-20",
"CWE-129"
] | linux | f961e3f2acae94b727380c0b74e2d3954d0edf79 | 297,703,330,393,455,050,000,000,000,000,000,000,000 | 16 | nfsd: encoders mustn't use unitialized values in error cases
In error cases, lgp->lg_layout_type may be out of bounds; so we
shouldn't be using it until after the check of nfserr.
This was seen to crash nfsd threads when the server receives a LAYOUTGET
request with a large layout type.
GETDEVICEINFO has the same pro... |
ZEND_VM_COLD_CONSTCONST_HANDLER(3, ZEND_MUL, CONST|TMPVARCV, CONST|TMPVARCV, SPEC(COMMUTATIVE))
{
USE_OPLINE
zend_free_op free_op1, free_op2;
zval *op1, *op2, *result;
double d1, d2;
op1 = GET_OP1_ZVAL_PTR_UNDEF(BP_VAR_R);
op2 = GET_OP2_ZVAL_PTR_UNDEF(BP_VAR_R);
if (ZEND_VM_SPEC && OP1_TYPE == IS_CONST && OP2_T... | 0 | [
"CWE-787"
] | php-src | f1ce8d5f5839cb2069ea37ff424fb96b8cd6932d | 87,704,359,096,601,350,000,000,000,000,000,000,000 | 41 | Fix #73122: Integer Overflow when concatenating strings
We must avoid integer overflows in memory allocations, so we introduce
an additional check in the VM, and bail out in the rare case of an
overflow. Since the recent fix for bug #74960 still doesn't catch all
possible overflows, we fix that right away. |
static void jp2_cdef_dumpdata(jp2_box_t *box, FILE *out)
{
jp2_cdef_t *cdef = &box->data.cdef;
unsigned int i;
for (i = 0; i < cdef->numchans; ++i) {
fprintf(out, "channo=%d; type=%d; assoc=%d\n",
cdef->ents[i].channo, cdef->ents[i].type, cdef->ents[i].assoc);
}
} | 0 | [
"CWE-189"
] | jasper | 3c55b399c36ef46befcb21e4ebc4799367f89684 | 334,065,122,464,420,400,000,000,000,000,000,000,000 | 9 | At many places in the code, jas_malloc or jas_recalloc was being
invoked with the size argument being computed in a manner that would not
allow integer overflow to be detected. Now, these places in the code
have been modified to use special-purpose memory allocation functions
(e.g., jas_alloc2, jas_alloc3, jas_realloc... |
static inline void ModulateHSI(const double percent_hue,
const double percent_saturation,const double percent_intensity,double *red,
double *green,double *blue)
{
double
intensity,
hue,
saturation;
/*
Increase or decrease color intensity, saturation, or hue.
*/
ConvertRGBToHSI(*red,*green,*... | 0 | [
"CWE-401",
"CWE-119",
"CWE-787"
] | ImageMagick | 1cc6f0ccc92c20c7cab6c4a7335daf29c91f0d8e | 154,481,507,044,163,900,000,000,000,000,000,000,000 | 18 | https://github.com/ImageMagick/ImageMagick/issues/663
https://github.com/ImageMagick/ImageMagick/issues/655 |
static void __del_from_nat_cache(struct f2fs_nm_info *nm_i, struct nat_entry *e)
{
list_del(&e->list);
radix_tree_delete(&nm_i->nat_root, nat_get_nid(e));
nm_i->nat_cnt--;
kmem_cache_free(nat_entry_slab, e);
} | 0 | [
"CWE-200",
"CWE-362"
] | linux | 30a61ddf8117c26ac5b295e1233eaa9629a94ca3 | 43,263,161,511,149,490,000,000,000,000,000,000,000 | 7 | f2fs: fix race condition in between free nid allocator/initializer
In below concurrent case, allocated nid can be loaded into free nid cache
and be allocated again.
Thread A Thread B
- f2fs_create
- f2fs_new_inode
- alloc_nid
- __insert_nid_to_list(ALLOC_NID_LIST)
- f2fs_balance_fs_bg
- build_free... |
moveCallback(void *callbackData, T_DIMSE_C_MoveRQ *request,
int responseCount, T_DIMSE_C_MoveRSP *response)
{
OFCondition cond = EC_Normal;
MyCallbackInfo *myCallbackData;
OFString temp_str;
myCallbackData = OFstatic_cast(MyCallbackInfo*, callbackData);
if (movescuLogger.isEnabledFor(OFLogger:... | 0 | [
"CWE-264"
] | dcmtk | beaf5a5c24101daeeafa48c375120b16197c9e95 | 306,739,465,625,555,540,000,000,000,000,000,000,000 | 27 | Make sure to handle setuid() return code properly.
In some tools the return value of setuid() is not checked. In the worst
case this could lead to privilege escalation since the process does not
give up its root privileges and continue as root. |
ly_set_add(struct ly_set *set, void *node, int options)
{
unsigned int i;
void **new;
if (!set || !node) {
LOGARG;
return -1;
}
if (!(options & LY_SET_OPT_USEASLIST)) {
/* search for duplication */
for (i = 0; i < set->number; i++) {
if (set->set.g[i] ==... | 0 | [
"CWE-119"
] | libyang | 32fb4993bc8bb49e93e84016af3c10ea53964be5 | 314,500,199,575,536,440,000,000,000,000,000,000,000 | 31 | schema tree BUGFIX do not check features while still resolving schema
Fixes #723 |
void __init fork_init(unsigned long mempages)
{
#ifndef __HAVE_ARCH_TASK_STRUCT_ALLOCATOR
#ifndef ARCH_MIN_TASKALIGN
#define ARCH_MIN_TASKALIGN L1_CACHE_BYTES
#endif
/* create a slab on which task_structs can be allocated */
task_struct_cachep =
kmem_cache_create("task_struct", sizeof(struct task_struct),
ARCH_M... | 0 | [
"CWE-264"
] | linux-2.6 | 2d5516cbb9daf7d0e342a2e3b0fc6f8c39a81205 | 88,749,989,008,141,950,000,000,000,000,000,000,000 | 33 | copy_process: fix CLONE_PARENT && parent_exec_id interaction
CLONE_PARENT can fool the ->self_exec_id/parent_exec_id logic. If we
re-use the old parent, we must also re-use ->parent_exec_id to make
sure exit_notify() sees the right ->xxx_exec_id's when the CLONE_PARENT'ed
task exits.
Also, move down the "p->parent_ex... |
static int dsa_do_verify(const unsigned char *dgst, int dgst_len,
DSA_SIG *sig, DSA *dsa)
{
BN_CTX *ctx;
BIGNUM u1, u2, t1;
BN_MONT_CTX *mont = NULL;
int ret = -1, i;
if (!dsa->p || !dsa->q || !dsa->g) {
DSAerr(DSA_F_DSA_DO_VERIFY, DSA_R_MISSING_PARAMETERS);
... | 0 | [
"CWE-203"
] | openssl | d168705e11526a4b487640c7cac5b53ee3646cbc | 30,931,763,318,067,500,000,000,000,000,000,000,000 | 99 | Fix DSA, preserve BN_FLG_CONSTTIME
Operations in the DSA signing algorithm should run in constant time in
order to avoid side channel attacks. A flaw in the OpenSSL DSA
implementation means that a non-constant time codepath is followed for
certain operations. This has been demonstrated through a cache-timing
attack to... |
static int mmtimer_mmap(struct file *file, struct vm_area_struct *vma)
{
unsigned long mmtimer_addr;
if (vma->vm_end - vma->vm_start != PAGE_SIZE)
return -EINVAL;
if (vma->vm_flags & VM_WRITE)
return -EPERM;
if (PAGE_SIZE > (1 << 16))
return -ENOSYS;
vma->vm_page_prot = pgprot_noncached(vma->vm_page_prot... | 0 | [
"CWE-189"
] | linux | f8bd2258e2d520dff28c855658bd24bdafb5102d | 187,183,929,210,215,420,000,000,000,000,000,000,000 | 27 | remove div_long_long_rem
x86 is the only arch right now, which provides an optimized for
div_long_long_rem and it has the downside that one has to be very careful that
the divide doesn't overflow.
The API is a little akward, as the arguments for the unsigned divide are
signed. The signed version also doesn't handle ... |
struct dm_table *dm_get_live_table(struct mapped_device *md, int *srcu_idx) __acquires(md->io_barrier)
{
*srcu_idx = srcu_read_lock(&md->io_barrier);
return srcu_dereference(md->map, &md->io_barrier);
} | 0 | [
"CWE-362"
] | linux | b9a41d21dceadf8104812626ef85dc56ee8a60ed | 244,973,131,290,895,250,000,000,000,000,000,000,000 | 6 | dm: fix race between dm_get_from_kobject() and __dm_destroy()
The following BUG_ON was hit when testing repeat creation and removal of
DM devices:
kernel BUG at drivers/md/dm.c:2919!
CPU: 7 PID: 750 Comm: systemd-udevd Not tainted 4.1.44
Call Trace:
[<ffffffff81649e8b>] dm_get_from_kobject+0x34/0x3a
... |
rsvg_new_filter_primitive_image (const char *element_name, RsvgNode *parent)
{
RsvgFilterPrimitiveImage *filter;
filter = g_new0 (RsvgFilterPrimitiveImage, 1);
filter->super.in = g_string_new ("none");
filter->super.result = g_string_new ("none");
filter->super.render = rsvg_filter_primitive_image_... | 0 | [
"CWE-369"
] | librsvg | ecf9267a24b2c3c0cd211dbdfa9ef2232511972a | 44,196,524,969,869,240,000,000,000,000,000,000,000 | 18 | bgo#783835 - Don't divide by zero in box_blur_line() for gaussian blurs
We were making the decision to use box blurs, instead of a true
Gaussian kernel, based on the size of *both* x and y dimensions. Do
them individually instead. |
static int qxl_track_command(PCIQXLDevice *qxl, struct QXLCommandExt *ext)
{
switch (le32_to_cpu(ext->cmd.type)) {
case QXL_CMD_SURFACE:
{
QXLSurfaceCmd *cmd = qxl_phys2virt(qxl, ext->cmd.data, ext->group_id);
if (!cmd) {
return 1;
}
uint32_t id = le32_to_cpu(cmd... | 0 | [
"CWE-476"
] | qemu | d52680fc932efb8a2f334cc6993e705ed1e31e99 | 130,756,248,190,520,920,000,000,000,000,000,000,000 | 59 | qxl: check release info object
When releasing spice resources in release_resource() routine,
if release info object 'ext.info' is null, it leads to null
pointer dereference. Add check to avoid it.
Reported-by: Bugs SysSec <bugs-syssec@rub.de>
Signed-off-by: Prasad J Pandit <pjp@fedoraproject.org>
Message-id: 20190425... |
#ifdef HAVE_IMAP_MUTF7
static void php_imap_mutf7(INTERNAL_FUNCTION_PARAMETERS, int mode) /* {{{ */
{
zend_string *in;
unsigned char *out;
if (zend_parse_parameters(ZEND_NUM_ARGS(), "S", &in) == FAILURE) {
return;
}
if (ZSTR_LEN(in) < 1) {
RETURN_EMPTY_STRING();
}
if (mode == 0) {
out = utf8_to_mutf7((u... | 0 | [
"CWE-88"
] | php-src | 336d2086a9189006909ae06c7e95902d7d5ff77e | 80,759,859,573,771,880,000,000,000,000,000,000,000 | 25 | Disable rsh/ssh functionality in imap by default (bug #77153) |
bool get_date(MYSQL_TIME *ltime, ulonglong fuzzydate)
{ return Field_datetime::get_TIME(ltime, ptr, fuzzydate); } | 0 | [
"CWE-416",
"CWE-703"
] | server | 08c7ab404f69d9c4ca6ca7a9cf7eec74c804f917 | 260,427,895,754,925,880,000,000,000,000,000,000,000 | 2 | MDEV-24176 Server crashes after insert in the table with virtual
column generated using date_format() and if()
vcol_info->expr is allocated on expr_arena at parsing stage. Since
expr item is allocated on expr_arena all its containee items must be
allocated on expr_arena too. Otherwise fix_session_expr() will
encounter... |
int crypt_volume_key_load_in_keyring(struct crypt_device *cd, struct volume_key *vk)
{
int r;
const char *type_name = key_type_name(LOGON_KEY);
if (!vk || !cd || !type_name)
return -EINVAL;
if (!vk->key_description) {
log_dbg(cd, "Invalid key description");
return -EINVAL;
}
log_dbg(cd, "Loading key (%zu... | 0 | [
"CWE-345"
] | cryptsetup | 0113ac2d889c5322659ad0596d4cfc6da53e356c | 212,701,988,676,792,460,000,000,000,000,000,000,000 | 24 | Fix CVE-2021-4122 - LUKS2 reencryption crash recovery attack
Fix possible attacks against data confidentiality through LUKS2 online
reencryption extension crash recovery.
An attacker can modify on-disk metadata to simulate decryption in
progress with crashed (unfinished) reencryption step and persistently
decrypt par... |
make_cond_for_table_from_pred(THD *thd, Item *root_cond, Item *cond,
table_map tables, table_map used_table,
int join_tab_idx_arg,
bool exclude_expensive_cond __attribute__
((unused)),
... | 0 | [
"CWE-89"
] | server | 5ba77222e9fe7af8ff403816b5338b18b342053c | 89,548,033,346,853,980,000,000,000,000,000,000,000 | 151 | MDEV-21028 Server crashes in Query_arena::set_query_arena upon SELECT from view
if the view has algorithm=temptable it is not updatable,
so DEFAULT() for its fields is meaningless,
and thus it's NULL or 0/'' for NOT NULL columns. |
send_ldap_intermediate(Slapi_PBlock *pb, LDAPControl **ectrls, char *responseName, struct berval *responseValue)
{
ber_tag_t tag;
BerElement *ber;
Slapi_Connection *connection;
Slapi_Operation *operation;
int rc = 0;
int logit = 0;
slapi_log_err(SLAPI_LOG_TRACE, "send_ldap_intermediate", "=... | 0 | [
"CWE-399",
"CWE-203"
] | 389-ds-base | cc0f69283abc082488824702dae485b8eae938bc | 336,545,162,834,794,500,000,000,000,000,000,000,000 | 71 | Issue 4480 - Unexpected info returned to ldap request (#4491)
Bug description:
If the bind entry does not exist, the bind result info
reports that 'No such entry'. It should not give any
information if the target entry exists or not
Fix description:
Does not return any additional information d... |
static void sctp_inet_event_msgname(struct sctp_ulpevent *event, char *msgname,
int *addr_len)
{
struct sockaddr_in *sin, *sinfrom;
if (msgname) {
struct sctp_association *asoc;
asoc = event->asoc;
sctp_inet_msgname(msgname, addr_len);
sin = (struct sockaddr_in *)msgname;
sinfrom = &asoc->peer.pri... | 0 | [
"CWE-119",
"CWE-787"
] | linux | 8e2d61e0aed2b7c4ecb35844fe07e0b2b762dee4 | 29,552,696,184,212,805,000,000,000,000,000,000,000 | 16 | sctp: fix race on protocol/netns initialization
Consider sctp module is unloaded and is being requested because an user
is creating a sctp socket.
During initialization, sctp will add the new protocol type and then
initialize pernet subsys:
status = sctp_v4_protosw_init();
if (status)
... |
ves_icall_System_Reflection_Assembly_get_ReflectionOnly (MonoReflectionAssembly *assembly)
{
MONO_ARCH_SAVE_REGS;
return assembly->assembly->ref_only;
} | 0 | [
"CWE-264"
] | mono | 035c8587c0d8d307e45f1b7171a0d337bb451f1e | 208,818,520,962,004,400,000,000,000,000,000,000,000 | 6 | Allow only primitive types/enums in RuntimeHelpers.InitializeArray (). |
static u64 do_task_delta_exec(struct task_struct *p, struct rq *rq)
{
u64 ns = 0;
if (task_current(rq, p)) {
update_rq_clock(rq);
ns = rq->clock_task - p->se.exec_start;
if ((s64)ns < 0)
ns = 0;
}
return ns;
} | 0 | [
"CWE-703",
"CWE-835"
] | linux | f26f9aff6aaf67e9a430d16c266f91b13a5bff64 | 93,173,586,270,504,520,000,000,000,000,000,000,000 | 13 | Sched: fix skip_clock_update optimization
idle_balance() drops/retakes rq->lock, leaving the previous task
vulnerable to set_tsk_need_resched(). Clear it after we return
from balancing instead, and in setup_thread_stack() as well, so
no successfully descheduled or never scheduled task has it set.
Need resched confus... |
int __remove_suid(struct dentry *dentry, int kill)
{
struct iattr newattrs;
newattrs.ia_valid = ATTR_FORCE | kill;
return notify_change(dentry, &newattrs);
} | 0 | [
"CWE-20"
] | linux | 124d3b7041f9a0ca7c43a6293e1cae4576c32fd5 | 182,691,721,135,415,880,000,000,000,000,000,000,000 | 7 | 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... |
ext4_ext_rm_leaf(handle_t *handle, struct inode *inode,
struct ext4_ext_path *path, ext4_lblk_t start)
{
int err = 0, correct_index = 0;
int depth = ext_depth(inode), credits;
struct ext4_extent_header *eh;
ext4_lblk_t a, b, block;
unsigned num;
ext4_lblk_t ex_ee_block;
unsigned short ex_ee_len;
unsigned unin... | 0 | [
"CWE-703"
] | linux | 667eff35a1f56fa74ce98a0c7c29a40adc1ba4e3 | 337,242,720,843,916,120,000,000,000,000,000,000,000 | 130 | ext4: reimplement convert and split_unwritten
Reimplement ext4_ext_convert_to_initialized() and
ext4_split_unwritten_extents() using ext4_split_extent()
Signed-off-by: Yongqiang Yang <xiaoqiangnk@gmail.com>
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
Tested-by: Allison Henderson <achender@linux.vnet.ibm.com> |
int Field_blob::store(longlong nr, bool unsigned_val)
{
CHARSET_INFO *cs=charset();
value.set_int(nr, unsigned_val, cs);
return Field_blob::store(value.ptr(), (uint) value.length(), cs);
} | 0 | [
"CWE-120"
] | server | eca207c46293bc72dd8d0d5622153fab4d3fccf1 | 40,081,208,134,188,904,000,000,000,000,000,000,000 | 6 | 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... |
get_user_cmd_nargs(expand_T *xp UNUSED, int idx)
{
static char *user_cmd_nargs[] = {"0", "1", "*", "?", "+"};
if (idx >= (int)(sizeof(user_cmd_nargs) / sizeof(user_cmd_nargs[0])))
return NULL;
return (char_u *)user_cmd_nargs[idx];
} | 0 | [
"CWE-78"
] | vim | 8c62a08faf89663e5633dc5036cd8695c80f1075 | 82,123,802,298,556,130,000,000,000,000,000,000,000 | 8 | patch 8.1.0881: can execute shell commands in rvim through interfaces
Problem: Can execute shell commands in rvim through interfaces.
Solution: Disable using interfaces in restricted mode. Allow for writing
file with writefile(), histadd() and a few others. |
p2hsv(UINT8 *out, const UINT8 *in, int xsize, const UINT8 *palette) {
int x;
for (x = 0; x < xsize; x++, out += 4) {
const UINT8 *rgb = &palette[*in++ * 4];
rgb2hsv_row(out, rgb);
out[3] = 255;
}
} | 0 | [
"CWE-120"
] | Pillow | 518ee3722a99d7f7d890db82a20bd81c1c0327fb | 273,853,196,204,430,670,000,000,000,000,000,000,000 | 8 | Use snprintf instead of sprintf |
GGadget *GTextAreaCreate(struct gwindow *base, GGadgetData *gd,void *data) {
GTextField *gt = calloc(1,sizeof(GTextField));
gt->multi_line = true;
gt->accepts_returns = true;
_GTextFieldCreate(gt,base,gd,data,&_GGadget_gtextfield_box);
return( >->g );
} | 0 | [
"CWE-119",
"CWE-787"
] | fontforge | 626f751752875a0ddd74b9e217b6f4828713573c | 285,980,292,226,679,140,000,000,000,000,000,000,000 | 8 | Warn users before discarding their unsaved scripts (#3852)
* Warn users before discarding their unsaved scripts
This closes #3846. |
static void cxusb_bluebird_gpio_pulse(struct dvb_usb_device *d, u8 pin, int low)
{
cxusb_bluebird_gpio_rw(d, pin, low ? 0 : pin);
msleep(5);
cxusb_bluebird_gpio_rw(d, pin, low ? pin : 0);
} | 0 | [
"CWE-119",
"CWE-787"
] | linux | 3f190e3aec212fc8c61e202c51400afa7384d4bc | 88,272,364,317,195,140,000,000,000,000,000,000,000 | 6 | [media] cxusb: Use a dma capable buffer also for reading
Commit 17ce039b4e54 ("[media] cxusb: don't do DMA on stack")
added a kmalloc'ed bounce buffer for writes, but missed to do the same
for reads. As the read only happens after the write is finished, we can
reuse the same buffer.
As dvb_usb_generic_rw handles a re... |
ews_authenticate_sync (CamelService *service,
const gchar *mechanism,
GCancellable *cancellable,
GError **error)
{
CamelAuthenticationResult result;
CamelEwsStore *ews_store;
CamelSettings *settings;
CamelEwsSettings *ews_settings;
EEwsConnection... | 0 | [
"CWE-295"
] | evolution-ews | 915226eca9454b8b3e5adb6f2fff9698451778de | 253,256,895,857,515,450,000,000,000,000,000,000,000 | 185 | 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 inline void v9fs_invalidate_inode_attr(struct inode *inode)
{
struct v9fs_inode *v9inode;
v9inode = V9FS_I(inode);
v9inode->cache_validity |= V9FS_INO_INVALID_ATTR;
return;
} | 0 | [
"CWE-835"
] | linux | 5e3cc1ee1405a7eb3487ed24f786dec01b4cbe1f | 150,107,186,956,317,890,000,000,000,000,000,000,000 | 7 | 9p: use inode->i_lock to protect i_size_write() under 32-bit
Use inode->i_lock to protect i_size_write(), else i_size_read() in
generic_fillattr() may loop infinitely in read_seqcount_begin() when
multiple processes invoke v9fs_vfs_getattr() or v9fs_vfs_getattr_dotl()
simultaneously under 32-bit SMP environment, and a... |
gboolean
mono_reflection_is_valid_dynamic_token (MonoDynamicImage *image, guint32 token)
{
return mono_g_hash_table_lookup (image->tokens, GUINT_TO_POINTER (token)) != NULL; | 0 | [
"CWE-20"
] | mono | 4905ef1130feb26c3150b28b97e4a96752e0d399 | 306,539,949,801,040,600,000,000,000,000,000,000,000 | 4 | Handle invalid instantiation of generic methods.
* verify.c: Add new function to internal verifier API to check
method instantiations.
* reflection.c (mono_reflection_bind_generic_method_parameters):
Check the instantiation before returning it.
Fixes #655847 |
push_attribute(pk11_object_t *obj, isc_mem_t *mctx, size_t len) {
CK_ATTRIBUTE *old = obj->repr;
CK_ATTRIBUTE *attr;
CK_BYTE cnt = obj->attrcnt;
REQUIRE(old != NULL || cnt == 0);
obj->repr = isc_mem_get(mctx, (cnt + 1) * sizeof(*attr));
if (obj->repr == NULL) {
obj->repr = old;
return (NULL);
}
memset(obj... | 0 | [
"CWE-617"
] | bind9 | 8d807cc21655eaa6e6a08afafeec3682c0f3f2ab | 302,672,484,152,099,870,000,000,000,000,000,000,000 | 33 | Fix crash in pk11_numbits() when native-pkcs11 is used
When pk11_numbits() is passed a user provided input that contains all
zeroes (via crafted DNS message), it would crash with assertion
failure. Fix that by properly handling such input. |
HttpIo::HttpImpl::HttpImpl(const std::string& url, size_t blockSize):Impl(url, blockSize)
{
hostInfo_ = Exiv2::Uri::Parse(url);
Exiv2::Uri::Decode(hostInfo_);
} | 0 | [
"CWE-125"
] | exiv2 | 6e3855aed7ba8bb4731fc4087ca7f9078b2f3d97 | 296,134,668,622,119,000,000,000,000,000,000,000,000 | 5 | Fix https://github.com/Exiv2/exiv2/issues/55 |
static inline bool kvm_check_request(int req, struct kvm_vcpu *vcpu)
{
if (test_bit(req, &vcpu->requests)) {
clear_bit(req, &vcpu->requests);
return true;
} else {
return false;
}
} | 0 | [
"CWE-399"
] | kvm | 5b40572ed5f0344b9dbee486a17c589ce1abe1a3 | 285,721,302,782,991,120,000,000,000,000,000,000,000 | 9 | 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
... |
static void * __init find_section32(Elf32_Ehdr *ehdr, const char *secname,
unsigned long *size)
{
Elf32_Shdr *sechdrs;
unsigned int i;
char *secnames;
/* Grab section headers and strings so we can tell who is who */
sechdrs = (void *)ehdr + ehdr->e_shoff;
secnames = (void *)ehdr + sechdrs[ehdr->e_shstrndx]... | 0 | [
"CWE-20"
] | linux-2.6 | 89f5b7da2a6bad2e84670422ab8192382a5aeb9f | 273,867,450,400,085,660,000,000,000,000,000,000,000 | 22 | Reinstate ZERO_PAGE optimization in 'get_user_pages()' and fix XIP
KAMEZAWA Hiroyuki and Oleg Nesterov point out that since the commit
557ed1fa2620dc119adb86b34c614e152a629a80 ("remove ZERO_PAGE") removed
the ZERO_PAGE from the VM mappings, any users of get_user_pages() will
generally now populate the VM with real emp... |
gdk_pixbuf__tiff_image_load (FILE *f, GError **error)
{
return gdk_pixbuf__tiff_image_load_real (f, NULL, error);
} | 1 | [
"CWE-20"
] | gdk-pixbuf | 3bac204e0d0241a0d68586ece7099e6acf0e9bea | 84,187,907,249,551,590,000,000,000,000,000,000,000 | 4 | Initial stab at getting the focus code to work.
Fri Jun 1 18:54:47 2001 Jonathan Blandford <jrb@redhat.com>
* gtk/gtktreeview.c: (gtk_tree_view_focus): Initial stab at
getting the focus code to work.
(gtk_tree_view_class_init): Add a bunch of keybindings.
* gtk/gtktreeviewcolumn.c
(gtk_tree_view_column_set_c... |
inline void AssignIDToDefinition::visit(Holder &ope) {
auto p = static_cast<void *>(ope.outer_);
if (ids.count(p)) { return; }
auto id = ids.size();
ids[p] = id;
ope.outer_->id = id;
ope.ope_->accept(*this);
} | 0 | [
"CWE-125"
] | cpp-peglib | b3b29ce8f3acf3a32733d930105a17d7b0ba347e | 174,071,429,939,074,200,000,000,000,000,000,000,000 | 8 | Fix #122 |
map_traverse(mapobject *lz, visitproc visit, void *arg)
{
Py_VISIT(lz->iters);
Py_VISIT(lz->func);
return 0;
} | 0 | [
"CWE-125"
] | cpython | dcfcd146f8e6fc5c2fc16a4c192a0c5f5ca8c53c | 26,566,100,526,095,060,000,000,000,000,000,000,000 | 6 | bpo-35766: Merge typed_ast back into CPython (GH-11645) |
CImgArgumentException(const char *const format, ...) { _cimg_exception_err("CImgArgumentException",true); } | 0 | [
"CWE-770"
] | cimg | 619cb58dd90b4e03ac68286c70ed98acbefd1c90 | 84,235,413,905,151,720,000,000,000,000,000,000,000 | 1 | CImg<>::load_bmp() and CImg<>::load_pandore(): Check that dimensions encoded in file does not exceed file size. |
static CURLcode imap_perform(struct connectdata *conn, bool *connected,
bool *dophase_done)
{
/* This is IMAP and no proxy */
CURLcode result = CURLE_OK;
struct Curl_easy *data = conn->data;
struct IMAP *imap = data->req.protop;
struct imap_conn *imapc = &conn->proto.imapc;
bool... | 0 | [
"CWE-119"
] | curl | 13c9a9ded3ae744a1e11cbc14e9146d9fa427040 | 173,860,944,248,287,050,000,000,000,000,000,000,000 | 61 | imap: if a FETCH response has no size, don't call write callback
CVE-2017-1000257
Reported-by: Brian Carpenter and 0xd34db347
Also detected by OSS-Fuzz: https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=3586 |
static inline PixelTrait GetPixelGrayTraits(const Image *restrict image)
{
return(image->channel_map[GrayPixelChannel].traits);
} | 0 | [
"CWE-119",
"CWE-787"
] | ImageMagick | 450bd716ed3b9186dd10f9e60f630a3d9eeea2a4 | 235,557,300,396,716,100,000,000,000,000,000,000,000 | 4 | |
BGD_DECLARE(gdImagePtr) gdImageClone (gdImagePtr src) {
gdImagePtr dst;
register int i, x;
if (src->trueColor) {
dst = gdImageCreateTrueColor(src->sx , src->sy);
} else {
dst = gdImageCreate(src->sx , src->sy);
}
if (dst == NULL) {
return NULL;
}
if (src->trueColor == 0) {
dst->colorsTotal = src->col... | 1 | [
"CWE-476"
] | libgd | a93eac0e843148dc2d631c3ba80af17e9c8c860f | 66,196,013,709,543,050,000,000,000,000,000,000,000 | 94 | Fix potential NULL pointer dereference in gdImageClone() |
static int copy_sighand(unsigned long clone_flags, struct task_struct *tsk)
{
struct sighand_struct *sig;
if (clone_flags & CLONE_SIGHAND) {
atomic_inc(¤t->sighand->count);
return 0;
}
sig = kmem_cache_alloc(sighand_cachep, GFP_KERNEL);
rcu_assign_pointer(tsk->sighand, sig);
if (!sig)
return -ENOMEM;... | 0 | [
"CWE-264"
] | linux-2.6 | 2d5516cbb9daf7d0e342a2e3b0fc6f8c39a81205 | 323,823,915,917,350,500,000,000,000,000,000,000,000 | 16 | copy_process: fix CLONE_PARENT && parent_exec_id interaction
CLONE_PARENT can fool the ->self_exec_id/parent_exec_id logic. If we
re-use the old parent, we must also re-use ->parent_exec_id to make
sure exit_notify() sees the right ->xxx_exec_id's when the CLONE_PARENT'ed
task exits.
Also, move down the "p->parent_ex... |
static int js_delvar(js_State *J, const char *name)
{
js_Environment *E = J->E;
do {
js_Property *ref = jsV_getownproperty(J, E->variables, name);
if (ref) {
if (ref->atts & JS_DONTCONF) {
if (J->strict)
js_typeerror(J, "'%s' is non-configurable", name);
return 0;
}
jsV_delproperty(J, E->var... | 0 | [
"CWE-476"
] | mujs | 77ab465f1c394bb77f00966cd950650f3f53cb24 | 99,068,194,515,006,830,000,000,000,000,000,000,000 | 18 | Fix 697401: Error when dropping extra arguments to lightweight functions. |
static void dom_load_html(INTERNAL_FUNCTION_PARAMETERS, int mode) /* {{{ */
{
zval *id;
xmlDoc *docp = NULL, *newdoc;
dom_object *intern;
dom_doc_propsptr doc_prop;
char *source;
int source_len, refcount, ret;
long options = 0;
htmlParserCtxtPtr ctxt;
id = getThis();
if (zend_parse_parameters(ZEND_NUM_ARGS... | 1 | [
"CWE-20"
] | php-src | 52b93f0cfd3cba7ff98cc5198df6ca4f23865f80 | 51,876,507,247,267,100,000,000,000,000,000,000,000 | 78 | Fixed bug #69353 (Missing null byte checks for paths in various PHP extensions) |
*/
static xmlNodePtr
xmlXPathNextDescendantOrSelfElemParent(xmlNodePtr cur,
xmlNodePtr contextNode)
{
if (cur == NULL) {
if (contextNode == NULL)
return(NULL);
switch (contextNode->type) {
case XML_ELEMENT_NODE:
case XML_XINCLUDE_START:
case XML_DOCUMENT_FRAG_NODE:
case XML_DO... | 0 | [
"CWE-119"
] | libxml2 | 91d19754d46acd4a639a8b9e31f50f31c78f8c9c | 113,221,871,506,293,160,000,000,000,000,000,000,000 | 62 | Fix the semantic of XPath axis for namespace/attribute context nodes
The processing of namespace and attributes nodes was not compliant
to the XPath-1.0 specification |
rsvg_lookup_parse_style_pair (RsvgHandle * ctx, RsvgState * state,
const char *key, RsvgPropertyBag * atts)
{
const char *value;
if ((value = rsvg_property_bag_lookup (atts, key)) != NULL)
rsvg_parse_style_pair (ctx, state, key, value, FALSE);
} | 0 | [
"CWE-20"
] | librsvg | d1c9191949747f6dcfd207831d15dd4ba00e31f2 | 236,827,952,695,314,800,000,000,000,000,000,000,000 | 8 | state: Store mask as reference
Instead of immediately looking up the mask, store the reference and look
it up on use. |
static void spl_filesystem_dir_it_move_forward(zend_object_iterator *iter TSRMLS_DC)
{
spl_filesystem_object *object = spl_filesystem_iterator_to_object((spl_filesystem_iterator *)iter);
object->u.dir.index++;
spl_filesystem_dir_read(object TSRMLS_CC);
if (object->file_name) {
efree(object->file_name);
object... | 1 | [
"CWE-190"
] | php-src | 7245bff300d3fa8bacbef7897ff080a6f1c23eba | 14,186,278,265,599,674,000,000,000,000,000,000,000 | 11 | Fix bug #72262 - do not overflow int |
int ip_queue_xmit(struct sk_buff *skb)
{
struct sock *sk = skb->sk;
struct inet_sock *inet = inet_sk(sk);
struct ip_options_rcu *inet_opt;
struct rtable *rt;
struct iphdr *iph;
int res;
/* Skip all of this if the packet is already routed,
* f.e. by something like SCTP.
*/
rcu_read_lock();
inet_opt = rcu_d... | 0 | [
"CWE-362"
] | linux-2.6 | f6d8bd051c391c1c0458a30b2a7abcd939329259 | 271,204,917,493,217,220,000,000,000,000,000,000,000 | 85 | 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... |
CImg(const unsigned int size_x, const unsigned int size_y, const unsigned int size_z,
std::initializer_list<t> values,
const bool repeat_values=true):
_width(0),_height(0),_depth(0),_spectrum(0),_is_shared(false),_data(0) {
assign(size_x,size_y,size_z);
_cimg_constructor_cpp11(re... | 0 | [
"CWE-770"
] | cimg | 619cb58dd90b4e03ac68286c70ed98acbefd1c90 | 273,694,001,825,539,780,000,000,000,000,000,000,000 | 7 | CImg<>::load_bmp() and CImg<>::load_pandore(): Check that dimensions encoded in file does not exceed file size. |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.