func
string
target
int64
cwe
list
project
string
commit_id
string
hash
float64
size
int64
message
string
oal_download_response_cb (SoupSession *soup_session, SoupMessage *soup_message, gpointer user_data) { GSimpleAsyncResult *simple; struct _oal_req_data *data; simple = G_SIMPLE_ASYNC_RESULT (user_data); data = g_simple_async_result_get_op_res_gpointer (simple); ...
0
[ "CWE-295" ]
evolution-ews
915226eca9454b8b3e5adb6f2fff9698451778de
252,336,493,868,541,350,000,000,000,000,000,000,000
34
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 up_free(struct Curl_easy *data) { struct urlpieces *up = &data->state.up; Curl_safefree(up->scheme); Curl_safefree(up->hostname); Curl_safefree(up->port); Curl_safefree(up->user); Curl_safefree(up->password); Curl_safefree(up->options); Curl_safefree(up->path); Curl_safefree(up->query); ...
0
[]
curl
852aa5ad351ea53e5f01d2f44b5b4370c2bf5425
167,058,804,281,632,850,000,000,000,000,000,000,000
14
url: check sasl additional parameters for connection reuse. Also move static function safecmp() as non-static Curl_safecmp() since its purpose is needed at several places. Bug: https://curl.se/docs/CVE-2022-22576.html CVE-2022-22576 Closes #8746
read_image_block(Gif_Reader *grr, uint8_t *buffer, int *bit_pos_store, int *bit_len_store, int bits_needed) { int bit_position = *bit_pos_store; int bit_length = *bit_len_store; uint8_t block_len; while (bit_position + bits_needed > bit_length) { /* Read in the next data block. */ if (bit_position >...
0
[ "CWE-416" ]
gifsicle
81fd7823f6d9c85ab598bc850e40382068361185
287,476,599,555,823,400,000,000,000,000,000,000,000
28
Fix use-after-free problems reported in #114.
int mutt_b64_decode(char *out, const char *in) { int len = 0; unsigned char digit4; do { const unsigned char digit1 = in[0]; if ((digit1 > 127) || (base64val(digit1) == BAD)) return -1; const unsigned char digit2 = in[1]; if ((digit2 > 127) || (base64val(digit2) == BAD)) return -1; ...
1
[ "CWE-120", "CWE-119", "CWE-787" ]
neomutt
6f163e07ae68654d7ac5268cbb7565f6df79ad85
219,496,782,028,034,100,000,000,000,000,000,000,000
38
Check outbuf length in mutt_to_base64() The obuf can be overflowed in auth_cram.c, and possibly auth_gss.c. Thanks to Jeriko One for the bug report.
static int fsck_tag_buffer(struct tag *tag, const char *data, unsigned long size, struct fsck_options *options) { unsigned char sha1[20]; int ret = 0; const char *buffer; char *to_free = NULL, *eol; struct strbuf sb = STRBUF_INIT; if (data) buffer = data; else { enum object_type type; buffer = to_free =...
0
[ "CWE-20", "CWE-88", "CWE-522" ]
git
a124133e1e6ab5c7a9fef6d0e6bcb084e3455b46
286,968,616,891,165,100,000,000,000,000,000,000,000
93
fsck: detect submodule urls starting with dash Urls with leading dashes can cause mischief on older versions of Git. We should detect them so that they can be rejected by receive.fsckObjects, preventing modern versions of git from being a vector by which attacks can spread. Signed-off-by: Jeff King <peff@peff.net> Si...
void setInline(Handle handle, absl::string_view value) override { header_map_->setInline(handle, value); header_map_->verifyByteSizeInternalForTest(); }
0
[]
envoy
2c60632d41555ec8b3d9ef5246242be637a2db0f
58,085,301,165,994,830,000,000,000,000,000,000,000
4
http: header map security fixes for duplicate headers (#197) Previously header matching did not match on all headers for non-inline headers. This patch changes the default behavior to always logically match on all headers. Multiple individual headers will be logically concatenated with ',' similar to what is done with...
static void set_effective_user(struct passwd *user_info_arg) { #if !defined(__WIN__) DBUG_ASSERT(user_info_arg != 0); if (setregid((gid_t)-1, user_info_arg->pw_gid) == -1) { sql_perror("setregid"); unireg_abort(1); } if (setreuid((uid_t)-1, user_info_arg->pw_uid) == -1) { sql_perror("setreuid");...
0
[ "CWE-362" ]
server
347eeefbfc658c8531878218487d729f4e020805
6,521,762,894,007,323,000,000,000,000,000,000,000
17
don't use my_copystat in the server it was supposed to be used in command-line tools only. Different fix for 4e5473862e: Bug#24388746: PRIVILEGE ESCALATION AND RACE CONDITION USING CREATE TABLE
int sqlite3Fts3GetVarintBounded( const char *pBuf, const char *pEnd, sqlite_int64 *v ){ const unsigned char *p = (const unsigned char*)pBuf; const unsigned char *pStart = p; const unsigned char *pX = (const unsigned char*)pEnd; u64 b = 0; int shift; for(shift=0; shift<=63; shift+=7){ u64 c = p<pX ...
0
[ "CWE-908" ]
sqlite
70d1a1a3ed64d7bd82fd90268e4c9cf208ca1be0
234,581,181,774,034,020,000,000,000,000,000,000,000
19
Further improve detection of corrupt records in fts3. FossilOrigin-Name: a0f6d526baecd061a5e2bec5eb698fb5dfb10122ac79c853d7b3f4a48bc9f49b
static ParameterError add2list(struct curl_slist **list, char *ptr) { struct curl_slist *newlist = curl_slist_append(*list, ptr); if(newlist) *list = newlist; else return PARAM_NO_MEM; return PARAM_OK; }
0
[ "CWE-125" ]
curl
70b1900dd13d16f2e83f571407a614541d5ac9ba
305,591,316,760,454,230,000,000,000,000,000,000,000
11
'mytx' in bug report #1723194 (http://curl.haxx.se/bug/view.cgi?id=1723194) pointed out that the warnf() function in the curl tool didn't properly deal with the cases when excessively long words were used in the string to chop up.
void EC_GROUP_set_asn1_flag(EC_GROUP *group, int flag) { group->asn1_flag &= ~EC_GROUP_ASN1_FLAG_MASK; group->asn1_flag |= flag & EC_GROUP_ASN1_FLAG_MASK; }
0
[]
openssl
21c856b75d81eff61aa63b4f036bb64a85bf6d46
288,292,971,350,444,070,000,000,000,000,000,000,000
5
[crypto/ec] for ECC parameters with NULL or zero cofactor, compute it The cofactor argument to EC_GROUP_set_generator is optional, and SCA mitigations for ECC currently use it. So the library currently falls back to very old SCA-vulnerable code if the cofactor is not present. This PR allows EC_GROUP_set_generator to ...
handle_env (pam_handle_t *pamh, int argc, const char **argv) { int retval, ctrl, readenv=DEFAULT_READ_ENVFILE; int user_readenv = DEFAULT_USER_READ_ENVFILE; const char *conf_file = NULL, *env_file = NULL, *user_env_file = NULL; /* * this module sets environment variables read in from a file */ D(("Cal...
0
[ "CWE-119" ]
linux-pam
caf5e7f61c8d9288daa49b4f61962e6b1239121d
313,887,073,633,916,900,000,000,000,000,000,000,000
62
pam_env: correctly count leading whitespace when parsing environment file * modules/pam_env/pam_env.c (_assemble_line): Correctly count leading whitespace. Fixes CVE-2011-3148. Bug-Ubuntu: https://bugs.launchpad.net/ubuntu/+source/pam/+bug/874469
ProcedureCreate(const char *procedureName, Oid procNamespace, bool replace, bool returnsSet, Oid returnType, Oid proowner, Oid languageObjectId, Oid languageValidator, const char *prosrc, const char *probin, bool isAgg, bool isWindowFunc, bool security_definer, bool i...
0
[ "CWE-264" ]
postgres
537cbd35c893e67a63c59bc636c3e888bd228bc7
19,494,381,503,567,526,000,000,000,000,000,000,000
640
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 ...
SPL_METHOD(Array, seek) { long opos, position; zval *object = getThis(); spl_array_object *intern = (spl_array_object*)zend_object_store_get_object(object TSRMLS_CC); HashTable *aht = spl_array_get_hash_table(intern, 0 TSRMLS_CC); int result; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "l", &position) =...
0
[]
php-src
a374dfab567ff7f0ab0dc150f14cc891b0340b47
309,703,729,199,568,520,000,000,000,000,000,000,000
31
Fix bug #67492: unserialize() SPL ArrayObject / SPLObjectStorage Type Confusion
amgtar_discover( application_argument_t *argument ) { DIR *dir; struct dirent *dp; char *full_path; size_t path_len; size_t path_alloc; struct stat stat_buf; char *file_type; gboolean reported_entries = FALSE; if (argument->dle.disk) { if ((dir = opendir(argument->dle.disk)) ==...
0
[ "CWE-77" ]
amanda
29bae2e271093cd8d06ea98f73a474c685c5a314
200,804,741,376,444,400,000,000,000,000,000,000,000
81
* application-src/ambsdtar.c, application-src/amgtar.c, application-src/amstar.c: Filter option from COMMAND-OPTIONS * common-src/ammessage.c: Add message. git-svn-id: https://svn.code.sf.net/p/amanda/code/amanda/trunk@6483 a8d146d6-cc15-0410-8900-af154a0219e0
Status AuthorizationManager::getBSONForPrivileges(const PrivilegeVector& privileges, mutablebson::Element resultArray) { for (PrivilegeVector::const_iterator it = privileges.begin(); it != privileges.end(); ++it) { std::string errmsg; ParsedPrivilege...
0
[ "CWE-613" ]
mongo
64d8e9e1b12d16b54d6a592bae8110226c491b4e
279,867,287,731,075,640,000,000,000,000,000,000,000
12
SERVER-38984 Validate unique User ID on UserCache hit (cherry picked from commit e55d6e2292e5dbe2f97153251d8193d1cc89f5d7)
static struct regulator_supply_alias *regulator_find_supply_alias( struct device *dev, const char *supply) { struct regulator_supply_alias *map; list_for_each_entry(map, &regulator_supply_alias_list, list) if (map->src_dev == dev && strcmp(map->src_supply, supply) == 0) return map; return NULL; }
0
[ "CWE-416" ]
linux
60a2362f769cf549dc466134efe71c8bf9fbaaba
204,632,252,681,733,870,000,000,000,000,000,000,000
11
regulator: core: Fix regualtor_ena_gpio_free not to access pin after freeing After freeing pin from regulator_ena_gpio_free, loop can access the pin. So this patch fixes not to access pin after freeing. Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com> Signed-off-by: Mark Brown <broonie@kernel.org>
router_get_routerlist(void) { if (PREDICT_UNLIKELY(!routerlist)) { routerlist = tor_malloc_zero(sizeof(routerlist_t)); routerlist->routers = smartlist_create(); routerlist->old_routers = smartlist_create(); routerlist->identity_map = rimap_new(); routerlist->desc_digest_map = sdmap_new(); rout...
0
[ "CWE-399" ]
tor
308f6dad20675c42b29862f4269ad1fbfb00dc9a
157,063,805,240,936,960,000,000,000,000,000,000,000
23
Mitigate a side-channel leak of which relays Tor chooses for a circuit Tor's and OpenSSL's current design guarantee that there are other leaks, but this one is likely to be more easily exploitable, and is easy to fix.
int ipc_rcu_getref(void *ptr) { struct ipc_rcu *p = ((struct ipc_rcu *)ptr) - 1; return atomic_inc_not_zero(&p->refcount); }
0
[ "CWE-362", "CWE-401" ]
linux
b9a532277938798b53178d5a66af6e2915cb27cf
278,263,332,545,847,260,000,000,000,000,000,000,000
6
Initialize msg/shm IPC objects before doing ipc_addid() As reported by Dmitry Vyukov, we really shouldn't do ipc_addid() before having initialized the IPC object state. Yes, we initialize the IPC object in a locked state, but with all the lockless RCU lookup work, that IPC object lock no longer means that the state c...
static int binder_translate_fd_array(struct binder_fd_array_object *fda, struct binder_buffer_object *parent, struct binder_transaction *t, struct binder_thread *thread, struct binder_transaction *in_reply_to) { binder_size_t fdi, fd_buf_size; uintptr_t parent_buffer; u32 *fd_arra...
0
[ "CWE-416" ]
linux
7bada55ab50697861eee6bb7d60b41e68a961a9c
335,938,337,398,318,120,000,000,000,000,000,000,000
45
binder: fix race that allows malicious free of live buffer Malicious code can attempt to free buffers using the BC_FREE_BUFFER ioctl to binder. There are protections against a user freeing a buffer while in use by the kernel, however there was a window where BC_FREE_BUFFER could be used to free a recently allocated bu...
static int parse_filter(const char *spec, struct USBAutoFilter *f) { enum { BUS, DEV, VID, PID, DONE }; const char *p = spec; int i; f->bus_num = -1; f->addr = -1; f->vendor_id = -1; f->product_id = -1; for (i = BUS; i < DONE; i++) { p = strpbrk(p, ":."); if (!p) br...
0
[ "CWE-119" ]
qemu
babd03fde68093482528010a5435c14ce9128e3f
193,266,224,385,206,340,000,000,000,000,000,000,000
34
usb-linux.c: fix buffer overflow In usb-linux.c:usb_host_handle_control, we pass a 1024-byte buffer and length to the kernel. However, the length was provided by the caller of dev->handle_packet, and is not checked, so the kernel might provide too much data and overflow our buffer. For example, hw/usb-uhci.c could s...
int MonClient::get_monmap() { ldout(cct, 10) << __func__ << dendl; std::lock_guard l(monc_lock); sub.want("monmap", 0, 0); if (!_opened()) _reopen_session(); while (want_monmap) map_cond.Wait(monc_lock); ldout(cct, 10) << __func__ << " done" << dendl; return 0; }
0
[ "CWE-294" ]
ceph
2927fd91d41e505237cc73f9700e5c6a63e5cb4f
276,679,592,787,326,000,000,000,000,000,000,000,000
15
mon/MonClient: bring back CEPHX_V2 authorizer challenges Commit c58c5754dfd2 ("msg/async/ProtocolV1: use AuthServer and AuthClient") introduced a backwards compatibility issue into msgr1. To fix it, commit 321548010578 ("mon/MonClient: skip CEPHX_V2 challenge if client doesn't support it") set out to skip authorizer c...
static apr_array_header_t *parse_errorlog_string(apr_pool_t *p, const char *s, const char **err, int is_main_fmt) { apr_array_header_t *a = apr_array_make(p, 30, ...
0
[ "CWE-416", "CWE-284" ]
httpd
4cc27823899e070268b906ca677ee838d07cf67a
298,543,093,102,370,660,000,000,000,000,000,000,000
49
core: Disallow Methods' registration at run time (.htaccess), they may be used only if registered at init time (httpd.conf). Calling ap_method_register() in children processes is not the right scope since it won't be shared for all requests. git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1807655 13f7...
map_over_funcs (function) sh_var_map_func_t *function; { VARLIST *vlist; SHELL_VAR **ret; if (shell_functions == 0 || HASH_ENTRIES (shell_functions) == 0) return ((SHELL_VAR **)NULL); vlist = vlist_alloc (HASH_ENTRIES (shell_functions)); flatten (shell_functions, function, vlist, 0); ret = vlis...
0
[]
bash
863d31ae775d56b785dc5b0105b6d251515d81d5
251,789,926,260,034,640,000,000,000,000,000,000,000
17
commit bash-20120224 snapshot
dealloc(GraphicsManager* self) { size_t i; if (self->images) { for (i = 0; i < self->image_count; i++) free_image(self, self->images + i); free(self->images); } free(self->render_data); Py_TYPE(self)->tp_free((PyObject*)self); }
0
[ "CWE-787" ]
kitty
82c137878c2b99100a3cdc1c0f0efea069313901
775,835,602,908,198,300,000,000,000,000,000,000
9
Graphics protocol: Dont return filename in the error message when opening file fails, since filenames can contain control characters Fixes #3128
int btd_adapter_add_remote_oob_data(struct btd_adapter *adapter, const bdaddr_t *bdaddr, uint8_t *hash, uint8_t *randomizer) { struct mgmt_cp_add_remote_oob_data cp; char addr[18]; ba2str(bdaddr, addr); DBG("hci%d bdaddr %s", adapter->dev_id, addr); memset(&cp, 0, sizeof(cp)); bacpy(&cp.addr.bdaddr, b...
0
[ "CWE-862", "CWE-863" ]
bluez
b497b5942a8beb8f89ca1c359c54ad67ec843055
288,570,152,119,398,250,000,000,000,000,000,000,000
24
adapter: Fix storing discoverable setting discoverable setting shall only be store when changed via Discoverable property and not when discovery client set it as that be considered temporary just for the lifetime of the discovery.
lips_media_selection(int width, int height) { int landscape = 0; int tmp; paper_table *pt; if (width > height) { landscape = 1; tmp = width; width = height; height = tmp; } for (pt = lips_paper_table; pt->num_unit < 80; pt++) if (pt->width == width && pt-...
0
[ "CWE-787" ]
ghostpdl
9f39ed4a92578a020ae10459643e1fe72573d134
265,139,358,436,215,500,000,000,000,000,000,000,000
18
Bug 701792: Avoid going beyond buffer in GetNumSameData() and GetNumWrongData(). GetNumSameData() compared buffer contents before checking that we are still within bounds of buffer, which caused the bug. Have made similar fix to GetNumWrongData() because it has similar error. Fixes address sanitizer error in: ./...
static MagickBooleanType CLISimpleOperatorImage(MagickCLI *cli_wand, const char *option, const char *arg1n, const char *arg2n, ExceptionInfo *exception) { Image * new_image; GeometryInfo geometry_info; RectangleInfo geometry; MagickStatusType flags; ssize_t parse; const char ...
0
[ "CWE-617" ]
ImageMagick
716496e6df0add89e9679d6da9c0afca814cfe49
141,814,982,792,844,250,000,000,000,000,000,000,000
2,070
do not attempt to write a null image list (thanks to Vinay Rohila)
xmlBufSetInputBaseCur(xmlBufPtr buf, xmlParserInputPtr input, size_t base, size_t cur) { if (input == NULL) return(-1); if ((buf == NULL) || (buf->error)) { input->base = input->cur = input->end = BAD_CAST ""; return(-1); } CHECK_COMPAT(buf) input->base ...
0
[ "CWE-190" ]
libxml2
6c283d83eccd940bcde15634ac8c7f100e3caefd
155,520,646,735,803,430,000,000,000,000,000,000,000
14
[CVE-2022-29824] Fix integer overflows in xmlBuf and xmlBuffer In several places, the code handling string buffers didn't check for integer overflow or used wrong types for buffer sizes. This could result in out-of-bounds writes or other memory errors when working on large, multi-gigabyte buffers. Thanks to Felix Wil...
static void rawsock_destruct(struct sock *sk) { pr_debug("sk=%p\n", sk); if (sk->sk_state == TCP_ESTABLISHED) { nfc_deactivate_target(nfc_rawsock(sk)->dev, nfc_rawsock(sk)->target_idx); nfc_put_device(nfc_rawsock(sk)->dev); } skb_queue_purge(&sk->sk_receive_queue); if (!sock_flag(sk, SOCK_DEAD)) {...
0
[ "CWE-20", "CWE-269" ]
linux
f3d3342602f8bcbf37d7c46641cb9bca7618eb1c
210,649,271,636,909,820,000,000,000,000,000,000,000
17
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...
writeRandomBytes_getrandom_nonblock(void *target, size_t count) { int success = 0; /* full count bytes written? */ size_t bytesWrittenTotal = 0; const unsigned int getrandomFlags = GRND_NONBLOCK; do { void *const currentTarget = (void *)((char *)target + bytesWrittenTotal); const size_t bytesToWrite = ...
0
[ "CWE-611", "CWE-776", "CWE-415", "CWE-125" ]
libexpat
c20b758c332d9a13afbbb276d30db1d183a85d43
91,076,921,172,649,330,000,000,000,000,000,000,000
25
xmlparse.c: Deny internal entities closing the doctype
check_map_keycodes(void) { mapblock_T *mp; char_u *p; int i; char_u buf[3]; char_u *save_name; int abbr; int hash; #ifdef FEAT_LOCALMAP buf_T *bp; #endif validate_maphash(); save_name = sourcing_name; sourcing_name = (char_u *)"mappings"; /* avoids giving error messages *...
0
[ "CWE-78" ]
vim
53575521406739cf20bbe4e384d88e7dca11f040
104,956,752,805,658,810,000,000,000,000,000,000,000
84
patch 8.1.1365: source command doesn't check for the sandbox Problem: Source command doesn't check for the sandbox. (Armin Razmjou) Solution: Check for the sandbox when sourcing a file.
is_step_limit_reached(double offset, double offset_correction) { if (make_step_limit == 0) { return 0; } else if (make_step_limit > 0) { make_step_limit--; } return fabs(offset - offset_correction) > make_step_threshold; }
0
[ "CWE-59" ]
chrony
e18903a6b56341481a2e08469c0602010bf7bfe3
320,351,479,556,242,550,000,000,000,000,000,000,000
9
switch to new util file functions Replace all fopen(), rename(), and unlink() calls with the new util functions.
void kvm_get_segment(struct kvm_vcpu *vcpu, struct kvm_segment *var, int seg) { static_call(kvm_x86_get_segment)(vcpu, var, seg); }
0
[ "CWE-476" ]
linux
55749769fe608fa3f4a075e42e89d237c8e37637
259,847,063,483,451,950,000,000,000,000,000,000,000
5
KVM: x86: Fix wall clock writes in Xen shared_info not to mark page dirty When dirty ring logging is enabled, any dirty logging without an active vCPU context will cause a kernel oops. But we've already declared that the shared_info page doesn't get dirty tracking anyway, since it would be kind of insane to mark it di...
int sas_smp_phy_control(struct domain_device *dev, int phy_id, enum phy_func phy_func, struct sas_phy_linkrates *rates) { u8 *pc_req; u8 *pc_resp; int res; pc_req = alloc_smp_req(PC_REQ_SIZE); if (!pc_req) return -ENOMEM; pc_resp = alloc_smp_resp(PC_RESP_SIZE); if (!pc_resp) { kfree(pc_req); return...
0
[ "CWE-399", "CWE-772" ]
linux
4a491b1ab11ca0556d2fda1ff1301e862a2d44c4
237,852,370,518,649,570,000,000,000,000,000,000,000
32
scsi: libsas: fix memory leak in sas_smp_get_phy_events() We've got a memory leak with the following producer: while true; do cat /sys/class/sas_phy/phy-1:0:12/invalid_dword_count >/dev/null; done The buffer req is allocated and not freed after we return. Fix it. Fixes: 2908d778ab3e ("[SCSI] aic94xx: new driver") S...
void __init tcp_init(void) { struct sk_buff *skb = NULL; unsigned long limit; int max_rshare, max_wshare, cnt; unsigned int i; BUILD_BUG_ON(sizeof(struct tcp_skb_cb) > sizeof(skb->cb)); percpu_counter_init(&tcp_sockets_allocated, 0); percpu_counter_init(&tcp_orphan_count, 0); tcp_hashinfo.bind_bucket_cachep =...
0
[]
linux
7bced397510ab569d31de4c70b39e13355046387
38,115,535,206,707,564,000,000,000,000,000,000,000
82
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...
init_om( XOM om) { XLCd lcd = om->core.lcd; XOMGenericPart *gen = XOM_GENERIC(om); OMData data; XlcCharSet *charset_list; FontData font_data; char **required_list; XOrientation *orientation; char **value, buf[BUFSIZ], *bufptr; int count = 0, num = 0, length = 0; _XlcGetResou...
1
[ "CWE-190" ]
libx11
acdaaadcb3d85c61fd43669fc5dddf0f8c3f911d
178,831,148,815,629,430,000,000,000,000,000,000,000
159
Fix an integer overflow in init_om() CVE-2020-14363 This can lead to a double free later, as reported by Jayden Rivers. Signed-off-by: Matthieu Herrb <matthieu@herrb.eu>
void FilterManager::decodeTrailers(ActiveStreamDecoderFilter* filter, RequestTrailerMap& trailers) { // See decodeData() above for why we check local_complete_ here. if (state_.local_complete_) { return; } // Filter iteration may start at the current filter. std::list<ActiveStreamDecoderFilterPtr>::itera...
0
[ "CWE-416" ]
envoy
148de954ed3585d8b4298b424aa24916d0de6136
279,084,158,930,578,700,000,000,000,000,000,000,000
45
CVE-2021-43825 Response filter manager crash Signed-off-by: Yan Avlasov <yavlasov@google.com>
static unsigned long huge_tte_to_size(pte_t pte) { unsigned long size = 1UL << huge_tte_to_shift(pte); if (size == REAL_HPAGE_SIZE) size = HPAGE_SIZE; return size; }
0
[ "CWE-119" ]
linux
1be7107fbe18eed3e319a6c3e83c78254b693acb
186,921,553,360,341,600,000,000,000,000,000,000,000
8
mm: larger stack guard gap, between vmas Stack guard page is a useful feature to reduce a risk of stack smashing into a different mapping. We have been using a single page gap which is sufficient to prevent having stack adjacent to a different mapping. But this seems to be insufficient in the light of the stack usage ...
static void pxa2xx_fir_reset(PXA2xxFIrState *s) { s->control[0] = 0x00; s->control[1] = 0x00; s->control[2] = 0x00; s->status[0] = 0x00; s->status[1] = 0x00; s->enable = 0; }
0
[ "CWE-119" ]
qemu
caa881abe0e01f9931125a0977ec33c5343e4aa7
124,939,820,972,857,470,000,000,000,000,000,000,000
9
pxa2xx: avoid buffer overrun on incoming migration CVE-2013-4533 s->rx_level is read from the wire and used to determine how many bytes to subsequently read into s->rx_fifo[]. If s->rx_level exceeds the length of s->rx_fifo[] the buffer can be overrun with arbitrary data from the wire. Fix this by validating rx_leve...
void remove(Connection& c) { std::lock_guard lock{mutex}; if (c.is_linked()) { connections.erase(List::s_iterator_to(c)); } }
0
[ "CWE-400" ]
ceph
ff72c50a2c43c57aead933eb4903ad1ca6d1748a
252,367,912,944,113,430,000,000,000,000,000,000,000
6
rgw: improve beast Avoid leaking connections that had partially-consumed client data on unexpected disconnect. Resolves CVE-2020-1700 (moderate impact flaw). Fixes: https://tracker.ceph.com/issues/42531 Signed-off-by: Or Friedmann <ofriedma@redhat.com> Signed-off-by: Matt Benjamin <mbenjamin@redhat.com>
void NumberFormatTest::TestFormattableSize(void) { if(sizeof(Formattable) > 112) { errln("Error: sizeof(Formattable)=%d, 112=%d\n", sizeof(Formattable), 112); } else if(sizeof(Formattable) < 112) { logln("Warning: sizeof(Formattable)=%d, 112=%d\n", sizeof(Formattable), 112); } else { ...
0
[ "CWE-190" ]
icu
53d8c8f3d181d87a6aa925b449b51c4a2c922a51
311,742,959,065,006,340,000,000,000,000,000,000,000
12
ICU-20246 Fixing another integer overflow in number parsing.
bool Scanner::read(size_t want) { DASSERT(!files.empty()); for (size_t i = files.size(); i --> 0; ) { Input *in = files[i]; const size_t have = fread(lim, 1, want, in->file); in->so = lim; lim += have; in->eo = lim; want -= have; // buffer filled ...
0
[ "CWE-787" ]
re2c
c4603ba5ce229db83a2a4fb93e6d4b4e3ec3776a
34,098,604,169,556,887,000,000,000,000,000,000,000
16
Fix crash in lexer refill (reported by Agostino Sarubbo). The crash happened in a rare case of a very long lexeme that doen't fit into the buffer, forcing buffer reallocation. The crash was caused by an incorrect calculation of the shift offset (it was smaller than necessary). As a consequence, the data from buffer s...
lua_datum::lua_datum(CLua &_lua, int stackpos, bool pop) : lua(_lua), need_cleanup(true) { // Store the datum in the registry indexed by "this". lua_pushvalue(lua, stackpos); lua_pushlightuserdata(lua, this); // Move the key (this) before the value. lua_insert(lua, -2); lua_settable(lua, LUA...
0
[ "CWE-434" ]
crawl
fc522ff6eb1bbb85e3de60c60a45762571e48c28
184,681,427,535,715,500,000,000,000,000,000,000,000
15
Disable lua load(), loadstring() bytcode loading
static int notifier_add_vio(struct hvc_struct *hp, int data) { struct port *port; port = find_port_by_vtermno(hp->vtermno); if (!port) return -EINVAL; hp->irq_requested = 1; resize_console(port); return 0; }
0
[ "CWE-119", "CWE-787" ]
linux
c4baad50297d84bde1a7ad45e50c73adae4a2192
149,431,732,979,504,100,000,000,000,000,000,000,000
13
virtio-console: avoid DMA from stack put_chars() stuffs the buffer it gets into an sg, but that buffer may be on the stack. This breaks with CONFIG_VMAP_STACK=y (for me, it manifested as printks getting turned into NUL bytes). Signed-off-by: Omar Sandoval <osandov@fb.com> Signed-off-by: Michael S. Tsirkin <mst@redhat...
thumbnail_state_free (ThumbnailState *state) { g_object_unref (state->cancellable); g_free (state); }
0
[]
nautilus
7632a3e13874a2c5e8988428ca913620a25df983
205,742,005,464,290,280,000,000,000,000,000,000,000
5
Check for trusted desktop file launchers. 2009-02-24 Alexander Larsson <alexl@redhat.com> * libnautilus-private/nautilus-directory-async.c: Check for trusted desktop file launchers. * libnautilus-private/nautilus-file-private.h: * libnautilus-private/nautilus-file.c: * libnautilus-...
getfs_by_dir (const char *dir) { struct mntentchn *mc, *mc0; char *cdir; mc0 = fstab_head(); for (mc = mc0->nxt; mc && mc != mc0; mc = mc->nxt) if (streq(mc->m.mnt_dir, dir)) return mc; cdir = canonicalize(dir); for (mc = mc0->nxt; mc && mc != mc0; mc = mc->nxt) { if (streq(mc->m.mnt_dir, cdir)) { fre...
0
[ "CWE-399" ]
util-linux
4b39b6aefd5dd8ac68a92adc650dc13d5d54d704
337,257,781,401,238,900,000,000,000,000,000,000,000
19
mount: use fflush() and temporary file for mtab updates (CVE-2011-1089) http://thread.gmane.org/gmane.comp.security.oss.general/4374 Changes: - force mount(8) to use /etc/mtab.tmp file every time. The original code used the tmp file for remount/move operations only. - call and check fflush() return code for...
static void em28xx_pre_card_setup(struct em28xx *dev) { /* * Set the initial XCLK and I2C clock values based on the board * definition */ em28xx_set_xclk_i2c_speed(dev); /* request some modules */ switch (dev->model) { case EM2861_BOARD_PLEXTOR_PX_TV100U: /* Sets the msp34xx I2S speed */ dev->i2s_speed ...
0
[ "CWE-416" ]
linux
c08eadca1bdfa099e20a32f8fa4b52b2f672236d
80,836,242,544,221,290,000,000,000,000,000,000,000
123
media: em28xx: initialize refcount before kref_get The commit 47677e51e2a4("[media] em28xx: Only deallocate struct em28xx after finishing all extensions") adds kref_get to many init functions (e.g., em28xx_audio_init). However, kref_init is called too late in em28xx_usb_probe, since em28xx_init_dev before will invoke ...
DECLAREContigPutFunc(put1bitcmaptile) { uint32** PALmap = img->PALmap; (void) x; (void) y; fromskew /= 8; while (h-- > 0) { uint32* bw; UNROLL8(w, bw = PALmap[*pp++], *cp++ = *bw++); cp += toskew; pp += fromskew; } }
0
[ "CWE-119" ]
libtiff
40a5955cbf0df62b1f9e9bd7d9657b0070725d19
17,254,021,800,831,200,000,000,000,000,000,000,000
13
* libtiff/tif_next.c: add new tests to check that we don't read outside of the compressed input stream buffer. * libtiff/tif_getimage.c: in OJPEG case, fix checks on strile width/height
static struct nft_expr *nft_expr_init(const struct nft_ctx *ctx, const struct nlattr *nla) { struct nft_expr_info expr_info; struct nft_expr *expr; struct module *owner; int err; err = nf_tables_expr_parse(ctx, nla, &expr_info); if (err < 0) goto err1; err = -ENOMEM; expr = kzalloc(expr_info.ops->...
0
[ "CWE-665" ]
linux
ad9f151e560b016b6ad3280b48e42fa11e1a5440
133,215,653,385,367,960,000,000,000,000,000,000,000
33
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: ...
void setChroot(const SpawnPreparationInfo &info) { if (info.chrootDir != "/") { int ret = chroot(info.chrootDir.c_str()); if (ret == -1) { int e = errno; fprintf(stderr, "Cannot chroot() to '%s': %s (errno=%d)\n", info.chrootDir.c_str(), strerror(e), e); fflush(stderr); _exit(1);...
0
[]
passenger
8c6693e0818772c345c979840d28312c2edd4ba4
277,766,332,732,661,220,000,000,000,000,000,000,000
14
Security check socket filenames reported by spawned application processes.
onig_number_of_capture_histories(regex_t* reg) { #ifdef USE_CAPTURE_HISTORY int i, n; n = 0; for (i = 0; i <= ONIG_MAX_CAPTURE_HISTORY_GROUP; i++) { if (MEM_STATUS_AT(reg->capture_history, i) != 0) n++; } return n; #else return 0; #endif }
0
[ "CWE-125" ]
oniguruma
d3e402928b6eb3327f8f7d59a9edfa622fec557b
90,275,851,091,409,040,000,000,000,000,000,000,000
15
fix heap-buffer-overflow
xmlRelaxNGTryCompile(xmlRelaxNGParserCtxtPtr ctxt, xmlRelaxNGDefinePtr def) { int ret = 0; xmlRelaxNGDefinePtr list; if ((ctxt == NULL) || (def == NULL)) return (-1); if ((def->type == XML_RELAXNG_START) || (def->type == XML_RELAXNG_ELEMENT)) { ret = xmlRelaxNGIsCompileable(def...
0
[ "CWE-134" ]
libxml2
502f6a6d08b08c04b3ddfb1cd21b2f699c1b7f5b
12,623,213,985,447,532,000,000,000,000,000,000,000
75
More format string warnings with possible format string vulnerability For https://bugzilla.gnome.org/show_bug.cgi?id=761029 adds a new xmlEscapeFormatString() function to escape composed format strings
static void Ins_CLEAR( INS_ARG ) { (void)args; CUR.new_top = 0; }
0
[ "CWE-125" ]
ghostpdl
c7c55972758a93350882c32147801a3485b010fe
158,143,572,539,603,310,000,000,000,000,000,000,000
4
Bug 698024: bounds check zone pointer in Ins_MIRP()
ebt_check_entry(struct ebt_entry *e, struct net *net, const struct ebt_table_info *newinfo, const char *name, unsigned int *cnt, struct ebt_cl_stack *cl_s, unsigned int udc_cnt) { struct ebt_entry_target *t; struct xt_target *target; unsigned int i, j, hook = 0, hookmask = 0; size_t gap; int ret; struct xt_...
0
[ "CWE-787" ]
linux
b71812168571fa55e44cdd0254471331b9c4c4c6
17,760,272,458,515,962,000,000,000,000,000,000,000
110
netfilter: ebtables: CONFIG_COMPAT: don't trust userland offsets We need to make sure the offsets are not out of range of the total size. Also check that they are in ascending order. The WARN_ON triggered by syzkaller (it sets panic_on_warn) is changed to also bail out, no point in continuing parsing. Briefly tested...
static unsigned char* ensure(printbuffer * const p, size_t needed) { unsigned char *newbuffer = NULL; size_t newsize = 0; if ((p == NULL) || (p->buffer == NULL)) { return NULL; } if ((p->length > 0) && (p->offset >= p->length)) { /* make sure that offset is valid */ ...
0
[ "CWE-754", "CWE-787" ]
cJSON
be749d7efa7c9021da746e685bd6dec79f9dd99b
314,640,790,943,105,040,000,000,000,000,000,000,000
86
Fix crash of cJSON_GetObjectItemCaseSensitive when calling it on arrays
void MYSQL_BIN_LOG::signal_update() { DBUG_ENTER("MYSQL_BIN_LOG::signal_update"); signal_cnt++; mysql_cond_broadcast(&update_cond); DBUG_VOID_RETURN; }
0
[ "CWE-264" ]
mysql-server
48bd8b16fe382be302c6f0b45931be5aa6f29a0e
163,218,124,222,984,400,000,000,000,000,000,000,000
7
Bug#24388753: PRIVILEGE ESCALATION USING MYSQLD_SAFE [This is the 5.5/5.6 version of the bugfix]. The problem was that it was possible to write log files ending in .ini/.cnf that later could be parsed as an options file. This made it possible for users to specify startup options without the permissions to do so. Thi...
ex_exit(exarg_T *eap) { #ifdef FEAT_CMDWIN if (cmdwin_type != 0) { cmdwin_result = Ctrl_C; return; } #endif /* Don't quit while editing the command line. */ if (text_locked()) { text_locked_msg(); return; } if (before_quit_autocmds(curwin, FALSE, eap->forceit)) return; /* ...
0
[ "CWE-78" ]
vim
8c62a08faf89663e5633dc5036cd8695c80f1075
241,713,472,285,311,300,000,000,000,000,000,000,000
44
patch 8.1.0881: can execute shell commands in rvim through interfaces Problem: Can execute shell commands in rvim through interfaces. Solution: Disable using interfaces in restricted mode. Allow for writing file with writefile(), histadd() and a few others.
static int __btrfs_map_block_for_discard(struct btrfs_fs_info *fs_info, u64 logical, u64 length, struct btrfs_bio **bbio_ret) { struct extent_map *em; struct map_lookup *map; struct btrfs_bio *bbio; u64 offset; u64 stripe_nr; u64 stripe_nr_end; u64 stripe_end_offset; u64 stripe_cnt; u64 stripe_len;...
0
[ "CWE-476", "CWE-284" ]
linux
09ba3bc9dd150457c506e4661380a6183af651c1
109,052,305,833,910,330,000,000,000,000,000,000,000
146
btrfs: merge btrfs_find_device and find_device Both btrfs_find_device() and find_device() does the same thing except that the latter does not take the seed device onto account in the device scanning context. We can merge them. Signed-off-by: Anand Jain <anand.jain@oracle.com> Reviewed-by: David Sterba <dsterba@suse.c...
_gdm_user_set_login_frequency (GdmUser *user, gulong login_frequency) { user->login_frequency = login_frequency; g_object_notify (G_OBJECT (user), "login-frequency"); }
0
[]
gdm
c25ef9245be4e0be2126ef3d075df4401949b570
280,036,465,301,357,300,000,000,000,000,000,000,000
6
Store the face and dmrc files in a cache. Refer to bug #565151.
static void mod_wstunnel_merge_config_cpv(plugin_config * const pconf, const config_plugin_value_t * const cpv) { switch (cpv->k_id) { /* index into static config_plugin_keys_t cpk[] */ case 0: /* wstunnel.server */ if (cpv->vtype == T_CONFIG_LOCAL) { gw_plugin_config * const gw = cpv->v.v...
0
[ "CWE-476" ]
lighttpd1.4
971773f1fae600074b46ef64f3ca1f76c227985f
187,867,129,898,915,780,000,000,000,000,000,000,000
33
[mod_wstunnel] fix crash with bad hybivers (fixes #3165) (thx Michał Dardas) x-ref: "mod_wstunnel null pointer dereference" https://redmine.lighttpd.net/issues/3165
static int selinux_ptrace_traceme(struct task_struct *parent) { return avc_has_perm(&selinux_state, task_sid(parent), current_sid(), SECCLASS_PROCESS, PROCESS__PTRACE, NULL); }
0
[ "CWE-349" ]
linux
fb73974172ffaaf57a7c42f35424d9aece1a5af6
234,586,191,087,512,530,000,000,000,000,000,000,000
6
selinux: properly handle multiple messages in selinux_netlink_send() Fix the SELinux netlink_send hook to properly handle multiple netlink messages in a single sk_buff; each message is parsed and subject to SELinux access control. Prior to this patch, SELinux only inspected the first message in the sk_buff. Cc: stab...
ModuleExport void UnregisterCALSImage(void) { (void) UnregisterMagickInfo("CAL"); (void) UnregisterMagickInfo("CALS"); }
0
[ "CWE-20", "CWE-252" ]
ImageMagick
6b6bff054d569a77973f2140c0e86366e6168a6c
320,121,458,137,080,900,000,000,000,000,000,000,000
5
https://github.com/ImageMagick/ImageMagick/issues/1199
static void hide_cursor(struct vc_data *vc) { if (vc_is_sel(vc)) clear_selection(); vc->vc_sw->con_cursor(vc, CM_ERASE); hide_softcursor(vc); }
0
[ "CWE-125" ]
linux
3c4e0dff2095c579b142d5a0693257f1c58b4804
223,823,688,815,424,400,000,000,000,000,000,000,000
8
vt: Disable KD_FONT_OP_COPY It's buggy: On Fri, Nov 06, 2020 at 10:30:08PM +0800, Minh Yuan wrote: > We recently discovered a slab-out-of-bounds read in fbcon in the latest > kernel ( v5.10-rc2 for now ). The root cause of this vulnerability is that > "fbcon_do_set_font" did not handle "vc->vc_font.data" and > "vc->...
static struct usb_function *hidg_alloc(struct usb_function_instance *fi) { struct f_hidg *hidg; struct f_hid_opts *opts; /* allocate and initialize one new instance */ hidg = kzalloc(sizeof(*hidg), GFP_KERNEL); if (!hidg) return ERR_PTR(-ENOMEM); opts = container_of(fi, struct f_hid_opts, func_inst); mutex_...
0
[ "CWE-703", "CWE-667", "CWE-189" ]
linux
072684e8c58d17e853f8e8b9f6d9ce2e58d2b036
101,338,702,627,888,840,000,000,000,000,000,000,000
46
USB: gadget: f_hid: fix deadlock in f_hidg_write() In f_hidg_write() the write_spinlock is acquired before calling usb_ep_queue() which causes a deadlock when dummy_hcd is being used. This is because dummy_queue() callbacks into f_hidg_req_complete() which tries to acquire the same spinlock. This is (part of) the back...
int CLASS ljpeg_diff_new (LibRaw_bit_buffer& bits, LibRaw_byte_buffer* buf,ushort *huff) { int len, diff; len = bits._gethuff_lj(buf,*huff,huff+1); if (len == 16 && (!dng_version || dng_version >= 0x1010000)) return -32768; diff = bits._getbits_lj(buf,len); if ((diff & (1 << (len-1))) == 0) diff -= (...
1
[ "CWE-703" ]
LibRaw
11909cc59e712e09b508dda729b99aeaac2b29ad
283,340,647,829,935,360,000,000,000,000,000,000,000
12
cumulated data checks patch
static void __io_uring_show_fdinfo(struct io_ring_ctx *ctx, struct seq_file *m) { int i; mutex_lock(&ctx->uring_lock); seq_printf(m, "UserFiles:\t%u\n", ctx->nr_user_files); for (i = 0; i < ctx->nr_user_files; i++) { struct fixed_file_table *table; struct file *f; table = &ctx->file_data->table[i >> IORING_...
0
[ "CWE-416" ]
linux
6d816e088c359866f9867057e04f244c608c42fe
258,268,727,430,836,800,000,000,000,000,000,000,000
41
io_uring: hold 'ctx' reference around task_work queue + execute We're holding the request reference, but we need to go one higher to ensure that the ctx remains valid after the request has finished. If the ring is closed with pending task_work inflight, and the given io_kiocb finishes sync during issue, then we need a...
lyd_get_unique_default(const char* unique_expr, struct lyd_node *list, const char **dflt) { struct ly_ctx *ctx = list->schema->module->ctx; const struct lys_node *parent; const struct lys_node_leaf *sleaf = NULL; struct lys_tpdf *tpdf; struct lyd_node *last, *node; struct ly_set *s, *r; unsi...
0
[ "CWE-119" ]
libyang
32fb4993bc8bb49e93e84016af3c10ea53964be5
134,182,860,997,510,950,000,000,000,000,000,000,000
110
schema tree BUGFIX do not check features while still resolving schema Fixes #723
static void sysbus_esp_init(Object *obj) { SysBusESPState *sysbus = SYSBUS_ESP(obj); object_initialize_child(obj, "esp", &sysbus->esp, TYPE_ESP); }
0
[ "CWE-476" ]
qemu
0db895361b8a82e1114372ff9f4857abea605701
92,532,453,424,655,430,000,000,000,000,000,000,000
6
esp: always check current_req is not NULL before use in DMA callbacks After issuing a SCSI command the SCSI layer can call the SCSIBusInfo .cancel callback which resets both current_req and current_dev to NULL. If any data is left in the transfer buffer (async_len != 0) then the next TI (Transfer Information) command ...
u32 bnx2x_fw_command(struct bnx2x *bp, u32 command, u32 param) { int mb_idx = BP_FW_MB_IDX(bp); u32 seq; u32 rc = 0; u32 cnt = 1; u8 delay = CHIP_REV_IS_SLOW(bp) ? 100 : 10; mutex_lock(&bp->fw_mb_mutex); seq = ++bp->fw_seq; SHMEM_WR(bp, func_mb[mb_idx].drv_mb_param, param); SHMEM_WR(bp, func_mb[mb_idx].drv_mb...
0
[ "CWE-20" ]
linux
8914a595110a6eca69a5e275b323f5d09e18f4f9
328,958,374,341,505,940,000,000,000,000,000,000,000
41
bnx2x: disable GSO where gso_size is too big for hardware If a bnx2x card is passed a GSO packet with a gso_size larger than ~9700 bytes, it will cause a firmware error that will bring the card down: bnx2x: [bnx2x_attn_int_deasserted3:4323(enP24p1s0f0)]MC assert! bnx2x: [bnx2x_mc_assert:720(enP24p1s0f0)]XSTORM_ASSERT...
output_print_addr(HFS_PRINT_ADDR * print) { if (!print->accumulating) return; if (print->blockCount == 1) { tsk_fprintf(print->hFile, "%" PRIuDADDR " ", print->startBlock); print->idx += 1; } else if (print->blockCount > 1) { tsk_fprintf(print->hFile, "%" PRIuDADDR "-%" ...
0
[ "CWE-190", "CWE-284" ]
sleuthkit
114cd3d0aac8bd1aeaf4b33840feb0163d342d5b
66,019,476,192,964,020,000,000,000,000,000,000,000
18
hfs: fix keylen check in hfs_cat_traverse() If key->key_len is 65535, calculating "uint16_t keylen' would cause an overflow: uint16_t keylen; ... keylen = 2 + tsk_getu16(hfs->fs_info.endian, key->key_len) so the code bypasses the sanity check "if (keylen > nodesize)" which results in crash later: ./too...
Item_func_sp::sp_check_access(THD *thd) { DBUG_ENTER("Item_func_sp::sp_check_access"); DBUG_ASSERT(m_sp); if (check_routine_access(thd, EXECUTE_ACL, m_sp->m_db.str, m_sp->m_name.str, 0, FALSE)) DBUG_RETURN(TRUE); DBUG_RETURN(FALSE); }
0
[ "CWE-120" ]
server
eca207c46293bc72dd8d0d5622153fab4d3fccf1
194,533,451,991,751,040,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...
static void free_modinfo(struct module *mod) { struct module_attribute *attr; int i; for (i = 0; (attr = modinfo_attrs[i]); i++) { if (attr->free) attr->free(mod); } }
0
[ "CWE-362", "CWE-347" ]
linux
0c18f29aae7ce3dadd26d8ee3505d07cc982df75
188,407,875,601,137,400,000,000,000,000,000,000,000
10
module: limit enabling module.sig_enforce Irrespective as to whether CONFIG_MODULE_SIG is configured, specifying "module.sig_enforce=1" on the boot command line sets "sig_enforce". Only allow "sig_enforce" to be set when CONFIG_MODULE_SIG is configured. This patch makes the presence of /sys/module/module/parameters/s...
void wsrep_SE_initialized(enum Wsrep_SE_init_result result) { mysql_mutex_lock (&LOCK_wsrep_sst_init); if (SE_initialized == WSREP_SE_INIT_RESULT_NONE) { SE_initialized= result; } mysql_cond_signal (&COND_wsrep_sst_init); mysql_mutex_unlock (&LOCK_wsrep_sst_init); }
0
[ "CWE-77" ]
mysql-wsrep
4ea4b0c6a318209ac09b15aaa906c7b4a13b988c
144,370,462,336,448,880,000,000,000,000,000,000,000
10
codership/mysql-wsrep-bugs#758 Donor uses invalid SST methods
ofpact_is_allowed_in_actions_set(const struct ofpact *a) { return action_set_classify(a) != ACTION_SLOT_INVALID; }
0
[ "CWE-416" ]
ovs
77cccc74deede443e8b9102299efc869a52b65b2
32,689,204,731,283,970,000,000,000,000,000,000,000
4
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...
static long php_jpeg_emit_message(j_common_ptr jpeg_info, int level) { char message[JMSG_LENGTH_MAX]; jmpbuf_wrapper *jmpbufw; int ignore_warning = 0; jmpbufw = (jmpbuf_wrapper *) jpeg_info->client_data; if (jmpbufw != 0) { ignore_warning = jmpbufw->ignore_warning; } (jpeg_info->err->format_message)(jpeg_in...
0
[ "CWE-415" ]
php-src
089f7c0bc28d399b0420aa6ef058e4c1c120b2ae
285,701,883,268,466,380,000,000,000,000,000,000,000
36
Sync with upstream Even though libgd/libgd#492 is not a relevant bug fix for PHP, since the binding doesn't use the `gdImage*Ptr()` functions at all, we're porting the fix to stay in sync here.
new_network_activate_cb (GtkWidget *menu_item, NMApplet *applet) { GtkWidget *dialog; dialog = nma_wireless_dialog_new_for_create (applet); if (!dialog) return; g_signal_connect (dialog, "response", G_CALLBACK (wireless_dialog_response_cb), applet); show_ignore_focus_stea...
0
[ "CWE-310" ]
network-manager-applet
4020594dfbf566f1852f0acb36ad631a9e73a82b
177,394,079,854,006,700,000,000,000,000,000,000,000
14
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...
hybiReadAndDecode(ws_ctx_t *wsctx, char *dst, int len, int *sockRet, int nInBuf) { int n; int i; int toReturn; /* number of data bytes to return */ int toDecode; /* number of bytes to decode starting at wsctx->writePos */ int bufsize; int nextRead; unsigned char *data; uint32_t *data32; /* if data wa...
1
[ "CWE-787" ]
libvncserver
0cf1400c61850065de590d403f6d49e32882fd76
94,805,613,523,944,400,000,000,000,000,000,000,000
132
fix crash because of unaligned accesses in hybiReadAndDecode()
static int jpc_dec_process_siz(jpc_dec_t *dec, jpc_ms_t *ms) { jpc_siz_t *siz = &ms->parms.siz; int compno; int tileno; jpc_dec_tile_t *tile; jpc_dec_tcomp_t *tcomp; int htileno; int vtileno; jpc_dec_cmpt_t *cmpt; size_t size; size_t num_samples; size_t num_samples_delta; size_t tile_samples; if (!jas_saf...
1
[ "CWE-617" ]
jasper
1b1c591306817e46e1e6a3300f714992b32f972b
20,009,022,757,512,388,000,000,000,000,000,000,000
155
jpc_dec: fix another integer overflow in SIZ Validate the width and height values first, before doing anything else. This prevents integer overflows in the `numhtiles` / `numvtiles` calculation below, triggering assertion failures. Fixes CVE-2017-13750 Closes https://github.com/mdadams/jasper/issues/165 Closes http...
explicit Buffer(std::size_t capacity, std::size_t memory_limit) : capacity_(capacity), memory_limit_(memory_limit), current_bytes_(0) {}
0
[ "CWE-20", "CWE-703" ]
tensorflow
cebe3c45d76357d201c65bdbbf0dbe6e8a63bbdb
244,727,097,997,202,500,000,000,000,000,000,000,000
2
Fix tf.raw_ops.StagePeek vulnerability with invalid `index`. Check that input is actually a scalar before treating it as such. PiperOrigin-RevId: 445524908
CImg<T>& autocrop(const T *const color=0, const char *const axes="zyx") { if (is_empty()) return *this; if (!color) { // Guess color const CImg<T> col1 = get_vector_at(0,0,0); const unsigned int w = _width, h = _height, d = _depth, s = _spectrum; autocrop(col1,axes); if (...
0
[ "CWE-770" ]
cimg
619cb58dd90b4e03ac68286c70ed98acbefd1c90
42,406,837,903,307,320,000,000,000,000,000,000,000
46
CImg<>::load_bmp() and CImg<>::load_pandore(): Check that dimensions encoded in file does not exceed file size.
static int firebird_handle_preparer(pdo_dbh_t *dbh, const char *sql, size_t sql_len, /* {{{ */ pdo_stmt_t *stmt, zval *driver_options) { pdo_firebird_db_handle *H = (pdo_firebird_db_handle *)dbh->driver_data; pdo_firebird_stmt *S = NULL; HashTable *np; do { isc_stmt_handle s = PDO_FIREBIRD_HANDLE_INITIALIZER; ...
0
[ "CWE-787" ]
php-src
08da7c73726f7b86b67d6f0ff87c73c585a7834a
266,642,682,220,934,920,000,000,000,000,000,000,000
83
Fix #76449: SIGSEGV in firebird_handle_doer We need to verify that the `result_size` is not larger than our buffer, and also should make sure that the `len` which is passed to `isc_vax_integer()` has a permissible value; otherwise we bail out.
static int ext4_inode_blocks_set(handle_t *handle, struct ext4_inode *raw_inode, struct ext4_inode_info *ei) { struct inode *inode = &(ei->vfs_inode); u64 i_blocks = READ_ONCE(inode->i_blocks); struct super_block *sb = inode->i_sb; if (i_blocks <= ~0U) { /* * i_blocks can be represented in a 32 bit va...
0
[ "CWE-703" ]
linux
ce9f24cccdc019229b70a5c15e2b09ad9c0ab5d1
156,378,834,974,320,360,000,000,000,000,000,000,000
38
ext4: check journal inode extents more carefully Currently, system zones just track ranges of block, that are "important" fs metadata (bitmaps, group descriptors, journal blocks, etc.). This however complicates how extent tree (or indirect blocks) can be checked for inodes that actually track such metadata - currently...
get_key_exp(krb5_db_entry *entry) { if (entry->expiration == 0) return entry->pw_expiration; if (entry->pw_expiration == 0) return entry->expiration; return ts_min(entry->expiration, entry->pw_expiration); }
0
[ "CWE-20", "CWE-617" ]
krb5
ffb35baac6981f9e8914f8f3bffd37f284b85970
64,574,078,709,222,570,000,000,000,000,000,000,000
8
Prevent KDC unset status assertion failures Assign status values if S4U2Self padata fails to decode, if an S4U2Proxy request uses invalid KDC options, or if an S4U2Proxy request uses an evidence ticket which does not match the canonicalized request server principal name. Reported by Samuel Cabrero. If a status value...
privsep_interface_curhlim(const char *iface, uint32_t hlim) { struct privsep_command cmd; cmd.type = SET_INTERFACE_CURHLIM; strncpy(cmd.iface, iface, sizeof(cmd.iface)); cmd.val = hlim; if (writen(pfd, &cmd, sizeof(cmd)) != sizeof(cmd)) return (-1); return 0; }
0
[ "CWE-20" ]
radvd
074816cd0b37aac7b3209987e6e998f0a847b275
218,024,908,068,946,400,000,000,000,000,000,000,000
10
privsep_read_loop() should return on unprivileged daemon death / socket close(), not loop forever with polling read() getting -1.
mlx5_mprq_buf_free_cb(void *addr __rte_unused, void *opaque) { struct mlx5_mprq_buf *buf = opaque; if (__atomic_load_n(&buf->refcnt, __ATOMIC_RELAXED) == 1) { rte_mempool_put(buf->mp, buf); } else if (unlikely(__atomic_sub_fetch(&buf->refcnt, 1, __ATOMIC_RELAXED) == 0)) { __atomic_store_n(&buf->refc...
0
[]
dpdk-stable
ef311075d21b4f68c8ccfc46a00cda7c2a0bf4cc
266,818,925,404,166,750,000,000,000,000,000,000,000
12
net/mlx5: fix Rx queue recovery mechanism The local variables are getting inconsistent in data receiving routines after queue error recovery. Receive queue consumer index is getting wrong, need to reset one to the size of the queue (as RQ was fully replenished in recovery procedure). In MPRQ case, also the local cons...
static void fm10k_tx_map(struct fm10k_ring *tx_ring, struct fm10k_tx_buffer *first) { struct sk_buff *skb = first->skb; struct fm10k_tx_buffer *tx_buffer; struct fm10k_tx_desc *tx_desc; struct skb_frag_struct *frag; unsigned char *data; dma_addr_t dma; unsigned int data_len, size; u32 tx_flags = first->tx_f...
0
[ "CWE-476" ]
linux
01ca667133d019edc9f0a1f70a272447c84ec41f
209,688,794,330,306,930,000,000,000,000,000,000,000
123
fm10k: Fix a potential NULL pointer dereference Syzkaller report this: kasan: GPF could be caused by NULL-ptr deref or user memory access general protection fault: 0000 [#1] SMP KASAN PTI CPU: 0 PID: 4378 Comm: syz-executor.0 Tainted: G C 5.0.0+ #5 Hardware name: QEMU Standard PC (i440FX + PIIX, 1996),...
GF_Err gf_odf_write_command(GF_BitStream *bs, GF_ODCom *com) { switch (com->tag) { case GF_ODF_OD_UPDATE_TAG: return gf_odf_write_od_update(bs, (GF_ODUpdate *)com); case GF_ODF_OD_REMOVE_TAG: return gf_odf_write_od_remove(bs, (GF_ODRemove *)com); case GF_ODF_ESD_UPDATE_TAG: return gf_odf_write_esd_update(bs,...
0
[ "CWE-787" ]
gpac
4e56ad72ac1afb4e049a10f2d99e7512d7141f9d
306,547,695,795,378,160,000,000,000,000,000,000,000
27
fixed #2216
_hb_buffer_swap( HB_Buffer buffer ) { HB_GlyphItem tmp_string; int tmp_length; int tmp_pos; if ( buffer->separate_out ) { tmp_string = buffer->in_string; buffer->in_string = buffer->out_string; buffer->out_string = tmp_string; buffer->alt_string = buffer->out_string; } tmp_le...
1
[]
pango
336bb3201096bdd0494d29926dd44e8cca8bed26
311,922,746,781,343,040,000,000,000,000,000,000,000
22
[HB] Remove all references to the old code!
qf_parse_fmt_c(regmatch_T *rmp, int midx, qffields_T *fields) { if (rmp->startp[midx] == NULL) return QF_FAIL; fields->col = (int)atol((char *)rmp->startp[midx]); return QF_OK; }
0
[ "CWE-416" ]
vim
4f1b083be43f351bc107541e7b0c9655a5d2c0bb
90,624,964,295,167,070,000,000,000,000,000,000,000
7
patch 9.0.0322: crash when no errors and 'quickfixtextfunc' is set Problem: Crash when no errors and 'quickfixtextfunc' is set. Solution: Do not handle errors if there aren't any.
void TR_table::store(uint field_id, timeval ts) { table->field[field_id]->store_timestamp(ts.tv_sec, ts.tv_usec); table->field[field_id]->set_notnull(); }
0
[ "CWE-416" ]
server
c02ebf3510850ba78a106be9974c94c3b97d8585
235,002,700,097,846,000,000,000,000,000,000,000,000
5
MDEV-24176 Preparations 1. moved fix_vcol_exprs() call to open_table() mysql_alter_table() doesn't do lock_tables() so it cannot win from fix_vcol_exprs() from there. Tests affected: main.default_session 2. Vanilla cleanups and comments.
static int __dwc3_gadget_kick_transfer(struct dwc3_ep *dep) { struct dwc3_gadget_ep_cmd_params params; struct dwc3_request *req; int starting; int ret; u32 cmd; if (!dwc3_calc_trbs_left(dep)) return 0; starting = !(dep->flags & DWC3_EP_BUSY); dwc3_prepare_trbs(dep); req = next_request(&dep->star...
0
[ "CWE-703", "CWE-667", "CWE-189" ]
linux
c91815b596245fd7da349ecc43c8def670d2269e
25,431,037,669,033,163,000,000,000,000,000,000,000
57
usb: dwc3: gadget: never call ->complete() from ->ep_queue() This is a requirement which has always existed but, somehow, wasn't reflected in the documentation and problems weren't found until now when Tuba Yavuz found a possible deadlock happening between dwc3 and f_hid. She described the situation as follows: spin_...
usage( char* execname ) { fprintf( stderr, "\n" ); fprintf( stderr, "ftview: simple glyph viewer -- part of the FreeType project\n" ); fprintf( stderr, "-----------------------------------------------------------\n" ); fprintf( stderr, "\n" ); fprintf( stderr, "Usage: %s [options] pt font ...
0
[ "CWE-120" ]
freetype2-demos
b995299b73ba4cd259f221f500d4e63095508bec
75,703,399,204,467,290,000,000,000,000,000,000,000
31
Fix Savannah bug #30054. * src/ftdiff.c, src/ftgrid.c, src/ftmulti.c, src/ftstring.c, src/ftview.c: Use precision for `%s' where appropriate to avoid buffer overflows.
int red_stream_get_no_delay(RedStream *stream) { return red_socket_get_no_delay(stream->socket); }
0
[]
spice
95a0cfac8a1c8eff50f05e65df945da3bb501fc9
154,894,412,760,387,870,000,000,000,000,000,000,000
4
With OpenSSL 1.0.2 and earlier: disable client-side renegotiation. Fixed issue #49 Fixes BZ#1904459 Signed-off-by: Julien Ropé <jrope@redhat.com> Reported-by: BlackKD Acked-by: Frediano Ziglio <fziglio@redhat.com>
static int get_vmx_mem_address(struct kvm_vcpu *vcpu, unsigned long exit_qualification, u32 vmx_instruction_info, bool wr, gva_t *ret) { gva_t off; bool exn; struct kvm_segment s; /* * According to Vol. 3B, "Information for VM Exits Due to Instruction * Execution", on an exit, vmx_instruction_info ho...
0
[ "CWE-284", "CWE-264" ]
linux
3ce424e45411cf5a13105e0386b6ecf6eeb4f66f
65,907,804,365,073,700,000,000,000,000,000,000,000
91
kvm:vmx: more complete state update on APICv on/off The function to update APICv on/off state (in particular, to deactivate it when enabling Hyper-V SynIC) is incomplete: it doesn't adjust APICv-related fields among secondary processor-based VM-execution controls. As a result, Windows 2012 guests get stuck when SynIC...
static void l2cap_tx_state_xmit(struct l2cap_chan *chan, struct l2cap_ctrl *control, struct sk_buff_head *skbs, u8 event) { BT_DBG("chan %p, control %p, skbs %p, event %d", chan, control, skbs, event); switch (event) { case L2CAP_EV_DATA_REQUEST: if (chan->tx_send_head == NULL) chan->tx_send_he...
0
[ "CWE-787" ]
linux
e860d2c904d1a9f38a24eb44c9f34b8f915a6ea3
291,996,189,714,977,800,000,000,000,000,000,000,000
71
Bluetooth: Properly check L2CAP config option output buffer length Validate the output buffer length for L2CAP config requests and responses to avoid overflowing the stack buffer used for building the option blocks. Cc: stable@vger.kernel.org Signed-off-by: Ben Seri <ben@armis.com> Signed-off-by: Marcel Holtmann <mar...
static int getSingletonPos(const char* str) { int result =-1; int i=0; int len = 0; if( str && ((len=strlen(str))>0) ){ for( i=0; i<len ; i++){ if( isIDSeparator(*(str+i)) ){ if( i==1){ /* string is of the form x-avy or a-prv1 */ result =0; break; } else { /* delimiter found; check...
0
[ "CWE-125" ]
php-src
97eff7eb57fc2320c267a949cffd622c38712484
334,844,666,913,805,470,000,000,000,000,000,000,000
27
Fix bug #72241: get_icu_value_internal out-of-bounds read
compute_consensus_method(smartlist_t *votes) { smartlist_t *all_methods = smartlist_new(); smartlist_t *acceptable_methods = smartlist_new(); smartlist_t *tmp = smartlist_new(); int min = (smartlist_len(votes) * 2) / 3; int n_ok; int result; SMARTLIST_FOREACH(votes, networkstatus_t *, vote, { tor_as...
0
[]
tor
a0ef3cf0880e3cd343977b3fcbd0a2e7572f0cb4
175,861,424,409,129,400,000,000,000,000,000,000,000
32
Prevent int underflow in dirvote.c compare_vote_rs_. This should be "impossible" without making a SHA1 collision, but let's not keep the assumption that SHA1 collisions are super-hard. This prevents another case related to 21278. There should be no behavioral change unless -ftrapv is on.
static long btrfs_ioctl_quota_ctl(struct file *file, void __user *arg) { struct btrfs_root *root = BTRFS_I(file_inode(file))->root; struct btrfs_ioctl_quota_ctl_args *sa; struct btrfs_trans_handle *trans = NULL; int ret; int err; if (!capable(CAP_SYS_ADMIN)) return -EPERM; ret = mnt_want_write_file(file); i...
0
[ "CWE-200" ]
linux
8039d87d9e473aeb740d4fdbd59b9d2f89b2ced9
46,388,360,886,335,800,000,000,000,000,000,000,000
50
Btrfs: fix file corruption and data loss after cloning inline extents Currently the clone ioctl allows to clone an inline extent from one file to another that already has other (non-inlined) extents. This is a problem because btrfs is not designed to deal with files having inline and regular extents, if a file has an ...
int i2d_PUBKEY_bio(BIO *bp, EVP_PKEY *pkey) { return ASN1_i2d_bio_of(EVP_PKEY,i2d_PUBKEY,bp,pkey); }
0
[ "CWE-310" ]
openssl
684400ce192dac51df3d3e92b61830a6ef90be3e
153,920,185,826,322,000,000,000,000,000,000,000,000
4
Fix various certificate fingerprint issues. By using non-DER or invalid encodings outside the signed portion of a certificate the fingerprint can be changed without breaking the signature. Although no details of the signed portion of the certificate can be changed this can cause problems with some applications: e.g. t...
check_sgr(TERMTYPE2 *tp, char *zero, int num, char *cap, const char *name) { char *test; _nc_tparm_err = 0; test = TPARM_9(set_attributes, num == 1, num == 2, num == 3, num == 4, num == 5, num == 6, num == 7, num == 8, num == 9); if (test != 0) { if (PRESEN...
1
[]
ncurses
790a85dbd4a81d5f5d8dd02a44d84f01512ef443
14,967,183,406,778,414,000,000,000,000,000,000,000
33
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...