func string | target int64 | cwe list | project string | commit_id string | hash float64 | size int64 | message string |
|---|---|---|---|---|---|---|---|
flatpak_dir_get_deploy_data (FlatpakDir *self,
FlatpakDecomposed *ref,
int required_version,
GCancellable *cancellable,
GError **error)
{
g_autoptr(GFile) deploy_dir... | 0 | [
"CWE-74"
] | flatpak | fb473cad801c6b61706353256cab32330557374a | 95,020,266,041,625,050,000,000,000,000,000,000,000 | 26 | dir: Pass environment via bwrap --setenv when running apply_extra
This means we can systematically pass the environment variables
through bwrap(1), even if it is setuid and thus is filtering out
security-sensitive environment variables. bwrap ends up being
run with an empty environment instead.
As with the previous c... |
static int ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_CV_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
{
zend_op *opline = EX(opline);
zend_free_op free_op2;
zval *result = &EX_T(opline->result.u.var).tmp_var;
is_identical_function(result,
_get_zval_ptr_cv(&opline->op1, EX(Ts), BP_VAR_R TSRMLS_CC),
_get_zval_ptr_tmp(&o... | 0 | [] | php-src | ce96fd6b0761d98353761bf78d5bfb55291179fd | 82,777,369,596,093,180,000,000,000,000,000,000,000 | 14 | - fix #39863, do not accept paths with NULL in them. See http://news.php.net/php.internals/50191, trunk will have the patch later (adding a macro and/or changing (some) APIs. Patch by Rasmus |
copy_banner(cupsd_client_t *con, /* I - Client connection */
cupsd_job_t *job, /* I - Job information */
const char *name) /* I - Name of banner */
{
int i; /* Looping var */
int kbytes; /* Size of banner file in kbytes */
char filename[1024]; /* Job filename */
cupsd_bann... | 0 | [
"CWE-20"
] | cups | 49fa4983f25b64ec29d548ffa3b9782426007df3 | 322,181,251,822,044,650,000,000,000,000,000,000,000 | 274 | DBUS notifications could crash the scheduler (Issue #5143)
- scheduler/ipp.c: Make sure requesting-user-name string is valid UTF-8. |
static bool fdc_reset_sensei_needed(void *opaque)
{
FDCtrl *s = opaque;
return s->reset_sensei != 0;
} | 0 | [
"CWE-119"
] | qemu | e907746266721f305d67bc0718795fedee2e824c | 41,198,656,724,018,570,000,000,000,000,000,000,000 | 6 | fdc: force the fifo access to be in bounds of the allocated buffer
During processing of certain commands such as FD_CMD_READ_ID and
FD_CMD_DRIVE_SPECIFICATION_COMMAND the fifo memory access could
get out of bounds leading to memory corruption with values coming
from the guest.
Fix this by making sure that the index i... |
static void ebus_class_init(ObjectClass *klass, void *data)
{
PCIDeviceClass *k = PCI_DEVICE_CLASS(klass);
DeviceClass *dc = DEVICE_CLASS(klass);
k->realize = ebus_realize;
k->vendor_id = PCI_VENDOR_ID_SUN;
k->device_id = PCI_DEVICE_ID_SUN_EBUS;
k->revision = 0x01;
k->class_id = PCI_CLASS_B... | 0 | [
"CWE-476"
] | qemu | ad280559c68360c9f1cd7be063857853759e6a73 | 193,340,463,885,000,630,000,000,000,000,000,000,000 | 12 | sun4u: add power_mem_read routine
Define skeleton 'power_mem_read' routine. Avoid NULL dereference.
Reported-by: Fakhri Zulkifli <mohdfakhrizulkifli@gmail.com>
Signed-off-by: Prasad J Pandit <pjp@fedoraproject.org>
Signed-off-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk> |
int key_link(struct key *keyring, struct key *key)
{
struct assoc_array_edit *edit;
int ret;
kenter("{%d,%d}", keyring->serial, refcount_read(&keyring->usage));
key_check(keyring);
key_check(key);
ret = __key_link_begin(keyring, &key->index_key, &edit);
if (ret == 0) {
kdebug("begun {%d,%d}", keyring->seria... | 0 | [
"CWE-20"
] | linux | 363b02dab09b3226f3bd1420dad9c72b79a42a76 | 169,031,159,518,106,400,000,000,000,000,000,000,000 | 24 | KEYS: Fix race between updating and finding a negative key
Consolidate KEY_FLAG_INSTANTIATED, KEY_FLAG_NEGATIVE and the rejection
error into one field such that:
(1) The instantiation state can be modified/read atomically.
(2) The error can be accessed atomically with the state.
(3) The error isn't stored unione... |
R_API void r_bin_java_get_field_json_definitions(RBinJavaObj *bin, PJ *pj) {
r_return_if_fail (pj);
RBinJavaField *fm_type = NULL;
RListIter *iter = NULL;
pj_ka (pj, "fields");
if (!bin) {
pj_end (pj);
return;
}
r_list_foreach (bin->fields_list, iter, fm_type) {
r_bin_java_get_field_json_definition (bin,... | 0 | [
"CWE-125"
] | radare2 | 0927ed3ae99444e7b47b84e43118deb10fe37529 | 94,705,517,506,402,320,000,000,000,000,000,000,000 | 16 | Fix oobread crash in java parser ##crash
* Reported by @bet4it via @huntrdev
* BountyID: 229a2e0d-9e5c-402f-9a24-57fa2eb1aaa7
* Reproducer: poc4java |
ecb_ews_verify_changes (ECalCache *cal_cache,
icalcomponent_kind kind,
GSList *in_items, /* EEwsItem * */
GCancellable *cancellable)
{
GSList *items = NULL, *link;
g_return_val_if_fail (E_IS_CAL_CACHE (cal_cache), in_items);
for (link = in_items; link; link = g_slist_next (link)) {
EEwsItem *item = link... | 0 | [
"CWE-295"
] | evolution-ews | 915226eca9454b8b3e5adb6f2fff9698451778de | 151,202,402,477,009,900,000,000,000,000,000,000,000 | 42 | 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 |
bool cleanup_excluding_fields_processor(void *arg)
{ return field ? 0 : cleanup_processor(arg); } | 0 | [
"CWE-617"
] | server | 2e7891080667c59ac80f788eef4d59d447595772 | 182,831,662,563,165,450,000,000,000,000,000,000,000 | 2 | 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.... |
const envoy::config::listener::v3::Listener& config() const { return config_; } | 0 | [
"CWE-400"
] | envoy | dfddb529e914d794ac552e906b13d71233609bf7 | 38,965,085,341,738,280,000,000,000,000,000,000,000 | 1 | listener: Add configurable accepted connection limits (#153)
Add support for per-listener limits on accepted connections.
Signed-off-by: Tony Allen <tony@allen.gg> |
static MagickBooleanType WriteOnePNGImage(MngInfo *mng_info,
const ImageInfo *IMimage_info,Image *IMimage,ExceptionInfo *exception)
{
char
im_vers[32],
libpng_runv[32],
libpng_vers[32],
zlib_runv[32],
zlib_vers[32];
Image
*image;
ImageInfo
*image_info;
char
*name,
s[2];
... | 0 | [
"CWE-416"
] | ImageMagick | 916d7bbd2c66a286d379dbd94bc6035c8fab937c | 229,387,549,869,980,600,000,000,000,000,000,000,000 | 3,547 | Removed invalid free reported in #1791. |
int machine_check_generic(struct pt_regs *regs)
{
unsigned long reason = get_mc_reason(regs);
printk("Machine check in kernel mode.\n");
printk("Caused by (from SRR1=%lx): ", reason);
switch (reason & 0x601F0000) {
case 0x80000:
printk("Machine check signal\n");
break;
case 0: /* for 601 */
case 0x40000:
... | 0 | [] | linux | 5d176f751ee3c6eededd984ad409bff201f436a7 | 177,445,355,386,278,600,000,000,000,000,000,000,000 | 35 | powerpc: tm: Enable transactional memory (TM) lazily for userspace
Currently the MSR TM bit is always set if the hardware is TM capable.
This adds extra overhead as it means the TM SPRS (TFHAR, TEXASR and
TFAIR) must be swapped for each process regardless of if they use TM.
For processes that don't use TM the TM MSR ... |
nf_ct_frag6_reasm(struct frag_queue *fq, struct sk_buff *prev, struct net_device *dev)
{
struct sk_buff *fp, *head = fq->q.fragments;
int payload_len;
u8 ecn;
inet_frag_kill(&fq->q);
WARN_ON(head == NULL);
WARN_ON(head->ip_defrag_offset != 0);
ecn = ip_frag_ecn_table[fq->ecn];
if (unlikely(ecn == 0xff))
... | 0 | [
"CWE-20"
] | linux | 5d407b071dc369c26a38398326ee2be53651cfe4 | 300,446,202,847,744,080,000,000,000,000,000,000,000 | 131 | ip: frags: fix crash in ip_do_fragment()
A kernel crash occurrs when defragmented packet is fragmented
in ip_do_fragment().
In defragment routine, skb_orphan() is called and
skb->ip_defrag_offset is set. but skb->sk and
skb->ip_defrag_offset are same union member. so that
frag->sk is not NULL.
Hence crash occurrs in s... |
static int pptp_getname(struct socket *sock, struct sockaddr *uaddr,
int *usockaddr_len, int peer)
{
int len = sizeof(struct sockaddr_pppox);
struct sockaddr_pppox sp;
memset(&sp.sa_addr, 0, sizeof(sp.sa_addr));
sp.sa_family = AF_PPPOX;
sp.sa_protocol = PX_PROTO_PPTP;
sp.sa_addr.pptp = pppox_sk(sock->sk)->... | 0 | [
"CWE-200"
] | net | 09ccfd238e5a0e670d8178cf50180ea81ae09ae1 | 50,653,068,883,499,220,000,000,000,000,000,000,000 | 18 | pptp: verify sockaddr_len in pptp_bind() and pptp_connect()
Reported-by: Dmitry Vyukov <dvyukov@gmail.com>
Signed-off-by: Cong Wang <xiyou.wangcong@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net> |
static int opmul(RAsm *a, ut8 *data, const Opcode *op) {
int l = 0;
if ( op->operands[0].type & OT_QWORD ) {
data[l++] = 0x48;
}
switch (op->operands_count) {
case 1:
if ( op->operands[0].type & OT_WORD ) {
data[l++] = 0x66;
}
if (op->operands[0].type & OT_BYTE) {
data[l++] = 0xf6;
} else {
dat... | 0 | [
"CWE-119",
"CWE-125",
"CWE-787"
] | radare2 | 9b46d38dd3c4de6048a488b655c7319f845af185 | 174,334,805,396,817,300,000,000,000,000,000,000,000 | 27 | Fix #12372 and #12373 - Crash in x86 assembler (#12380)
0 ,0,[bP-bL-bP-bL-bL-r-bL-bP-bL-bL-
mov ,0,[ax+Bx-ax+Bx-ax+ax+Bx-ax+Bx--
leA ,0,[bP-bL-bL-bP-bL-bP-bL-60@bL-
leA ,0,[bP-bL-r-bP-bL-bP-bL-60@bL-
mov ,0,[ax+Bx-ax+Bx-ax+ax+Bx-ax+Bx-- |
int ff_set_ref_count(H264Context *h)
{
int ref_count[2], list_count;
int num_ref_idx_active_override_flag;
// set defaults, might be overridden a few lines later
ref_count[0] = h->pps.ref_count[0];
ref_count[1] = h->pps.ref_count[1];
if (h->slice_type_nos != AV_PICTURE_TYPE_I) {
unsign... | 0 | [
"CWE-703"
] | FFmpeg | 8a3b85f3a7952c54a2c36ba1797f7e0cde9f85aa | 177,789,967,204,296,500,000,000,000,000,000,000,000 | 53 | avcodec/h264: update current_sps & sps->new only after the whole slice header decoder and init code finished
This avoids them being cleared before the full initialization finished
Fixes out of array read
Fixes: asan_heap-oob_f0c5e6_7071_cov_1605985132_mov_h264_aac__Demo_FlagOfOurFathers.mov
Found-by: Mateusz "j00ru" ... |
gimp_channel_init (GimpChannel *channel)
{
gimp_rgba_set (&channel->color, 0.0, 0.0, 0.0, GIMP_OPACITY_OPAQUE);
channel->show_masked = FALSE;
/* Selection mask variables */
channel->boundary_known = FALSE;
channel->segs_in = NULL;
channel->segs_out = NULL;
channel->num_segs_in = 0;
... | 0 | [
"CWE-703"
] | gimp | 6ab90ecbbd7cc95901933f62227fd140c0576d55 | 108,765,075,406,516,030,000,000,000,000,000,000,000 | 19 | app: fix #8230 crash in gimp_layer_invalidate_boundary when channel is NULL
gimp_channel_is_empty returns FALSE if channel is NULL. This causes
gimp_layer_invalidate_boundary to crash if the mask channel is NULL.
With a NULL channel gimp_channel_is_empty should return TRUE, just like
the similar gimp_image_is_empty d... |
int qcow2_mark_consistent(BlockDriverState *bs)
{
BDRVQcowState *s = bs->opaque;
if (s->incompatible_features & QCOW2_INCOMPAT_CORRUPT) {
int ret = bdrv_flush(bs);
if (ret < 0) {
return ret;
}
s->incompatible_features &= ~QCOW2_INCOMPAT_CORRUPT;
return qcow2... | 0 | [
"CWE-476"
] | qemu | 11b128f4062dd7f89b14abc8877ff20d41b28be9 | 6,826,081,122,312,479,000,000,000,000,000,000,000 | 15 | qcow2: Fix NULL dereference in qcow2_open() error path (CVE-2014-0146)
The qcow2 code assumes that s->snapshots is non-NULL if s->nb_snapshots
!= 0. By having the initialisation of both fields separated in
qcow2_open(), any error occuring in between would cause the error path
to dereference NULL in qcow2_free_snapshot... |
static inline int get_amv(Mpeg4DecContext *ctx, int n)
{
MpegEncContext *s = &ctx->m;
int x, y, mb_v, sum, dx, dy, shift;
int len = 1 << (s->f_code + 4);
const int a = s->sprite_warping_accuracy;
if (s->workaround_bugs & FF_BUG_AMV)
len >>= s->quarter_sample;
if (s->real_sprite_war... | 0 | [
"CWE-703"
] | FFmpeg | 3edc3b159503d512c919b3d5902f7026e961823a | 50,219,869,252,177,640,000,000,000,000,000,000,000 | 46 | avcodec/mpeg4videodec: Check for bitstream overread in decode_vol_header()
Fixes out of array read
Fixes: 08e48e9daae7d8f8ab6dbe3919e797e5-asan_heap-oob_157461c_5295_cov_1266798650_firefing.mpg
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at> |
u32 hugetlb_fault_mutex_hash(struct address_space *mapping, pgoff_t idx)
{
return 0;
} | 0 | [
"CWE-362"
] | linux | 17743798d81238ab13050e8e2833699b54e15467 | 253,168,988,228,444,950,000,000,000,000,000,000,000 | 4 | mm/hugetlb: fix a race between hugetlb sysctl handlers
There is a race between the assignment of `table->data` and write value
to the pointer of `table->data` in the __do_proc_doulongvec_minmax() on
the other thread.
CPU0: CPU1:
proc_sys_write
... |
ecma_bigint_or (ecma_value_t left_value, /**< left BigInt value */
ecma_value_t right_value) /**< right BigInt value */
{
if (left_value == ECMA_BIGINT_ZERO)
{
return ecma_copy_value (right_value);
}
if (right_value == ECMA_BIGINT_ZERO)
{
return ecma_copy_value (left_value);
}
ec... | 0 | [
"CWE-416"
] | jerryscript | 3bcd48f72d4af01d1304b754ef19fe1a02c96049 | 144,707,969,585,332,630,000,000,000,000,000,000,000 | 45 | Improve parse_identifier (#4691)
Ascii string length is no longer computed during string allocation.
JerryScript-DCO-1.0-Signed-off-by: Daniel Batiz batizjob@gmail.com |
format_SET_MPLS_LABEL(const struct ofpact_mpls_label *a, struct ds *s)
{
ds_put_format(s, "%sset_mpls_label(%s%"PRIu32"%s)%s",
colors.paren, colors.end, ntohl(a->label),
colors.paren, colors.end);
} | 0 | [
"CWE-125"
] | ovs | 9237a63c47bd314b807cda0bd2216264e82edbe8 | 169,486,781,114,149,670,000,000,000,000,000,000,000 | 6 | ofp-actions: Avoid buffer overread in BUNDLE action decoding.
Reported-at: https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=9052
Signed-off-by: Ben Pfaff <blp@ovn.org>
Acked-by: Justin Pettit <jpettit@ovn.org> |
static __cold void io_free_req(struct io_kiocb *req)
{
struct io_ring_ctx *ctx = req->ctx;
io_req_put_rsrc(req);
io_dismantle_req(req);
io_put_task(req->task, 1);
spin_lock(&ctx->completion_lock);
wq_list_add_head(&req->comp_list, &ctx->locked_free_list);
ctx->locked_free_nr++;
spin_unlock(&ctx->completion_lo... | 0 | [
"CWE-416"
] | linux | 9cae36a094e7e9d6e5fe8b6dcd4642138b3eb0c7 | 323,974,319,708,730,770,000,000,000,000,000,000,000 | 13 | 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... |
AP_DECLARE(void) ap_destroy_sub_req(request_rec *r)
{
/* Reclaim the space */
apr_pool_destroy(r->pool);
} | 0 | [] | httpd | eb986059aa5aa0b6c1d52714ea83e3dd758afdd1 | 186,741,465,041,478,140,000,000,000,000,000,000,000 | 5 | Merge r1889036 from trunk:
legacy default slash-matching behavior w/ 'MergeSlashes OFF'
Submitted By: Ruediger Pluem
Reviewed By: covener, rpluem, ylavic
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/branches/2.4.x@1889038 13f79535-47bb-0310-9956-ffa450edef68 |
static void __attribute__((__noreturn__)) usage(FILE *out)
{
fputs(USAGE_HEADER, out);
fprintf(out, _(
" %1$s [-lhV]\n"
" %1$s -a [options]\n"
" %1$s [options] [--source] <source> | [--target] <directory>\n"
" %1$s [options] <source> <directory>\n"
" %1$s <operation> <mountpoint> [<target>]\n"),
program_i... | 0 | [
"CWE-200"
] | util-linux | 5ebbc3865d1e53ef42e5f121c41faab23dd59075 | 69,397,083,812,479,330,000,000,000,000,000,000,000 | 74 | mount: sanitize paths from non-root users
$ mount /root/.ssh/../../dev/sda2
mount: only root can mount UUID=17bc65ec-4125-4e7c-8a7d-e2795064c736 on /boot
this is too promiscuous. It seems better to ignore on command line
specified paths which are not resolve-able for non-root users.
Fixed version:
$ mount /root... |
ecma_bigint_to_bigint (ecma_value_t value, /**< any value */
bool allow_numbers) /**< converting ecma numbers is allowed */
{
bool free_value = false;
if (ecma_is_value_object (value))
{
value = ecma_op_object_default_value (ecma_get_object_from_value (value), ECMA_PREFERRED_TYPE_NUMBE... | 0 | [
"CWE-416"
] | jerryscript | 3bcd48f72d4af01d1304b754ef19fe1a02c96049 | 12,707,787,153,286,784,000,000,000,000,000,000,000 | 59 | Improve parse_identifier (#4691)
Ascii string length is no longer computed during string allocation.
JerryScript-DCO-1.0-Signed-off-by: Daniel Batiz batizjob@gmail.com |
void reset_render_context(ASS_Renderer *render_priv, ASS_Style *style)
{
style = handle_selective_style_overrides(render_priv, style);
init_font_scale(render_priv);
render_priv->state.c[0] = style->PrimaryColour;
render_priv->state.c[1] = style->SecondaryColour;
render_priv->state.c[2] = style->Ou... | 0 | [
"CWE-125"
] | libass | f4f48950788b91c6a30029cc28a240b834713ea7 | 255,807,743,377,498,030,000,000,000,000,000,000,000 | 40 | Fix line wrapping mode 0/3 bugs
This fixes two separate bugs:
a) Don't move a linebreak into the first symbol. This results in a empty
line at the front, which does not help to equalize line lengths at all.
Instead, merge line with the second one.
b) When moving a linebreak into a symbol that already is a break... |
static double mp_bitwise_right_shift(_cimg_math_parser& mp) {
return (double)((longT)_mp_arg(2)>>(unsigned int)_mp_arg(3));
} | 0 | [
"CWE-770"
] | cimg | 619cb58dd90b4e03ac68286c70ed98acbefd1c90 | 65,643,724,799,307,240,000,000,000,000,000,000,000 | 3 | CImg<>::load_bmp() and CImg<>::load_pandore(): Check that dimensions encoded in file does not exceed file size. |
static int piv_check_sw(struct sc_card *card, unsigned int sw1, unsigned int sw2)
{
struct sc_card_driver *iso_drv = sc_get_iso7816_driver();
int r;
piv_private_data_t * priv = PIV_DATA(card);
/* may be called before piv_init has allocated priv */
if (priv) {
/* need to save sw1 and sw2 if trying to determine... | 0 | [
"CWE-125"
] | OpenSC | 8fe377e93b4b56060e5bbfb6f3142ceaeca744fa | 326,725,020,700,923,800,000,000,000,000,000,000,000 | 42 | fixed out of bounds reads
Thanks to Eric Sesterhenn from X41 D-SEC GmbH
for reporting and suggesting security fixes. |
GF_Err gf_isom_set_high_dynamic_range_info(GF_ISOFile* movie, u32 trackNumber, u32 StreamDescriptionIndex, GF_MasteringDisplayColourVolumeInfo* mdcv, GF_ContentLightLevelInfo* clli)
{
GF_Err e;
GF_TrackBox* trak;
GF_SampleEntryBox* entry;
GF_SampleDescriptionBox* stsd;
e = CanAccessMovie(movie, GF_ISOM_OPEN_WRITE... | 0 | [
"CWE-476"
] | gpac | ebfa346eff05049718f7b80041093b4c5581c24e | 28,882,893,277,403,320,000,000,000,000,000,000,000 | 42 | fixed #1706 |
static u32 vmx_secondary_exec_control(struct vcpu_vmx *vmx)
{
u32 exec_control = vmcs_config.cpu_based_2nd_exec_ctrl;
if (!vm_need_virtualize_apic_accesses(vmx->vcpu.kvm))
exec_control &= ~SECONDARY_EXEC_VIRTUALIZE_APIC_ACCESSES;
if (vmx->vpid == 0)
exec_control &= ~SECONDARY_EXEC_ENABLE_VPID;
if (!enable_ept) ... | 0 | [] | kvm | a642fc305053cc1c6e47e4f4df327895747ab485 | 205,510,616,168,061,750,000,000,000,000,000,000,000 | 29 | kvm: vmx: handle invvpid vm exit gracefully
On systems with invvpid instruction support (corresponding bit in
IA32_VMX_EPT_VPID_CAP MSR is set) guest invocation of invvpid
causes vm exit, which is currently not handled and results in
propagation of unknown exit to userspace.
Fix this by installing an invvpid vm exit ... |
gpk_erase_card(sc_card_t *card)
{
struct gpk_private_data *priv = DRVDATA(card);
sc_apdu_t apdu;
u8 offset;
int r;
SC_FUNC_CALLED(card->ctx, SC_LOG_DEBUG_VERBOSE);
switch (card->type) {
case SC_CARD_TYPE_GPK_GPK4000_su256:
case SC_CARD_TYPE_GPK_GPK4000_sdo:
offset = 0x6B; /* courtesy gemplus hotline */
... | 0 | [
"CWE-125"
] | OpenSC | 8fe377e93b4b56060e5bbfb6f3142ceaeca744fa | 100,206,811,748,177,500,000,000,000,000,000,000,000 | 43 | fixed out of bounds reads
Thanks to Eric Sesterhenn from X41 D-SEC GmbH
for reporting and suggesting security fixes. |
static int ethtool_self_test(struct net_device *dev, char __user *useraddr)
{
struct ethtool_test test;
struct ethtool_ops *ops = dev->ethtool_ops;
u64 *data;
int ret;
if (!ops->self_test || !ops->self_test_count)
return -EOPNOTSUPP;
if (copy_from_user(&test, useraddr, sizeof(test)))
return -EFAULT;
test.... | 0 | [] | linux | e89e9cf539a28df7d0eb1d0a545368e9920b34ac | 287,975,874,044,632,200,000,000,000,000,000,000,000 | 32 | [IPv4/IPv6]: UFO Scatter-gather approach
Attached is kernel patch for UDP Fragmentation Offload (UFO) feature.
1. This patch incorporate the review comments by Jeff Garzik.
2. Renamed USO as UFO (UDP Fragmentation Offload)
3. udp sendfile support with UFO
This patches uses scatter-gather feature of skb to generate l... |
static Image *ReadTIFFImage(const ImageInfo *image_info,
ExceptionInfo *exception)
{
#define ThrowTIFFException(severity,message) \
{ \
if (tiff_pixels != (unsigned char *) NULL) \
tiff_pixels=(unsigned char *) RelinquishMagickMemory(tiff_pixels); \
if (quantum_info != (QuantumInfo *) NULL) \
quantum_info... | 0 | [
"CWE-399",
"CWE-772"
] | ImageMagick | 256825d4eb33dc301496710d15cf5a7ae924088b | 255,127,043,394,063,760,000,000,000,000,000,000,000 | 1,042 | Fixed possible memory leak reported in #1206 |
call_start(struct rpc_task *task)
{
struct rpc_clnt *clnt = task->tk_client;
dprintk("RPC: %5u call_start %s%d proc %s (%s)\n", task->tk_pid,
clnt->cl_protname, clnt->cl_vers,
rpc_proc_name(task),
(RPC_IS_ASYNC(task) ? "async" : "sync"));
/* Increment call count */
task->tk_msg.rpc_proc->p_count++;
clnt... | 0 | [
"CWE-400",
"CWE-399",
"CWE-703"
] | linux | 0b760113a3a155269a3fba93a409c640031dd68f | 195,270,841,327,294,760,000,000,000,000,000,000,000 | 14 | NLM: Don't hang forever on NLM unlock requests
If the NLM daemon is killed on the NFS server, we can currently end up
hanging forever on an 'unlock' request, instead of aborting. Basically,
if the rpcbind request fails, or the server keeps returning garbage, we
really want to quit instead of retrying.
Tested-by: Vasi... |
int ha_partition::rnd_pos(uchar * buf, uchar *pos)
{
uint part_id;
handler *file;
DBUG_ENTER("ha_partition::rnd_pos");
part_id= uint2korr((const uchar *) pos);
DBUG_ASSERT(part_id < m_tot_parts);
file= m_file[part_id];
m_last_part= part_id;
DBUG_RETURN(file->rnd_pos(buf, (pos + PARTITION_BYTES_IN_POS))... | 0 | [] | mysql-server | be901b60ae59c93848c829d1b0b2cb523ab8692e | 199,311,237,589,461,140,000,000,000,000,000,000,000 | 12 | Bug#26390632: CREATE TABLE CAN CAUSE MYSQL TO EXIT.
Analysis
========
CREATE TABLE of InnoDB table with a partition name
which exceeds the path limit can cause the server
to exit.
During the preparation of the partition name,
there was no check to identify whether the complete
path name for partition exceeds the max ... |
add_keyserver_modify (PKT_signature *sig,int enabled)
{
const byte *s;
size_t n;
int i;
char *buf;
/* The keyserver modify flag is a negative flag (i.e. no-modify) */
enabled=!enabled;
s = parse_sig_subpkt (sig->hashed, SIGSUBPKT_KS_FLAGS, &n );
/* Already set or cleared */
if (s && n &&
((ena... | 0 | [
"CWE-20"
] | gnupg | 2183683bd633818dd031b090b5530951de76f392 | 184,336,627,152,437,370,000,000,000,000,000,000,000 | 42 | Use inline functions to convert buffer data to scalars.
* common/host2net.h (buf16_to_ulong, buf16_to_uint): New.
(buf16_to_ushort, buf16_to_u16): New.
(buf32_to_size_t, buf32_to_ulong, buf32_to_uint, buf32_to_u32): New.
--
Commit 91b826a38880fd8a989318585eb502582636ddd8 was not enough to
avoid all sign extension on ... |
static int io_shutdown_prep(struct io_kiocb *req,
const struct io_uring_sqe *sqe)
{
if (unlikely(sqe->off || sqe->addr || sqe->rw_flags ||
sqe->buf_index || sqe->splice_fd_in))
return -EINVAL;
req->shutdown.how = READ_ONCE(sqe->len);
return 0;
} | 0 | [
"CWE-416"
] | linux | 9cae36a094e7e9d6e5fe8b6dcd4642138b3eb0c7 | 127,913,931,299,329,850,000,000,000,000,000,000,000 | 10 | 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... |
void WebContents::ResetManagedWebContents(bool async) {
if (async) {
// Browser context should be destroyed only after the WebContents,
// this is guaranteed in the sync mode by the order of declaration,
// in the async version we maintain a reference until the WebContents
// is destroyed.
// //el... | 0 | [
"CWE-200",
"CWE-668"
] | electron | 07a1c2a3e5845901f7e2eda9506695be58edc73c | 43,829,519,097,569,840,000,000,000,000,000,000,000 | 14 | fix: restrict sendToFrame to same-process frames by default (#26875) |
JBIG2Bitmap *JBIG2Bitmap::getSlice(unsigned int x, unsigned int y, unsigned int wA, unsigned int hA)
{
JBIG2Bitmap *slice;
unsigned int xx, yy;
if (!data) {
return nullptr;
}
slice = new JBIG2Bitmap(0, wA, hA);
if (slice->isOk()) {
slice->clearToZero();
for (yy = 0; yy ... | 0 | [
"CWE-476",
"CWE-190"
] | poppler | 27354e9d9696ee2bc063910a6c9a6b27c5184a52 | 222,193,585,535,460,820,000,000,000,000,000,000,000 | 25 | JBIG2Stream: Fix crash on broken file
https://github.com/jeffssh/CVE-2021-30860
Thanks to David Warren for the heads up |
static int raw_setsockopt(struct socket *sock, int level, int optname,
char __user *optval, int optlen)
{
struct sock *sk = sock->sk;
struct raw_sock *ro = raw_sk(sk);
struct can_filter *filter = NULL; /* dyn. alloc'ed filters */
struct can_filter sfilter; /* single filter */
struct net_device *dev =... | 0 | [
"CWE-200"
] | linux-2.6 | e84b90ae5eb3c112d1f208964df1d8156a538289 | 151,661,969,498,324,420,000,000,000,000,000,000,000 | 143 | can: Fix raw_getname() leak
raw_getname() can leak 10 bytes of kernel memory to user
(two bytes hole between can_family and can_ifindex,
8 bytes at the end of sockaddr_can structure)
Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
Acked-by: Oliver Hartkopp <oliver@hartkopp.net>
Signed-off-by: David S. Miller <d... |
unsigned int scalar7(const mp_func op,
const unsigned int arg1, const unsigned int arg2, const unsigned int arg3,
const unsigned int arg4, const unsigned int arg5, const unsigned int arg6,
const unsigned int arg7) {
const uns... | 0 | [
"CWE-770"
] | cimg | 619cb58dd90b4e03ac68286c70ed98acbefd1c90 | 255,076,793,394,432,230,000,000,000,000,000,000,000 | 16 | CImg<>::load_bmp() and CImg<>::load_pandore(): Check that dimensions encoded in file does not exceed file size. |
static void MapToLabels(const string& subscript, Labels* labels,
absl::flat_hash_map<char, int>* label_mapping) {
for (int i = 0; i < subscript.size(); ++i) {
const char label_char = subscript[i];
if (label_char == '.') {
labels->push_back(kEllipsisLabel);
i +... | 0 | [
"CWE-703",
"CWE-824"
] | tensorflow | f09caa532b6e1ac8d2aa61b7832c78c5b79300c6 | 269,972,592,379,462,180,000,000,000,000,000,000,000 | 17 | Fix EinsumHelper::ParseEquation to avoid uninitialized accesses.
EinsumHelper::ParseEquation is supposed to return true or false in
input_has_ellipsis and output_has_ellipsis to indicate whether there is
ellipsis in the inputs and output. Previously, when there is no ellipsis in the
inputs or output, the routine doesn... |
int security_socket_post_create(struct socket *sock, int family,
int type, int protocol, int kern)
{
return security_ops->socket_post_create(sock, family, type,
protocol, kern);
} | 0 | [] | linux-2.6 | ee18d64c1f632043a02e6f5ba5e045bb26a5465f | 136,252,895,632,536,370,000,000,000,000,000,000,000 | 6 | KEYS: Add a keyctl to install a process's session keyring on its parent [try #6]
Add a keyctl to install a process's session keyring onto its parent. This
replaces the parent's session keyring. Because the COW credential code does
not permit one process to change another process's credentials directly, the
change is... |
read_vhost_message(struct virtio_net *dev, int sockfd, struct vhu_msg_context *ctx)
{
int ret;
ret = read_fd_message(dev->ifname, sockfd, (char *)&ctx->msg, VHOST_USER_HDR_SIZE,
ctx->fds, VHOST_MEMORY_MAX_NREGIONS, &ctx->fd_num);
if (ret <= 0) {
return ret;
} else if (ret != VHOST_USER_HDR_SIZE) {
VHOST_LOG... | 0 | [
"CWE-125",
"CWE-787"
] | dpdk | 6442c329b9d2ded0f44b27d2016aaba8ba5844c5 | 180,722,638,425,687,300,000,000,000,000,000,000,000 | 31 | vhost: fix queue number check when setting inflight FD
In function vhost_user_set_inflight_fd, queue number in inflight
message is used to access virtqueue. However, queue number could
be larger than VHOST_MAX_VRING and cause write OOB as this number
will be used to write inflight info in virtqueue structure. This
pat... |
MemoryRegion *flatview_translate(struct uc_struct *uc, FlatView *fv, hwaddr addr, hwaddr *xlat,
hwaddr *plen, bool is_write,
MemTxAttrs attrs)
{
MemoryRegion *mr;
MemoryRegionSection section;
AddressSpace *as = NULL;
/* This can be MMIO,... | 0 | [
"CWE-476"
] | unicorn | 3d3deac5e6d38602b689c4fef5dac004f07a2e63 | 274,723,237,617,755,350,000,000,000,000,000,000,000 | 15 | Fix crash when mapping a big memory and calling uc_close |
static void sctp_generate_autoclose_event(unsigned long data)
{
struct sctp_association *asoc = (struct sctp_association *) data;
sctp_generate_timeout_event(asoc, SCTP_EVENT_TIMEOUT_AUTOCLOSE);
} | 0 | [] | linux | 196d67593439b03088913227093e374235596e33 | 230,581,908,655,443,400,000,000,000,000,000,000,000 | 5 | sctp: Add support to per-association statistics via a new SCTP_GET_ASSOC_STATS call
The current SCTP stack is lacking a mechanism to have per association
statistics. This is an implementation modeled after OpenSolaris'
SCTP_GET_ASSOC_STATS.
Userspace part will follow on lksctp if/when there is a general ACK on
this.
... |
int brcmf_net_attach(struct brcmf_if *ifp, bool rtnl_locked)
{
struct brcmf_pub *drvr = ifp->drvr;
struct net_device *ndev;
s32 err;
brcmf_dbg(TRACE, "Enter, bsscfgidx=%d mac=%pM\n", ifp->bsscfgidx,
ifp->mac_addr);
ndev = ifp->ndev;
/* set appropriate operations */
ndev->netdev_ops = &brcmf_netdev_ops_pri;... | 0 | [
"CWE-20"
] | linux | a4176ec356c73a46c07c181c6d04039fafa34a9f | 324,458,815,384,539,400,000,000,000,000,000,000,000 | 41 | brcmfmac: add subtype check for event handling in data path
For USB there is no separate channel being used to pass events
from firmware to the host driver and as such are passed over the
data path. In order to detect mock event messages an additional
check is needed on event subtype. This check is added conditionally... |
static const char *cmd_debug_log(cmd_parms *cmd, void *_dcfg, const char *p1)
{
directory_config *dcfg = (directory_config *)_dcfg;
apr_status_t rc;
dcfg->debuglog_name = ap_server_root_relative(cmd->pool, p1);
rc = apr_file_open(&dcfg->debuglog_fd, dcfg->debuglog_name,
APR_WRITE | ... | 0 | [
"CWE-20",
"CWE-611"
] | ModSecurity | d4d80b38aa85eccb26e3c61b04d16e8ca5de76fe | 245,056,294,977,400,360,000,000,000,000,000,000,000 | 18 | Added SecXmlExternalEntity |
int mingw_rmdir(const char *pathname)
{
int ret, tries = 0;
wchar_t wpathname[MAX_PATH];
if (xutftowcs_path(wpathname, pathname) < 0)
return -1;
while ((ret = _wrmdir(wpathname)) == -1 && tries < ARRAY_SIZE(delay)) {
if (!is_file_in_use_error(GetLastError()))
errno = err_win_to_posix(GetLastError());
if (... | 0 | [
"CWE-59",
"CWE-61"
] | git | 684dd4c2b414bcf648505e74498a608f28de4592 | 290,526,033,117,860,850,000,000,000,000,000,000,000 | 34 | checkout: fix bug that makes checkout follow symlinks in leading path
Before checking out a file, we have to confirm that all of its leading
components are real existing directories. And to reduce the number of
lstat() calls in this process, we cache the last leading path known to
contain only directories. However, wh... |
mt_copy(mrb_state *mrb, mt_tbl *t)
{
mt_tbl *t2;
size_t i;
if (t == NULL) return NULL;
if (t->alloc == 0) return NULL;
if (t->size == 0) return NULL;
t2 = mt_new(mrb);
for (i=0; i<t->alloc; i++) {
struct mt_elem *slot = &t->table[i];
if (slot->key) {
mt_put(mrb, t2, slot->key, slot->func_... | 0 | [
"CWE-476",
"CWE-190"
] | mruby | f5e10c5a79a17939af763b1dcf5232ce47e24a34 | 232,484,388,817,422,060,000,000,000,000,000,000,000 | 19 | proc.c: add `mrb_state` argument to `mrb_proc_copy()`.
The function may invoke the garbage collection and it requires
`mrb_state` to run. |
static struct ldb_message *ldb_msg_copy_shallow_impl(TALLOC_CTX *mem_ctx,
const struct ldb_message *msg)
{
struct ldb_message *msg2;
unsigned int i;
msg2 = talloc(mem_ctx, struct ldb_message);
if (msg2 == NULL) return NULL;
*msg2 = *msg;
msg2->elements = talloc_array(msg2, struct ldb_message_element,
... | 0 | [
"CWE-200"
] | samba | 7efe8182c165fbf17d2f88c173527a7a554e214b | 8,074,455,010,544,177,000,000,000,000,000,000,000 | 25 | CVE-2022-32746 ldb: Add flag to mark message element values as shared
When making a shallow copy of an ldb message, mark the message elements
of the copy as sharing their values with the message elements in the
original message.
This flag value will be heeded in the next commit.
BUG: https://bugzilla.samba.org/show_... |
Luv24toRGB(LogLuvState* sp, uint8* op, tmsize_t n)
{
uint32* luv = (uint32*) sp->tbuf;
uint8* rgb = (uint8*) op;
while (n-- > 0) {
float xyz[3];
LogLuv24toXYZ(*luv++, xyz);
XYZtoRGB24(xyz, rgb);
rgb += 3;
}
} | 0 | [
"CWE-787"
] | libtiff | aaab5c3c9d2a2c6984f23ccbc79702610439bc65 | 77,236,954,705,133,750,000,000,000,000,000,000,000 | 13 | * libtiff/tif_luv.c: fix potential out-of-bound writes in decode
functions in non debug builds by replacing assert()s by regular if
checks (bugzilla #2522).
Fix potential out-of-bound reads in case of short input data. |
static int get_crl_sk(X509_STORE_CTX *ctx, X509_CRL **pcrl,
X509_NAME *nm, STACK_OF(X509_CRL) *crls)
{
int i;
X509_CRL *crl, *best_crl = NULL;
for (i = 0; i < sk_X509_CRL_num(crls); i++) {
crl = sk_X509_CRL_value(crls, i);
if (X509_NAME_cmp(nm, X509_CRL_get_issuer(crl))... | 0 | [
"CWE-119"
] | openssl | fa57f74a3941db6b2efb2f43c6add914ec83db20 | 69,931,342,185,485,510,000,000,000,000,000,000,000 | 23 | Fix length checks in X509_cmp_time to avoid out-of-bounds reads.
Also tighten X509_cmp_time to reject more than three fractional
seconds in the time; and to reject trailing garbage after the offset.
CVE-2015-1789
Reviewed-by: Viktor Dukhovni <viktor@openssl.org>
Reviewed-by: Richard Levitte <levitte@openssl.org> |
evalfun(struct funcnode *func, int argc, char **argv, int flags)
{
volatile struct shparam saveparam;
struct jmploc *volatile savehandler;
struct jmploc jmploc;
int e;
int savefuncline;
int saveloopnest;
saveparam = shellparam;
savefuncline = funcline;
saveloopnest = loopnest;
savehandler = handler;
if ((e ... | 0 | [] | dash | 29d6f2148f10213de4e904d515e792d2cf8c968e | 122,046,087,746,783,330,000,000,000,000,000,000,000 | 40 | eval: Check nflag in evaltree instead of cmdloop
This patch moves the nflag check from cmdloop into evaltree. This
is so that nflag will be in force even if we enter the shell via a
path other than cmdloop, e.g., through sh -c.
Reported-by: Joey Hess <id@joeyh.name>
Signed-off-by: Herbert Xu <herbert@gondor.apana.or... |
void __khugepaged_exit(struct mm_struct *mm)
{
struct mm_slot *mm_slot;
int free = 0;
spin_lock(&khugepaged_mm_lock);
mm_slot = get_mm_slot(mm);
if (mm_slot && khugepaged_scan.mm_slot != mm_slot) {
hlist_del(&mm_slot->hash);
list_del(&mm_slot->mm_node);
free = 1;
}
if (free) {
spin_unlock(&khugepaged_m... | 0 | [
"CWE-399"
] | linux | 78f11a255749d09025f54d4e2df4fbcb031530e2 | 249,714,507,788,414,800,000,000,000,000,000,000,000 | 33 | mm: thp: fix /dev/zero MAP_PRIVATE and vm_flags cleanups
The huge_memory.c THP page fault was allowed to run if vm_ops was null
(which would succeed for /dev/zero MAP_PRIVATE, as the f_op->mmap wouldn't
setup a special vma->vm_ops and it would fallback to regular anonymous
memory) but other THP logics weren't fully ac... |
int MYSQL_BIN_LOG::close_purge_index_file()
{
int error= 0;
DBUG_ENTER("MYSQL_BIN_LOG::close_purge_index_file");
if (my_b_inited(&purge_index_file))
{
end_io_cache(&purge_index_file);
error= my_close(purge_index_file.file, MYF(0));
}
my_delete(purge_index_file_name, MYF(0));
bzero((char*) &purge... | 0 | [
"CWE-264"
] | mysql-server | 48bd8b16fe382be302c6f0b45931be5aa6f29a0e | 313,417,511,008,017,550,000,000,000,000,000,000,000 | 16 | 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... |
bdecode_node bdecode_node::non_owning() const
{
// if we're not a root, just return a copy of ourself
if (m_tokens.empty()) return *this;
// otherwise, return a reference to this node, but without
// being an owning root node
return bdecode_node(&m_tokens[0], m_buffer, m_buffer_size, m_token_idx);
} | 0 | [
"CWE-125"
] | libtorrent | ec30a5e9ec703afb8abefba757c6d401303b53db | 337,234,345,495,649,200,000,000,000,000,000,000,000 | 9 | fix out-of-bounds read in bdecode
Fixes #2099 |
static struct bio *bio_copy_kern(struct request_queue *q, void *data,
unsigned int len, gfp_t gfp_mask, int reading)
{
unsigned long kaddr = (unsigned long)data;
unsigned long end = (kaddr + len + PAGE_SIZE - 1) >> PAGE_SHIFT;
unsigned long start = kaddr >> PAGE_SHIFT;
struct bio *bio;
void *p = data;
int nr_pa... | 0 | [
"CWE-200"
] | linux | cc8f7fe1f5eab010191aa4570f27641876fa1267 | 303,855,384,279,556,270,000,000,000,000,000,000,000 | 56 | block-map: add __GFP_ZERO flag for alloc_page in function bio_copy_kern
Add __GFP_ZERO flag for alloc_page in function bio_copy_kern to initialize
the buffer of a bio.
Signed-off-by: Haimin Zhang <tcs.kernel@gmail.com>
Reviewed-by: Chaitanya Kulkarni <kch@nvidia.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Link: ... |
isis_print_mt_capability_subtlv(netdissect_options *ndo,
const uint8_t *tptr, int len)
{
int stlv_type, stlv_len, tmp;
while (len > 2)
{
ND_TCHECK2(*tptr, 2);
stlv_type = *(tptr++);
stlv_len = *(tptr++);
/* first lets see if we know the subTLVs name*/
ND_PRIN... | 0 | [
"CWE-125",
"CWE-787"
] | tcpdump | b20e1639dbac84b3fcb393858521c13ad47a9d70 | 118,527,614,125,380,520,000,000,000,000,000,000,000 | 124 | CVE-2017-13026/IS-IS: Clean up processing of subTLVs.
Add bounds checks, do a common check to make sure we captured the entire
subTLV, add checks to make sure the subTLV fits within the TLV.
This fixes a buffer over-read discovered by Bhargava Shastry,
SecT/TU Berlin.
Add tests using the capture files supplied by th... |
static UINT rdpei_recv_pdu(RDPEI_CHANNEL_CALLBACK* callback, wStream* s)
{
UINT16 eventId;
UINT32 pduLength;
UINT error;
Stream_Read_UINT16(s, eventId); /* eventId (2 bytes) */
Stream_Read_UINT32(s, pduLength); /* pduLength (4 bytes) */
#ifdef WITH_DEBUG_RDPEI
WLog_DBG(TAG, "rdpei_recv_pdu: eventId: %" PRIu16 "... | 1 | [
"CWE-125"
] | FreeRDP | 6b485b146a1b9d6ce72dfd7b5f36456c166e7a16 | 50,489,604,797,886,400,000,000,000,000,000,000,000 | 53 | Fixed oob read in irp_write and similar |
static void opj_tcd_code_block_dec_deallocate(opj_tcd_precinct_t * p_precinct)
{
OPJ_UINT32 cblkno, l_nb_code_blocks;
opj_tcd_cblk_dec_t * l_code_block = p_precinct->cblks.dec;
if (l_code_block) {
/*fprintf(stderr,"deallocate codeblock:{\n");*/
/*fprintf(stderr,"\t x0=%d, y0=%d, x1=%d, y1=%... | 0 | [
"CWE-119",
"CWE-787"
] | openjpeg | 397f62c0a838e15d667ef50e27d5d011d2c79c04 | 297,714,395,684,474,750,000,000,000,000,000,000,000 | 34 | Fix write heap buffer overflow in opj_mqc_byteout(). Discovered by Ke Liu of Tencent's Xuanwu LAB (#835) |
int ssl3_get_cert_status(SSL *s)
{
int ok, al;
unsigned long resplen, n;
const unsigned char *p;
n = s->method->ssl_get_message(s,
SSL3_ST_CR_CERT_STATUS_A,
SSL3_ST_CR_CERT_STATUS_B,
SSL3_MT_CERTIFI... | 0 | [
"CWE-362"
] | openssl | 98ece4eebfb6cd45cc8d550c6ac0022965071afc | 13,314,422,574,417,710,000,000,000,000,000,000,000 | 59 | Fix race condition in NewSessionTicket
If a NewSessionTicket is received by a multi-threaded client when
attempting to reuse a previous ticket then a race condition can occur
potentially leading to a double free of the ticket data.
CVE-2015-1791
This also fixes RT#3808 where a session ID is changed for a session alr... |
int ExpressionRegex::execute(RegexExecutionState* regexState) const {
invariant(regexState);
invariant(!regexState->nullish());
invariant(regexState->pcrePtr);
int execResult = pcre_exec(regexState->pcrePtr.get(),
nullptr,
regexState->input-... | 0 | [
"CWE-190"
] | mongo | 21d8699ed6c517b45e1613e20231cd8eba894985 | 209,031,738,197,493,760,000,000,000,000,000,000,000 | 22 | SERVER-43699 $mod should not overflow for large negative values |
static OPJ_BOOL opj_j2k_exec ( opj_j2k_t * p_j2k,
opj_procedure_list_t * p_procedure_list,
opj_stream_private_t *p_stream,
opj_event_mgr_t * p_manager )
{
OPJ_BOOL (** l_procedure) (opj_j2k_t ... | 0 | [
"CWE-416"
] | openjpeg | 940100c28ae28931722290794889cf84a92c5f6f | 251,980,492,157,794,430,000,000,000,000,000,000,000 | 27 | Fix potential use-after-free in opj_j2k_write_mco function
Fixes #563 |
static int __vxlan_fdb_delete(struct vxlan_dev *vxlan,
const unsigned char *addr, union vxlan_addr ip,
__be16 port, __be32 src_vni, __be32 vni,
u32 ifindex, bool swdev_notify)
{
struct vxlan_fdb *f;
struct vxlan_rdst *rd = NULL;
int err = -ENOENT;
f = vxlan_find_mac(vxlan, addr, src_vni)... | 0 | [] | net | 6c8991f41546c3c472503dff1ea9daaddf9331c2 | 156,796,629,330,474,630,000,000,000,000,000,000,000 | 32 | 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... |
static int pfkey_process(struct sock *sk, struct sk_buff *skb, const struct sadb_msg *hdr)
{
void *ext_hdrs[SADB_EXT_MAX];
int err;
/* Non-zero return value of pfkey_broadcast() does not always signal
* an error and even on an actual error we may still want to process
* the message so rather ignore the return v... | 0 | [
"CWE-362"
] | linux | ba953a9d89a00c078b85f4b190bc1dde66fe16b5 | 114,365,429,316,846,140,000,000,000,000,000,000,000 | 21 | af_key: Do not call xfrm_probe_algs in parallel
When namespace support was added to xfrm/afkey, it caused the
previously single-threaded call to xfrm_probe_algs to become
multi-threaded. This is buggy and needs to be fixed with a mutex.
Reported-by: Abhishek Shah <abhishek.shah@columbia.edu>
Fixes: 283bc9f35bbb ("xf... |
static void vnc_client_write_locked(VncState *vs)
{
#ifdef CONFIG_VNC_SASL
if (vs->sasl.conn &&
vs->sasl.runSSF &&
!vs->sasl.waitWriteSSF) {
vnc_client_write_sasl(vs);
} else
#endif /* CONFIG_VNC_SASL */
{
vnc_client_write_plain(vs);
}
} | 0 | [
"CWE-401"
] | qemu | 6bf21f3d83e95bcc4ba35a7a07cc6655e8b010b0 | 153,238,091,471,603,430,000,000,000,000,000,000,000 | 13 | vnc: fix memory leak when vnc disconnect
Currently when qemu receives a vnc connect, it creates a 'VncState' to
represent this connection. In 'vnc_worker_thread_loop' it creates a
local 'VncState'. The connection 'VcnState' and local 'VncState' exchange
data in 'vnc_async_encoding_start' and 'vnc_async_encoding_end'.
... |
cnt_recv_prep(struct req *req, const char *ci)
{
const char *xff;
if (req->restarts == 0) {
/*
* This really should be done earlier, but we want to capture
* it in the VSL log.
*/
http_CollectHdr(req->http, H_X_Forwarded_For);
if (http_GetHdr(req->http, H_X_Forwarded_For, &xff)) {
http_Unset(req->h... | 1 | [
"CWE-212"
] | varnish-cache | bd7b3d6d47ccbb5e1747126f8e2a297f38e56b8c | 11,672,790,114,875,600,000,000,000,000,000,000,000 | 36 | Clear err_code and err_reason at start of request handling
req->err_code and req->err_reason are set when going to synthetic
handling. From there the resp.reason HTTP field is set from
req->err_reason if set, or the generic code based on req->err_code is used
if it was NULL. This patch clears these members so that a v... |
void crypto_remove_final(struct list_head *list)
{
struct crypto_alg *alg;
struct crypto_alg *n;
list_for_each_entry_safe(alg, n, list, cra_list) {
list_del_init(&alg->cra_list);
crypto_alg_put(alg);
}
} | 0 | [
"CWE-284",
"CWE-264",
"CWE-269"
] | linux | 4943ba16bbc2db05115707b3ff7b4874e9e3c560 | 265,491,001,249,372,670,000,000,000,000,000,000,000 | 10 | crypto: include crypto- module prefix in template
This adds the module loading prefix "crypto-" to the template lookup
as well.
For example, attempting to load 'vfat(blowfish)' via AF_ALG now correctly
includes the "crypto-" prefix at every level, correctly rejecting "vfat":
net-pf-38
algif-hash
crypto-vfat(blowf... |
gnome_desktop_thumbnail_script_exec (const char *cmd,
int size,
const char *uri,
GError **error)
{
g_autofree char *error_out = NULL;
g_auto(GStrv) expanded_script = NULL;
int exit_status;
gboolean ret;
GBytes *image = NULL;
ScriptExec *exec;
exec = script_exec_n... | 0 | [] | nautilus | 2ddba428ef2b13d0620bd599c3635b9c11044659 | 165,652,418,179,901,460,000,000,000,000,000,000,000 | 41 | Update gnome-desktop code
Closes https://gitlab.gnome.org/GNOME/nautilus/issues/987 |
static int nft_basechain_init(struct nft_base_chain *basechain, u8 family,
struct nft_chain_hook *hook, u32 flags)
{
struct nft_chain *chain;
struct nft_hook *h;
basechain->type = hook->type;
INIT_LIST_HEAD(&basechain->hook_list);
chain = &basechain->chain;
if (nft_base_chain_netdev(family, hook->num))... | 0 | [
"CWE-400",
"CWE-703"
] | linux | e02f0d3970404bfea385b6edb86f2d936db0ea2b | 331,175,646,678,084,700,000,000,000,000,000,000,000 | 31 | netfilter: nf_tables: disallow binding to already bound chain
Update nft_data_init() to report EINVAL if chain is already bound.
Fixes: d0e2c7de92c7 ("netfilter: nf_tables: add NFT_CHAIN_BINDING")
Reported-by: Gwangun Jung <exsociety@gmail.com>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> |
static int verify_policy_type(u8 type)
{
switch (type) {
case XFRM_POLICY_TYPE_MAIN:
#ifdef CONFIG_XFRM_SUB_POLICY
case XFRM_POLICY_TYPE_SUB:
#endif
break;
default:
return -EINVAL;
}
return 0;
} | 0 | [
"CWE-264"
] | net | 90f62cf30a78721641e08737bda787552428061e | 44,457,221,366,198,300,000,000,000,000,000,000,000 | 15 | 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.
... |
bgp_attr_default_intern (u_char origin)
{
struct attr attr;
struct attr *new;
memset (&attr, 0, sizeof (struct attr));
bgp_attr_extra_get (&attr);
bgp_attr_default_set(&attr, origin);
new = bgp_attr_intern (&attr);
bgp_attr_extra_free (&attr);
aspath_unintern (&new->aspath);
return new;
} | 0 | [] | quagga | 8794e8d229dc9fe29ea31424883433d4880ef408 | 47,438,454,302,229,060,000,000,000,000,000,000,000 | 16 | bgpd: Fix regression in args consolidation, total should be inited from args
* bgp_attr.c: (bgp_attr_unknown) total should be initialised from the args. |
static void sp_node_init(struct sp_node *node, unsigned long start,
unsigned long end, struct mempolicy *pol)
{
node->start = start;
node->end = end;
node->policy = pol;
} | 0 | [
"CWE-388"
] | linux | cf01fb9985e8deb25ccf0ea54d916b8871ae0e62 | 177,219,190,065,642,900,000,000,000,000,000,000,000 | 7 | mm/mempolicy.c: fix error handling in set_mempolicy and mbind.
In the case that compat_get_bitmap fails we do not want to copy the
bitmap to the user as it will contain uninitialized stack data and leak
sensitive data.
Signed-off-by: Chris Salls <salls@cs.ucsb.edu>
Signed-off-by: Linus Torvalds <torvalds@linux-founda... |
static void squashfs_stat(char *source)
{
time_t mkfs_time = (time_t) sBlk.s.mkfs_time;
struct tm *t = use_localtime ? localtime(&mkfs_time) :
gmtime(&mkfs_time);
char *mkfs_str = asctime(t);
#if __BYTE_ORDER == __BIG_ENDIAN
printf("Found a valid %sSQUASHFS %d:%d superblock on %s.\n",
swap ? "little endian ... | 0 | [
"CWE-200",
"CWE-59",
"CWE-22"
] | squashfs-tools | e0485802ec72996c20026da320650d8362f555bd | 261,229,164,687,668,760,000,000,000,000,000,000,000 | 41 | Unsquashfs: additional write outside destination directory exploit fix
An issue on github (https://github.com/plougher/squashfs-tools/issues/72)
showed how some specially crafted Squashfs filesystems containing
invalid file names (with '/' and '..') can cause Unsquashfs to write
files outside of the destination direct... |
static inline struct frag_queue *fq_find(struct net *net, __be32 id,
u32 user, struct in6_addr *src,
struct in6_addr *dst)
{
struct inet_frag_queue *q;
struct ip6_create_arg arg;
unsigned int hash;
arg.id = id;
arg.user = user;
arg.src = src;
arg.dst = dst;
read_lock_bh(&nf_frags.lock);
hash = in... | 0 | [] | linux | 3ef0eb0db4bf92c6d2510fe5c4dc51852746f206 | 222,325,954,294,138,500,000,000,000,000,000,000,000 | 26 | net: frag, move LRU list maintenance outside of rwlock
Updating the fragmentation queues LRU (Least-Recently-Used) list,
required taking the hash writer lock. However, the LRU list isn't
tied to the hash at all, so we can use a separate lock for it.
Original-idea-by: Florian Westphal <fw@strlen.de>
Signed-off-by: Je... |
in_csum(const uint16_t *addr, size_t len, uint32_t csum, uint32_t *acc)
{
register size_t nleft = len;
const uint16_t *w = addr;
register uint16_t answer;
register uint32_t sum = csum;
/*
* Our algorithm is simple, using a 32 bit accumulator (sum),
* we add sequential 16 bit words to it, and at the end, fol... | 0 | [
"CWE-59",
"CWE-61"
] | keepalived | 04f2d32871bb3b11d7dc024039952f2fe2750306 | 152,953,414,475,488,440,000,000,000,000,000,000,000 | 33 | 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 ... |
explicit BoostedTreesCalculateBestFeatureSplitV2(
OpKernelConstruction* const context)
: OpKernel(context) {
OP_REQUIRES_OK(context, context->GetAttr("logits_dimension", &logits_dim_));
OP_REQUIRES_OK(context, context->GetAttr("num_features", &num_features_));
} | 0 | [
"CWE-125",
"CWE-369"
] | tensorflow | e84c975313e8e8e38bb2ea118196369c45c51378 | 108,780,669,935,181,480,000,000,000,000,000,000,000 | 6 | In tf.raw_ops.BoostedTreesSparseCalculateBestFeatureSplit, limit stat_dim in stats_summary_indices to under stats_dims in stats_summary_shape
PiperOrigin-RevId: 387171191
Change-Id: I83ca8a75b22aa78c037e8b98779da6cced16bfaa |
int unit_deserialize_skip(FILE *f) {
int r;
assert(f);
/* Skip serialized data for this unit. We don't know what it is. */
for (;;) {
_cleanup_free_ char *line = NULL;
char *l;
r = read_line(f, LONG_LINE_MAX, &line);
if (... | 0 | [
"CWE-269"
] | systemd | bf65b7e0c9fc215897b676ab9a7c9d1c688143ba | 151,466,329,413,560,950,000,000,000,000,000,000,000 | 23 | core: imply NNP and SUID/SGID restriction for DynamicUser=yes service
Let's be safe, rather than sorry. This way DynamicUser=yes services can
neither take benefit of, nor create SUID/SGID binaries.
Given that DynamicUser= is a recent addition only we should be able to
get away with turning this on, even though this i... |
xmlTextReaderXmlLang(xmlTextReaderPtr reader) {
if (reader == NULL)
return(NULL);
if (reader->node == NULL)
return(NULL);
return(xmlNodeGetLang(reader->node));
} | 0 | [
"CWE-399"
] | libxml2 | 213f1fe0d76d30eaed6e5853057defc43e6df2c9 | 97,427,362,784,597,340,000,000,000,000,000,000,000 | 7 | CVE-2015-1819 Enforce the reader to run in constant memory
One of the operation on the reader could resolve entities
leading to the classic expansion issue. Make sure the
buffer used for xmlreader operation is bounded.
Introduce a new allocation type for the buffers for this effect. |
static void ioport_write(void *opaque, uint32_t addr, uint32_t val)
{
PCIQXLDevice *d = opaque;
uint32_t io_port = addr - d->io_base;
switch (io_port) {
case QXL_IO_RESET:
case QXL_IO_SET_MODE:
case QXL_IO_MEMSLOT_ADD:
case QXL_IO_MEMSLOT_DEL:
case QXL_IO_CREATE_PRIMARY:
case QXL_IO... | 1 | [] | qemu-kvm | 5ff4e36c804157bd84af43c139f8cd3a59722db9 | 316,514,169,486,879,240,000,000,000,000,000,000,000 | 113 | qxl: async io support using new spice api
Some of the QXL port i/o commands are waiting for the spice server to
complete certain actions. Add async versions for these commands, so we
don't block the vcpu while the spice server processses the command.
Instead the qxl device will raise an IRQ when done.
The async comm... |
HeaderMapImpl::HeaderEntryImpl& HeaderMapImpl::maybeCreateInline(HeaderEntryImpl** entry,
const LowerCaseString& key,
HeaderString&& value) {
if (*entry) {
value.clear();
return **... | 0 | [
"CWE-400",
"CWE-703"
] | envoy | afc39bea36fd436e54262f150c009e8d72db5014 | 50,691,742,735,470,530,000,000,000,000,000,000,000 | 14 | Track byteSize of HeaderMap internally.
Introduces a cached byte size updated internally in HeaderMap. The value
is stored as an optional, and is cleared whenever a non-const pointer or
reference to a HeaderEntry is accessed. The cached value can be set with
refreshByteSize() which performs an iteration over the Heade... |
static void load_vmcs12_host_state(struct kvm_vcpu *vcpu,
struct vmcs12 *vmcs12)
{
struct kvm_segment seg;
if (vmcs12->vm_exit_controls & VM_EXIT_LOAD_IA32_EFER)
vcpu->arch.efer = vmcs12->host_ia32_efer;
else if (vmcs12->vm_exit_controls & VM_EXIT_HOST_ADDR_SPACE_SIZE)
vcpu->arch.efer |= (EFER_LMA | EFER... | 0 | [] | kvm | a642fc305053cc1c6e47e4f4df327895747ab485 | 211,079,946,111,516,530,000,000,000,000,000,000,000 | 124 | kvm: vmx: handle invvpid vm exit gracefully
On systems with invvpid instruction support (corresponding bit in
IA32_VMX_EPT_VPID_CAP MSR is set) guest invocation of invvpid
causes vm exit, which is currently not handled and results in
propagation of unknown exit to userspace.
Fix this by installing an invvpid vm exit ... |
size_t ZSTD_CCtx_refPrefix(ZSTD_CCtx* cctx, const void* prefix, size_t prefixSize)
{
return ZSTD_CCtx_refPrefix_advanced(cctx, prefix, prefixSize, ZSTD_dct_rawContent);
} | 0 | [
"CWE-362"
] | zstd | 3e5cdf1b6a85843e991d7d10f6a2567c15580da0 | 223,457,181,447,601,470,000,000,000,000,000,000,000 | 4 | fixed T36302429 |
cifs_get_tcp_session(struct smb_vol *volume_info)
{
struct TCP_Server_Info *tcp_ses = NULL;
struct sockaddr_storage addr;
struct sockaddr_in *sin_server = (struct sockaddr_in *) &addr;
struct sockaddr_in6 *sin_server6 = (struct sockaddr_in6 *) &addr;
int rc;
memset(&addr, 0, sizeof(struct sockaddr_storage));
c... | 0 | [
"CWE-20"
] | linux | 70945643722ffeac779d2529a348f99567fa5c33 | 255,372,489,296,652,200,000,000,000,000,000,000,000 | 145 | cifs: always do is_path_accessible check in cifs_mount
Currently, we skip doing the is_path_accessible check in cifs_mount if
there is no prefixpath. I have a report of at least one server however
that allows a TREE_CONNECT to a share that has a DFS referral at its
root. The reporter in this case was using a UNC that ... |
xmlDictQLookup(xmlDictPtr dict, const xmlChar *prefix, const xmlChar *name) {
unsigned long okey, key, nbi = 0;
xmlDictEntryPtr entry;
xmlDictEntryPtr insert;
const xmlChar *ret;
unsigned int len, plen, l;
if ((dict == NULL) || (name == NULL))
return(NULL);
if (prefix == NULL)
retu... | 0 | [
"CWE-119"
] | libxml2 | 6360a31a84efe69d155ed96306b9a931a40beab9 | 147,468,554,162,670,840,000,000,000,000,000,000,000 | 93 | CVE-2015-7497 Avoid an heap buffer overflow in xmlDictComputeFastQKey
For https://bugzilla.gnome.org/show_bug.cgi?id=756528
It was possible to hit a negative offset in the name indexing
used to randomize the dictionary key generation
Reported and fix provided by David Drysdale @ Google |
static inline u32 keepalive_time_elapsed(const struct tcp_sock *tp)
{
const struct inet_connection_sock *icsk = &tp->inet_conn;
return min_t(u32, tcp_time_stamp - icsk->icsk_ack.lrcvtime,
tcp_time_stamp - tp->rcv_tstamp);
} | 0 | [
"CWE-416",
"CWE-269"
] | linux | bb1fceca22492109be12640d49f5ea5a544c6bb4 | 180,664,203,543,868,140,000,000,000,000,000,000,000 | 7 | tcp: fix use after free in tcp_xmit_retransmit_queue()
When tcp_sendmsg() allocates a fresh and empty skb, it puts it at the
tail of the write queue using tcp_add_write_queue_tail()
Then it attempts to copy user data into this fresh skb.
If the copy fails, we undo the work and remove the fresh skb.
Unfortunately, t... |
SmartArrayPointer<char> GetGVNFlagsString(GVNFlagSet flags) {
char underlying_buffer[kLastFlag * 128];
Vector<char> buffer(underlying_buffer, sizeof(underlying_buffer));
#if DEBUG
int offset = 0;
const char* separator = "";
const char* comma = ", ";
buffer[0] = 0;
uint32_t set_depends_on = 0;
uint32_t s... | 0 | [] | node | fd80a31e0697d6317ce8c2d289575399f4e06d21 | 8,017,850,465,771,217,000,000,000,000,000,000,000 | 84 | 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... |
static int decode_slice_header(H264Context *h, H264Context *h0)
{
unsigned int first_mb_in_slice;
unsigned int pps_id;
int ret;
unsigned int slice_type, tmp, i, j;
int last_pic_structure, last_pic_droppable;
int must_reinit;
int needs_reinit = 0;
int field_pic_flag, bottom_field_flag;
... | 1 | [
"CWE-703"
] | FFmpeg | 8a3b85f3a7952c54a2c36ba1797f7e0cde9f85aa | 24,783,762,682,806,170,000,000,000,000,000,000,000 | 694 | avcodec/h264: update current_sps & sps->new only after the whole slice header decoder and init code finished
This avoids them being cleared before the full initialization finished
Fixes out of array read
Fixes: asan_heap-oob_f0c5e6_7071_cov_1605985132_mov_h264_aac__Demo_FlagOfOurFathers.mov
Found-by: Mateusz "j00ru" ... |
static int cap_inode_link(struct dentry *old_dentry, struct inode *inode,
struct dentry *new_dentry)
{
return 0;
} | 0 | [] | linux-2.6 | ee18d64c1f632043a02e6f5ba5e045bb26a5465f | 294,393,981,334,092,680,000,000,000,000,000,000,000 | 5 | KEYS: Add a keyctl to install a process's session keyring on its parent [try #6]
Add a keyctl to install a process's session keyring onto its parent. This
replaces the parent's session keyring. Because the COW credential code does
not permit one process to change another process's credentials directly, the
change is... |
_fill_xrgb32_lerp_spans (void *abstract_renderer, int y, int h,
const cairo_half_open_span_t *spans, unsigned num_spans)
{
cairo_image_span_renderer_t *r = abstract_renderer;
if (num_spans == 0)
return CAIRO_STATUS_SUCCESS;
if (likely(h == 1)) {
do {
uint8_t a = mul8_8 (spans[0].coverage, r->op... | 1 | [
"CWE-787"
] | cairo | c986a7310bb06582b7d8a566d5f007ba4e5e75bf | 193,829,035,771,489,200,000,000,000,000,000,000,000 | 42 | image: Enable inplace compositing with opacities for general routines
On a SNB i5-2500:
Speedups
========
firefox-chalkboard 34284.16 -> 19637.40: 1.74x speedup
swfdec-giant-steps 778.35 -> 665.37: 1.17x speedup
ocitysmap 485.64 -> 431.94: 1.12x speedup
Slowdowns
===... |
static int extract_min_max(IPAddressOrRange *aor,
unsigned char *min, unsigned char *max, int length)
{
if (aor == NULL || min == NULL || max == NULL)
return 0;
switch (aor->type) {
case IPAddressOrRange_addressPrefix:
return (addr_expand(min, aor->u.addressPrefix,... | 0 | [
"CWE-119",
"CWE-787"
] | openssl | 068b963bb7afc57f5bdd723de0dd15e7795d5822 | 23,525,152,507,353,740,000,000,000,000,000,000,000 | 15 | Avoid out-of-bounds read
Fixes CVE 2017-3735
Reviewed-by: Kurt Roeckx <kurt@roeckx.be>
(Merged from https://github.com/openssl/openssl/pull/4276)
(cherry picked from commit b23171744b01e473ebbfd6edad70c1c3825ffbcd) |
check_no_proxy(char *domain)
{
TextListItem *tl;
volatile int ret = 0;
MySignalHandler(*volatile prevtrap) (SIGNAL_ARG) = NULL;
if (NO_proxy_domains == NULL || NO_proxy_domains->nitem == 0 ||
domain == NULL)
return 0;
for (tl = NO_proxy_domains->first; tl != NULL; tl = tl->next) {
if (domain_mat... | 0 | [
"CWE-119"
] | w3m | ba9d78faeba9024c3e8840579c3b0e959ae2cb0f | 131,686,969,676,735,760,000,000,000,000,000,000,000 | 103 | Prevent global-buffer-overflow in parseURL()
Bug-Debian: https://github.com/tats/w3m/issues/41 |
R_API RBinJavaCPTypeObj *r_bin_java_find_cp_ref_info_from_name_and_type(RBinJavaObj *bin, ut16 name_idx, ut16 descriptor_idx) {
RBinJavaCPTypeObj *obj = r_bin_java_find_cp_name_and_type_info (bin, name_idx, descriptor_idx);
if (obj) {
return r_bin_java_find_cp_ref_info (bin, obj->metas->ord);
}
return NULL;
} | 0 | [
"CWE-119",
"CWE-788"
] | radare2 | 6c4428f018d385fc80a33ecddcb37becea685dd5 | 205,987,599,135,130,400,000,000,000,000,000,000,000 | 7 | Improve boundary checks to fix oobread segfaults ##crash
* Reported by Cen Zhang via huntr.dev
* Reproducer: bins/fuzzed/javaoob-havoc.class |
struct vport *ovs_lookup_vport(const struct datapath *dp, u16 port_no)
{
struct vport *vport;
struct hlist_head *head;
head = vport_hash_bucket(dp, port_no);
hlist_for_each_entry_rcu(vport, head, dp_hash_node) {
if (vport->port_no == port_no)
return vport;
}
return NULL;
} | 0 | [
"CWE-416"
] | net | 36d5fe6a000790f56039afe26834265db0a3ad4c | 53,844,672,766,947,050,000,000,000,000,000,000,000 | 12 | core, nfqueue, openvswitch: Orphan frags in skb_zerocopy and handle errors
skb_zerocopy can copy elements of the frags array between skbs, but it doesn't
orphan them. Also, it doesn't handle errors, so this patch takes care of that
as well, and modify the callers accordingly. skb_tx_error() is also added to
the caller... |
static pyc_object *get_binary_float_object(RzBuffer *buffer) {
pyc_object *ret = NULL;
bool error = false;
double f;
f = get_float64(buffer, &error);
if (error) {
return NULL;
}
ret = RZ_NEW0(pyc_object);
if (!ret) {
return NULL;
}
ret->type = TYPE_FLOAT;
ret->data = rz_str_newf("%.15g", f);
if (!ret->... | 0 | [
"CWE-190"
] | rizin | e645e5827327d945307ddfde4f617ae4c36561fd | 12,838,104,146,011,217,000,000,000,000,000,000,000 | 21 | Fix the crash caused by get_long_object() #2739 from PeiweiHu/Peiwei_0625 |
static PHP_RSHUTDOWN_FUNCTION(session) /* {{{ */
{
int i;
zend_try {
php_session_flush(TSRMLS_C);
} zend_end_try();
php_rshutdown_session_globals(TSRMLS_C);
/* this should NOT be done in php_rshutdown_session_globals() */
for (i = 0; i < 7; i++) {
if (PS(mod_user_names).names[i] != NULL) {
zval_ptr_dtor(... | 0 | [
"CWE-264"
] | php-src | 25e8fcc88fa20dc9d4c47184471003f436927cde | 47,744,362,063,156,380,000,000,000,000,000,000,000 | 19 | Strict session |
static void loongarch_qemu_write(void *opaque, hwaddr addr,
uint64_t val, unsigned size)
{
} | 0 | [] | qemu | 3517fb726741c109cae7995f9ea46f0cab6187d6 | 29,091,883,490,871,030,000,000,000,000,000,000,000 | 4 | target/loongarch: Clean up tlb when cpu reset
We should make sure that tlb is clean when cpu reset.
Signed-off-by: Song Gao <gaosong@loongson.cn>
Message-Id: <20220705070950.2364243-1-gaosong@loongson.cn>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson... |
Status ReductionShape(InferenceContext* c) {
ShapeHandle input = c->input(0);
ShapeHandle indices;
// Older versions of TensorFlow accidentally allowed higher rank tensors like
// [[1,2]] or [[1],[2]] to represent axis=[1,2].
if (c->graph_def_version() < 21) {
indices = c->input(1);
} else {
TF_RET... | 0 | [
"CWE-369"
] | tensorflow | 8a793b5d7f59e37ac7f3cd0954a750a2fe76bad4 | 90,198,227,210,960,300,000,000,000,000,000,000,000 | 56 | Prevent division by 0 in common shape functions.
PiperOrigin-RevId: 387712197
Change-Id: Id25c7460e35b68aeeeac23b9a88e455b443ee149 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.