func
string
target
int64
cwe
list
project
string
commit_id
string
hash
float64
size
int64
message
string
struct FFTW3_info { FFTW3_info() { fftw_init_threads();
0
[ "CWE-119", "CWE-787" ]
CImg
ac8003393569aba51048c9d67e1491559877b1d1
55,316,893,799,180,870,000,000,000,000,000,000,000
3
.
static stbi_uc *stbi__resample_row_hv_2(stbi_uc *out, stbi_uc *in_near, stbi_uc *in_far, int w, int hs) { // need to generate 2x2 samples for every one in input int i,t0,t1; if (w == 1) { out[0] = out[1] = stbi__div4(3*in_near[0] + in_far[0] + 2); return out; } t1 = 3*in_near[0] + in_far[0];...
0
[ "CWE-787" ]
stb
5ba0baaa269b3fd681828e0e3b3ac0f1472eaf40
201,934,926,812,170,380,000,000,000,000,000,000,000
23
stb_image: Reject fractional JPEG component subsampling ratios The component resamplers are not written to support this and I've never seen it happen in a real (non-crafted) JPEG file so I'm fine rejecting this as outright corrupt. Fixes issue #1178.
static inline void sync_cr8_to_lapic(struct kvm_vcpu *vcpu) { struct vcpu_svm *svm = to_svm(vcpu); if (is_nested(svm) && (vcpu->arch.hflags & HF_VINTR_MASK)) return; if (!(svm->vmcb->control.intercept_cr_write & INTERCEPT_CR8_MASK)) { int cr8 = svm->vmcb->control.int_ctl & V_TPR_MASK; kvm_set_cr8(vcpu, cr8);...
0
[ "CWE-400" ]
linux-2.6
9581d442b9058d3699b4be568b6e5eae38a41493
299,058,379,525,131,800,000,000,000,000,000,000,000
12
KVM: Fix fs/gs reload oops with invalid ldt kvm reloads the host's fs and gs blindly, however the underlying segment descriptors may be invalid due to the user modifying the ldt after loading them. Fix by using the safe accessors (loadsegment() and load_gs_index()) instead of home grown unsafe versions. This is CVE-...
string_compare (NMConnection *dst, NMConnection *src, const char *tag) { const char *s1, *s2; s1 = (const char *) g_object_get_data (G_OBJECT (src), tag); s2 = (const char *) g_object_get_data (G_OBJECT (dst), tag); if (s1 && !s2) return FALSE; if (!s1 && s2) return FALSE; if (!s1 && !s2) return TRUE; g_...
0
[ "CWE-310" ]
network-manager-applet
4020594dfbf566f1852f0acb36ad631a9e73a82b
129,394,538,881,085,820,000,000,000,000,000,000,000
16
core: fix CA cert mishandling after cert file deletion (deb #560067) (rh #546793) If a connection was created with a CA certificate, but the user later moved or deleted that CA certificate, the applet would simply provide the connection to NetworkManager without any CA certificate. This could cause NM to connect to t...
sg_write(struct file *filp, const char __user *buf, size_t count, loff_t * ppos) { int mxsize, cmd_size, k; int input_size, blocking; unsigned char opcode; Sg_device *sdp; Sg_fd *sfp; Sg_request *srp; struct sg_header old_hdr; sg_io_hdr_t *hp; unsigned char cmnd[SG_MAX_CDB_SIZE]; int retval; retval = sg_che...
0
[]
linux
83c6f2390040f188cc25b270b4befeb5628c1aee
222,191,310,242,095,470,000,000,000,000,000,000,000
111
scsi: sg: add sg_remove_request in sg_write If the __copy_from_user function failed we need to call sg_remove_request in sg_write. Link: https://lore.kernel.org/r/610618d9-e983-fd56-ed0f-639428343af7@huawei.com Acked-by: Douglas Gilbert <dgilbert@interlog.com> Signed-off-by: Wu Bo <wubo40@huawei.com> Signed-off-by: M...
static double mp_norm1(_cimg_math_parser& mp) { const unsigned int i_end = (unsigned int)mp.opcode[2]; switch (i_end - 3) { case 1 : return cimg::abs(_mp_arg(3)); case 2 : return cimg::abs(_mp_arg(3)) + cimg::abs(_mp_arg(4)); } double res = 0; for (unsigned...
0
[ "CWE-125" ]
CImg
10af1e8c1ad2a58a0a3342a856bae63e8f257abb
283,407,214,175,005,880,000,000,000,000,000,000,000
11
Fix other issues in 'CImg<T>::load_bmp()'.
virtio_gpu_find_resource(VirtIOGPU *g, uint32_t resource_id) { struct virtio_gpu_simple_resource *res; QTAILQ_FOREACH(res, &g->reslist, next) { if (res->resource_id == resource_id) { return res; } } return NULL; }
0
[]
qemu
acfc4846508a02cc4c83aa27799fd74ac280bdb2
338,992,823,599,394,300,000,000,000,000,000,000,000
11
virtio-gpu: use VIRTIO_GPU_MAX_SCANOUTS The value is defined in virtio_gpu.h already (changing from 4 to 16). Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com> Message-id: 1463653560-26958-6-git-send-email-marcandre.lureau@redhat.com Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
add_signing_records(dns_db_t *db, dns_rdatatype_t privatetype, dns_dbversion_t *ver, dns_diff_t *diff, bool sign_all) { dns_difftuple_t *tuple, *newtuple = NULL; dns_rdata_dnskey_t dnskey; dns_rdata_t rdata = DNS_RDATA_INIT; bool flag; isc_region_t r; isc_result_t result = ISC_R_SUCCESS; uint16_t key...
0
[ "CWE-327" ]
bind9
f09352d20a9d360e50683cd1d2fc52ccedcd77a0
331,570,208,588,641,530,000,000,000,000,000,000,000
67
Update keyfetch_done compute_tag check If in keyfetch_done the compute_tag fails (because for example the algorithm is not supported), don't crash, but instead ignore the key.
static MagickBooleanType WritePOCKETMODImage(const ImageInfo *image_info, Image *image,ExceptionInfo *exception) { #define PocketPageOrder "1,2,3,4,0,7,6,5" const Image *next; Image *pages, *pocket_mod; MagickBooleanType status; register ssize_t i; assert(image_info != (const Image...
1
[ "CWE-91" ]
ImageMagick
89a1c73ee2693ded91a72d00bdf3aba410f349f1
54,461,528,742,268,640,000,000,000,000,000,000,000
89
fix shell injection vulnerability via the -authenticate option
static int readdir_search_pagecache(struct nfs_readdir_descriptor *desc) { int res; if (nfs_readdir_dont_search_cache(desc)) return -EBADCOOKIE; do { if (desc->page_index == 0) { desc->current_index = 0; desc->prev_index = 0; desc->last_cookie = 0; } res = find_and_lock_cache_page(desc); } while ...
0
[ "CWE-909" ]
linux
ac795161c93699d600db16c1a8cc23a65a1eceaf
211,899,998,708,340,170,000,000,000,000,000,000,000
17
NFSv4: Handle case where the lookup of a directory fails If the application sets the O_DIRECTORY flag, and tries to open a regular file, nfs_atomic_open() will punt to doing a regular lookup. If the server then returns a regular file, we will happily return a file descriptor with uninitialised open state. The fix is ...
TEST_F(ConnectionHandlerTest, WildcardListenerWithNoOriginalDst) { TestListener* test_listener1 = addListener(1, true, true, "test_listener1"); Network::MockListener* listener1 = new Network::MockListener(); Network::ListenerCallbacks* listener_callbacks1; EXPECT_CALL(dispatcher_, createListener_(_, _, _)) ...
1
[ "CWE-835" ]
envoy
c8de199e2971f79cbcbc6b5eadc8c566b28705d1
65,475,801,110,904,370,000,000,000,000,000,000,000
37
listener: clean up accept filter before creating connection (#8922) Signed-off-by: Yuchen Dai <silentdai@gmail.com>
void pjsua_init_tpselector(pjsua_transport_id tp_id, pjsip_tpselector *sel) { pjsua_transport_data *tpdata; unsigned flag; pj_bzero(sel, sizeof(*sel)); if (tp_id == PJSUA_INVALID_ID) return; pj_assert(tp_id >= 0 && tp_id < (int)PJ_ARRAY_SIZE(pjsua_var.tpdata)); tpdata = &pjsua_var.tpdat...
1
[ "CWE-120", "CWE-787" ]
pjproject
d27f79da11df7bc8bb56c2f291d71e54df8d2c47
12,696,429,549,407,620,000,000,000,000,000,000,000
23
Use PJ_ASSERT_RETURN() on pjsip_auth_create_digest() and pjsua_init_tpselector() (#3009) * Use PJ_ASSERT_RETURN on pjsip_auth_create_digest * Use PJ_ASSERT_RETURN on pjsua_init_tpselector() * Fix incorrect check. * Add return value to pjsip_auth_create_digest() and pjsip_auth_create_digestSHA256() * Modifi...
static plist_t parse_real_node(const char **bnode, uint8_t size) { plist_data_t data = plist_new_plist_data(); uint8_t buf[8]; size = 1 << size; // make length less misleading switch (size) { case sizeof(uint32_t): *(uint32_t*)buf = float_bswap32(*(uint32_t*)*bnode); data->rea...
0
[ "CWE-119", "CWE-787" ]
libplist
fbd8494d5e4e46bf2e90cb6116903e404374fb56
103,986,420,462,948,830,000,000,000,000,000,000,000
26
bplist: Make sure to bail out if malloc() fails in parse_string_node() Credit to Wang Junjie <zhunkibatu@gmail.com> (#93)
gnutls_ocsp_resp_get_responder(gnutls_ocsp_resp_t resp, gnutls_datum_t * dn) { int ret; size_t l = 0; if (resp == NULL || dn == NULL) { gnutls_assert(); return GNUTLS_E_INVALID_REQUEST; } dn->data = NULL; dn->size = 0; ret = _gnutls_x509_parse_dn (resp->basicresp, "tbsResponseData.responder...
0
[ "CWE-264" ]
gnutls
964632f37dfdfb914ebc5e49db4fa29af35b1de9
234,906,646,253,668,930,000,000,000,000,000,000,000
42
ocsp: corrected the comparison of the serial size in OCSP response Previously the OCSP certificate check wouldn't verify the serial length and could succeed in cases it shouldn't. Reported by Stefan Buehler.
QPDFWriter::setStaticID(bool val) { this->static_id = val; }
0
[ "CWE-399", "CWE-835" ]
qpdf
8249a26d69f72b9cda584c14cc3f12769985e481
231,902,942,615,346,700,000,000,000,000,000,000,000
4
Fix infinite loop in QPDFWriter (fixes #143)
transformColumnType(CreateStmtContext *cxt, ColumnDef *column) { /* * All we really need to do here is verify that the type is valid, * including any collation spec that might be present. */ Type ctype = typenameType(cxt->pstate, column->typeName, NULL); if (column->collClause) { Form_pg_type typtup = (Fo...
0
[ "CWE-94" ]
postgres
b9b21acc766db54d8c337d508d0fe2f5bf2daab0
214,587,474,567,927,860,000,000,000,000,000,000,000
27
In extensions, don't replace objects not belonging to the extension. Previously, if an extension script did CREATE OR REPLACE and there was an existing object not belonging to the extension, it would overwrite the object and adopt it into the extension. This is problematic, first because the overwrite is probably uni...
version(void) { fprintf(stdout,"bsdcpio %s -- %s\n", BSDCPIO_VERSION_STRING, archive_version_details()); exit(0); }
0
[ "CWE-703", "CWE-22" ]
libarchive
59357157706d47c365b2227739e17daba3607526
29,156,778,430,997,525,000,000,000,000,000,000,000
7
Add ARCHIVE_EXTRACT_SECURE_NOABSOLUTEPATHS option This fixes a directory traversal in the cpio tool.
TEST_CASE("String capture test", "[general]") { parser parser(R"( ROOT <- _ ('[' TAG_NAME ']' _)* TAG_NAME <- (!']' .)+ _ <- [ \t]* )"); std::vector<std::string> tags; parser["TAG_NAME"] = [&](const SemanticValues& sv) { tags.push_back(sv.str()); };...
1
[ "CWE-125" ]
cpp-peglib
b3b29ce8f3acf3a32733d930105a17d7b0ba347e
154,057,807,850,972,360,000,000,000,000,000,000,000
22
Fix #122
static int __nl80211_set_channel(struct cfg80211_registered_device *rdev, struct wireless_dev *wdev, struct genl_info *info) { enum nl80211_channel_type channel_type = NL80211_CHAN_NO_HT; u32 freq; int result; if (!info->attrs[NL80211_ATTR_WIPHY_FREQ]) return -EINVAL; if (!nl80211_can_set_dev_channel...
0
[ "CWE-362", "CWE-119" ]
linux
208c72f4fe44fe09577e7975ba0e7fa0278f3d03
214,308,572,875,766,740,000,000,000,000,000,000,000
38
nl80211: fix check for valid SSID size in scan operations In both trigger_scan and sched_scan operations, we were checking for the SSID length before assigning the value correctly. Since the memory was just kzalloc'ed, the check was always failing and SSID with over 32 characters were allowed to go through. This was...
int SSL_set_trust(SSL *s, int trust) { return X509_VERIFY_PARAM_set_trust(s->param, trust); }
0
[ "CWE-310" ]
openssl
56f1acf5ef8a432992497a04792ff4b3b2c6f286
273,253,346,489,898,500,000,000,000,000,000,000,000
4
Disable SSLv2 default build, default negotiation and weak ciphers. SSLv2 is by default disabled at build-time. Builds that are not configured with "enable-ssl2" will not support SSLv2. Even if "enable-ssl2" is used, users who want to negotiate SSLv2 via the version-flexible SSLv23_method() will need to explicitly ca...
mptcp_analysis_add_subflows(packet_info *pinfo _U_, tvbuff_t *tvb, proto_tree *parent_tree, struct mptcp_analysis* mptcpd) { wmem_list_frame_t *it; proto_tree *tree; proto_item *item; item=proto_tree_add_item(parent_tree, hf_mptcp_analysis_subflows, tvb, 0, 0, ENC_NA); PROTO_ITEM_SET_GENERATED...
0
[ "CWE-354" ]
wireshark
7f3fe6164a68b76d9988c4253b24d43f498f1753
229,540,375,069,498,960,000,000,000,000,000,000,000
24
TCP: do not use an unknown status when the checksum is 0xffff Otherwise it triggers an assert when adding the column as the field is defined as BASE_NONE and not BASE_DEC or BASE_HEX. Thus an unknown value (not in proto_checksum_vals[)array) cannot be represented. Mark the checksum as bad even if we process the packet...
term_check_channel_closed_recently() { term_T *term; term_T *next_term; for (term = first_term; term != NULL; term = next_term) { next_term = term->tl_next; if (term->tl_channel_recently_closed) { term->tl_channel_recently_closed = FALSE; if (term_after_channel_closed(term)) // start ove...
0
[ "CWE-476" ]
vim
cd929f7ba8cc5b6d6dcf35c8b34124e969fed6b8
297,126,303,411,669,200,000,000,000,000,000,000,000
17
patch 8.1.0633: crash when out of memory while opening a terminal window Problem: Crash when out of memory while opening a terminal window. Solution: Handle out-of-memory more gracefully.
void netlink_ack(struct sk_buff *in_skb, struct nlmsghdr *nlh, int err) { struct sk_buff *skb; struct nlmsghdr *rep; struct nlmsgerr *errmsg; size_t payload = sizeof(*errmsg); /* error messages get the original request appened */ if (err) payload += nlmsg_len(nlh); skb = netlink_alloc_skb(in_skb->sk, nlmsg_t...
0
[ "CWE-20", "CWE-269" ]
linux
f3d3342602f8bcbf37d7c46641cb9bca7618eb1c
180,037,031,545,305,830,000,000,000,000,000,000,000
34
net: rework recvmsg handler msg_name and msg_namelen logic This patch now always passes msg->msg_namelen as 0. recvmsg handlers must set msg_namelen to the proper size <= sizeof(struct sockaddr_storage) to return msg_name to the user. This prevents numerous uninitialized memory leaks we had in the recvmsg handlers an...
int SSL_CTX_get_ex_new_index(long argl, void *argp, CRYPTO_EX_new *new_func, CRYPTO_EX_dup *dup_func, CRYPTO_EX_free *free_func) { return CRYPTO_get_ex_new_index(CRYPTO_EX_INDEX_SSL_CTX, argl, argp, new_func, dup_func, free...
0
[ "CWE-310" ]
openssl
56f1acf5ef8a432992497a04792ff4b3b2c6f286
166,322,852,888,919,360,000,000,000,000,000,000,000
7
Disable SSLv2 default build, default negotiation and weak ciphers. SSLv2 is by default disabled at build-time. Builds that are not configured with "enable-ssl2" will not support SSLv2. Even if "enable-ssl2" is used, users who want to negotiate SSLv2 via the version-flexible SSLv23_method() will need to explicitly ca...
static ZIPARCHIVE_METHOD(addFromString) { struct zip *intern; zval *this = getThis(); char *buffer, *name; int buffer_len, name_len; ze_zip_object *ze_obj; struct zip_source *zs; int pos = 0; int cur_idx; if (!this) { RETURN_FALSE; } ZIP_FROM_OBJECT(intern, this); if (zend_parse_parameters(ZEND_NUM_ARG...
1
[ "CWE-22" ]
php-src
f9c2bf73adb2ede0a486b0db466c264f2b27e0bb
163,232,837,205,593,890,000,000,000,000,000,000,000
55
Fixed bug #70350: ZipArchive::extractTo allows for directory traversal when creating directories
BOOL license_send(rdpLicense* license, wStream* s, BYTE type) { int length; BYTE flags; UINT16 wMsgSize; UINT16 sec_flags; DEBUG_LICENSE("Sending %s Packet", LICENSE_MESSAGE_STRINGS[type & 0x1F]); length = Stream_GetPosition(s); Stream_SetPosition(s, 0); sec_flags = SEC_LICENSE_PKT; wMsgSize = length - LICE...
0
[]
FreeRDP
f1d6afca6ae620f9855a33280bdc6f3ad9153be0
4,145,639,006,285,878,000,000,000,000,000,000,000
44
Fix CVE-2014-0791 This patch fixes CVE-2014-0791, the remaining length in the stream is checked before doing some malloc().
static char *parse_acc(char *p, struct SYMBOL *s) { int pit = 0, acc; unsigned nacc; nacc = 0; for (;;) { if (nacc >= sizeof s->u.key.pits) { syntax("Too many accidentals", p); break; } p = parse_acc_pit(p, &pit, &acc); if (acc < 0) break; s->u.key.pits[nacc] = pit; s->u.key.accs[nacc++] = ...
0
[ "CWE-125", "CWE-787" ]
abcm2ps
3169ace6d63f6f517a64e8df0298f44a490c4a15
71,026,839,465,794,840,000,000,000,000,000,000,000
29
fix: crash when accidental without a note at start of line after K: Issue #84.
mail_config_ews_autodiscover_run_cb (GObject *source_object, GAsyncResult *result, gpointer user_data) { AsyncContext *async_context = user_data; EMailConfigEwsAutodiscover *autodiscover; EAlertSink *alert_sink; GError *error = NULL; EMailCo...
0
[ "CWE-295" ]
evolution-ews
915226eca9454b8b3e5adb6f2fff9698451778de
135,694,467,823,802,050,000,000,000,000,000,000,000
81
I#27 - SSL Certificates are not validated This depends on https://gitlab.gnome.org/GNOME/evolution-data-server/commit/6672b8236139bd6ef41ecb915f4c72e2a052dba5 too. Closes https://gitlab.gnome.org/GNOME/evolution-ews/issues/27
static void dev_gso_skb_destructor(struct sk_buff *skb) { struct dev_gso_cb *cb; kfree_skb_list(skb->next); skb->next = NULL; cb = DEV_GSO_CB(skb); if (cb->destructor) cb->destructor(skb);
0
[]
linux
7bced397510ab569d31de4c70b39e13355046387
109,077,545,643,210,850,000,000,000,000,000,000,000
11
net_dma: simple removal Per commit "77873803363c net_dma: mark broken" net_dma is no longer used and there is no plan to fix it. This is the mechanical removal of bits in CONFIG_NET_DMA ifdef guards. Reverting the remainder of the net_dma induced changes is deferred to subsequent patches. Marked for stable due to Ro...
htmlCtxtReadDoc(htmlParserCtxtPtr ctxt, const xmlChar * cur, const char *URL, const char *encoding, int options) { xmlParserInputPtr stream; if (cur == NULL) return (NULL); if (ctxt == NULL) return (NULL); xmlInitParser(); htmlCtxtReset(ctxt); stream = xmlNewStr...
0
[ "CWE-119" ]
libxml2
e724879d964d774df9b7969fc846605aa1bac54c
193,419,305,572,715,000,000,000,000,000,000,000,000
20
Fix parsing short unclosed comment uninitialized access For https://bugzilla.gnome.org/show_bug.cgi?id=746048 The HTML parser was too optimistic when processing comments and didn't check for the end of the stream on the first 2 characters
static inline int sd_local_flags(int level) { if (sched_domains_numa_distance[level] > RECLAIM_DISTANCE) return 0; return SD_BALANCE_EXEC | SD_BALANCE_FORK | SD_WAKE_AFFINE; }
0
[ "CWE-200" ]
linux
4efbc454ba68def5ef285b26ebfcfdb605b52755
314,494,931,279,190,670,000,000,000,000,000,000,000
7
sched: Fix information leak in sys_sched_getattr() We're copying the on-stack structure to userspace, but forgot to give the right number of bytes to copy. This allows the calling process to obtain up to PAGE_SIZE bytes from the stack (and possibly adjacent kernel memory). This fix copies only as much as we actually ...
zephyr_print(netdissect_options *ndo, const u_char *cp, int length) { struct z_packet z; const char *parse = (const char *) cp; int parselen = length; const char *s; int lose = 0; /* squelch compiler warnings */ z.kind = 0; z.class = 0; z.inst = 0; z.opcode = 0; z.sender = ...
1
[ "CWE-125" ]
tcpdump
d17507ffa3e9742199b02a66aa940e79ababfa30
177,717,072,259,561,860,000,000,000,000,000,000,000
187
CVE-2017-12902/Zephyr: Fix bounds checking. Use ND_TTEST() rather than comparing against ndo->ndo_snapend ourselves; it's easy to get the tests wrong. Check for running out of packet data before checking for running out of captured data, and distinguish between running out of packet data (which might just mean "no mo...
bool matchesFilter(const fs::directory_entry& entry, std::vector<std::string> filters) { const auto filePath = entry.path(); if (filePath.extension() != ".json") { return false; } if (filters.size() == 0) { return true; } for (const auto& fil...
0
[ "CWE-755" ]
mongo
75f7184eafa78006a698cda4c4adfb57f1290047
295,560,407,574,056,800,000,000,000,000,000,000,000
23
SERVER-50170 fix max staleness read preference parameter for server selection
/* {{{ proto int pspell_config_create(string language [, string spelling [, string jargon [, string encoding]]]) Create a new config to be used later to create a manager */ static PHP_FUNCTION(pspell_config_create) { char *language, *spelling = NULL, *jargon = NULL, *encoding = NULL; int language_len, spelling_len...
0
[]
php-src
ce96fd6b0761d98353761bf78d5bfb55291179fd
75,498,520,106,106,530,000,000,000,000,000,000,000
64
- 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
plperl_init_shared_libs(pTHX) { char *file = __FILE__; newXS("DynaLoader::boot_DynaLoader", boot_DynaLoader, file); newXS("PostgreSQL::InServer::Util::bootstrap", boot_PostgreSQL__InServer__Util, file); /* newXS for...::SPI::bootstrap is in select_perl_context() */ }
0
[ "CWE-264" ]
postgres
537cbd35c893e67a63c59bc636c3e888bd228bc7
231,208,549,822,504,500,000,000,000,000,000,000,000
9
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 ...
debuginfod_fetch_separate_debug_info (struct dwarf_section * section, char ** filename, void * file) { size_t build_id_len; unsigned char * build_id; if (strcmp (section->uncompressed_name, ".gnu_debuglink") == 0) { /* Get the ...
0
[ "CWE-269" ]
binutils-gdb
e98e7d9a70dcc987bff0e925f20b78cd4a2979ed
185,461,687,034,927,900,000,000,000,000,000,000,000
62
Fix NULL pointer indirection when parsing corrupt DWARF data. PR 29290 * dwarf.c (read_and_display_attr_value): Check that debug_info_p is set before dereferencing it.
~CConnectQueueTimer() override { // This is only needed when ZNC shuts down: // CZNC::~CZNC() sets its CConnectQueueTimer pointer to nullptr and // calls the manager's Cleanup() which destroys all sockets and // timers. If something calls CZNC::EnableConnectQueue() here // (e...
0
[ "CWE-20" ]
znc
64613bc8b6b4adf1e32231f9844d99cd512b8973
102,604,454,452,408,130,000,000,000,000,000,000,000
12
Don't crash if user specified invalid encoding. This is CVE-2019-9917
static bool is_lq_table_valid(struct iwl_priv *priv, struct iwl_rxon_context *ctx, struct iwl_link_quality_cmd *lq) { int i; if (ctx->ht.enabled) return true; IWL_DEBUG_INFO(priv, "Channel %u is not an HT channel\n", ctx->active.channel); for (i = 0; i < LINK_QUAL_MAX_RETRY_NUM; i++) ...
0
[ "CWE-119", "CWE-787" ]
linux
2da424b0773cea3db47e1e81db71eeebde8269d4
71,689,156,731,612,000,000,000,000,000,000,000,000
22
iwlwifi: Sanity check for sta_id On my testing, I saw some strange behavior [ 421.739708] iwlwifi 0000:01:00.0: ACTIVATE a non DRIVER active station id 148 addr 00:00:00:00:00:00 [ 421.739719] iwlwifi 0000:01:00.0: iwl_sta_ucode_activate Added STA id 148 addr 00:00:00:00:00:00 to uCode not sure how it happen, but ...
njs_string_prototype_repeat(njs_vm_t *vm, njs_value_t *args, njs_uint_t nargs, njs_index_t unused) { u_char *p; int64_t n, max; uint64_t size, length; njs_int_t ret; njs_value_t *this; njs_string_prop_t string; this = njs_argument(args, ...
0
[]
njs
36f04a3178fcb6da8513cc3dbf35215c2a581b3f
265,071,524,254,204,630,000,000,000,000,000,000,000
63
Fixed String.prototype.replace() with byte strings. This closes #522 issue on Github.
static bool can_checksum_protocol(unsigned long features, __be16 protocol) { return ((features & NETIF_F_GEN_CSUM) || ((features & NETIF_F_V4_CSUM) && protocol == htons(ETH_P_IP)) || ((features & NETIF_F_V6_CSUM) && protocol == htons(ETH_P_IPV6)) || ((features & NETIF_F_FCOE_CRC) && protocol == htons(ET...
0
[ "CWE-264" ]
linux
8909c9ad8ff03611c9c96c9a92656213e4bb495b
40,296,931,321,269,703,000,000,000,000,000,000,000
10
net: don't allow CAP_NET_ADMIN to load non-netdev kernel modules Since a8f80e8ff94ecba629542d9b4b5f5a8ee3eb565c any process with CAP_NET_ADMIN may load any module from /lib/modules/. This doesn't mean that CAP_NET_ADMIN is a superset of CAP_SYS_MODULE as modules are limited to /lib/modules/**. However, CAP_NET_ADMIN...
int Field_year::store(const char *from, size_t len,CHARSET_INFO *cs) { ASSERT_COLUMN_MARKED_FOR_WRITE_OR_COMPUTED; THD *thd= get_thd(); char *end; int error; longlong nr= cs->cset->strntoull10rnd(cs, from, len, 0, &end, &error); if (nr < 0 || (nr >= 100 && nr <= 1900) || nr > 2155 || error == MY_ERR...
0
[ "CWE-416", "CWE-703" ]
server
08c7ab404f69d9c4ca6ca7a9cf7eec74c804f917
183,495,871,033,252,450,000,000,000,000,000,000,000
43
MDEV-24176 Server crashes after insert in the table with virtual column generated using date_format() and if() vcol_info->expr is allocated on expr_arena at parsing stage. Since expr item is allocated on expr_arena all its containee items must be allocated on expr_arena too. Otherwise fix_session_expr() will encounter...
static inline void CoefficientsToAffineArgs(double *coeff) { /* map internal c0,c1,c2,c3,c4,c5 to external sx,ry,rx,sy,tx,ty */ double tmp[4]; /* note indexes 0 and 5 remain unchanged */ tmp[0]=coeff[3]; tmp[1]=coeff[1]; tmp[2]=coeff[4]; tmp[3]=coeff[2]; coeff[1]=tmp[0]; coeff[2]=tmp[1]; coeff[3]=tmp[2]; co...
0
[]
ImageMagick6
4eafab89a2742865d770857a9d7434993f65ae6b
250,859,794,942,668,600,000,000,000,000,000,000,000
7
https://github.com/ImageMagick/ImageMagick/issues/3331
Status AuthorizationManager::initialize(OperationContext* txn) { invalidateUserCache(); Status status = _externalState->initialize(txn); if (!status.isOK()) return status; return Status::OK(); }
0
[ "CWE-613" ]
mongo
64d8e9e1b12d16b54d6a592bae8110226c491b4e
62,776,285,997,760,940,000,000,000,000,000,000,000
8
SERVER-38984 Validate unique User ID on UserCache hit (cherry picked from commit e55d6e2292e5dbe2f97153251d8193d1cc89f5d7)
m4_debugmode (struct obstack *obs, int argc, token_data **argv) { int new_debug_level; int change_flag; if (bad_argc (argv[0], argc, 1, 2)) return; if (argc == 1) debug_level = 0; else { if (ARG (1)[0] == '+' || ARG (1)[0] == '-') { change_flag = ARG (1)[0]; new_debug_level = debug_...
0
[]
m4
5345bb49077bfda9fabd048e563f9e7077fe335d
284,029,656,798,357,630,000,000,000,000,000,000,000
45
Minor security fix: Quote output of mkstemp. * src/builtin.c (mkstemp_helper): Produce quoted output. * doc/m4.texinfo (Mkstemp): Update the documentation and tests. * NEWS: Document this change. Signed-off-by: Eric Blake <ebb9@byu.net> (cherry picked from commit bd9900d65eb9cd5add0f107e94b513fa267495ba)
static void io_flush_cached_locked_reqs(struct io_ring_ctx *ctx, struct io_comp_state *cs) { spin_lock_irq(&ctx->completion_lock); list_splice_init(&ctx->locked_free_list, &cs->free_list); ctx->locked_free_nr = 0; spin_unlock_irq(&ctx->completion_lock); }
0
[ "CWE-125" ]
linux
89c2b3b74918200e46699338d7bcc19b1ea12110
270,512,157,680,146,750,000,000,000,000,000,000,000
8
io_uring: reexpand under-reexpanded iters [ 74.211232] BUG: KASAN: stack-out-of-bounds in iov_iter_revert+0x809/0x900 [ 74.212778] Read of size 8 at addr ffff888025dc78b8 by task syz-executor.0/828 [ 74.214756] CPU: 0 PID: 828 Comm: syz-executor.0 Not tainted 5.14.0-rc3-next-20210730 #1 [ 74.216525] Hardware n...
SPL_METHOD(SplObjectStorage, unserialize) { spl_SplObjectStorage *intern = (spl_SplObjectStorage*)zend_object_store_get_object(getThis() TSRMLS_CC); char *buf; int buf_len; const unsigned char *p, *s; php_unserialize_data_t var_hash; zval *pentry, *pmembers, *pcount = NULL, *pinf; long count; if (zend_parse_p...
1
[]
php-src
f06a069c462d37c2e009f6d1d93b8c8e7b713393
188,549,923,336,069,400,000,000,000,000,000,000,000
130
Fix bug #70365 - use-after-free vulnerability in unserialize() with SplObjectStorage
int pipe_proc_fn(struct ctl_table *table, int write, void __user *buf, size_t *lenp, loff_t *ppos) { int ret; ret = proc_dointvec_minmax(table, write, buf, lenp, ppos); if (ret < 0 || !write) return ret; pipe_max_size = round_pipe_size(pipe_max_size); return ret; }
0
[ "CWE-17" ]
linux
f0d1bec9d58d4c038d0ac958c9af82be6eb18045
78,756,489,313,495,410,000,000,000,000,000,000,000
12
new helper: copy_page_from_iter() parallel to copy_page_to_iter(). pipe_write() switched to it (and became ->write_iter()). Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
static int _gdImageWebpCtx (gdImagePtr im, gdIOCtx * outfile, int quality) { uint8_t *argb; int x, y; uint8_t *p; uint8_t *out; size_t out_size; int ret = 0; if (im == NULL) { return 1; } if (!gdImageTrueColor(im)) { gd_error("Palette image not supported by webp"); return 1; } if (quality == -1) ...
0
[ "CWE-415" ]
libgd
a49feeae76d41959d85ee733925a4cf40bac61b2
120,886,717,661,245,850,000,000,000,000,000,000,000
66
Fix double-free in gdImageWebPtr() The issue is that gdImageWebpCtx() (which is called by gdImageWebpPtr() and the other WebP output functions to do the real work) does not return whether it succeeded or failed, so this is not checked in gdImageWebpPtr() and the function wrongly assumes everything is okay, which is no...
static void hci_cs_le_ext_create_conn(struct hci_dev *hdev, u8 status) { struct hci_cp_le_ext_create_conn *cp; BT_DBG("%s status 0x%2.2x", hdev->name, status); /* All connection failure handling is taken care of by the * hci_le_conn_failed function which is triggered by the HCI * request completion callbacks u...
0
[ "CWE-290" ]
linux
3ca44c16b0dcc764b641ee4ac226909f5c421aa3
18,287,875,596,522,012,000,000,000,000,000,000,000
24
Bluetooth: Consolidate encryption handling in hci_encrypt_cfm This makes hci_encrypt_cfm calls hci_connect_cfm in case the connection state is BT_CONFIG so callers don't have to check the state. Signed-off-by: Luiz Augusto von Dentz <luiz.von.dentz@intel.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
func_ref(char_u *name) { ufunc_T *fp; if (name == NULL || !func_name_refcount(name)) return; fp = find_func(name, FALSE); if (fp != NULL) ++fp->uf_refcount; else if (numbered_function(name)) // Only give an error for a numbered function. // Fail silently, when named or lambda function isn't fou...
0
[ "CWE-416" ]
vim
91c7cbfe31bbef57d5fcf7d76989fc159f73ef15
90,745,633,511,746,900,000,000,000,000,000,000,000
14
patch 9.0.0225: using freed memory with multiple line breaks in expression Problem: Using freed memory with multiple line breaks in expression. Solution: Free eval_tofree later.
make_bound_box(POLYGON *poly) { int i; double x1, y1, x2, y2; if (poly->npts > 0) { x2 = x1 = poly->p[0].x; y2 = y1 = poly->p[0].y; for (i = 1; i < poly->npts; i++) { if (poly->p[i].x < x1) x1 = poly->p[i].x; if (poly->p[i].x > x2) x2 = poly->p[i].x; if (poly->p[i].y < y1) ...
0
[ "CWE-703", "CWE-189" ]
postgres
31400a673325147e1205326008e32135a78b4d8a
273,224,273,332,805,300,000,000,000,000,000,000,000
31
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...
void bdrv_set_io_limits(BlockDriverState *bs, ThrottleConfig *cfg) { int i; throttle_config(&bs->throttle_state, cfg); for (i = 0; i < 2; i++) { qemu_co_enter_next(&bs->throttled_reqs[i]); } }
0
[ "CWE-190" ]
qemu
8f4754ede56e3f9ea3fd7207f4a7c4453e59285b
37,586,635,228,609,550,000,000,000,000,000,000,000
11
block: Limit request size (CVE-2014-0143) Limiting the size of a single request to INT_MAX not only fixes a direct integer overflow in bdrv_check_request() (which would only trigger bad behaviour with ridiculously huge images, as in close to 2^64 bytes), but can also prevent overflows in all block drivers. Signed-off...
static void kvm_invalidate_memslot(struct kvm *kvm, struct kvm_memory_slot *old, struct kvm_memory_slot *invalid_slot) { /* * Mark the current slot INVALID. As with all memslot modifications, * this must be done on an unreachable slot to avoid modifying the * current slot in the active tree. */...
1
[ "CWE-459" ]
linux
683412ccf61294d727ead4a73d97397396e69a6b
203,037,765,762,838,770,000,000,000,000,000,000,000
40
KVM: SEV: add cache flush to solve SEV cache incoherency issues Flush the CPU caches when memory is reclaimed from an SEV guest (where reclaim also includes it being unmapped from KVM's memslots). Due to lack of coherency for SEV encrypted memory, failure to flush results in silent data corruption if userspace is mal...
void ECDSA_SIG_free(ECDSA_SIG *sig) { if (sig == NULL) return; BN_clear_free(sig->r); BN_clear_free(sig->s); OPENSSL_free(sig); }
0
[ "CWE-125" ]
openssl
94d23fcff9b2a7a8368dfe52214d5c2569882c11
38,256,417,240,045,545,000,000,000,000,000,000,000
8
Fix EC_GROUP_new_from_ecparameters to check the base length Check that there's at least one byte in params->base before trying to read it. CVE-2021-3712 Reviewed-by: Viktor Dukhovni <viktor@openssl.org> Reviewed-by: Paul Dale <pauli@openssl.org>
void JOIN::cleanup(bool full) { DBUG_ENTER("JOIN::cleanup"); DBUG_PRINT("enter", ("full %u", (uint) full)); if (full) have_query_plan= QEP_DELETED; if (original_join_tab) { /* Free the original optimized join created for the group_by_handler */ join_tab= original_join_tab; original_join_ta...
0
[]
server
ff77a09bda884fe6bf3917eb29b9d3a2f53f919b
124,736,876,951,185,620,000,000,000,000,000,000,000
118
MDEV-22464 Server crash on UPDATE with nested subquery Uninitialized ref_pointer_array[] because setup_fields() got empty fields list. mysql_multi_update() for some reason does that by substituting the fields list with empty total_list for the mysql_select() call (looks like wrong merge since total_list is not used a...
void NumberFormatTest::TestParseNegativeWithAlternateMinusSign() { UErrorCode status = U_ZERO_ERROR; DecimalFormat *test = (DecimalFormat *) NumberFormat::createInstance("en", status); CHECK_DATA(status, "NumberFormat::createInstance") test->setLenient(TRUE); Formattable af; ParsePosition ppos; ...
0
[ "CWE-190" ]
icu
53d8c8f3d181d87a6aa925b449b51c4a2c922a51
159,697,380,398,047,150,000,000,000,000,000,000,000
15
ICU-20246 Fixing another integer overflow in number parsing.
inline void fatal_error() { DBUG_ASSERT(get_stmt_da()->is_error() || killed); is_fatal_error= 1; DBUG_PRINT("error",("Fatal error set")); }
0
[ "CWE-416" ]
server
4681b6f2d8c82b4ec5cf115e83698251963d80d5
279,760,822,789,606,220,000,000,000,000,000,000,000
6
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...
static void nfc_llcp_recv_agf(struct nfc_llcp_local *local, struct sk_buff *skb) { u8 ptype; u16 pdu_len; struct sk_buff *new_skb; if (skb->len <= LLCP_HEADER_SIZE) { pr_err("Malformed AGF PDU\n"); return; } skb_pull(skb, LLCP_HEADER_SIZE); while (skb->len > LLCP_AGF_PDU_HEADER_SIZE) { pdu_len = skb->da...
0
[ "CWE-476" ]
linux
58bdd544e2933a21a51eecf17c3f5f94038261b5
208,657,730,040,369,040,000,000,000,000,000,000,000
43
net: nfc: Fix NULL dereference on nfc_llcp_build_tlv fails KASAN report this: BUG: KASAN: null-ptr-deref in nfc_llcp_build_gb+0x37f/0x540 [nfc] Read of size 3 at addr 0000000000000000 by task syz-executor.0/5401 CPU: 0 PID: 5401 Comm: syz-executor.0 Not tainted 5.0.0-rc7+ #45 Hardware name: QEMU Standard PC (i440FX ...
static void opj_j2k_read_int16_to_float (const void * p_src_data, void * p_dest_data, OPJ_UINT32 p_nb_elem) { OPJ_BYTE * l_src_data = (OPJ_BYTE *) p_src_data; OPJ_FLOAT32 * l_dest_data = (OPJ_FLOAT32 *) p_dest_data; OPJ_UINT32 i; OPJ_UINT32 l_temp; for (i=0;i<p_nb_elem;++i) { ...
0
[ "CWE-416" ]
openjpeg
940100c28ae28931722290794889cf84a92c5f6f
126,713,536,900,387,420,000,000,000,000,000,000,000
15
Fix potential use-after-free in opj_j2k_write_mco function Fixes #563
ArgParser::argForceVersion(char* parameter) { o.force_version = parameter; }
0
[ "CWE-787" ]
qpdf
d71f05ca07eb5c7cfa4d6d23e5c1f2a800f52e8e
290,717,335,426,755,120,000,000,000,000,000,000,000
4
Fix sign and conversion warnings (major) This makes all integer type conversions that have potential data loss explicit with calls that do range checks and raise an exception. After this commit, qpdf builds with no warnings when -Wsign-conversion -Wconversion is used with gcc or clang or when -W3 -Wd4800 is used with ...
static void virgl_cmd_get_capset(VirtIOGPU *g, struct virtio_gpu_ctrl_command *cmd) { struct virtio_gpu_get_capset gc; struct virtio_gpu_resp_capset *resp; uint32_t max_ver, max_size; VIRTIO_GPU_FILL_CMD(gc); virgl_renderer_get_cap_set(gc.capset_id, &max_ver, ...
0
[]
qemu
2fe760554eb3769d70f608a158474f728ba45ba6
295,333,696,503,140,000,000,000,000,000,000,000,000
19
virtio-gpu: check max_outputs only The scanout id should not be above the configured num_scanouts. Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com> Message-id: 1463653560-26958-5-git-send-email-marcandre.lureau@redhat.com Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
static NTSTATUS pdb_samba_dsdb_mod_groupmem_by_sid(struct pdb_methods *m, TALLOC_CTX *mem_ctx, const struct dom_sid *groupsid, const struct dom_sid *membersid, int mod_op) { struct pdb_samba_dsdb_state *state = talloc_get_type_abort( m->private_data, struct pdb_samba_d...
0
[ "CWE-200" ]
samba
0a3aa5f908e351201dc9c4d4807b09ed9eedff77
190,621,610,389,535,770,000,000,000,000,000,000,000
59
CVE-2022-32746 ldb: Make use of functions for appending to an ldb_message This aims to minimise usage of the error-prone pattern of searching for a just-added message element in order to make modifications to it (and potentially finding the wrong element). BUG: https://bugzilla.samba.org/show_bug.cgi?id=15009 Signed...
static int megasas_get_ld_vf_affiliation_12(struct megasas_instance *instance, int initial) { struct megasas_cmd *cmd; struct megasas_dcmd_frame *dcmd; struct MR_LD_VF_AFFILIATION *new_affiliation = NULL; struct MR_LD_VF_MAP *newmap = NULL, *savedmap = NULL; dma_addr_t new_affiliation_h; int i, j, retval...
0
[ "CWE-476" ]
linux
bcf3b67d16a4c8ffae0aa79de5853435e683945c
163,956,186,344,902,950,000,000,000,000,000,000,000
165
scsi: megaraid_sas: return error when create DMA pool failed when create DMA pool for cmd frames failed, we should return -ENOMEM, instead of 0. In some case in: megasas_init_adapter_fusion() -->megasas_alloc_cmds() -->megasas_create_frame_pool create DMA pool failed, --> megasas_fre...
span_renderer_init (cairo_abstract_span_renderer_t *_r, const cairo_composite_rectangles_t *composite, cairo_antialias_t antialias, cairo_bool_t needs_clip) { cairo_image_span_renderer_t *r = (cairo_image_span_renderer_t *)_r; cairo_image_surface_t *dst = (cairo_image_surface_t *)composi...
0
[]
cairo
03a820b173ed1fdef6ff14b4468f5dbc02ff59be
66,708,819,345,717,350,000,000,000,000,000,000,000
131
Fix mask usage in image-compositor
read_rssi_compensation_param(struct ar6_softc *ar) { u8 *cust_data_ptr; //#define RSSICOMPENSATION_PRINT #ifdef RSSICOMPENSATION_PRINT s16 i; cust_data_ptr = ar6000_get_cust_data_buffer(ar->arTargetType); for (i=0; i<16; i++) { A_PRINTF("cust_data_%d = %x \n", i, *(u8 *)cust_data_ptr); ...
0
[ "CWE-703", "CWE-264" ]
linux
550fd08c2cebad61c548def135f67aba284c6162
50,947,711,219,197,830,000,000,000,000,000,000,000
41
net: Audit drivers to identify those needing IFF_TX_SKB_SHARING cleared After the last patch, We are left in a state in which only drivers calling ether_setup have IFF_TX_SKB_SHARING set (we assume that drivers touching real hardware call ether_setup for their net_devices and don't hold any state in their skbs. There...
TEST_F(HttpConnectionManagerConfigTest, UnknownRequestIDExtension) { const std::string yaml_string = R"EOF( stat_prefix: ingress_http route_config: name: local_route request_id_extension: typed_config: "@type": type.googleapis.com/test.http_connection_manager.UnknownRequestIDExtension http_filte...
0
[ "CWE-22" ]
envoy
5333b928d8bcffa26ab19bf018369a835f697585
67,868,104,598,018,600,000,000,000,000,000,000,000
15
Implement handling of escaped slash characters in URL path Fixes: CVE-2021-29492 Signed-off-by: Yan Avlasov <yavlasov@google.com>
static void arrange_posix_perms(const char *filename, canon_ace **pp_list_head) { canon_ace *list_head = *pp_list_head; canon_ace *owner_ace = NULL; canon_ace *other_ace = NULL; canon_ace *ace = NULL; for (ace = list_head; ace; ace = ace->next) { if (ace->type == SMB_ACL_USER_OBJ) owner_ace = ace; else if ...
0
[ "CWE-264" ]
samba
d6c28913f3109d1327a3d1369b6eafd3874b2dca
17,852,681,413,331,870,000,000,000,000,000,000,000
39
Bug 6488: acl_group_override() call in posix acls references an uninitialized variable. (cherry picked from commit f92195e3a1baaddda47a5d496f9488c8445b41ad)
static void testDoubleSlashPath(CuTest *tc) { int r; r = aug_rm(aug, "/augeas/load/*"); CuAssertPositive(tc, r); r = aug_set(aug, "/augeas/load/Hosts/lens", "Hosts.lns"); CuAssertRetSuccess(tc, r); r = aug_set(aug, "/augeas/load/Hosts/incl", "/etc//hosts"); CuAssertRetSuccess(tc, r); r...
0
[]
augeas
f5b4fc0ceb0e5a2be5f3a19f63ad936897a3ac26
272,630,560,898,917,730,000,000,000,000,000,000,000
34
Fix umask handling when creating new files * src/transform.c (transform_save): faulty umask arithmetic would cause overly-open file modes when the umask contains "7", as the umask was incorrectly subtracted from the target file mode Fixes CVE-2013-6412, RHBZ#1034261
sds getAllClientsInfoString(int type) { listNode *ln; listIter li; client *client; sds o = sdsnewlen(SDS_NOINIT,200*listLength(server.clients)); sdsclear(o); listRewind(server.clients,&li); while ((ln = listNext(&li)) != NULL) { client = listNodeValue(ln); if (type != -1 && g...
0
[ "CWE-770" ]
redis
5674b0057ff2903d43eaff802017eddf37c360f8
316,953,885,494,539,760,000,000,000,000,000,000,000
15
Prevent unauthenticated client from easily consuming lots of memory (CVE-2021-32675) This change sets a low limit for multibulk and bulk length in the protocol for unauthenticated connections, so that they can't easily cause redis to allocate massive amounts of memory by sending just a few characters on the network. T...
void file_tree_checksum::write(config& cfg) const { cfg["nfiles"] = lexical_cast<std::string>(nfiles); cfg["size"] = lexical_cast<std::string>(sum_size); cfg["modified"] = lexical_cast<std::string>(modified); }
0
[ "CWE-200" ]
wesnoth
af61f9fdd15cd439da9e2fe5fa39d174c923eaae
122,316,707,403,299,080,000,000,000,000,000,000,000
6
fs: Use game data path to resolve ./ in the absence of a current_dir Fixes a file content disclosure bug (#22042) affecting functionality relying on the get_wml_location() function and not passing a non-empty value for the current_dir parameter. See <https://gna.org/bugs/?22042> for details. This is a candidate for ...
static TEE_Result get_pbkdf2_params(const TEE_Attribute *params, uint32_t param_count, void **salt, size_t *salt_len, size_t *derived_key_len, size_t *iteration_count) { size_t n; enum { SALT = 0x1, LENGTH = 0x2, COUNT = 0x4 }; uint8_t found = 0; *salt = NULL; *salt_len = *derived_key_len = *...
0
[ "CWE-119", "CWE-787" ]
optee_os
a637243270fc1faae16de059091795c32d86e65e
274,522,991,187,278,150,000,000,000,000,000,000,000
44
svc: check for allocation overflow in crypto calls Without checking for overflow there is a risk of allocating a buffer with size smaller than anticipated and as a consequence of that it might lead to a heap based overflow with attacker controlled data written outside the boundaries of the buffer. Fixes: OP-TEE-2018-...
nv_hor_scrollbar(cmdarg_T *cap) { if (cap->oap->op_type != OP_NOP) clearopbeep(cap->oap); // Even if an operator was pending, we still want to scroll gui_do_horiz_scroll(scrollbar_value, FALSE); }
0
[ "CWE-416" ]
vim
35a9a00afcb20897d462a766793ff45534810dc3
339,410,758,806,873,700,000,000,000,000,000,000,000
8
patch 8.2.3428: using freed memory when replacing Problem: Using freed memory when replacing. (Dhiraj Mishra) Solution: Get the line pointer after calling ins_copychar().
int hashTypeNext(hashTypeIterator *hi) { if (hi->encoding == OBJ_ENCODING_ZIPLIST) { unsigned char *zl; unsigned char *fptr, *vptr; zl = hi->subject->ptr; fptr = hi->fptr; vptr = hi->vptr; if (fptr == NULL) { /* Initialize cursor */ serverAss...
0
[ "CWE-190" ]
redis
f6a40570fa63d5afdd596c78083d754081d80ae3
207,896,635,972,926,900,000,000,000,000,000,000,000
34
Fix ziplist and listpack overflows and truncations (CVE-2021-32627, CVE-2021-32628) - fix possible heap corruption in ziplist and listpack resulting by trying to allocate more than the maximum size of 4GB. - prevent ziplist (hash and zset) from reaching size of above 1GB, will be converted to HT encoding, that's n...
_gnutls_handshake_common (gnutls_session_t session) { int ret = 0; /* send and recv the change cipher spec and finished messages */ if ((session->internals.resumed == RESUME_TRUE && session->security_parameters.entity == GNUTLS_CLIENT) || (session->internals.resumed == RESUME_FALSE && session->se...
0
[ "CWE-189" ]
gnutls
bc8102405fda11ea00ca3b42acc4f4bce9d6e97b
148,991,324,840,524,220,000,000,000,000,000,000,000
39
Fix GNUTLS-SA-2008-1 security vulnerabilities. See http://www.gnu.org/software/gnutls/security.html for updates.
CImg<Tfloat> get_resize_object3d() const { return CImg<Tfloat>(*this,false).resize_object3d(); }
0
[ "CWE-770" ]
cimg
619cb58dd90b4e03ac68286c70ed98acbefd1c90
270,077,541,160,083,700,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 void decorrelate_init(QuicFamily *family, int bpc) { const unsigned int pixelbitmask = bppmask[bpc]; const unsigned int pixelbitmaskshr = pixelbitmask >> 1; unsigned int s; //spice_assert(bpc <= 8); for (s = 0; s <= pixelbitmask; s++) { if (s <= pixelbitmaskshr) { family...
0
[]
spice-common
762e0abae36033ccde658fd52d3235887b60862d
265,115,318,992,900,480,000,000,000,000,000,000,000
16
quic: Check we have some data to start decoding quic image All paths already pass some data to quic_decode_begin but for the test check it, it's not that expensive test. Checking for not 0 is enough, all other words will potentially be read calling more_io_words but we need one to avoid a potential initial buffer over...
static my_socket mariadb_get_socket(MYSQL *mysql) { my_socket sock= INVALID_SOCKET; if (mysql->net.pvio) { ma_pvio_get_handle(mysql->net.pvio, &sock); } /* if an asynchronous connect is in progress, we need to obtain pvio handle from async_context until the connection was successfully establish...
0
[]
mariadb-connector-c
27b2f3d1f1550dfaee0f63a331a406ab31c1b37e
315,036,384,148,822,500,000,000,000,000,000,000,000
19
various checks for corrupted packets in the protocol also: check the return value of unpack_fields()
TEST(UriSuite, TestUriUserInfoHostPort22Bug1948038) { UriParserStateA stateA; UriUriA uriA; stateA.uri = &uriA; int res; res = uriParseUriA(&stateA, "http://user:21@host/"); ASSERT_TRUE(URI_SUCCESS == res); ASSERT_TRUE(!memcmp(uriA.userInfo.first, "user:21", 7 * sizeof(char))); ASSERT_TRUE(uriA.userIn...
0
[ "CWE-125" ]
uriparser
cef25028de5ff872c2e1f0a6c562eb3ea9ecbce4
285,793,819,229,483,820,000,000,000,000,000,000,000
29
Fix uriParse*Ex* out-of-bounds read
static ssize_t new_offset_show(struct md_rdev *rdev, char *page) { return sprintf(page, "%llu\n", (unsigned long long)rdev->new_data_offset); }
0
[ "CWE-200" ]
linux
b6878d9e03043695dbf3fa1caa6dfc09db225b16
139,865,661,549,110,080,000,000,000,000,000,000,000
5
md: use kzalloc() when bitmap is disabled In drivers/md/md.c get_bitmap_file() uses kmalloc() for creating a mdu_bitmap_file_t called "file". 5769 file = kmalloc(sizeof(*file), GFP_NOIO); 5770 if (!file) 5771 return -ENOMEM; This structure is copied to user space at the end of the fun...
static long madvise_behavior(struct vm_area_struct *vma, struct vm_area_struct **prev, unsigned long start, unsigned long end, int behavior) { struct mm_struct *mm = vma->vm_mm; int error = 0; pgoff_t pgoff; unsigned long new_flags = vma->vm_flags; switch (behavior) { case MADV_NORMAL: new_flags ...
0
[]
linux
bc0c4d1e176eeb614dc8734fc3ace34292771f11
313,758,393,622,988,230,000,000,000,000,000,000,000
116
mm: check that mm is still valid in madvise() IORING_OP_MADVISE can end up basically doing mprotect() on the VM of another process, which means that it can race with our crazy core dump handling which accesses the VM state without holding the mmap_sem (because it incorrectly thinks that it is the final user). This is...
int ip6_xmit(struct sock *sk, struct sk_buff *skb, struct flowi6 *fl6, struct ipv6_txoptions *opt, int tclass) { struct net *net = sock_net(sk); struct ipv6_pinfo *np = inet6_sk(sk); struct in6_addr *first_hop = &fl6->daddr; struct dst_entry *dst = skb_dst(skb); struct ipv6hdr *hdr; u8 proto = fl6->flowi6_...
0
[ "CWE-119", "CWE-401" ]
linux
2811ebac2521ceac84f2bdae402455baa6a7fb47
286,504,319,071,119,300,000,000,000,000,000,000,000
80
ipv6: udp packets following an UFO enqueued packet need also be handled by UFO In the following scenario the socket is corked: If the first UDP packet is larger then the mtu we try to append it to the write queue via ip6_ufo_append_data. A following packet, which is smaller than the mtu would be appended to the alread...
static void AddAttrToList( AttVal** list, AttVal* av ) { if ( *list == NULL ) *list = av; else { AttVal* here = *list; while ( here->next ) here = here->next; here->next = av; } }
0
[ "CWE-119" ]
tidy-html5
c18f27a58792f7fbd0b30a0ff50d6b40a82f940d
26,294,795,103,508,583,000,000,000,000,000,000,000
12
Issue #217 - avoid len going negative, ever...
Int32 BZ2_decompress ( DState* s ) { UChar uc; Int32 retVal; Int32 minLen, maxLen; bz_stream* strm = s->strm; /* stuff that needs to be saved/restored */ Int32 i; Int32 j; Int32 t; Int32 alphaSize; Int32 nGroups; Int32 nSelectors; Int32 EOB; Int32 groupNo; ...
1
[ "CWE-787" ]
bzip2
74de1e2e6ffc9d51ef9824db71a8ffee5962cdbc
165,979,335,088,151,360,000,000,000,000,000,000,000
536
Make sure nSelectors is not out of range nSelectors is used in a loop from 0 to nSelectors to access selectorMtf which is UChar selectorMtf[BZ_MAX_SELECTORS]; so if nSelectors is bigger than BZ_MAX_SELECTORS it'll do an invalid memory access Fixes out of bounds access discovered while fuzzying karchive
static int jp2_getct(int colorspace, int type, int assoc) { if (type == 1 && assoc == 0) { return JAS_IMAGE_CT_OPACITY; } if (type == 0 && assoc >= 1 && assoc <= 65534) { switch (colorspace) { case JAS_CLRSPC_FAM_RGB: switch (assoc) { case JP2_CDEF_RGB_R: return JAS_IMAGE_CT_COLOR(JAS_CLRSPC_CHANIND_...
0
[ "CWE-189" ]
jasper
3c55b399c36ef46befcb21e4ebc4799367f89684
313,244,786,017,913,330,000,000,000,000,000,000,000
47
At many places in the code, jas_malloc or jas_recalloc was being invoked with the size argument being computed in a manner that would not allow integer overflow to be detected. Now, these places in the code have been modified to use special-purpose memory allocation functions (e.g., jas_alloc2, jas_alloc3, jas_realloc...
const Block* BlockGroup::GetBlock() const { return &m_block; }
0
[ "CWE-20" ]
libvpx
34d54b04e98dd0bac32e9aab0fbda0bf501bc742
65,327,289,279,930,260,000,000,000,000,000,000,000
1
update libwebm to libwebm-1.0.0.27-358-gdbf1d10 changelog: https://chromium.googlesource.com/webm/libwebm/+log/libwebm-1.0.0.27-351-g9f23fbc..libwebm-1.0.0.27-358-gdbf1d10 Change-Id: I28a6b3ae02a53fb1f2029eee11e9449afb94c8e3
static long pipe_set_size(struct pipe_inode_info *pipe, unsigned long nr_pages) { struct pipe_buffer *bufs; /* * We can shrink the pipe, if arg >= pipe->nrbufs. Since we don't * expect a lot of shrink+grow operations, just free and allocate * again like we would do for growing. If the pipe currently * contai...
1
[ "CWE-399" ]
linux
759c01142a5d0f364a462346168a56de28a80f52
230,367,434,695,169,570,000,000,000,000,000,000,000
44
pipe: limit the per-user amount of pages allocated in pipes On no-so-small systems, it is possible for a single process to cause an OOM condition by filling large pipes with data that are never read. A typical process filling 4000 pipes with 1 MB of data will use 4 GB of memory. On small systems it may be tricky to se...
SPL_METHOD(SplObjectStorage, getInfo) { spl_SplObjectStorageElement *element; spl_SplObjectStorage *intern = (spl_SplObjectStorage*)zend_object_store_get_object(getThis() TSRMLS_CC); if (zend_parse_parameters_none() == FAILURE) { return; } if (zend_hash_get_current_data_ex(&intern->storage, (void**)&element, &...
0
[ "CWE-416" ]
php-src
c2e197e4efc663ca55f393bf0e799848842286f3
108,483,085,111,394,110,000,000,000,000,000,000,000
14
Fix bug #70168 - Use After Free Vulnerability in unserialize() with SplObjectStorage
brcmf_cfg80211_del_pmksa(struct wiphy *wiphy, struct net_device *ndev, struct cfg80211_pmksa *pmksa) { struct brcmf_cfg80211_info *cfg = wiphy_to_cfg(wiphy); struct brcmf_if *ifp = netdev_priv(ndev); struct brcmf_pmksa *pmk = &cfg->pmk_list.pmk[0]; s32 err; u32 npmk, i; brcmf_dbg(TRACE, "Enter\n"); if (!che...
0
[ "CWE-119", "CWE-703" ]
linux
ded89912156b1a47d940a0c954c43afbabd0c42c
136,019,426,069,490,530,000,000,000,000,000,000,000
39
brcmfmac: avoid potential stack overflow in brcmf_cfg80211_start_ap() User-space can choose to omit NL80211_ATTR_SSID and only provide raw IE TLV data. When doing so it can provide SSID IE with length exceeding the allowed size. The driver further processes this IE copying it into a local variable without checking the...
pkinit_get_certs_fs(krb5_context context, pkinit_plg_crypto_context plg_cryptoctx, pkinit_req_crypto_context req_cryptoctx, pkinit_identity_opts *idopts, pkinit_identity_crypto_context id_cryptoctx, krb5_principal princ)...
0
[ "CWE-119", "CWE-787" ]
krb5
fbb687db1088ddd894d975996e5f6a4252b9a2b4
267,287,151,339,542,300,000,000,000,000,000,000,000
25
Fix PKINIT cert matching data construction Rewrite X509_NAME_oneline_ex() and its call sites to use dynamic allocation and to perform proper error checking. ticket: 8617 target_version: 1.16 target_version: 1.15-next target_version: 1.14-next tags: pullup
ZEND_API void ZEND_FASTCALL zend_hash_to_packed(HashTable *ht) { void *new_data, *old_data = HT_GET_DATA_ADDR(ht); Bucket *old_buckets = ht->arData; HT_ASSERT(GC_REFCOUNT(ht) == 1); HANDLE_BLOCK_INTERRUPTIONS(); new_data = pemalloc(HT_SIZE_EX(ht->nTableSize, HT_MIN_MASK), (ht)->u.flags & HASH_FLAG_PERSISTENT); h...
0
[ "CWE-190" ]
php-src
4cc0286f2f3780abc6084bcdae5dce595daa3c12
312,887,415,190,756,440,000,000,000,000,000,000,000
16
Fix #73832 - leave the table in a safe state if the size is too big.
int Scanner::scan() { const char *p, *x, *y; scan: tok = cur; location = cur_loc(); #line 1706 "src/parse/lex.cc" { unsigned char yych; unsigned int yyaccept = 0; static const unsigned char yybm[] = { 0, 128, 128, 128, 128, 128, 128, 128, 128, 144, 0, 128, 128, 128, 128, 128, 128, 128, 128, ...
1
[ "CWE-787" ]
re2c
039c18949190c5de5397eba504d2c75dad2ea9ca
328,892,015,086,397,840,000,000,000,000,000,000,000
951
Emit an error when repetition lower bound exceeds upper bound. Historically this was allowed and re2c swapped the bounds. However, it most likely indicates an error in user code and there is only a single occurrence in the tests (and the test in an artificial one), so although the change is backwards incompatible ther...
too_many_lines (char const *filename) { fatal ("File %s has too many lines", quotearg (filename)); }
0
[ "CWE-59" ]
patch
dce4683cbbe107a95f1f0d45fabc304acfb5d71a
204,432,215,035,673,550,000,000,000,000,000,000,000
4
Don't follow symlinks unless --follow-symlinks is given * src/inp.c (plan_a, plan_b), src/util.c (copy_to_fd, copy_file, append_to_file): Unless the --follow-symlinks option is given, open files with the O_NOFOLLOW flag to avoid following symlinks. So far, we were only doing that consistently for input files. * src/u...
void Item_func_random_bytes::fix_length_and_dec() { collation.set(&my_charset_bin); max_length= MAX_RANDOM_BYTES_BUFFER; }
0
[]
mysql-server
475dcde2c7856dd0050b967099a86c087d94f32f
92,229,670,593,748,300,000,000,000,000,000,000,000
5
Bug#27099029: UNLIMITED LENGTH OF THE PASSWORD Description: my_crypt_genhash depends on the length of plaintext password. Longer the password, more is the time required to produce the transformation. An unusually large password may consume considerable amount of time...
TPML_ECC_CURVE_Unmarshal(TPML_ECC_CURVE *target, BYTE **buffer, INT32 *size) { TPM_RC rc = TPM_RC_SUCCESS; UINT32 i; if (rc == TPM_RC_SUCCESS) { rc = UINT32_Unmarshal(&target->count, buffer, size); } if (rc == TPM_RC_SUCCESS) { if (target->count > MAX_ECC_CURVES) { rc = TPM_RC_SIZE; } }...
1
[ "CWE-787" ]
libtpms
f16250b35aff6995e540143a9858c9cf0d1f9573
98,019,668,433,135,660,000,000,000,000,000,000,000
18
tpm2: Reset TPM2B buffer sizes after test fails for valid buffer size Reset the buffer size indicator in a TPM2B type of buffer after it failed the test for the maximum buffer size it allows. This prevents having bad buffer sizes in memory that can come to haunt us when writing the volatile state for example. Signed-...
format_SET_IP_ECN(const struct ofpact_ecn *a, struct ds *s) { ds_put_format(s, "%smod_nw_ecn:%s%d", colors.param, colors.end, a->ecn); }
0
[ "CWE-125" ]
ovs
9237a63c47bd314b807cda0bd2216264e82edbe8
277,434,063,469,218,500,000,000,000,000,000,000,000
5
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 void io_req_map_rw(struct io_kiocb *req, const struct iovec *iovec, const struct iovec *fast_iov, struct iov_iter *iter) { struct io_async_rw *rw = req->async_data; memcpy(&rw->s.iter, iter, sizeof(*iter)); rw->free_iovec = iovec; rw->bytes_done = 0; /* can only be fixed buffers, no need to do anythin...
0
[ "CWE-416" ]
linux
e677edbcabee849bfdd43f1602bccbecf736a646
259,710,641,403,850,550,000,000,000,000,000,000,000
26
io_uring: fix race between timeout flush and removal io_flush_timeouts() assumes the timeout isn't in progress of triggering or being removed/canceled, so it unconditionally removes it from the timeout list and attempts to cancel it. Leave it on the list and let the normal timeout cancelation take care of it. Cc: st...
int ath6kl_wmi_set_keepalive_cmd(struct wmi *wmi, u8 if_idx, u8 keep_alive_intvl) { struct sk_buff *skb; struct wmi_set_keepalive_cmd *cmd; int ret; skb = ath6kl_wmi_get_new_buf(sizeof(*cmd)); if (!skb) return -ENOMEM; cmd = (struct wmi_set_keepalive_cmd *) skb->data; cmd->keep_alive_intvl = keep_alive_...
0
[ "CWE-125" ]
linux
5d6751eaff672ea77642e74e92e6c0ac7f9709ab
97,210,781,720,914,230,000,000,000,000,000,000,000
22
ath6kl: add some bounds checking The "ev->traffic_class" and "reply->ac" variables come from the network and they're used as an offset into the wmi->stream_exist_for_ac[] array. Those variables are u8 so they can be 0-255 but the stream_exist_for_ac[] array only has WMM_NUM_AC (4) elements. We need to add a couple bo...
PHP_METHOD(HttpParams, offsetGet) { char *name_str; int name_len; zval **zparam, *zparams; if (SUCCESS != zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &name_str, &name_len)) { return; } zparams = php_http_ztyp(IS_ARRAY, zend_read_property(php_http_params_class_entry, getThis(), ZEND_STRL("params"), 0...
0
[ "CWE-399", "CWE-704" ]
ext-http
17137d4ab1ce81a2cee0fae842340a344ef3da83
65,346,009,025,693,050,000,000,000,000,000,000,000
18
fix bug #73055
search_memslots(struct kvm_memslots *slots, gfn_t gfn) { int start = 0, end = slots->used_slots; int slot = atomic_read(&slots->lru_slot); struct kvm_memory_slot *memslots = slots->memslots; if (unlikely(!slots->used_slots)) return NULL; if (gfn >= memslots[slot].base_gfn && gfn < memslots[slot].base_gfn ...
0
[ "CWE-416" ]
linux
0774a964ef561b7170d8d1b1bfe6f88002b6d219
235,844,977,515,726,350,000,000,000,000,000,000,000
30
KVM: Fix out of range accesses to memslots Reset the LRU slot if it becomes invalid when deleting a memslot to fix an out-of-bounds/use-after-free access when searching through memslots. Explicitly check for there being no used slots in search_memslots(), and in the caller of s390's approximation variant. Fixes: 369...
bool ValidateHashDRBG() { std::cout << "\nTesting NIST Hash DRBGs...\n\n"; bool pass=true, fail; // # CAVS 14.3 // # DRBG800-90A information for "drbg_pr" // # Generated on Tue Apr 02 15:32:09 2013 { // [SHA-1], [PredictionResistance = False], [EntropyInputLen = 128], [NonceLen = 64] // [Personal...
0
[ "CWE-190", "CWE-125" ]
cryptopp
07dbcc3d9644b18e05c1776db2a57fe04d780965
319,149,289,221,633,000,000,000,000,000,000,000,000
367
Add Inflator::BadDistanceErr exception (Issue 414) The improved validation and excpetion clears the Address Sanitizer and Undefined Behavior Sanitizer findings