func
string
target
int64
cwe
list
project
string
commit_id
string
hash
float64
size
int64
message
string
static void sctp_generate_timeout_event(struct sctp_association *asoc, sctp_event_timeout_t timeout_type) { struct net *net = sock_net(asoc->base.sk); int error = 0; bh_lock_sock(asoc->base.sk); if (sock_owned_by_user(asoc->base.sk)) { pr_debug("%s: sock is busy: timer %d\n", __func__, timeout_type); ...
1
[ "CWE-362" ]
linux
635682a14427d241bab7bbdeebb48a7d7b91638e
70,906,584,669,524,620,000,000,000,000,000,000,000
36
sctp: Prevent soft lockup when sctp_accept() is called during a timeout event A case can occur when sctp_accept() is called by the user during a heartbeat timeout event after the 4-way handshake. Since sctp_assoc_migrate() changes both assoc->base.sk and assoc->ep, the bh_sock_lock in sctp_generate_heartbeat_event() ...
static struct dmar_domain *find_or_alloc_domain(struct device *dev, int gaw) { struct device_domain_info *info; struct dmar_domain *domain = NULL; struct intel_iommu *iommu; u16 dma_alias; unsigned long flags; u8 bus, devfn; iommu = device_to_iommu(dev, &bus, &devfn); if (!iommu) return NULL; if (dev_is_pc...
0
[]
linux
d8b8591054575f33237556c32762d54e30774d28
198,214,028,261,201,300,000,000,000,000,000,000,000
46
iommu/vt-d: Disable ATS support on untrusted devices Commit fb58fdcd295b9 ("iommu/vt-d: Do not enable ATS for untrusted devices") disables ATS support on the devices which have been marked as untrusted. Unfortunately this is not enough to fix the DMA attack vulnerabiltiies because IOMMU driver allows translated reques...
static int validate_certificate_from_root(json_t * j_params, gnutls_x509_crt_t cert_leaf, cbor_item_t * x5c_array) { int ret = G_ERROR_NOT_FOUND, res; unsigned int result; gnutls_datum_t cert_dat = {NULL, 0}, issuer_dat = {NULL, 0}; gnutls_x509_trust_list_t tlist = NULL; gnutls_x509_crt_t cert_x509[cbor_array...
0
[ "CWE-787" ]
glewlwyd
4c5597c155bfbaf6491cf6b83479d241ae66940a
141,339,614,952,961,300,000,000,000,000,000,000,000
75
Fix possible buffer overflow
void CSoundFile::ApplyInstrumentPanning(ModChannel *pChn, const ModInstrument *instr, const ModSample *smp) const { int32 newPan = int32_min; // Default instrument panning if(instr != nullptr && instr->dwFlags[INS_SETPANNING]) newPan = instr->nPan; // Default sample panning if(smp != nullptr && smp->uFlags[CHN_P...
0
[ "CWE-125" ]
openmpt
7ebf02af2e90f03e0dbd0e18b8b3164f372fb97c
54,714,775,118,496,560,000,000,000,000,000,000,000
21
[Fix] Possible out-of-bounds read when computing length of some IT files with pattern loops (OpenMPT: formats that are converted to IT, libopenmpt: IT/ITP/MO3), caught with afl-fuzz. git-svn-id: https://source.openmpt.org/svn/openmpt/trunk/OpenMPT@10027 56274372-70c3-4bfc-bfc3-4c3a0b034d27
GF_Err moof_box_dump(GF_Box *a, FILE * trace) { GF_MovieFragmentBox *p; p = (GF_MovieFragmentBox *)a; gf_isom_box_dump_start(a, "MovieFragmentBox", trace); gf_fprintf(trace, "TrackFragments=\"%d\"", gf_list_count(p->TrackList)); if (p->internal_flags & GF_ISOM_BOX_COMPRESSED) gf_fprintf(trace, " compressedSize=\...
0
[ "CWE-787" ]
gpac
ea1eca00fd92fa17f0e25ac25652622924a9a6a0
185,221,319,158,004,160,000,000,000,000,000,000,000
12
fixed #2138
autoar_extractor_finalize (GObject *object) { AutoarExtractor *self; self = AUTOAR_EXTRACTOR (object); g_debug ("AutoarExtractor: finalize"); g_free (self->buffer); self->buffer = NULL; if (self->error != NULL) { g_error_free (self->error); self->error = NULL; } g_free (self->suggested_dest...
0
[ "CWE-22" ]
gnome-autoar
adb067e645732fdbe7103516e506d09eb6a54429
61,862,818,948,689,050,000,000,000,000,000,000,000
21
AutoarExtractor: Do not extract files outside the destination dir Currently, a malicious archive can cause that the files are extracted outside of the destination dir. This can happen if the archive contains a file whose parent is a symbolic link, which points outside of the destination dir. This is potentially a secu...
void setOutPipe(FIFOSamplePipe *pOutput) { assert(output == NULL); assert(pOutput != NULL); output = pOutput; }
0
[ "CWE-617" ]
soundtouch
107f2c5d201a4dfea1b7f15c5957ff2ac9e5f260
338,492,728,768,671,000,000,000,000,000,000,000,000
6
Replaced illegal-number-of-channel assertions with run-time exception
void CLASS cielab(ushort rgb[3], short lab[3]) { int c, i, j, k; float r, xyz[3]; #ifdef LIBRAW_NOTHREADS static float cbrt[0x10000], xyz_cam[3][4]; #else #define cbrt tls->ahd_data.cbrt #define xyz_cam tls->ahd_data.xyz_cam #endif if (!rgb) { #ifndef LIBRAW_NOTHREADS if (cbrt[0] < -1.0f) #endif fo...
0
[ "CWE-476", "CWE-119" ]
LibRaw
d7c3d2cb460be10a3ea7b32e9443a83c243b2251
227,304,745,499,510,900,000,000,000,000,000,000,000
45
Secunia SA75000 advisory: several buffer overruns
PHP_FUNCTION(xml_set_object) { xml_parser *parser; zval *pind, *mythis; if (zend_parse_parameters(ZEND_NUM_ARGS(), "ro/", &pind, &mythis) == FAILURE) { return; } if ((parser = (xml_parser *)zend_fetch_resource(Z_RES_P(pind), "XML Parser", le_xml_parser)) == NULL) { RETURN_FALSE; } /* please leave this com...
0
[ "CWE-190" ]
php-src
57b997ebf99e0eb9a073e0dafd2ab100bd4a112d
146,281,425,526,826,210,000,000,000,000,000,000,000
27
Fix bug #71637: Multiple Heap Overflow due to integer overflows
static int sctp_getsockopt_primary_addr(struct sock *sk, int len, char __user *optval, int __user *optlen) { struct sctp_prim prim; struct sctp_association *asoc; struct sctp_sock *sp = sctp_sk(sk); if (len != sizeof(struct sctp_prim)) return -EINVAL; if (copy_from_user(&prim, optval, sizeof(struct sctp_p...
0
[ "CWE-476" ]
linux
ea2bc483ff5caada7c4aa0d5fbf87d3a6590273d
221,609,508,933,997,800,000,000,000,000,000,000,000
31
[SCTP]: Fix assertion (!atomic_read(&sk->sk_rmem_alloc)) failed message In current implementation, LKSCTP does receive buffer accounting for data in sctp_receive_queue and pd_lobby. However, LKSCTP don't do accounting for data in frag_list when data is fragmented. In addition, LKSCTP doesn't do accounting for data in ...
scope_body(codegen_scope *s, node *tree, int val) { codegen_scope *scope = scope_new(s->mrb, s, tree->car); codegen(scope, tree->cdr, VAL); gen_return(scope, OP_RETURN, scope->sp-1); if (!s->iseq) { genop_0(scope, OP_STOP); } scope_finish(scope); if (!s->irep) { /* should not happen */ return...
0
[ "CWE-415", "CWE-122" ]
mruby
38b164ace7d6ae1c367883a3d67d7f559783faad
263,720,690,863,421,740,000,000,000,000,000,000,000
16
codegen.c: fix a bug in `gen_values()`. - Fix limit handling that fails 15 arguments method calls. - Fix too early argument packing in arrays.
static int nf_tables_validate(struct net *net) { struct nftables_pernet *nft_net = nft_pernet(net); struct nft_table *table; switch (nft_net->validate_state) { case NFT_VALIDATE_SKIP: break; case NFT_VALIDATE_NEED: nft_validate_state_update(net, NFT_VALIDATE_DO); fallthrough; case NFT_VALIDATE_DO: list_f...
0
[ "CWE-665" ]
linux
ad9f151e560b016b6ad3280b48e42fa11e1a5440
113,092,770,193,503,700,000,000,000,000,000,000,000
21
netfilter: nf_tables: initialize set before expression setup nft_set_elem_expr_alloc() needs an initialized set if expression sets on the NFT_EXPR_GC flag. Move set fields initialization before expression setup. [4512935.019450] ================================================================== [4512935.019456] BUG: ...
setlocale_perl(int category, char *locale) { char *RETVAL = setlocale(category, locale); if (RETVAL) { #ifdef USE_LOCALE_CTYPE if (category == LC_CTYPE #ifdef LC_ALL || category == LC_ALL #endif ) { char *newctype; #ifdef LC_ALL if (category == LC_ALL) newctype = setlocale(LC_CTYPE, NULL)...
0
[ "CWE-264" ]
postgres
537cbd35c893e67a63c59bc636c3e888bd228bc7
260,631,496,290,755,500,000,000,000,000,000,000,000
65
Prevent privilege escalation in explicit calls to PL validators. The primary role of PL validators is to be called implicitly during CREATE FUNCTION, but they are also normal functions that a user can call explicitly. Add a permissions check to each validator to ensure that a user cannot use explicit validator calls ...
static int l2tp_nl_cmd_tunnel_modify(struct sk_buff *skb, struct genl_info *info) { struct l2tp_tunnel *tunnel; u32 tunnel_id; int ret = 0; struct net *net = genl_info_net(info); if (!info->attrs[L2TP_ATTR_CONN_ID]) { ret = -EINVAL; goto out; } tunnel_id = nla_get_u32(info->attrs[L2TP_ATTR_CONN_ID]); tunn...
0
[ "CWE-416" ]
linux
f026bc29a8e093edfbb2a77700454b285c97e8ad
271,802,479,210,923,500,000,000,000,000,000,000,000
30
l2tp: pass tunnel pointer to ->session_create() Using l2tp_tunnel_find() in pppol2tp_session_create() and l2tp_eth_create() is racy, because no reference is held on the returned session. These functions are only used to implement the ->session_create callback which is run by l2tp_nl_cmd_session_create(). Therefore sea...
static int decode_slice(struct AVCodecContext *avctx, void *arg) { H264Context *h = *(void **)arg; int lf_x_start = h->mb_x; h->mb_skip_run = -1; h->is_complex = FRAME_MBAFF(h) || h->picture_structure != PICT_FRAME || avctx->codec_id != AV_CODEC_ID_H264 || (CONF...
0
[ "CWE-787" ]
FFmpeg
1f097d168d9cad473dd44010a337c1413a9cd198
100,425,908,472,135,720,000,000,000,000,000,000,000
160
h264: reset data partitioning at the beginning of each decode call Prevents using GetBitContexts with data from previous calls. Fixes access to freed memory. Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind CC:libav-stable@libav.org
static inline void add_offset_pair(zval *result, char *str, int len, int offset, char *name) { zval *match_pair; ALLOC_ZVAL(match_pair); array_init(match_pair); INIT_PZVAL(match_pair); /* Add (match, offset) to the return value */ add_next_index_stringl(match_pair, str, len, 1); add_next_index_long(match_pair,...
0
[]
php-src
03964892c054d0c736414c10b3edc7a40318b975
175,142,020,667,621,460,000,000,000,000,000,000,000
18
Fix bug #70345 (Multiple vulnerabilities related to PCRE functions)
bson_iter_array (const bson_iter_t *iter, /* IN */ uint32_t *array_len, /* OUT */ const uint8_t **array) /* OUT */ { BSON_ASSERT (iter); BSON_ASSERT (array_len); BSON_ASSERT (array); *array = NULL; *array_len = 0; if (ITER_TYPE (iter) == BSON_TYPE_ARRAY) { ...
0
[ "CWE-125" ]
libbson
42900956dc461dfe7fb91d93361d10737c1602b3
231,377,343,651,026,700,000,000,000,000,000,000,000
17
CDRIVER-2269 Check for zero string length in codewscope
static int rtl_usb_tx(struct ieee80211_hw *hw, struct ieee80211_sta *sta, struct sk_buff *skb, struct rtl_tcb_desc *dummy) { struct rtl_usb *rtlusb = rtl_usbdev(rtl_usbpriv(hw)); struct rtl_hal *rtlhal = rtl_hal(rtl_priv(hw)); struct ieee80211_hdr *hdr = (struct ieee80211_hdr *)(skb->data); ...
0
[ "CWE-400", "CWE-401" ]
linux
3f93616951138a598d930dcaec40f2bfd9ce43bb
207,318,237,086,672,070,000,000,000,000,000,000,000
22
rtlwifi: prevent memory leak in rtl_usb_probe In rtl_usb_probe if allocation for usb_data fails the allocated hw should be released. In addition the allocated rtlpriv->usb_data should be released on error handling path. Signed-off-by: Navid Emamdoost <navid.emamdoost@gmail.com> Signed-off-by: Kalle Valo <kvalo@codeau...
static struct sched_entity *pick_next_entity(struct cfs_rq *cfs_rq) { struct sched_entity *se = NULL; if (first_fair(cfs_rq)) { se = __pick_next_entity(cfs_rq); se = pick_next(cfs_rq, se); set_next_entity(cfs_rq, se); } return se; }
0
[]
linux-2.6
6a6029b8cefe0ca7e82f27f3904dbedba3de4e06
229,436,487,813,500,200,000,000,000,000,000,000,000
12
sched: simplify sched_slice() Use the existing calc_delta_mine() calculation for sched_slice(). This saves a divide and simplifies the code because we share it with the other /cfs_rq->load users. It also improves code size: text data bss dec hex filename 42659 2740 144 45543 b1e...
getsize_dump( dle_t *dle, int level, char **errmsg) { int pipefd[2], nullfd, stdoutfd, killctl[2]; pid_t dumppid; off_t size; FILE *dumpout; char *dumpkeys = NULL; char *device = NULL; char *fstype = NULL; char *cmd = NULL; char *name = NULL; char *line = N...
0
[ "CWE-264" ]
amanda
4bf5b9b356848da98560ffbb3a07a9cb5c4ea6d7
202,422,784,344,485,300,000,000,000,000,000,000,000
440
* Add a /etc/amanda-security.conf file git-svn-id: https://svn.code.sf.net/p/amanda/code/amanda/branches/3_3@6486 a8d146d6-cc15-0410-8900-af154a0219e0
static inline void prepare_key(unsigned flags, char *old_key, size_t old_len, char **new_key, size_t *new_len TSRMLS_DC) { zval zv; INIT_PZVAL(&zv); ZVAL_STRINGL(&zv, old_key, old_len, 1); if (flags & PHP_HTTP_PARAMS_URLENCODED) { prepare_urlencoded(&zv TSRMLS_CC); } if (flags & PHP_HTTP_PARAMS_ESCAPED) { ...
0
[ "CWE-399", "CWE-704" ]
ext-http
17137d4ab1ce81a2cee0fae842340a344ef3da83
335,438,504,722,585,700,000,000,000,000,000,000,000
22
fix bug #73055
TEST_F(HttpConnectionManagerImplTest, FilterAddBodyInTrailersCallback_NoDataFrames) { InSequence s; setup(false, ""); EXPECT_CALL(*codec_, dispatch(_)).WillOnce(Invoke([&](Buffer::Instance&) -> void { StreamDecoder* decoder = &conn_manager_->newStream(response_encoder_); HeaderMapPtr headers{ new...
0
[ "CWE-400", "CWE-703" ]
envoy
afc39bea36fd436e54262f150c009e8d72db5014
84,834,371,992,178,480,000,000,000,000,000,000,000
57
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...
*/ void unregister_netdev(struct net_device *dev) { rtnl_lock(); unregister_netdevice(dev); rtnl_unlock();
0
[ "CWE-400", "CWE-703" ]
linux
fac8e0f579695a3ecbc4d3cac369139d7f819971
215,580,594,772,456,150,000,000,000,000,000,000,000
6
tunnels: Don't apply GRO to multiple layers of encapsulation. When drivers express support for TSO of encapsulated packets, they only mean that they can do it for one layer of encapsulation. Supporting additional levels would mean updating, at a minimum, more IP length fields and they are unaware of this. No encapsul...
static Image *ReadPNGImage(const ImageInfo *image_info, ExceptionInfo *exception) { Image *image; MagickBooleanType logging, status; MngInfo *mng_info; char magic_number[MagickPathExtent]; ssize_t count; /* Open image file. */ assert(image_info != (const ImageInfo *) N...
0
[ "CWE-476" ]
ImageMagick
816ecab6c532ae086ff4186b3eaf4aa7092d536f
224,282,548,537,380,840,000,000,000,000,000,000,000
127
https://github.com/ImageMagick/ImageMagick/issues/58
DEFUN(nextT, NEXT_TAB, "Switch to the next tab") { int i; if (nTab <= 1) return; for (i = 0; i < PREC_NUM; i++) { if (CurrentTab->nextTab) CurrentTab = CurrentTab->nextTab; else CurrentTab = FirstTab; } displayBuffer(Currentbuf, B_REDRAW_IMAGE); }
0
[ "CWE-59", "CWE-241" ]
w3m
18dcbadf2771cdb0c18509b14e4e73505b242753
173,541,382,773,752,570,000,000,000,000,000,000,000
14
Make temporary directory safely when ~/.w3m is unwritable
table_map used_tables() const { return used_table_map; }
0
[]
mysql-server
f7316aa0c9a3909fc7498e7b95d5d3af044a7e21
131,256,224,339,828,500,000,000,000,000,000,000,000
1
Bug#26361149 MYSQL SERVER CRASHES AT: COL IN(IFNULL(CONST, COL), NAME_CONST('NAME', NULL)) Backport of Bug#19143243 fix. NAME_CONST item can return NULL_ITEM type in case of incorrect arguments. NULL_ITEM has special processing in Item_func_in function. In Item_func_in::fix_length_and_dec an a...
xmlAutomataNewEpsilon(xmlAutomataPtr am, xmlAutomataStatePtr from, xmlAutomataStatePtr to) { if ((am == NULL) || (from == NULL)) return(NULL); xmlFAGenerateEpsilonTransition(am, from, to); if (to == NULL) return(am->state); return(to); }
0
[ "CWE-119" ]
libxml2
cbb271655cadeb8dbb258a64701d9a3a0c4835b4
136,679,584,631,825,060,000,000,000,000,000,000,000
9
Bug 757711: heap-buffer-overflow in xmlFAParsePosCharGroup <https://bugzilla.gnome.org/show_bug.cgi?id=757711> * xmlregexp.c: (xmlFAParseCharRange): Only advance to the next character if there is no error. Advancing to the next character in case of an error while parsing regexp leads to an out of bounds access.
decode_NXAST_RAW_CONJUNCTION(const struct nx_action_conjunction *nac, enum ofp_version ofp_version OVS_UNUSED, struct ofpbuf *out) { if (nac->n_clauses < 2 || nac->n_clauses > 64 || nac->clause >= nac->n_clauses) { return OFPERR_NXBAC_BAD_CON...
0
[ "CWE-125" ]
ovs
9237a63c47bd314b807cda0bd2216264e82edbe8
222,425,212,100,994,300,000,000,000,000,000,000,000
12
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>
ClassDef(identifier name, asdl_seq * bases, asdl_seq * keywords, asdl_seq * body, asdl_seq * decorator_list, int lineno, int col_offset, int end_lineno, int end_col_offset, PyArena *arena) { stmt_ty p; if (!name) { PyErr_SetString(PyExc_ValueError, "field name i...
0
[ "CWE-125" ]
cpython
dcfcd146f8e6fc5c2fc16a4c192a0c5f5ca8c53c
98,819,012,416,299,200,000,000,000,000,000,000,000
25
bpo-35766: Merge typed_ast back into CPython (GH-11645)
my_decimal *Field_temporal::val_decimal(my_decimal *d) { MYSQL_TIME ltime; if (get_date(&ltime, 0)) { bzero(&ltime, sizeof(ltime)); ltime.time_type= mysql_type_to_time_type(type()); } return TIME_to_my_decimal(&ltime, d); }
0
[ "CWE-120" ]
server
eca207c46293bc72dd8d0d5622153fab4d3fccf1
309,552,097,285,221,880,000,000,000,000,000,000,000
10
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...
NTSTATUS smb2cli_validate_negotiate_info_recv(struct tevent_req *req) { return tevent_req_simple_recv_ntstatus(req); }
0
[ "CWE-20" ]
samba
a819d2b440aafa3138d95ff6e8b824da885a70e9
200,770,058,367,636,130,000,000,000,000,000,000,000
4
CVE-2015-5296: libcli/smb: make sure we require signing when we demand encryption on a session BUG: https://bugzilla.samba.org/show_bug.cgi?id=11536 Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
TEST_F(ExprMatchTest, ComplexExprMatchesCorrectly) { createMatcher( fromjson("{" " $expr: {" " $and: [" " {$eq: ['$a', 1]}," " {$eq: ['$b', '$c']}," " {" " $or: [...
0
[]
mongo
ee97c0699fd55b498310996ee002328e533681a3
293,325,844,408,897,820,000,000,000,000,000,000,000
35
SERVER-36993 Fix crash due to incorrect $or pushdown for indexed $expr.
static inline bool sched_debug(void) { return sched_debug_enabled; }
0
[ "CWE-119" ]
linux
29d6455178a09e1dc340380c582b13356227e8df
7,829,330,801,274,887,000,000,000,000,000,000,000
4
sched: panic on corrupted stack end Until now, hitting this BUG_ON caused a recursive oops (because oops handling involves do_exit(), which calls into the scheduler, which in turn raises an oops), which caused stuff below the stack to be overwritten until a panic happened (e.g. via an oops in interrupt context, cause...
static void __perf_mux_hrtimer_init(struct perf_cpu_context *cpuctx, int cpu) { struct hrtimer *timer = &cpuctx->hrtimer; struct pmu *pmu = cpuctx->ctx.pmu; u64 interval; /* no multiplexing needed for SW PMU */ if (pmu->task_ctx_nr == perf_sw_context) return; /* * check default is sane, if not set then forc...
0
[ "CWE-416", "CWE-362" ]
linux
12ca6ad2e3a896256f086497a7c7406a547ee373
140,479,559,513,324,570,000,000,000,000,000,000,000
24
perf: Fix race in swevent hash There's a race on CPU unplug where we free the swevent hash array while it can still have events on. This will result in a use-after-free which is BAD. Simply do not free the hash array on unplug. This leaves the thing around and no use-after-free takes place. When the last swevent die...
void __do_map_lock(struct f2fs_sb_info *sbi, int flag, bool lock) { if (flag == F2FS_GET_BLOCK_PRE_AIO) { if (lock) down_read(&sbi->node_change); else up_read(&sbi->node_change); } else { if (lock) f2fs_lock_op(sbi); else f2fs_unlock_op(sbi); } }
0
[ "CWE-476" ]
linux
4969c06a0d83c9c3dc50b8efcdc8eeedfce896f6
250,554,014,124,316,260,000,000,000,000,000,000,000
14
f2fs: support swap file w/ DIO Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
static int read_compacted_summaries(struct f2fs_sb_info *sbi) { struct f2fs_checkpoint *ckpt = F2FS_CKPT(sbi); struct curseg_info *seg_i; unsigned char *kaddr; struct page *page; block_t start; int i, j, offset; start = start_sum_block(sbi); page = get_meta_page(sbi, start++); kaddr = (unsigned char *)page_a...
0
[ "CWE-20" ]
linux
638164a2718f337ea224b747cf5977ef143166a4
57,839,357,119,750,880,000,000,000,000,000,000,000
59
f2fs: fix potential panic during fstrim As Ju Hyung Park reported: "When 'fstrim' is called for manual trim, a BUG() can be triggered randomly with this patch. I'm seeing this issue on both x86 Desktop and arm64 Android phone. On x86 Desktop, this was caused during Ubuntu boot-up. I have a cronjob installed which c...
static ulong find_set(TYPELIB *lib, const char *x, uint length, char **err_pos, uint *err_len) { const char *end= x + length; ulong found= 0; uint find; char buff[255]; *err_pos= 0; /* No error yet */ while (end > x && my_isspace(charset_info, end[-1])) end--; ...
0
[ "CWE-284", "CWE-295" ]
mysql-server
3bd5589e1a5a93f9c224badf983cd65c45215390
55,766,439,333,432,275,000,000,000,000,000,000,000
39
WL#6791 : Redefine client --ssl option to imply enforced encryption # Changed the meaning of the --ssl=1 option of all client binaries to mean force ssl, not try ssl and fail over to eunecrypted # Added a new MYSQL_OPT_SSL_ENFORCE mysql_options() option to specify that an ssl connection is required. # Added a new macr...
ieee80211_rx_h_ctrl(struct ieee80211_rx_data *rx, struct sk_buff_head *frames) { struct sk_buff *skb = rx->skb; struct ieee80211_bar *bar = (struct ieee80211_bar *)skb->data; struct tid_ampdu_rx *tid_agg_rx; u16 start_seq_num; u16 tid; if (likely(!ieee80211_is_ctl(bar->frame_control))) return RX_CONTINUE; if...
0
[]
linux
588f7d39b3592a36fb7702ae3b8bdd9be4621e2f
193,956,639,667,641,120,000,000,000,000,000,000,000
67
mac80211: drop robust management frames from unknown TA When receiving a robust management frame, drop it if we don't have rx->sta since then we don't have a security association and thus couldn't possibly validate the frame. Cc: stable@vger.kernel.org Signed-off-by: Johannes Berg <johannes.berg@intel.com>
struct ieee80211_sta *ieee80211_find_sta_by_ifaddr(struct ieee80211_hw *hw, const u8 *addr, const u8 *localaddr) { struct sta_info *sta, *nxt; /* * Just return a random station if localaddr is NULL * ... first in list. */ for_each_sta_info(hw_to_local(hw), addr, sta, nxt) { if (local...
0
[ "CWE-362" ]
linux
1d147bfa64293b2723c4fec50922168658e613ba
128,575,717,383,127,330,000,000,000,000,000,000,000
21
mac80211: fix AP powersave TX vs. wakeup race There is a race between the TX path and the STA wakeup: while a station is sleeping, mac80211 buffers frames until it wakes up, then the frames are transmitted. However, the RX and TX path are concurrent, so the packet indicating wakeup can be processed while a packet is b...
BIO* rdg_get_front_bio_and_take_ownership(rdpRdg* rdg) { if (!rdg) return NULL; rdg->attached = TRUE; return rdg->frontBio; }
0
[ "CWE-125" ]
FreeRDP
6b485b146a1b9d6ce72dfd7b5f36456c166e7a16
199,386,945,976,650,980,000,000,000,000,000,000,000
8
Fixed oob read in irp_write and similar
cleanup_pathname(struct archive_write_disk *a) { struct archive_string error_string; int error_number; int rc; archive_string_init(&error_string); rc = cleanup_pathname_fsobj(a->name, &error_number, &error_string, a->flags); if (rc != ARCHIVE_OK) { archive_set_error(&a->archive, error_number, "%s", error_string...
0
[ "CWE-20", "CWE-476" ]
libarchive
dfd6b54ce33960e420fb206d8872fb759b577ad9
153,651,190,429,152,020,000,000,000,000,000,000,000
13
Fixes for Issue #745 and Issue #746 from Doran Moppert.
void vncProperties::SaveToIniFile() { if (!m_allowproperties) return; // SAVE PER-USER PREFS IF ALLOWED if (!myIniFile.IsWritable() || vncService::RunningAsService()) { //First check if temp file is writable myIniFile.IniFileSetTemp( m_Tempfile); if (!myIniFile.IsWritable()) { ...
0
[ "CWE-787" ]
UltraVNC
36a31b37b98f70c1db0428f5ad83170d604fb352
339,530,870,984,295,800,000,000,000,000,000,000,000
87
security fix
device_removed (const char *path, BluetoothClient *client) { BluetoothClientPrivate *priv = BLUETOOTH_CLIENT_GET_PRIVATE(client); GtkTreeIter iter; if (get_iter_from_path(priv->store, &iter, path) == TRUE) { /* Note that removal can also happen from adapter_removed. */ g_signal_emit (G_OBJECT (client), s...
0
[]
gnome-bluetooth
6b5086d42ea64d46277f3c93b43984f331d12f89
26,164,473,999,725,530,000,000,000,000,000,000,000
12
lib: Fix Discoverable being reset when turned off Work-around race in bluetoothd which would reset the discoverable flag if a timeout change was requested before discoverable finished being set to off: See https://bugzilla.redhat.com/show_bug.cgi?id=1602985
void dm_persistent_snapshot_exit(void) { dm_exception_store_type_unregister(&_persistent_type); dm_exception_store_type_unregister(&_persistent_compat_type); }
0
[ "CWE-200", "CWE-264" ]
linux
e9c6a182649f4259db704ae15a91ac820e63b0ca
143,616,159,603,925,140,000,000,000,000,000,000,000
5
dm snapshot: fix data corruption This patch fixes a particular type of data corruption that has been encountered when loading a snapshot's metadata from disk. When we allocate a new chunk in persistent_prepare, we increment ps->next_free and we make sure that it doesn't point to a metadata area by further incrementin...
static void update_avg_stats(struct cfs_rq *cfs_rq, struct sched_entity *se) { if (!se->last_wakeup) return; update_avg(&se->avg_overlap, se->sum_exec_runtime - se->last_wakeup); se->last_wakeup = 0; }
0
[]
linux-2.6
ac884dec6d4a7df252150af875cffddf8f1d9c15
1,345,749,097,721,018,000,000,000,000,000,000,000
8
sched: fair-group scheduling vs latency Currently FAIR_GROUP sched grows the scheduler latency outside of sysctl_sched_latency, invert this so it stays within. Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl> Signed-off-by: Ingo Molnar <mingo@elte.hu>
ieeetod(double *dp) { double_t source; long sign,exp,mant; double dmant; source.ieee = ((double_t*)dp)->ieee; sign = source.ieee.sign; exp = source.ieee.exp; mant = source.ieee.mant; if (exp == 2047) { if (mant) /* Not a Number (NAN) */ *dp = HUGE_VAL; else /* +/- infinity */ *dp = (sign ? -HUG...
0
[ "CWE-369" ]
libtiff
3c5eb8b1be544e41d2c336191bc4936300ad7543
235,057,141,893,155,050,000,000,000,000,000,000,000
38
* libtiff/tif_{unix,vms,win32}.c (_TIFFmalloc): ANSI C does not require malloc() to return NULL pointer if requested allocation size is zero. Assure that _TIFFmalloc does.
virtual void setupConnection() { EXPECT_EQ(server->getConn().readCodec, nullptr); EXPECT_EQ(server->getConn().statsCallback, transportInfoCb_.get()); setupClientReadCodec(); recvClientHello(); IOBufEqualTo eq; EXPECT_TRUE(eq(getCryptoStreamData(), IOBuf::copyBuffer("SHLO"))); serverWrites...
0
[ "CWE-617", "CWE-703" ]
mvfst
a67083ff4b8dcbb7ee2839da6338032030d712b0
78,345,690,450,218,610,000,000,000,000,000,000,000
98
Close connection if we derive an extra 1-rtt write cipher Summary: Fixes CVE-2021-24029 Reviewed By: mjoras, lnicco Differential Revision: D26613890 fbshipit-source-id: 19bb2be2c731808144e1a074ece313fba11f1945
main(int argc, char *argv[]) { int ch; double r; double c; int my_colors; int f_option = 0; int m_option = 2; int r_option = 0; int s_option = 1; size_t need; char *my_env; while ((ch = getopt(argc, argv, "T:efm:r:s:")) != -1) { switch (ch) { case 'T': need = 6 +...
1
[]
ncurses
790a85dbd4a81d5f5d8dd02a44d84f01512ef443
127,382,103,677,209,280,000,000,000,000,000,000,000
96
ncurses 6.2 - patch 20200531 + correct configure version-check/warnng for g++ to allow for 10.x + re-enable "bel" in konsole-base (report by Nia Huang) + add linux-s entry (patch by Alexandre Montaron). + drop long-obsolete convert_configure.pl + add test/test_parm.c, for checking tparm changes. + improve parameter-ch...
check_STACK_PUSH(const struct ofpact_stack *a, const struct ofpact_check_params *cp) { return nxm_stack_push_check(a, cp->match); }
0
[ "CWE-416" ]
ovs
77cccc74deede443e8b9102299efc869a52b65b2
226,466,357,188,596,330,000,000,000,000,000,000,000
5
ofp-actions: Fix use-after-free while decoding RAW_ENCAP. While decoding RAW_ENCAP action, decode_ed_prop() might re-allocate ofpbuf if there is no enough space left. However, function 'decode_NXAST_RAW_ENCAP' continues to use old pointer to 'encap' structure leading to write-after-free and incorrect decoding. ==3...
cmsHPROFILE CMSEXPORT cmsCreate_sRGBProfileTHR(cmsContext ContextID) { cmsCIExyY D65; cmsCIExyYTRIPLE Rec709Primaries = { {0.6400, 0.3300, 1.0}, {0.3000, 0.6000, 1.0}, {0.1500, 0.0600, 1.0} ...
0
[]
Little-CMS
41d222df1bc6188131a8f46c32eab0a4d4cdf1b6
43,515,874,053,907,060,000,000,000,000,000,000,000
26
Memory squeezing fix: lcms2 cmsPipeline construction When creating a new pipeline, lcms would often try to allocate a stage and pass it to cmsPipelineInsertStage without checking whether the allocation succeeded. cmsPipelineInsertStage would then assert (or crash) if it had not. The fix here is to change cmsPipelineI...
g_file_unmount_mountable_finish (GFile *file, GAsyncResult *result, GError **error) { GFileIface *iface; g_return_val_if_fail (G_IS_FILE (file), FALSE); g_return_val_if_fail (G_IS_ASYNC_RESULT (result), FALSE); if (g_async_result...
0
[ "CWE-362" ]
glib
d8f8f4d637ce43f8699ba94c9b7648beda0ca174
269,793,145,974,806,400,000,000,000,000,000,000,000
17
gfile: Limit access to files when copying file_copy_fallback creates new files with default permissions and set the correct permissions after the operation is finished. This might cause that the files can be accessible by more users during the operation than expected. Use G_FILE_CREATE_PRIVATE for the new files to lim...
TEST_F(OptimizePipeline, MetaMatchPushedDown) { auto unpack = fromjson( "{$_internalUnpackBucket: { exclude: [], timeField: 'foo', metaField: 'myMeta', " "bucketMaxSpanSeconds: 3600}}"); auto pipeline = Pipeline::parse(makeVector(unpack, fromjson("{$match: {myMeta: {$gte: 0}}}")), getExp...
0
[]
mongo
b3107d73a2c58d7e016b834dae0acfd01c0db8d7
291,917,055,971,935,830,000,000,000,000,000,000,000
16
SERVER-59299: Flatten top-level nested $match stages in doOptimizeAt (cherry picked from commit 4db5eceda2cff697f35c84cd08232bac8c33beec)
static inline struct sched_entity *__pick_last_entity(struct cfs_rq *cfs_rq) { struct rb_node *last = rb_last(&cfs_rq->tasks_timeline); if (!last) return NULL; return rb_entry(last, struct sched_entity, run_node); }
0
[]
linux-2.6
6a6029b8cefe0ca7e82f27f3904dbedba3de4e06
23,053,885,557,868,725,000,000,000,000,000,000,000
9
sched: simplify sched_slice() Use the existing calc_delta_mine() calculation for sched_slice(). This saves a divide and simplifies the code because we share it with the other /cfs_rq->load users. It also improves code size: text data bss dec hex filename 42659 2740 144 45543 b1e...
static void disk_check_events(struct disk_events *ev, unsigned int *clearing_ptr) { struct gendisk *disk = ev->disk; char *envp[ARRAY_SIZE(disk_uevents) + 1] = { }; unsigned int clearing = *clearing_ptr; unsigned int events; unsigned long intv; int nr_events = 0, i; /* check events */ events = disk->f...
0
[ "CWE-416" ]
linux-stable
77da160530dd1dc94f6ae15a981f24e5f0021e84
304,848,004,094,747,760,000,000,000,000,000,000,000
39
block: fix use-after-free in seq file I got a KASAN report of use-after-free: ================================================================== BUG: KASAN: use-after-free in klist_iter_exit+0x61/0x70 at addr ffff8800b6581508 Read of size 8 by task trinity-c1/315 ======================================...
aiff_rewrite_header (SF_PRIVATE *psf) { /* Assuming here that the header has already been written and just ** needs to be corrected for new data length. That means that we ** only change the length fields of the FORM and SSND chunks ; ** everything else can be skipped over. */ int k, ch, comm_size, comm_frames ; ...
0
[ "CWE-476" ]
libsndfile
6f3266277bed16525f0ac2f0f03ff4626f1923e5
59,584,806,379,951,060,000,000,000,000,000,000,000
47
Fix max channel count bug The code was allowing files to be written with a channel count of exactly `SF_MAX_CHANNELS` but was failing to read some file formats with the same channel count.
static SECURITY_STATUS SEC_ENTRY negotiate_AcquireCredentialsHandleW( SEC_WCHAR* pszPrincipal, SEC_WCHAR* pszPackage, ULONG fCredentialUse, void* pvLogonID, void* pAuthData, SEC_GET_KEY_FN pGetKeyFn, void* pvGetKeyArgument, PCredHandle phCredential, PTimeStamp ptsExpiry) { BOOL kerberos, ntlm; if (!negot...
0
[]
FreeRDP
479e891545473f01c187daffdfa05fc752b54b72
301,166,167,888,855,840,000,000,000,000,000,000,000
40
check return values for SetCredentialsAttributes, throw warnings for unsupported attributes
static GF_Node *lsr_read_rect(GF_LASeRCodec *lsr, u32 same_type) { GF_Node *elt = gf_node_new(lsr->sg, TAG_SVG_rect); if (same_type) { if (lsr->prev_rect) { lsr_restore_base(lsr, (SVG_Element*)elt, (SVG_Element *)lsr->prev_rect, (same_type==2) ? 1 : 0, 0); } else { GF_LOG(GF_LOG_WARNING, GF_LOG_CODING, ("[...
0
[ "CWE-190" ]
gpac
faa75edde3dfeba1e2cf6ffa48e45a50f1042096
248,281,387,461,715,000,000,000,000,000,000,000,000
33
fixed #2213
int cmp_time(time_t file1, time_t file2) { if (file2 > file1) { if (file2 - file1 <= modify_window) return 0; return -1; } if (file1 - file2 <= modify_window) return 0; return 1; }
0
[ "CWE-59" ]
rsync
4cad402ea8a91031f86c53961d78bb7f4f174790
247,912,681,843,699,050,000,000,000,000,000,000,000
11
Receiver now rejects invalid filenames in filelist. If the receiver gets a filename with a leading slash (w/o --relative) and/or a filename with an embedded ".." dir in the path, it dies with an error (rather than continuing). Those invalid paths should never happen in reality, so just reject someone trying to pull a ...
print_p2r_unknown (const unsigned char *msg, size_t msglen) { print_p2r_header ("Unknown PC_to_RDR command", msg, msglen); if (msglen < 10) return; print_pr_data (msg, msglen, 0); }
0
[ "CWE-20" ]
gnupg
2183683bd633818dd031b090b5530951de76f392
22,790,042,205,084,430,000,000,000,000,000,000,000
7
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 ...
MONGO_EXPORT void mongo_replset_init( mongo *conn, const char *name ) { bson_errprintf("WARNING: mongo_replset_init() is deprecated, please use mongo_replica_set_init()\n"); mongo_replica_set_init( conn, name ); }
0
[ "CWE-190" ]
mongo-c-driver-legacy
1a1f5e26a4309480d88598913f9eebf9e9cba8ca
211,492,061,590,017,360,000,000,000,000,000,000,000
4
don't mix up int and size_t (first pass to fix that)
GrowableArray<Klass*>* InstanceKlass::compute_secondary_supers(int num_extra_slots, Array<InstanceKlass*>* transitive_interfaces) { // The secondaries are the implemented interfaces. Array<InstanceKlass*>* interfaces = transitive_interfaces; int num_s...
0
[]
jdk17u
f8eb9abe034f7c6bea4da05a9ea42017b3f80730
106,845,459,796,866,100,000,000,000,000,000,000,000
27
8270386: Better verification of scan methods Reviewed-by: coleenp Backport-of: ac329cef45979bd0159ecd1347e36f7129bb2ce4
void HTTPSession::onWindowUpdate(HTTPCodec::StreamID streamID, uint32_t amount) { VLOG(4) << *this << " got window update on streamID=" << streamID << " for " << amount << " bytes."; HTTPTransaction* txn = findTransaction(streamID); if (!txn) { // We MUST be using SP...
0
[ "CWE-20" ]
proxygen
0600ebe59c3e82cd012def77ca9ca1918da74a71
171,345,035,382,422,870,000,000,000,000,000,000,000
16
Check that a secondary auth manager is set before dereferencing. Summary: CVE-2018-6343 Reviewed By: mingtaoy Differential Revision: D12994423 fbshipit-source-id: 9229ec11da8085f1fa153595e8e5353e19d06fb7
static void remove_monitor_info(struct sk_buff *skb, unsigned int present_fcs_len, unsigned int rtap_space) { if (present_fcs_len) __pskb_trim(skb, skb->len - present_fcs_len); __pskb_pull(skb, rtap_space); }
0
[]
linux
588f7d39b3592a36fb7702ae3b8bdd9be4621e2f
312,180,177,859,166,720,000,000,000,000,000,000,000
8
mac80211: drop robust management frames from unknown TA When receiving a robust management frame, drop it if we don't have rx->sta since then we don't have a security association and thus couldn't possibly validate the frame. Cc: stable@vger.kernel.org Signed-off-by: Johannes Berg <johannes.berg@intel.com>
static void temac_set_multicast_list(struct net_device *ndev) { struct temac_local *lp = netdev_priv(ndev); u32 multi_addr_msw, multi_addr_lsw; int i = 0; unsigned long flags; bool promisc_mode_disabled = false; if (ndev->flags & (IFF_PROMISC | IFF_ALLMULTI) || (netdev_mc_count(ndev) > MULTICAST_CAM_TABLE_N...
0
[ "CWE-120", "CWE-787" ]
linux
c364df2489b8ef2f5e3159b1dff1ff1fdb16040d
242,776,996,813,767,400,000,000,000,000,000,000,000
56
net: ll_temac: Fix TX BD buffer overwrite Just as the initial check, we need to ensure num_frag+1 buffers available, as that is the number of buffers we are going to use. This fixes a buffer overflow, which might be seen during heavy network load. Complete lockup of TEMAC was reproducible within about 10 minutes of a...
inline Http2Stream* Http2Session::FindStream(int32_t id) { auto s = streams_.find(id); return s != streams_.end() ? s->second : nullptr; }
0
[]
node
ce22d6f9178507c7a41b04ac4097b9ea902049e3
274,640,054,240,343,300,000,000,000,000,000,000,000
4
http2: add altsvc support Add support for sending and receiving ALTSVC frames. PR-URL: https://github.com/nodejs/node/pull/17917 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com> Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
void __init dbg_late_init(void) { dbg_is_early = false; if (kgdb_io_module_registered) kgdb_arch_late(); kdb_init(KDB_INIT_FULL); if (kgdb_io_module_registered && kgdb_break_asap) kgdb_initial_breakpoint(); }
0
[ "CWE-787" ]
linux
eadb2f47a3ced5c64b23b90fd2a3463f63726066
74,629,730,041,669,190,000,000,000,000,000,000,000
10
lockdown: also lock down previous kgdb use KGDB and KDB allow read and write access to kernel memory, and thus should be restricted during lockdown. An attacker with access to a serial port (for example, via a hypervisor console, which some cloud vendors provide over the network) could trigger the debugger so it is i...
int crypt_resume_by_keyfile(struct crypt_device *cd, const char *name, int keyslot, const char *keyfile, size_t keyfile_size) { return crypt_resume_by_keyfile_device_offset(cd, name, keyslot, keyfile, keyfile_size, 0); }
0
[ "CWE-345" ]
cryptsetup
0113ac2d889c5322659ad0596d4cfc6da53e356c
9,948,534,356,864,740,000,000,000,000,000,000,000
9
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...
static inline int crypto_drbg_get_bytes_addtl_test(struct crypto_rng *drng, unsigned char *outbuf, unsigned int outlen, struct drbg_string *addtl, struct drbg_test_data *test_data) { int ret; struct drbg_gen genbuf; genbuf.outbuf = outbuf; genbuf.outlen = outlen; genbuf.addtl = addtl; genbuf.test_data = ...
1
[ "CWE-476" ]
linux
8fded5925d0a733c46f8d0b5edd1c9b315882b1d
212,953,367,726,331,860,000,000,000,000,000,000,000
14
crypto: drbg - Convert to new rng interface This patch converts the DRBG implementation to the new low-level rng interface. This allows us to get rid of struct drbg_gen by using the new RNG API instead. Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> Acked-by: Stephan Mueller <smueller@chronox.de>
pk_verify_host(krb5_context context, const char *realm, const krb5_krbhst_info *hi, struct krb5_pk_init_ctx_data *ctx, struct krb5_pk_cert *host) { krb5_error_code ret = 0; if (ctx->require_eku) { ret = hx509_cert_check_eku(context->hx509ctx, host->cert, &asn1_oid_id_pkk...
0
[ "CWE-320" ]
heimdal
2f7f3d9960aa6ea21358bdf3687cee5149aa35cf
111,112,827,156,243,310,000,000,000,000,000,000,000
92
CVE-2019-12098: krb5: always confirm PA-PKINIT-KX for anon PKINIT RFC8062 Section 7 requires verification of the PA-PKINIT-KX key excahnge when anonymous PKINIT is used. Failure to do so can permit an active attacker to become a man-in-the-middle. Introduced by a1ef548600c5bb51cf52a9a9ea12676506ede19f. First tagged...
stl_initialize_facet_check_nearby(stl_file *stl) { int i; if (stl->error) return; stl->stats.malloced = 0; stl->stats.freed = 0; stl->stats.collisions = 0; /* tolerance = STL_MAX(stl->stats.shortest_edge, tolerance);*/ /* tolerance = STL_MAX((stl->stats.bounding_diameter / 500000.0), tolerance);*/ ...
0
[ "CWE-125" ]
admesh
e84d8353f1347e1f26f0a95770d92ba14e6ede38
35,436,827,352,315,214,000,000,000,000,000,000,000
27
Fix heap buffer overflow in stl_update_connects_remove_1 - Add argument value check to the stl_update_connects_remove_1 - Add neighbor value check in stl_remove_degenerate Fixes https://github.com/admesh/admesh/issues/28 Merges https://github.com/admesh/admesh/pull/55
int ring_buffer_swap_cpu(struct ring_buffer *buffer_a, struct ring_buffer *buffer_b, int cpu) { struct ring_buffer_per_cpu *cpu_buffer_a; struct ring_buffer_per_cpu *cpu_buffer_b; int ret = -EINVAL; if (!cpumask_test_cpu(cpu, buffer_a->cpumask) || !cpumask_test_cpu(cpu, buffer_b->cpumask)) goto out; c...
0
[ "CWE-190" ]
linux-stable
59643d1535eb220668692a5359de22545af579f6
262,336,674,813,875,430,000,000,000,000,000,000,000
61
ring-buffer: Prevent overflow of size in ring_buffer_resize() If the size passed to ring_buffer_resize() is greater than MAX_LONG - BUF_PAGE_SIZE then the DIV_ROUND_UP() will return zero. Here's the details: # echo 18014398509481980 > /sys/kernel/debug/tracing/buffer_size_kb tracing_entries_write() processes this...
static u64 native_steal_clock(int cpu) { return 0; }
0
[ "CWE-200" ]
linux
5800dc5c19f34e6e03b5adab1282535cb102fafd
264,469,202,768,136,800,000,000,000,000,000,000,000
4
x86/paravirt: Fix spectre-v2 mitigations for paravirt guests Nadav reported that on guests we're failing to rewrite the indirect calls to CALLEE_SAVE paravirt functions. In particular the pv_queued_spin_unlock() call is left unpatched and that is all over the place. This obviously wrecks Spectre-v2 mitigation (for par...
TEST_F(HttpConnectionManagerImplTest, DrainClose) { setup(true, ""); MockStreamDecoderFilter* filter = new NiceMock<MockStreamDecoderFilter>(); EXPECT_CALL(filter_factory_, createFilterChain(_)) .WillOnce(Invoke([&](FilterChainFactoryCallbacks& callbacks) -> void { callbacks.addStreamDecoderFilter(...
0
[ "CWE-22" ]
envoy
5333b928d8bcffa26ab19bf018369a835f697585
91,427,574,252,747,950,000,000,000,000,000,000,000
48
Implement handling of escaped slash characters in URL path Fixes: CVE-2021-29492 Signed-off-by: Yan Avlasov <yavlasov@google.com>
static VALUE cState_indent_set(VALUE self, VALUE indent) { unsigned long len; GET_STATE(self); Check_Type(indent, T_STRING); len = RSTRING_LEN(indent); if (len == 0) { if (state->indent) { ruby_xfree(state->indent); state->indent = NULL; state->indent_len ...
1
[ "CWE-119", "CWE-787" ]
json
8f782fd8e181d9cfe9387ded43a5ca9692266b85
308,392,174,613,218,000,000,000,000,000,000,000,000
19
Fix arbitrary heap exposure problem
static ULONG STDMETHODCALLTYPE CliprdrEnumFORMATETC_AddRef(IEnumFORMATETC* This) { CliprdrEnumFORMATETC* instance = (CliprdrEnumFORMATETC*)This; if (!instance) return 0; return InterlockedIncrement(&instance->m_lRefCount); }
0
[ "CWE-20" ]
FreeRDP
0d79670a28c0ab049af08613621aa0c267f977e9
134,158,123,331,540,870,000,000,000,000,000,000,000
9
Fixed missing input checks for file contents request reported by Valentino Ricotta (Thalium)
static int __init ipip_init(void) { int err; printk(banner); if (xfrm4_tunnel_register(&ipip_handler, AF_INET)) { printk(KERN_INFO "ipip init: can't register tunnel\n"); return -EAGAIN; } err = register_pernet_device(&ipip_net_ops); if (err) xfrm4_tunnel_deregister(&ipip_handler, AF_INET); return err; ...
1
[]
linux-2.6
d5aa407f59f5b83d2c50ec88f5bf56d40f1f8978
185,638,023,506,352,700,000,000,000,000,000,000,000
17
tunnels: fix netns vs proto registration ordering Same stuff as in ip_gre patch: receive hook can be called before netns setup is done, oopsing in net_generic(). Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
struct tty_driver *__tty_alloc_driver(unsigned int lines, struct module *owner, unsigned long flags) { struct tty_driver *driver; unsigned int cdevs = 1; int err; if (!lines || (flags & TTY_DRIVER_UNNUMBERED_NODE && lines > 1)) return ERR_PTR(-EINVAL); driver = kzalloc(sizeof(*driver), GFP_KERNEL); if (!dri...
0
[ "CWE-416" ]
linux
c8bcd9c5be24fb9e6132e97da5a35e55a83e36b9
182,226,757,128,143,100,000,000,000,000,000,000,000
56
tty: Fix ->session locking Currently, locking of ->session is very inconsistent; most places protect it using the legacy tty mutex, but disassociate_ctty(), __do_SAK(), tiocspgrp() and tiocgsid() don't. Two of the writers hold the ctrl_lock (because they already need it for ->pgrp), but __proc_set_tty() doesn't do tha...
napi_status napi_is_exception_pending(napi_env env, bool* result) { // NAPI_PREAMBLE is not used here: this function must execute when there is a // pending exception. CHECK_ENV(env); CHECK_ARG(env, result); *result = !env->last_exception.IsEmpty(); return napi_clear_last_error(env); }
0
[ "CWE-191" ]
node
656260b4b65fec3b10f6da3fdc9f11fb941aafb5
315,464,734,852,296,180,000,000,000,000,000,000,000
9
napi: fix memory corruption vulnerability Fixes: https://hackerone.com/reports/784186 CVE-ID: CVE-2020-8174 PR-URL: https://github.com/nodejs-private/node-private/pull/195 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Gabriel Schulhof <gabriel.schulhof@intel.com> Reviewed-By: Michael Dawson <michael_da...
int propfind_owner(const xmlChar *name, xmlNsPtr ns, struct propfind_ctx *fctx, xmlNodePtr prop, xmlNodePtr resp __attribute__((unused)), struct propstat propstat[], void *rock __attribute__((unused))) { mbname_t *mbname;...
0
[]
cyrus-imapd
6703ff881b6056e0c045a7b795ce8ba1bbb87027
258,759,569,693,174,050,000,000,000,000,000,000,000
31
http_dav.c: add 'private' Cache-Control directive for cacheable responses that require authentication
builtin_dir(PyObject *self, PyObject *args) { PyObject *arg = NULL; if (!PyArg_UnpackTuple(args, "dir", 0, 1, &arg)) return NULL; return PyObject_Dir(arg); }
0
[ "CWE-125" ]
cpython
dcfcd146f8e6fc5c2fc16a4c192a0c5f5ca8c53c
28,426,872,810,740,600,000,000,000,000,000,000,000
8
bpo-35766: Merge typed_ast back into CPython (GH-11645)
int ha_partition::info(uint flag) { uint no_lock_flag= flag & HA_STATUS_NO_LOCK; uint extra_var_flag= flag & HA_STATUS_VARIABLE_EXTRA; DBUG_ENTER("ha_partition::info"); if (flag & HA_STATUS_AUTO) { bool auto_inc_is_first_in_idx= (table_share->next_number_keypart == 0); DBUG_PRINT("info", ("HA_STATUS_...
0
[]
mysql-server
be901b60ae59c93848c829d1b0b2cb523ab8692e
64,160,811,926,882,860,000,000,000,000,000,000,000
230
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 ...
static int init_inodecache(void) { sock_inode_cachep = kmem_cache_create("sock_inode_cache", sizeof(struct socket_alloc), 0, (SLAB_HWCACHE_ALIGN | SLAB_RECLAIM_ACCOUNT | SLAB_MEM_SPREAD), init_once); if (sock_inode_cachep == NULL) return -ENOMEM; ...
0
[ "CWE-264" ]
net
4de930efc23b92ddf88ce91c405ee645fe6e27ea
220,998,472,462,943,200,000,000,000,000,000,000,000
13
net: validate the range we feed to iov_iter_init() in sys_sendto/sys_recvfrom Cc: stable@vger.kernel.org # v3.19 Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> Signed-off-by: David S. Miller <davem@davemloft.net>
static zend_object *spl_dllist_object_clone(zval *zobject) /* {{{ */ { zend_object *old_object; zend_object *new_object; old_object = Z_OBJ_P(zobject); new_object = spl_dllist_object_new_ex(old_object->ce, zobject, 1); zend_objects_clone_members(new_object, old_object); return new_object; }
0
[ "CWE-415" ]
php-src
28a6ed9f9a36b9c517e4a8a429baf4dd382fc5d5
298,146,688,498,708,850,000,000,000,000,000,000,000
12
Fix bug #71735: Double-free in SplDoublyLinkedList::offsetSet
queryin(char *buf) { QPRS_STATE state; int32 i; ltxtquery *query; int32 commonlen; ITEM *ptr; NODE *tmp; int32 pos = 0; #ifdef BS_DEBUG char pbuf[16384], *cur; #endif /* init state */ state.buf = buf; state.state = WAITOPERAND; state.count = 0; state.num = 0; state.str = NULL; /* init...
0
[ "CWE-703", "CWE-189" ]
postgres
31400a673325147e1205326008e32135a78b4d8a
261,673,651,661,078,300,000,000,000,000,000,000,000
70
Predict integer overflow to avoid buffer overruns. Several functions, mostly type input functions, calculated an allocation size such that the calculation wrapped to a small positive value when arguments implied a sufficiently-large requirement. Writes past the end of the inadvertent small allocation followed shortly...
static void dccp_v6_reqsk_destructor(struct request_sock *req) { dccp_feat_list_purge(&dccp_rsk(req)->dreq_featneg); kfree(inet_rsk(req)->ipv6_opt); kfree_skb(inet_rsk(req)->pktopts); }
0
[ "CWE-241" ]
linux
83eaddab4378db256d00d295bda6ca997cd13a52
298,267,367,683,372,640,000,000,000,000,000,000,000
6
ipv6/dccp: do not inherit ipv6_mc_list from parent Like commit 657831ffc38e ("dccp/tcp: do not inherit mc_list from parent") we should clear ipv6_mc_list etc. for IPv6 sockets too. Cc: Eric Dumazet <edumazet@google.com> Signed-off-by: Cong Wang <xiyou.wangcong@gmail.com> Acked-by: Eric Dumazet <edumazet@google.com> S...
ngx_http_post_request_to_head(ngx_http_request_t *r) { ngx_http_posted_request_t *pr; pr = ngx_palloc(r->pool, sizeof(ngx_http_posted_request_t)); if (pr == NULL) { return NGX_ERROR; } pr->request = r; pr->next = r->main->posted_requests; r->main->posted_requests = pr; return...
0
[ "CWE-444" ]
lua-nginx-module
9ab38e8ee35fc08a57636b1b6190dca70b0076fa
316,459,598,490,144,700,000,000,000,000,000,000,000
15
bugfix: prevented request smuggling in the ngx.location.capture API. Signed-off-by: Yichun Zhang (agentzh) <yichun@openresty.com>
static int qeth_init_input_buffer(struct qeth_card *card, struct qeth_qdio_buffer *buf) { struct qeth_buffer_pool_entry *pool_entry; int i; if ((card->options.cq == QETH_CQ_ENABLED) && (!buf->rx_skb)) { buf->rx_skb = dev_alloc_skb(QETH_RX_PULL_LEN + ETH_HLEN); if (!buf->rx_skb) return 1; } pool_entry = ...
0
[ "CWE-200", "CWE-119" ]
linux
6fb392b1a63ae36c31f62bc3fc8630b49d602b62
246,473,779,932,451,540,000,000,000,000,000,000,000
35
qeth: avoid buffer overflow in snmp ioctl Check user-defined length in snmp ioctl request and allow request only if it fits into a qeth command buffer. Signed-off-by: Ursula Braun <ursula.braun@de.ibm.com> Signed-off-by: Frank Blaschka <frank.blaschka@de.ibm.com> Reviewed-by: Heiko Carstens <heicars2@linux.vnet.ibm.c...
void CommandHelpers::auditLogAuthEvent(OperationContext* opCtx, const CommandInvocation* invocation, const OpMsgRequest& request, ErrorCodes::Error err) { class Hook final : public audit::CommandInte...
0
[ "CWE-20" ]
mongo
d315547544d7146b93a8e6e94cc4b88cd0d19c95
234,639,340,448,718,200,000,000,000,000,000,000,000
31
SERVER-38275 ban explain with UUID
static int opadc(RAsm *a, ut8 *data, const Opcode *op) { if (op->operands[1].type & OT_CONSTANT) { if (op->operands[0].type & OT_GPREG && op->operands[0].type & OT_WORD) { return process_16bit_group_1 (a, data, op, 0x10); } if (!is_al_reg (&op->operands[0])) { return process_group_1 (a, data, op); ...
0
[ "CWE-119", "CWE-125", "CWE-787" ]
radare2
9b46d38dd3c4de6048a488b655c7319f845af185
241,500,417,643,995,000,000,000,000,000,000,000,000
12
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--
void *tdefl_compress_mem_to_heap(const void *pSrc_buf, size_t src_buf_len, size_t *pOut_len, int flags) { tdefl_output_buffer out_buf; MZ_CLEAR_OBJ(out_buf); if (!pOut_len) return MZ_FALSE; else *pOut_len = 0; out_buf.m_expandable = MZ_TRUE; if (!tdefl_compress_mem_t...
0
[ "CWE-20", "CWE-190" ]
tinyexr
a685e3332f61cd4e59324bf3f669d36973d64270
235,019,713,593,353,100,000,000,000,000,000,000,000
15
Make line_no with too large value(2**20) invalid. Fixes #124
get_scan_primary (OpKind kind) { switch (kind) { default: case OP_KIND_COPY: return f (_("Error while copying.")); case OP_KIND_MOVE: return f (_("Error while moving.")); case OP_KIND_DELETE: return f (_("Error while deleting.")); case OP_KIND_TRASH: return f (_("Error while moving files to trash.")); } ...
0
[]
nautilus
ca2fd475297946f163c32dcea897f25da892b89d
179,783,158,449,270,400,000,000,000,000,000,000,000
14
Add nautilus_file_mark_desktop_file_trusted(), this now adds a #! line if 2009-02-24 Alexander Larsson <alexl@redhat.com> * libnautilus-private/nautilus-file-operations.c: * libnautilus-private/nautilus-file-operations.h: Add nautilus_file_mark_desktop_file_trusted(), this now adds a #! line if th...
xfs_inode_ag_iterator_flags( struct xfs_mount *mp, int (*execute)(struct xfs_inode *ip, int flags, void *args), int flags, void *args, int iter_flags) { struct xfs_perag *pag; int error = 0; int last_error = 0; xfs_agnumber_t ag; ag = 0; while ((pag = xfs_perag_get(mp, ag))) { ag = pa...
0
[ "CWE-476" ]
linux
afca6c5b2595fc44383919fba740c194b0b76aff
287,157,142,438,932,200,000,000,000,000,000,000,000
27
xfs: validate cached inodes are free when allocated A recent fuzzed filesystem image cached random dcache corruption when the reproducer was run. This often showed up as panics in lookup_slow() on a null inode->i_ops pointer when doing pathwalks. BUG: unable to handle kernel NULL pointer dereference at 00000000000000...
void release_reserved_pushes(uint64_t pushes) { Mutex::Locker l(recovery_lock); assert(recovery_ops_reserved >= pushes); recovery_ops_reserved -= pushes; _maybe_queue_recovery(); }
0
[ "CWE-287", "CWE-284" ]
ceph
5ead97120e07054d80623dada90a5cc764c28468
96,439,000,548,129,070,000,000,000,000,000,000,000
6
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 ...
ins_eol(int c) { int i; if (echeck_abbr(c + ABBR_OFF)) return OK; if (stop_arrow() == FAIL) return FAIL; undisplay_dollar(); /* * Strange Vi behaviour: In Replace mode, typing a NL will not delete the * character under the cursor. Only push a NUL on the replace stack, * nothi...
0
[ "CWE-122", "CWE-787" ]
vim
0971c7a4e537ea120a6bb2195960be8d0815e97b
126,912,852,639,898,460,000,000,000,000,000,000,000
50
patch 8.2.5162: reading before the start of the line with BS in Replace mode Problem: Reading before the start of the line with BS in Replace mode. Solution: Check the cursor column is more than zero.
ecma_substring_copy_to_cesu8_buffer (const ecma_string_t *string_desc_p, /**< ecma-string descriptor */ lit_utf8_size_t start_pos, /**< position of the first character */ lit_utf8_size_t end_pos, /**< position of the last character */ ...
0
[ "CWE-416" ]
jerryscript
3bcd48f72d4af01d1304b754ef19fe1a02c96049
305,538,453,669,944,800,000,000,000,000,000,000,000
70
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
bool check_db_name(LEX_STRING *org_name) { char *name= org_name->str; uint name_length= org_name->length; bool check_for_path_chars; if ((check_for_path_chars= check_mysql50_prefix(name))) { name+= MYSQL50_TABLE_NAME_PREFIX_LENGTH; name_length-= MYSQL50_TABLE_NAME_PREFIX_LENGTH; } if (!name_leng...
0
[ "CWE-416" ]
server
4681b6f2d8c82b4ec5cf115e83698251963d80d5
23,055,698,961,923,317,000,000,000,000,000,000,000
26
MDEV-26281 ASAN use-after-poison when complex conversion is involved in blob the bug was that in_vector array in Item_func_in was allocated in the statement arena, not in the table->expr_arena. revert part of the 5acd391e8b2d. Instead, change the arena correctly in fix_all_session_vcol_exprs(). Remove TABLE_ARENA, t...
eafnosupport_ip6_mtu_from_fib6(const struct fib6_result *res, const struct in6_addr *daddr, const struct in6_addr *saddr) { return 0; }
0
[]
net
6c8991f41546c3c472503dff1ea9daaddf9331c2
84,558,185,480,483,760,000,000,000,000,000,000,000
6
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 packet_recvmsg(struct socket *sock, struct msghdr *msg, size_t len, int flags) { struct sock *sk = sock->sk; struct sk_buff *skb; int copied, err; int vnet_hdr_len = 0; unsigned int origlen = 0; err = -EINVAL; if (flags & ~(MSG_PEEK|MSG_DONTWAIT|MSG_TRUNC|MSG_CMSG_COMPAT|MSG_ERRQUEUE)) goto ou...
0
[ "CWE-416", "CWE-362" ]
linux
84ac7260236a49c79eede91617700174c2c19b0c
104,201,329,577,930,120,000,000,000,000,000,000,000
134
packet: fix race condition in packet_set_ring When packet_set_ring creates a ring buffer it will initialize a struct timer_list if the packet version is TPACKET_V3. This value can then be raced by a different thread calling setsockopt to set the version to TPACKET_V1 before packet_set_ring has finished. This leads to...
convert_to_unix_filename(char *filename) { char *p; while ((p = strchr(filename, '\\'))) { *p = '/'; } }
0
[ "CWE-787" ]
rdesktop
766ebcf6f23ccfe8323ac10242ae6e127d4505d2
125,495,901,290,471,330,000,000,000,000,000,000,000
9
Malicious RDP server security fixes This commit includes fixes for a set of 21 vulnerabilities in rdesktop when a malicious RDP server is used. All vulnerabilities was identified and reported by Eyal Itkin. * Add rdp_protocol_error function that is used in several fixes * Refactor of process_bitmap_updates * Fix pos...
static void bpf_destroy_state(struct lwtunnel_state *lwt) { struct bpf_lwt *bpf = bpf_lwt_lwtunnel(lwt); bpf_lwt_prog_destroy(&bpf->in); bpf_lwt_prog_destroy(&bpf->out); bpf_lwt_prog_destroy(&bpf->xmit); }
0
[]
net
6c8991f41546c3c472503dff1ea9daaddf9331c2
322,601,352,943,455,580,000,000,000,000,000,000,000
8
net: ipv6_stub: use ip6_dst_lookup_flow instead of ip6_dst_lookup ipv6_stub uses the ip6_dst_lookup function to allow other modules to perform IPv6 lookups. However, this function skips the XFRM layer entirely. All users of ipv6_stub->ip6_dst_lookup use ip_route_output_flow (via the ip_route_output_key and ip_route_o...