func
string
target
int64
cwe
list
project
string
commit_id
string
hash
float64
size
int64
message
string
AuthorizationManagerImpl::~AuthorizationManagerImpl() { for (stdx::unordered_map<UserName, User*>::iterator it = _userCache.begin(); it != _userCache.end(); ++it) { fassert(17265, it->second != internalSecurity.user); delete it->second; } }
0
[ "CWE-613" ]
mongo
6dfb92b1299de04677d0bd2230e89a52eb01003c
58,431,885,560,173,310,000,000,000,000,000,000,000
8
SERVER-38984 Validate unique User ID on UserCache hit (cherry picked from commit e55d6e2292e5dbe2f97153251d8193d1cc89f5d7)
int list_add_packet(struct pkt_buf **list, int length, unsigned char* packet) { struct pkt_buf *next = *list; if(length <= 0) return 1; if(packet == NULL) return 1; if(list == NULL) return 1; *list = (struct pkt_buf*) malloc(sizeof(struct pkt_buf)); if( *list == NULL ) return 1; (*list)->p...
0
[ "CWE-787" ]
aircrack-ng
ff70494dd389ba570dbdbf36f217c28d4381c6b5
122,892,414,510,744,100,000,000,000,000,000,000,000
20
Airodump-ng: Fixed GPS stack overflow (Closes #13 on GitHub). git-svn-id: http://svn.aircrack-ng.org/trunk@2416 28c6078b-6c39-48e3-add9-af49d547ecab
ldns_rr_pop_rdf(ldns_rr *rr) { size_t rd_count; ldns_rdf *pop; ldns_rdf** newrd; rd_count = ldns_rr_rd_count(rr); if (rd_count == 0) { return NULL; } pop = rr->_rdata_fields[rd_count - 1]; /* try to shrink the array */ if(rd_count > 1) { newrd = LDNS_XREALLOC( rr->_rdata_fields, ldns_rdf *, rd_count...
0
[ "CWE-415" ]
ldns
070b4595981f48a21cc6b4f5047fdc2d09d3da91
204,163,420,172,060,140,000,000,000,000,000,000,000
27
CAA and URI
exif_mnote_data_canon_get_name (ExifMnoteData *note, unsigned int i) { ExifMnoteDataCanon *dc = (ExifMnoteDataCanon *) note; unsigned int m, s; if (!dc) return NULL; exif_mnote_data_canon_get_tags (dc, i, &m, &s); if (m >= dc->count) return NULL; return mnote_canon_tag_get_name_sub (dc->entries[m].tag, s, dc->op...
0
[ "CWE-125" ]
libexif
435e21f05001fb03f9f186fa7cbc69454afd00d1
196,029,819,578,749,600,000,000,000,000,000,000,000
10
Fix MakerNote tag size overflow issues at read time. Check for a size overflow while reading tags, which ensures that the size is always consistent for the given components and type of the entry, making checking further down superfluous. This provides an alternate fix for https://sourceforge.net/p/libexif/bugs/125/ C...
void security_md5_16_32_32(const BYTE* in0, const BYTE* in1, const BYTE* in2, BYTE* output) { CryptoMd5 md5; md5 = crypto_md5_init(); crypto_md5_update(md5, in0, 16); crypto_md5_update(md5, in1, 32); crypto_md5_update(md5, in2, 32); crypto_md5_final(md5, output); }
0
[ "CWE-476" ]
FreeRDP
7d58aac24fe20ffaad7bd9b40c9ddf457c1b06e7
73,412,490,962,928,330,000,000,000,000,000,000,000
10
security: add a NULL pointer check to fix a server crash.
AVCodecParserContext *av_parser_init(int codec_id) { AVCodecParserContext *s = NULL; AVCodecParser *parser; int ret; if(codec_id == AV_CODEC_ID_NONE) return NULL; for(parser = av_first_parser; parser != NULL; parser = parser->next) { if (parser->codec_ids[0] == codec_id || ...
0
[ "CWE-119", "CWE-787" ]
FFmpeg
f31011e9abfb2ae75bb32bc44e2c34194c8dc40a
263,282,248,617,217,620,000,000,000,000,000,000,000
46
avcodec/parser: reset indexes on realloc failure Fixes Ticket2982 Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
bool tcmur_unregister_handler(struct tcmur_handler *handler) { int i; for (i = 0; i < darray_size(g_runner_handlers); i++) { if (darray_item(g_runner_handlers, i) == handler) { darray_remove(g_runner_handlers, i); return true; } } return false; }
0
[ "CWE-20" ]
tcmu-runner
e2d953050766ac538615a811c64b34358614edce
214,055,287,012,198,340,000,000,000,000,000,000,000
11
fixed local DoS when UnregisterHandler was called for a not existing handler Any user with DBUS access could cause a SEGFAULT in tcmu-runner by running something like this: dbus-send --system --print-reply --dest=org.kernel.TCMUService1 /org/kernel/TCMUService1/HandlerManager1 org.kernel.TCMUService1.HandlerManager1....
static CURLcode post_per_transfer(struct GlobalConfig *global, struct per_transfer *per, CURLcode result, bool *retryp, long *delay) /* milliseconds! */ { struct OutStruct *outs = &p...
0
[]
curl
8c7ee9083d0d719d0a77ab20d9cc2ae84eeea7f3
264,836,863,202,787,000,000,000,000,000,000,000,000
307
post_per_transfer: remove the updated file name When --remove-on-error is used with --no-clobber, it might have an updated file name to remove. Bug: https://curl.se/docs/CVE-2022-27778.html CVE-2022-27778 Reported-by: Harry Sintonen Closes #8824
static void ucvector_init_buffer(ucvector* p, unsigned char* buffer, size_t size) { p->data = buffer; p->allocsize = p->size = size; }
0
[ "CWE-401" ]
FreeRDP
9fee4ae076b1ec97b97efb79ece08d1dab4df29a
271,006,126,448,433,050,000,000,000,000,000,000,000
5
Fixed #5645: realloc return handling
SSL_CIPHER *dtls1_get_cipher(unsigned int u) { SSL_CIPHER *ciph = ssl3_get_cipher(u); if (ciph != NULL) { if ((ciph->algorithms&SSL_ENC_MASK) == SSL_RC4) return NULL; } return ciph; }
0
[ "CWE-310" ]
openssl
c6a876473cbff0fd323c8abcaace98ee2d21863d
84,065,192,807,007,780,000,000,000,000,000,000,000
12
Support TLS_FALLBACK_SCSV. Reviewed-by: Stephen Henson <steve@openssl.org>
double Item_null::val_real() { // following assert is redundant, because fixed=1 assigned in constructor DBUG_ASSERT(fixed == 1); null_value=1; return 0.0; }
0
[]
server
b000e169562697aa072600695d4f0c0412f94f4f
104,147,375,434,223,840,000,000,000,000,000,000,000
7
Bug#26361149 MYSQL SERVER CRASHES AT: COL IN(IFNULL(CONST, COL), NAME_CONST('NAME', NULL)) based on: commit f7316aa0c9a Author: Ajo Robert <ajo.robert@oracle.com> Date: Thu Aug 24 17:03:21 2017 +0530 Bug#26361149 MYSQL SERVER CRASHES AT: COL IN(IFNULL(CONST, COL), NAME_CONST('NAME'...
repodata_set_num(Repodata *data, Id solvid, Id keyname, unsigned long long num) { Repokey key; key.name = keyname; key.type = REPOKEY_TYPE_NUM; key.size = 0; key.storage = KEY_STORAGE_INCORE; if (num >= 0x80000000) { data->attrnum64data = solv_extend(data->attrnum64data, data->attrnum64datalen, 1,...
0
[ "CWE-125" ]
libsolv
fdb9c9c03508990e4583046b590c30d958f272da
253,560,185,475,851,650,000,000,000,000,000,000,000
15
repodata_schema2id: fix heap-buffer-overflow in memcmp When the length of last schema in data->schemadata is less than length of input schema, we got a read overflow in asan test. Signed-off-by: Zhipeng Xie <xiezhipeng1@huawei.com>
PJ_DEF(pj_status_t) pjmedia_rtcp_fb_parse_pli( const void *buf, pj_size_t length) { pjmedia_rtcp_common *hdr = (pjmedia_rtcp_common*) buf; PJ_ASSERT_RETURN(buf, PJ_EINVAL); PJ_ASSERT_RETURN(length >= 12, PJ_ETOOSMALL); /* PLI uses pt==RTCP_PSFB and FMT==1 */ if (hdr->pt != RTCP_PSFB || h...
1
[ "CWE-125" ]
pjproject
22af44e68a0c7d190ac1e25075e1382f77e9397a
95,573,602,701,562,140,000,000,000,000,000,000,000
15
Merge pull request from GHSA-m66q-q64c-hv36 * Prevent OOB read during RTP/RTCP parsing * Add log * Add more logs
void IDLParserErrorContext::appendGenericCommandArguments( const BSONObj& commandPassthroughFields, const std::vector<StringData>& knownFields, BSONObjBuilder* builder) { for (const auto& element : commandPassthroughFields) { StringData name = element.fieldNameStringData(); // Include ...
0
[ "CWE-20" ]
mongo
5c7c6729c37514760fd34da462b6961a2e385417
243,680,547,606,597,700,000,000,000,000,000,000,000
15
SERVER-38275 ban explain with UUID
void donoop(void) { #ifdef BORING_MODE addreply_noformat(200, "dc.w $4E71"); #else addreply_noformat(200, MSG_SLEEPING); #endif }
0
[ "CWE-434" ]
pure-ftpd
37ad222868e52271905b94afea4fc780d83294b4
297,785,136,038,764,130,000,000,000,000,000,000,000
8
Initialize the max upload file size when quotas are enabled Due to an unwanted check, files causing the quota to be exceeded were deleted after the upload, but not during the upload. The bug was introduced in 2009 in version 1.0.23 Spotted by @DroidTest, thanks!
static int qib_file_vma_fault(struct vm_area_struct *vma, struct vm_fault *vmf) { struct page *page; page = vmalloc_to_page((void *)(vmf->pgoff << PAGE_SHIFT)); if (!page) return VM_FAULT_SIGBUS; get_page(page); vmf->page = page; return 0; }
0
[ "CWE-284", "CWE-264" ]
linux
e6bd18f57aad1a2d1ef40e646d03ed0f2515c9e3
79,779,298,571,463,460,000,000,000,000,000,000,000
13
IB/security: Restrict use of the write() interface The drivers/infiniband stack uses write() as a replacement for bi-directional ioctl(). This is not safe. There are ways to trigger write calls that result in the return structure that is normally written to user space being shunted off to user specified kernel memory...
static u64 vmx_get_mt_mask(struct kvm_vcpu *vcpu, gfn_t gfn, bool is_mmio) { u8 cache; u64 ipat = 0; /* For VT-d and EPT combination * 1. MMIO: always map as UC * 2. EPT with VT-d: * a. VT-d without snooping control feature: can't guarantee the * result, try to trust guest. * b. VT-d with snooping con...
0
[ "CWE-284" ]
linux
727ba748e110b4de50d142edca9d6a9b7e6111d8
170,852,274,489,321,200,000,000,000,000,000,000,000
41
kvm: nVMX: Enforce cpl=0 for VMX instructions VMX instructions executed inside a L1 VM will always trigger a VM exit even when executed with cpl 3. This means we must perform the privilege check in software. Fixes: 70f3aac964ae("kvm: nVMX: Remove superfluous VMX instruction fault checks") Cc: stable@vger.kernel.org S...
void CLASS kodak_rgb_load_raw() { short buf[768], *bp; int row, col, len, c, i, rgb[3],ret; ushort *ip=image[0]; for (row=0; row < height; row++) { #ifdef LIBRAW_LIBRARY_BUILD checkCancel(); #endif for (col=0; col < width; col+=256) { len = MIN (256, width-col); ret = kodak_65000_decode (...
1
[ "CWE-787" ]
LibRaw
8682ad204392b914ab1cc6ebcca9c27c19c1a4b4
270,100,671,789,604,060,000,000,000,000,000,000,000
27
0.18.17
static umode_t udf_convert_permissions(struct fileEntry *fe) { umode_t mode; uint32_t permissions; uint32_t flags; permissions = le32_to_cpu(fe->permissions); flags = le16_to_cpu(fe->icbTag.flags); mode = ((permissions) & S_IRWXO) | ((permissions >> 2) & S_IRWXG) | ((permissions >> 4) & S_IRWXU) | ((flags...
0
[ "CWE-703", "CWE-189" ]
linux
23b133bdc452aa441fcb9b82cbf6dd05cfd342d0
90,888,028,996,362,810,000,000,000,000,000,000,000
18
udf: Check length of extended attributes and allocation descriptors Check length of extended attributes and allocation descriptors when loading inodes from disk. Otherwise corrupted filesystems could confuse the code and make the kernel oops. Reported-by: Carl Henrik Lunde <chlunde@ping.uio.no> CC: stable@vger.kernel...
relay_header_pack(uint8_t *dest, const relay_header_t *src) { set_uint8(dest, src->command); set_uint16(dest+1, htons(src->recognized)); set_uint16(dest+3, htons(src->stream_id)); memcpy(dest+5, src->integrity, 4); set_uint16(dest+9, htons(src->length)); }
0
[ "CWE-200", "CWE-617" ]
tor
56a7c5bc15e0447203a491c1ee37de9939ad1dcd
243,668,982,039,775,830,000,000,000,000,000,000,000
8
TROVE-2017-005: Fix assertion failure in connection_edge_process_relay_cell On an hidden service rendezvous circuit, a BEGIN_DIR could be sent (maliciously) which would trigger a tor_assert() because connection_edge_process_relay_cell() thought that the circuit is an or_circuit_t but is an origin circuit in reality. ...
static inline void blur(uint8_t *dst, int dst_step, const uint8_t *src, int src_step, int len, int radius) { /* Naive boxblur would sum source pixels from x-radius .. x+radius * for destination pixel x. That would be O(radius*width). * If you now look at what source pixels represen...
0
[ "CWE-119", "CWE-787" ]
FFmpeg
e43a0a232dbf6d3c161823c2e07c52e76227a1bc
184,017,558,013,727,400,000,000,000,000,000,000,000
40
avfilter: fix plane validity checks Fixes out of array accesses Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
static void hns_nic_ring_close(struct net_device *netdev, int idx) { struct hns_nic_priv *priv = netdev_priv(netdev); struct hnae_handle *h = priv->ae_handle; h->dev->ops->toggle_ring_irq(priv->ring_data[idx].ring, 1); disable_irq(priv->ring_data[idx].ring->irq); napi_disable(&priv->ring_data[idx].napi); }
0
[ "CWE-416" ]
linux
27463ad99f738ed93c7c8b3e2e5bc8c4853a2ff2
155,729,573,773,664,280,000,000,000,000,000,000,000
10
net: hns: Fix a skb used after free bug skb maybe freed in hns_nic_net_xmit_hw() and return NETDEV_TX_OK, which cause hns_nic_net_xmit to use a freed skb. BUG: KASAN: use-after-free in hns_nic_net_xmit_hw+0x62c/0x940... [17659.112635] alloc_debug_processing+0x18c/0x1a0 [17659.117208] __slab_alloc+0x52c/0x...
GF_Err dfla_box_size(GF_Box *s) { GF_FLACConfigBox *ptr = (GF_FLACConfigBox *) s; ptr->size += ptr->dataSize; return GF_OK; }
0
[ "CWE-787" ]
gpac
77510778516803b7f7402d7423c6d6bef50254c3
191,867,092,185,294,500,000,000,000,000,000,000,000
6
fixed #2255
has_function_privilege_id(PG_FUNCTION_ARGS) { Oid functionoid = PG_GETARG_OID(0); text *priv_type_text = PG_GETARG_TEXT_P(1); Oid roleid; AclMode mode; AclResult aclresult; roleid = GetUserId(); mode = convert_function_priv_string(priv_type_text); if (!SearchSysCacheExists1(PROCOID, ObjectIdGetDatum(f...
0
[ "CWE-264" ]
postgres
fea164a72a7bfd50d77ba5fb418d357f8f2bb7d0
164,524,734,796,593,650,000,000,000,000,000,000,000
18
Shore up ADMIN OPTION restrictions. Granting a role without ADMIN OPTION is supposed to prevent the grantee from adding or removing members from the granted role. Issuing SET ROLE before the GRANT bypassed that, because the role itself had an implicit right to add or remove members. Plug that hole by recognizing tha...
int transport_check_fds(rdpTransport** ptransport) { int pos; int status; UINT16 length; int recv_status; wStream* received; rdpTransport* transport = *ptransport; #ifdef _WIN32 WSAResetEvent(transport->TcpIn->wsa_event); #endif ResetEvent(transport->ReceiveEvent); status = transport_read_nonblocking(transpo...
0
[ "CWE-476", "CWE-125" ]
FreeRDP
0773bb9303d24473fe1185d85a424dfe159aff53
182,056,671,705,539,160,000,000,000,000,000,000,000
113
nla: invalidate sec handle after creation If sec pointer isn't invalidated after creation it is not possible to check if the upper and lower pointers are valid. This fixes a segfault in the server part if the client disconnects before the authentication was finished.
static int netdev_adjacent_sysfs_add(struct net_device *dev, struct net_device *adj_dev, struct list_head *dev_list) { char linkname[IFNAMSIZ+7]; sprintf(linkname, dev_list == &dev->adj_list.upper ? "upper_%s" : "lower_%s", adj_dev->name); return sysfs_create_link(&(dev->dev.kobj), &(adj_dev->d...
0
[ "CWE-476" ]
linux
0ad646c81b2182f7fa67ec0c8c825e0ee165696d
215,113,854,465,213,920,000,000,000,000,000,000,000
11
tun: call dev_get_valid_name() before register_netdevice() register_netdevice() could fail early when we have an invalid dev name, in which case ->ndo_uninit() is not called. For tun device, this is a problem because a timer etc. are already initialized and it expects ->ndo_uninit() to clean them up. We could move th...
static int MP4_ReadBox_hmhd( stream_t *p_stream, MP4_Box_t *p_box ) { MP4_READBOX_ENTER( MP4_Box_data_hmhd_t ); MP4_GETVERSIONFLAGS( p_box->data.p_hmhd ); MP4_GET2BYTES( p_box->data.p_hmhd->i_max_PDU_size ); MP4_GET2BYTES( p_box->data.p_hmhd->i_avg_PDU_size ); MP4_GET4BYTES( p_box->data.p_hmhd->i...
0
[ "CWE-120", "CWE-191", "CWE-787" ]
vlc
2e7c7091a61aa5d07e7997b393d821e91f593c39
87,008,181,462,679,010,000,000,000,000,000,000,000
23
demux: mp4: fix buffer overflow in parsing of string boxes. We ensure that pbox->i_size is never smaller than 8 to avoid an integer underflow in the third argument of the subsequent call to memcpy. We also make sure no truncation occurs when passing values derived from the 64 bit integer p_box->i_size to arguments of ...
bool asn1_write_Integer(struct asn1_data *data, int i) { if (!asn1_push_tag(data, ASN1_INTEGER)) return false; if (!asn1_write_implicit_Integer(data, i)) return false; return asn1_pop_tag(data); }
0
[ "CWE-399" ]
samba
9d989c9dd7a5b92d0c5d65287935471b83b6e884
296,614,544,668,011,060,000,000,000,000,000,000,000
6
CVE-2015-7540: lib: util: Check *every* asn1 return call and early return. BUG: https://bugzilla.samba.org/show_bug.cgi?id=9187 Signed-off-by: Jeremy Allison <jra@samba.org> Reviewed-by: Volker Lendecke <Volker.Lendecke@SerNet.DE> Autobuild-User(master): Jeremy Allison <jra@samba.org> Autobuild-Date(master): Fri Sep...
static CURLcode tftp_connect_for_rx(tftp_state_data_t *state, tftp_event_t event) { CURLcode result; #ifndef CURL_DISABLE_VERBOSE_STRINGS struct Curl_easy *data = state->conn->data; infof(data, "%s\n", "Connected for receive"); #endif state->state = TFTP_STATE_RX; result =...
0
[ "CWE-787" ]
curl
facb0e4662415b5f28163e853dc6742ac5fafb3d
161,250,662,722,506,860,000,000,000,000,000,000,000
15
tftp: Alloc maximum blksize, and use default unless OACK is received Fixes potential buffer overflow from 'recvfrom()', should the server return an OACK without blksize. Bug: https://curl.haxx.se/docs/CVE-2019-5482.html CVE-2019-5482
static int may_context_mount_inode_relabel(u32 sid, struct superblock_security_struct *sbsec, const struct cred *cred) { const struct task_security_struct *tsec = cred->security; int rc; rc = avc_has_perm(tsec->sid, sbsec->sid, SECCLASS_FILESYSTEM, FILESYSTEM__RELABELFROM, NULL); if (rc) return rc; r...
0
[]
linux-2.6
ee18d64c1f632043a02e6f5ba5e045bb26a5465f
181,433,245,925,657,300,000,000,000,000,000,000,000
15
KEYS: Add a keyctl to install a process's session keyring on its parent [try #6] Add a keyctl to install a process's session keyring onto its parent. This replaces the parent's session keyring. Because the COW credential code does not permit one process to change another process's credentials directly, the change is...
static void add_filtered_history(const char *string) { if (!check_histignore(string)) { #ifdef HAVE_READLINE if (not_in_history(string)) add_history(string); #endif if (opt_syslog) add_syslog(string); } }
0
[ "CWE-284", "CWE-295" ]
mysql-server
3bd5589e1a5a93f9c224badf983cd65c45215390
51,655,170,943,123,040,000,000,000,000,000,000,000
12
WL#6791 : Redefine client --ssl option to imply enforced encryption # Changed the meaning of the --ssl=1 option of all client binaries to mean force ssl, not try ssl and fail over to eunecrypted # Added a new MYSQL_OPT_SSL_ENFORCE mysql_options() option to specify that an ssl connection is required. # Added a new macr...
irc_server_send_one_msg (struct t_irc_server *server, int flags, const char *message, const char *tags) { static char buffer[4096]; const char *ptr_msg; char *new_msg, *pos, *nick, *command, *channel, *tags_to_send; char *ptr_chan_nick, *msg_encoded; char str_modifier[64], m...
0
[ "CWE-20" ]
weechat
c265cad1c95b84abfd4e8d861f25926ef13b5d91
287,438,306,414,235,240,000,000,000,000,000,000,000
181
Fix verification of SSL certificates by calling gnutls verify callback (patch #7459)
PHP_FUNCTION(radius_send_request) { radius_descriptor *raddesc; zval *z_radh; int res; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "r", &z_radh) == FAILURE) { return; } ZEND_FETCH_RESOURCE(raddesc, radius_descriptor *, &z_radh, -1, "rad_handle", le_radius); res = rad_send_request(raddesc->radh); ...
0
[ "CWE-119", "CWE-787" ]
php-radius
13c149b051f82b709e8d7cc32111e84b49d57234
70,463,978,932,791,200,000,000,000,000,000,000,000
20
Fix a security issue in radius_get_vendor_attr(). The underlying rad_get_vendor_attr() function assumed that it would always be given valid VSA data. Indeed, the buffer length wasn't even passed in; the assumption was that the length field within the VSA structure would be valid. This could result in denial of servic...
get_resource_id_quoted (WinResource *wr) { static char tmp[WINRES_ID_MAXLEN+2]; if (wr->numeric_id || wr->id[0] == '\0') return wr->id; sprintf(tmp, "'%s'", wr->id); return tmp; }
0
[]
icoutils
a8c8543731ed255e6f8bb81c662155f98710ac20
312,053,120,057,130,340,000,000,000,000,000,000,000
10
wrestool: read_library() moves memory around, check it doesn't overwrite header data
static void si_dbus_match_rule_update(struct session_info *info) { DBusError error; if (info->connection == NULL) return; si_dbus_match_remove(info); /* Seat signals */ if (info->seat != NULL) { info->match_seat_signals = g_strdup_printf ("type='signal',interface='%s',...
0
[ "CWE-362" ]
spice-vd_agent
5c50131797e985d0a5654c1fd7000ae945ed29a7
63,556,680,796,311,860,000,000,000,000,000,000,000
54
Better check for sessions Do not allow other users to hijack a session checking that the process is launched by the owner of the session. Signed-off-by: Frediano Ziglio <freddy77@gmail.com> Acked-by: Uri Lublin <uril@redhat.com>
static bool __in_atomic_pool(void *start, size_t size) { return addr_in_gen_pool(atomic_pool, (unsigned long)start, size); }
0
[ "CWE-200" ]
linux
6829e274a623187c24f7cfc0e3d35f25d087fcc5
36,522,384,331,792,394,000,000,000,000,000,000,000
4
arm64: dma-mapping: always clear allocated buffers Buffers allocated by dma_alloc_coherent() are always zeroed on Alpha, ARM (32bit), MIPS, PowerPC, x86/x86_64 and probably other architectures. It turned out that some drivers rely on this 'feature'. Allocated buffer might be also exposed to userspace with dma_mmap() c...
TEST_F(RouterTest, DoNotForward0) { testDoNotForward(absl::nullopt); }
0
[ "CWE-703" ]
envoy
18871dbfb168d3512a10c78dd267ff7c03f564c6
100,996,530,145,783,810,000,000,000,000,000,000,000
1
[1.18] CVE-2022-21655 Crash with direct_response Signed-off-by: Otto van der Schaaf <ovanders@redhat.com>
static int mov_read_rtmd_track(AVFormatContext *s, AVStream *st) { MOVStreamContext *sc = st->priv_data; char buf[AV_TIMECODE_STR_SIZE]; int64_t cur_pos = avio_tell(sc->pb); int hh, mm, ss, ff, drop; if (!st->nb_index_entries) return -1; avio_seek(sc->pb, st->index_entries->pos, SEEK_S...
0
[ "CWE-399", "CWE-834" ]
FFmpeg
9cb4eb772839c5e1de2855d126bf74ff16d13382
91,813,523,805,381,800,000,000,000,000,000,000,000
24
avformat/mov: Fix DoS in read_tfra() Fixes: Missing EOF check in loop No testcase Found-by: Xiaohei and Wangchu from Alibaba Security Team Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
int kvm_write_guest_offset_cached(struct kvm *kvm, struct gfn_to_hva_cache *ghc, void *data, unsigned int offset, unsigned long len) { struct kvm_memslots *slots = kvm_memslots(kvm); int r; gpa_t gpa = ghc->gpa + offset; BUG_ON(len + offset > ghc->len); if (slots->generation != ghc->generation) { i...
0
[ "CWE-119" ]
linux
f8be156be163a052a067306417cd0ff679068c97
183,597,604,946,247,830,000,000,000,000,000,000,000
28
KVM: do not allow mapping valid but non-reference-counted pages It's possible to create a region which maps valid but non-refcounted pages (e.g., tail pages of non-compound higher order allocations). These host pages can then be returned by gfn_to_page, gfn_to_pfn, etc., family of APIs, which take a reference to the p...
static struct rpc_task *nfs4_do_unlck(struct file_lock *fl, struct nfs_open_context *ctx, struct nfs4_lock_state *lsp, struct nfs_seqid *seqid) { struct nfs4_unlockdata *data; struct rpc_message msg = { .rpc_proc = &nfs4_procedures[NFSPROC4_CLNT_LOCKU], .rpc_cred = ctx->cred, }; struct rpc_task_setup task...
0
[ "CWE-703", "CWE-189" ]
linux
bf118a342f10dafe44b14451a1392c3254629a1f
296,292,926,986,694,740,000,000,000,000,000,000,000
34
NFSv4: include bitmap in nfsv4 get acl data The NFSv4 bitmap size is unbounded: a server can return an arbitrary sized bitmap in an FATTR4_WORD0_ACL request. Replace using the nfs4_fattr_bitmap_maxsz as a guess to the maximum bitmask returned by a server with the inclusion of the bitmap (xdr length plus bitmasks) and...
void luac_add_section(RzList *section_list, char *name, ut64 offset, ut32 size, bool is_func) { RzBinSection *bin_sec = RZ_NEW0(RzBinSection); if (!bin_sec || !name) { free(bin_sec); return; } bin_sec->name = rz_str_new(name); bin_sec->vaddr = bin_sec->paddr = offset; bin_sec->size = bin_sec->vsize = size; ...
0
[ "CWE-200", "CWE-787" ]
rizin
07b43bc8aa1ffebd9b68d60624c9610cf7e460c7
315,140,892,040,672,500,000,000,000,000,000,000,000
26
fix oob read on luac
sctp_disposition_t sctp_sf_do_prm_requestheartbeat( struct net *net, const struct sctp_endpoint *ep, const struct sctp_association *asoc, const sctp_subtype_t type, void *arg, sctp_cmd_seq_t *commands) { if (SCTP_DISPOSITION_NOMEM == sctp_sf_heartbeat(ep, asoc, type, (struct sct...
0
[]
linux
196d67593439b03088913227093e374235596e33
89,208,610,338,631,780,000,000,000,000,000,000,000
27
sctp: Add support to per-association statistics via a new SCTP_GET_ASSOC_STATS call The current SCTP stack is lacking a mechanism to have per association statistics. This is an implementation modeled after OpenSolaris' SCTP_GET_ASSOC_STATS. Userspace part will follow on lksctp if/when there is a general ACK on this. ...
gx_default_install(gx_device * dev, gs_gstate * pgs) { return 0; }
0
[]
ghostpdl
c9b362ba908ca4b1d7c72663a33229588012d7d9
57,265,142,926,023,725,000,000,000,000,000,000,000
4
Bug 699670: disallow copying of the epo device The erasepage optimisation (epo) subclass device shouldn't be allowed to be copied because the subclass private data, child and parent pointers end up being shared between the original device and the copy. Add an epo_finish_copydevice which NULLs the three offending poin...
static void virtio_register_types(void) { type_register_static(&virtio_gpu_info); }
0
[]
qemu
acfc4846508a02cc4c83aa27799fd74ac280bdb2
213,236,318,814,448,060,000,000,000,000,000,000,000
4
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>
uint get_length() const { return length_bytes == 1 ? (uint) *ptr : uint2korr(ptr); }
0
[ "CWE-416", "CWE-703" ]
server
08c7ab404f69d9c4ca6ca7a9cf7eec74c804f917
49,607,419,509,431,090,000,000,000,000,000,000,000
4
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...
bool Utility::reconstituteCrumbledCookies(const HeaderString& key, const HeaderString& value, HeaderString& cookies) { if (key != Headers::get().Cookie.get().c_str()) { return false; } if (!cookies.empty()) { cookies.append("; ", 2); } const absl::string_vie...
0
[ "CWE-400", "CWE-703" ]
envoy
afc39bea36fd436e54262f150c009e8d72db5014
218,310,690,186,473,900,000,000,000,000,000,000,000
14
Track byteSize of HeaderMap internally. Introduces a cached byte size updated internally in HeaderMap. The value is stored as an optional, and is cleared whenever a non-const pointer or reference to a HeaderEntry is accessed. The cached value can be set with refreshByteSize() which performs an iteration over the Heade...
static void print_hint_h_format(HintNode *node) { switch (node->type) { case HINT_NODE_ADDR: { const RzAnalysisAddrHintRecord *record; rz_vector_foreach(node->addr_hints, record) { switch (record->type) { case RZ_ANALYSIS_ADDR_HINT_TYPE_IMMBASE: rz_cons_printf(" immbase=%d", record->immbase); break;...
0
[ "CWE-703" ]
rizin
6ce71d8aa3dafe3cdb52d5d72ae8f4b95916f939
223,869,286,523,888,980,000,000,000,000,000,000,000
78
Initialize retctx,ctx before freeing the inner elements In rz_core_analysis_type_match retctx structure was initialized on the stack only after a "goto out_function", where a field of that structure was freed. When the goto path is taken, the field is not properly initialized and it cause cause a crash of Rizin or hav...
int main(int argc, char *argv[]) { struct fuse_args args = FUSE_ARGS_INIT(argc, argv); struct fuse_session *se; struct fuse_cmdline_opts opts; struct lo_data lo = { .sandbox = SANDBOX_NAMESPACE, .debug = 0, .writeback = 0, .posix_lock = 0, .allow_direct_io = 0, ...
0
[]
qemu
6084633dff3a05d63176e06d7012c7e15aba15be
96,417,848,713,222,250,000,000,000,000,000,000,000
160
tools/virtiofsd: xattr name mappings: Add option Add an option to define mappings of xattr names so that the client and server filesystems see different views. This can be used to have different SELinux mappings as seen by the guest, to run the virtiofsd with less privileges (e.g. in a case where it can't set trusted/...
GF_Err gf_isom_apple_enum_tag(GF_ISOFile *mov, u32 idx, GF_ISOiTunesTag *out_tag, const u8 **data, u32 *data_len, u64 *out_int_val, u32 *out_int_val2, u32 *out_flags) { u32 i, child_index; GF_ListItemBox *info; GF_ItemListBox *ilst; GF_MetaBox *meta; GF_DataBox *dbox = NULL; u32 itype, tag_val; s32 tag_idx; *da...
1
[ "CWE-787" ]
gpac
f0a41d178a2dc5ac185506d9fa0b0a58356b16f7
216,096,733,567,254,700,000,000,000,000,000,000,000
130
fixed #2120
bool BitTestMatchExpression::performBitTest(long long eValue) const { const MatchType mt = matchType(); switch (mt) { case BITS_ALL_SET: return (eValue & _bitMask) == _bitMask; case BITS_ALL_CLEAR: return (~eValue & _bitMask) == _bitMask; case BITS_ANY_SET: ...
0
[ "CWE-190" ]
mongo
21d8699ed6c517b45e1613e20231cd8eba894985
152,122,072,874,442,060,000,000,000,000,000,000,000
16
SERVER-43699 $mod should not overflow for large negative values
PHP_FUNCTION(pcntl_waitpid) { long pid, options = 0; zval *z_status = NULL; int status; pid_t child_id; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "lz|l", &pid, &z_status, &options) == FAILURE) return; convert_to_long_ex(&z_status); status = Z_LVAL_P(z_status); child_id = waitpid((pid_t) pid, &...
1
[ "CWE-19" ]
php-src
be9b2a95adb504abd5acdc092d770444ad6f6854
16,699,925,062,264,355,000,000,000,000,000,000,000
24
Fixed bug #69418 - more s->p fixes for filenames
inline void Http2Stream::Shutdown() { CHECK(!this->IsDestroyed()); Http2Scope h2scope(this); flags_ |= NGHTTP2_STREAM_FLAG_SHUT; CHECK_NE(nghttp2_session_resume_data(session_->session(), id_), NGHTTP2_ERR_NOMEM); DEBUG_HTTP2STREAM(this, "writable side shutdown"); }
0
[]
node
ce22d6f9178507c7a41b04ac4097b9ea902049e3
98,575,809,159,586,410,000,000,000,000,000,000,000
8
http2: add altsvc support Add support for sending and receiving ALTSVC frames. PR-URL: https://github.com/nodejs/node/pull/17917 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com> Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
static int snd_ftu_eff_switch_put(struct snd_kcontrol *kctl, struct snd_ctl_elem_value *ucontrol) { struct usb_mixer_elem_list *list = snd_kcontrol_chip(kctl); unsigned int pval = list->kctl->private_value; int cur_val, err, new_val; cur_val = pval >> 24; new_val = ucontrol->value.enumerated.item[0]; if (cu...
0
[]
sound
447d6275f0c21f6cc97a88b3a0c601436a4cdf2a
4,699,720,763,280,577,500,000,000,000,000,000,000
17
ALSA: usb-audio: Add sanity checks for endpoint accesses Add some sanity check codes before actually accessing the endpoint via get_endpoint() in order to avoid the invalid access through a malformed USB descriptor. Mostly just checking bNumEndpoints, but in one place (snd_microii_spdif_default_get()), the validity o...
router_append_dirobj_signature(char *buf, size_t buf_len, const char *digest, size_t digest_len, crypto_pk_t *private_key) { size_t sig_len, s_len; char *sig = router_get_dirobj_signature(digest, digest_len, private_key); if (!sig) { log_warn(LD_BUG, "No signature generated"); ...
0
[ "CWE-119" ]
tor
d978216dea6b21ac38230a59d172139185a68dbd
37,772,632,899,618,823,000,000,000,000,000,000,000
19
Fix parsing bug with unecognized token at EOS In get_token(), we could read one byte past the end of the region. This is only a big problem in the case where the region itself is (a) potentially hostile, and (b) not explicitly nul-terminated. This patch fixes the underlying bug, and also makes sure that the one remai...
explicit StreamBitReader(Stream *strA) : str(strA), inputBits(0), isAtEof(false) { }
0
[]
poppler
81044c64b9ed9a10ae82a28bac753060bdfdac74
287,151,191,180,528,580,000,000,000,000,000,000,000
1
Hints::readTables: bail out if we run out of file when reading Fixes #1230
s32 gf_avc_parse_nalu(GF_BitStream *bs, AVCState *avc) { u8 idr_flag; s32 slice, ret; u32 nal_hdr; AVCSliceInfo n_state; gf_bs_enable_emulation_byte_removal(bs, GF_TRUE); if (!gf_bs_available(bs)) return -1; gf_bs_mark_overflow(bs, GF_TRUE); nal_hdr = gf_bs_read_u8(bs); slice = 0; memcpy(&n_state, &avc->s_...
0
[ "CWE-190" ]
gpac
0cd19f4db70615d707e0e6202933c2ea0c1d36df
61,628,602,982,554,430,000,000,000,000,000,000,000
172
fixed #2067
DLLIMPORT cfg_validate_callback2_t cfg_set_validate_func2(cfg_t *cfg, const char *name, cfg_validate_callback2_t vf) { cfg_opt_t *opt; cfg_validate_callback2_t oldvf; opt = cfg_getopt_array(cfg->opts, cfg->flags, name); if (!opt) return NULL; oldvf = opt->validcb2; opt->validcb2 = vf; return oldvf; }
0
[]
libconfuse
d73777c2c3566fb2647727bb56d9a2295b81669b
134,085,717,889,365,460,000,000,000,000,000,000,000
14
Fix #163: unterminated username used with getpwnam() Signed-off-by: Joachim Wiberg <troglobit@gmail.com>
void CBINDInstallDlg::InstallTags() { CString tag; tag.LoadString(IDS_INSTALL_FILE); GetDlgItem(IDC_COPY_TAG)->SetWindowText(tag); GetDlgItem(IDC_COPY_FILE)->SetWindowText(""); tag.LoadString(IDS_INSTALL_DIR); GetDlgItem(IDC_DIR_TAG)->SetWindowText(tag); GetDlgItem(IDC_CREATE_DIR)->SetWindowText(""); GetDlgIt...
0
[ "CWE-284" ]
bind9
967a3b9419a3c12b8c0870c86d1ee3840bcbbad7
153,927,714,193,109,420,000,000,000,000,000,000,000
19
[master] quote service registry paths 4532. [security] The BIND installer on Windows used an unquoted service path, which can enable privilege escalation. (CVE-2017-3141) [RT #45229]
StatusWith<std::size_t> SnappyMessageCompressor::compressData(ConstDataRange input, DataRange output) { size_t outLength; snappy::RawCompress(input.data(), input.length(), const_cast<char*>(output.data()), &outLength); counterHitCompress(input.l...
1
[]
mongo
5ad69b851801edadbfde8fdf271f4ba7c21170b5
82,824,202,720,638,740,000,000,000,000,000,000,000
8
SERVER-31273 Use Source/Sink version of snappy functions (cherry picked from commit 59ead734faa8aa51f0c53bf2bd39d0a0247ddf99)
QueryDataTyped& SQLInternal::rowsTyped() { return resultsTyped_; }
0
[ "CWE-77", "CWE-295" ]
osquery
c3f9a3dae22d43ed3b4f6a403cbf89da4cba7c3c
211,798,102,808,462,740,000,000,000,000,000,000,000
3
Merge pull request from GHSA-4g56-2482-x7q8 * Proposed fix for attach tables vulnerability * Add authorizer to ATC tables and cleanups - Add unit test for authorizer function
static void make_response(struct xen_blkif_ring *ring, u64 id, unsigned short op, int st) { struct blkif_response *resp; unsigned long flags; union blkif_back_rings *blk_rings; int notify; spin_lock_irqsave(&ring->blk_ring_lock, flags); blk_rings = &ring->blk_rings; /* Place on the response ring for th...
0
[ "CWE-200" ]
linux
089bc0143f489bd3a4578bdff5f4ca68fb26f341
109,265,719,939,330,550,000,000,000,000,000,000,000
38
xen-blkback: don't leak stack data via response ring Rather than constructing a local structure instance on the stack, fill the fields directly on the shared ring, just like other backends do. Build on the fact that all response structure flavors are actually identical (the old code did make this assumption too). Thi...
messageIsEncoding(message *m) { static const char encoding[] = "Content-Transfer-Encoding"; static const char binhex[] = "(This file must be converted with BinHex 4.0)"; const char *line = lineGetData(m->body_last->t_line); /*if(m->ctx == NULL) cli_dbgmsg("messageIsEncoding, ctx == NULL\n");*/ if((m->encoding ...
0
[ "CWE-125" ]
clamav-devel
586a5180287262070637c8943f2f7efd652e4a2c
173,783,311,050,712,130,000,000,000,000,000,000,000
32
bb11797 - fix invalid read in fuzzed mail file.
static void v4l_print_jpegcompression(const void *arg, bool write_only) { const struct v4l2_jpegcompression *p = arg; pr_cont("quality=%d, APPn=%d, APP_len=%d, COM_len=%d, jpeg_markers=0x%x\n", p->quality, p->APPn, p->APP_len, p->COM_len, p->jpeg_markers); }
0
[ "CWE-401" ]
linux
fb18802a338b36f675a388fc03d2aa504a0d0899
204,378,209,184,215,060,000,000,000,000,000,000,000
8
media: v4l: ioctl: Fix memory leak in video_usercopy When an IOCTL with argument size larger than 128 that also used array arguments were handled, two memory allocations were made but alas, only the latter one of them was released. This happened because there was only a single local variable to hold such a temporary a...
const absl::optional<std::string>& userAgent() override { return user_agent_; }
0
[ "CWE-400", "CWE-703" ]
envoy
afc39bea36fd436e54262f150c009e8d72db5014
212,376,937,358,970,480,000,000,000,000,000,000,000
1
Track byteSize of HeaderMap internally. Introduces a cached byte size updated internally in HeaderMap. The value is stored as an optional, and is cleared whenever a non-const pointer or reference to a HeaderEntry is accessed. The cached value can be set with refreshByteSize() which performs an iteration over the Heade...
lrc_descriptor(struct intel_context *ce, struct intel_engine_cs *engine) { u64 desc; desc = INTEL_LEGACY_32B_CONTEXT; if (i915_vm_is_4lvl(ce->vm)) desc = INTEL_LEGACY_64B_CONTEXT; desc <<= GEN8_CTX_ADDRESSING_MODE_SHIFT; desc |= GEN8_CTX_VALID | GEN8_CTX_PRIVILEGE; if (IS_GEN(engine->i915, 8)) desc |= GEN8_...
0
[]
linux
bc8a76a152c5f9ef3b48104154a65a68a8b76946
54,777,690,898,860,050,000,000,000,000,000,000,000
29
drm/i915/gen9: Clear residual context state on context switch Intel ID: PSIRT-TA-201910-001 CVEID: CVE-2019-14615 Intel GPU Hardware prior to Gen11 does not clear EU state during a context switch. This can result in information leakage between contexts. For Gen8 and Gen9, hardware provides a mechanism for fast clear...
NO_INLINE JsVar *jspeFactorObject() { if (JSP_SHOULD_EXECUTE) { JsVar *contents = jsvNewObject(); if (!contents) { // out of memory jspSetError(false); return 0; } /* JSON-style object definition */ JSP_MATCH_WITH_RETURN('{', contents); while (!JSP_SHOULDNT_PARSE && lex->tk != '}')...
0
[ "CWE-119", "CWE-125" ]
Espruino
c36d30529118aa049797db43f111ddad468aad29
172,539,215,599,133,270,000,000,000,000,000,000,000
50
Fix stack overflow if void void void... is repeated many times (fix #1434)
bool AuthorizationSessionImpl::isAuthorizedToParseNamespaceElement(const BSONElement& element) { const bool isUUID = element.type() == BinData && element.binDataType() == BinDataType::newUUID; uassert(ErrorCodes::InvalidNamespace, "Failed to parse namespace element", element.type() == S...
0
[ "CWE-613" ]
mongo
e55d6e2292e5dbe2f97153251d8193d1cc89f5d7
288,325,337,216,906,900,000,000,000,000,000,000,000
14
SERVER-38984 Validate unique User ID on UserCache hit
archive_read_format_zip_cleanup(struct archive_read *a) { struct zip *zip; struct zip_entry *zip_entry, *next_zip_entry; zip = (struct zip *)(a->format->data); #ifdef HAVE_ZLIB_H if (zip->stream_valid) inflateEnd(&zip->stream); #endif #if HAVE_LZMA_H && HAVE_LIBLZMA if (zip->zipx_lzma_valid) { lzma_end(&...
0
[ "CWE-399", "CWE-401" ]
libarchive
ba641f73f3d758d9032b3f0e5597a9c6e593a505
220,099,279,269,899,840,000,000,000,000,000,000,000
51
Fix typo in preprocessor macro in archive_read_format_zip_cleanup() Frees lzma_stream on cleanup() Fixes #1165
SYSCALL_DEFINE0(restart_syscall) { struct restart_block *restart = &current_thread_info()->restart_block; return restart->fn(restart); }
0
[]
linux-2.6
0083fc2c50e6c5127c2802ad323adf8143ab7856
81,162,979,245,818,690,000,000,000,000,000,000,000
5
do_sigaltstack: avoid copying 'stack_t' as a structure to user space Ulrich Drepper correctly points out that there is generally padding in the structure on 64-bit hosts, and that copying the structure from kernel to user space can leak information from the kernel stack in those padding bytes. Avoid the whole issue b...
static MagickBooleanType WriteTIFFImage(const ImageInfo *image_info, Image *image,ExceptionInfo *exception) { const char *mode, *option; CompressionType compression; EndianType endian_type; MagickBooleanType adjoin, debug, preserve_compression, status; MagickOffsetType ...
0
[ "CWE-703", "CWE-122" ]
ImageMagick
6ee5059cd3ac8d82714a1ab1321399b88539abf0
287,117,802,553,124,660,000,000,000,000,000,000,000
922
possible TIFF related-heap buffer overflow (alert & POC by Hardik Shah)
PHP_METHOD(Phar, extractTo) { char *error = NULL; php_stream *fp; php_stream_statbuf ssb; phar_entry_info *entry; char *pathto, *filename; size_t pathto_len, filename_len; int ret, i; int nelems; zval *zval_files = NULL; zend_bool overwrite = 0; PHAR_ARCHIVE_OBJECT(); if (zend_parse_parameters(ZEND_NUM_AR...
0
[ "CWE-20" ]
php-src
1e9b175204e3286d64dfd6c9f09151c31b5e099a
261,981,385,720,997,830,000,000,000,000,000,000,000
131
Fix bug #71860: Require valid paths for phar filenames
sg_remove_scat(Sg_fd * sfp, Sg_scatter_hold * schp) { SCSI_LOG_TIMEOUT(4, sg_printk(KERN_INFO, sfp->parentdp, "sg_remove_scat: k_use_sg=%d\n", schp->k_use_sg)); if (schp->pages && schp->sglist_len > 0) { if (!schp->dio_in_use) { int k; for (k = 0; k < schp->k_use_sg && schp->pages[k]; k++) { SCSI_LOG...
0
[ "CWE-190", "CWE-189" ]
linux
fdc81f45e9f57858da6351836507fbcf1b7583ee
21,393,318,628,629,953,000,000,000,000,000,000,000
21
sg_start_req(): use import_iovec() Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
gss_get_mic_iov_length(OM_uint32 *minor_status, gss_ctx_id_t context_handle, gss_qop_t qop_req, gss_iov_buffer_desc *iov, int iov_count) { OM_uint32 status; gss_union_ctx_id_t ctx; gss_mechanism mech; status = val_wrap_iov_args(minor_status, context_handle, 0, qop_req, NULL, ...
1
[ "CWE-415" ]
krb5
56f7b1bc95a2a3eeb420e069e7655fb181ade5cf
199,207,809,444,619,070,000,000,000,000,000,000,000
26
Preserve GSS context on init/accept failure After gss_init_sec_context() or gss_accept_sec_context() has created a context, don't delete the mechglue context on failures from subsequent calls, even if the mechanism deletes the mech-specific context (which is allowed by RFC 2744 but not preferred). Check for union con...
clear_opt_anc_info(OptAncInfo* anc) { anc->left_anchor = 0; anc->right_anchor = 0; }
0
[ "CWE-125" ]
php-src
c6e34d91b88638966662caac62c4d0e90538e317
104,815,710,871,315,990,000,000,000,000,000,000,000
5
Fix bug #77371 (heap buffer overflow in mb regex functions - compile_string_node)
static void evdev_pass_values(struct evdev_client *client, const struct input_value *vals, unsigned int count, ktime_t mono, ktime_t real) { struct evdev *evdev = client->evdev; const struct input_value *v; struct input_event event; bool wakeup = false; if (client->revoked) return; event.time = ktime_to...
0
[]
linux
7c4f56070fde2367766fa1fb04852599b5e1ad35
86,488,893,954,456,130,000,000,000,000,000,000,000
32
Input: evdev - fix EVIOCG{type} ioctl The 'max' size passed into the function is measured in number of bits (KEY_MAX, LED_MAX, etc) so we need to convert it accordingly before trying to copy the data out, otherwise we will try copying too much and end up with up with a page fault. Reported-by: Pavel Machek <pavel@ucw...
*/ static inline int skb_linearize(struct sk_buff *skb) { return skb_is_nonlinear(skb) ? __skb_linearize(skb) : 0;
0
[ "CWE-20" ]
linux
2b16f048729bf35e6c28a40cbfad07239f9dcd90
100,365,554,425,311,430,000,000,000,000,000,000,000
4
net: create skb_gso_validate_mac_len() If you take a GSO skb, and split it into packets, will the MAC length (L2 + L3 + L4 headers + payload) of those packets be small enough to fit within a given length? Move skb_gso_mac_seglen() to skbuff.h with other related functions like skb_gso_network_seglen() so we can use it...
double64_be_write (double in, unsigned char *out) { int exponent, mantissa ; memset (out, 0, sizeof (double)) ; if (fabs (in) < 1e-30) return ; if (in < 0.0) { in *= -1.0 ; out [0] |= 0x80 ; } ; in = frexp (in, &exponent) ; exponent += 1022 ; out [0] |= (exponent >> 4) & 0x7F ; out [1] |= (exponent...
0
[ "CWE-369" ]
libsndfile
85c877d5072866aadbe8ed0c3e0590fbb5e16788
285,339,875,778,485,850,000,000,000,000,000,000,000
38
double64_init: Check psf->sf.channels against upper bound This prevents division by zero later in the code. While the trivial case to catch this (i.e. sf.channels < 1) has already been covered, a crafted file may report a number of channels that is so high (i.e. > INT_MAX/sizeof(double)) that it "somehow" gets miscal...
mrb_gc_mark_mt_size(mrb_state *mrb, struct RClass *c) { khash_t(mt) *h = c->mt; if (!h) return 0; return kh_size(h); }
0
[ "CWE-476", "CWE-415" ]
mruby
faa4eaf6803bd11669bc324b4c34e7162286bfa3
106,650,364,514,299,600,000,000,000,000,000,000,000
7
`mrb_class_real()` did not work for `BasicObject`; fix #4037
static long snd_info_entry_ioctl(struct file *file, unsigned int cmd, unsigned long arg) { struct snd_info_private_data *data = file->private_data; struct snd_info_entry *entry = data->entry; if (!entry->c.ops->ioctl) return -ENOTTY; return entry->c.ops->ioctl(entry, data->file_private_data, file, cmd...
0
[ "CWE-416" ]
linux
8c2f870890fd28e023b0fcf49dcee333f2c8bad7
130,050,249,201,671,480,000,000,000,000,000,000,000
11
ALSA: info: Fix racy addition/deletion of nodes The ALSA proc helper manages the child nodes in a linked list, but its addition and deletion is done without any lock. This leads to a corruption if they are operated concurrently. Usually this isn't a problem because the proc entries are added sequentially in the driv...
bool CTransaction::ReadFromDisk(CTxDB& txdb, COutPoint prevout, CTxIndex& txindexRet) { SetNull(); if (!txdb.ReadTxIndex(prevout.hash, txindexRet)) return false; if (!ReadFromDisk(txindexRet.pos)) return false; if (prevout.n >= vout.size()) { SetNull(); return false; ...
0
[ "CWE-16", "CWE-787" ]
bitcoin
a206b0ea12eb4606b93323268fc81a4f1f952531
170,539,852,331,682,180,000,000,000,000,000,000,000
14
Do not allow overwriting unspent transactions (BIP 30) Introduce the following network rule: * a block is not valid if it contains a transaction whose hash already exists in the block chain, unless all that transaction's outputs were already spent before said block. Warning: this is effectively a network rule ...
ip_allow_ruby_exit_set(self, val) VALUE self, val; { struct tcltkip *ptr = get_ip(self); Tk_Window mainWin; /* ip is deleted? */ if (deleted_ip(ptr)) { rb_raise(rb_eRuntimeError, "interpreter is deleted"); } if (Tcl_IsSafe(ptr->ip)) { rb_raise(rb_eSecurityError, ...
0
[]
tk
ebd0fc80d62eeb7b8556522256f8d035e013eb65
158,478,352,578,155,460,000,000,000,000,000,000,000
52
tcltklib.c: check argument * ext/tk/tcltklib.c (ip_cancel_eval_core): check argument type and length. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51468 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
static inline int igmp6_proc_init(struct net *net) { return 0; }
0
[ "CWE-703" ]
linux
2d3916f3189172d5c69d33065c3c21119fe539fc
15,920,433,603,357,972,000,000,000,000,000,000,000
4
ipv6: fix skb drops in igmp6_event_query() and igmp6_event_report() While investigating on why a synchronize_net() has been added recently in ipv6_mc_down(), I found that igmp6_event_query() and igmp6_event_report() might drop skbs in some cases. Discussion about removing synchronize_net() from ipv6_mc_down() will ha...
static bool tcp_reset_check(const struct sock *sk, const struct sk_buff *skb) { struct tcp_sock *tp = tcp_sk(sk); return unlikely(TCP_SKB_CB(skb)->seq == (tp->rcv_nxt - 1) && (1 << sk->sk_state) & (TCPF_CLOSE_WAIT | TCPF_LAST_ACK | TCPF_CLOSING)); }
0
[ "CWE-190" ]
net
3b4929f65b0d8249f19a50245cd88ed1a2f78cff
310,539,815,878,658,980,000,000,000,000,000,000,000
8
tcp: limit payload size of sacked skbs Jonathan Looney reported that TCP can trigger the following crash in tcp_shifted_skb() : BUG_ON(tcp_skb_pcount(skb) < pcount); This can happen if the remote peer has advertized the smallest MSS that linux TCP accepts : 48 An skb can hold 17 fragments, and each fragment can ho...
static int post_recv_path(struct rtrs_clt_path *clt_path) { size_t q_size = 0; int err, cid; for (cid = 0; cid < clt_path->s.con_num; cid++) { if (cid == 0) q_size = SERVICE_CON_QUEUE_DEPTH; else q_size = clt_path->queue_depth; /* * x2 for RDMA read responses + FR key invalidations, * RDMA writes...
0
[ "CWE-415" ]
linux
8700af2cc18c919b2a83e74e0479038fd113c15d
318,144,596,336,549,060,000,000,000,000,000,000,000
27
RDMA/rtrs-clt: Fix possible double free in error case Callback function rtrs_clt_dev_release() for put_device() calls kfree(clt) to free memory. We shouldn't call kfree(clt) again, and we can't use the clt after kfree too. Replace device_register() with device_initialize() and device_add() so that dev_set_name can() ...
**/ CImg<T>& distance(const T& value, const unsigned int metric=2) { if (is_empty()) return *this; if (cimg::type<Tint>::string()!=cimg::type<T>::string()) // For datatype < int return CImg<Tint>(*this,false).distance((Tint)value,metric). cut((Tint)cimg::type<T>::min(),(Tint)cimg::...
0
[ "CWE-119", "CWE-787" ]
CImg
ac8003393569aba51048c9d67e1491559877b1d1
252,454,322,681,273,200,000,000,000,000,000,000,000
16
.
static void print_tags_recursive(const u8 * buf0, const u8 * buf, size_t buflen, size_t depth) { int r; size_t i; size_t bytesleft = buflen; const char *classes[4] = { "Universal", "Application", "Context", "Private" }; const u8 *p = buf; while (bytesleft >= 2) { unsigned int cla = 0, tag = 0, hl...
0
[ "CWE-119", "CWE-787" ]
OpenSC
412a6142c27a5973c61ba540e33cdc22d5608e68
177,584,470,148,305,000,000,000,000,000,000,000,000
113
fixed out of bounds access of ASN.1 Bitstring Credit to OSS-Fuzz
_outConstraint(StringInfo str, const Constraint *node) { WRITE_NODE_TYPE("CONSTRAINT"); WRITE_STRING_FIELD(conname); WRITE_BOOL_FIELD(deferrable); WRITE_BOOL_FIELD(initdeferred); WRITE_LOCATION_FIELD(location); appendStringInfoString(str, " :contype "); switch (node->contype) { case CONSTR_NULL: appendSt...
0
[ "CWE-362" ]
postgres
5f173040e324f6c2eebb90d86cf1b0cdb5890f0a
338,053,909,355,297,930,000,000,000,000,000,000,000
97
Avoid repeated name lookups during table and index DDL. If the name lookups come to different conclusions due to concurrent activity, we might perform some parts of the DDL on a different table than other parts. At least in the case of CREATE INDEX, this can be used to cause the permissions checks to be performed aga...
int wc_ecc_shared_secret_gen(ecc_key* private_key, ecc_point* point, byte* out, word32 *outlen) { int err; DECLARE_CURVE_SPECS(curve, 2); if (private_key == NULL || point == NULL || out == NULL || ...
0
[ "CWE-326", "CWE-203" ]
wolfssl
1de07da61f0c8e9926dcbd68119f73230dae283f
286,221,097,716,953,000,000,000,000,000,000,000,000
37
Constant time EC map to affine for private operations For fast math, use a constant time modular inverse when mapping to affine when operation involves a private key - key gen, calc shared secret, sign.
smb3_enum_snapshots(const unsigned int xid, struct cifs_tcon *tcon, struct cifsFileInfo *cfile, void __user *ioc_buf) { char *retbuf = NULL; unsigned int ret_data_len = 0; int rc; u32 max_response_size; struct smb_snapshot_array snapshot_in; /* * On the first query to enumerate the list of snapshots avail...
0
[ "CWE-476" ]
linux
d6f5e358452479fa8a773b5c6ccc9e4ec5a20880
147,894,157,863,274,240,000,000,000,000,000,000,000
81
cifs: fix NULL ptr dereference in smb2_ioctl_query_info() When calling smb2_ioctl_query_info() with invalid smb_query_info::flags, a NULL ptr dereference is triggered when trying to kfree() uninitialised rqst[n].rq_iov array. This also fixes leaked paths that are created in SMB2_open_init() which required SMB2_open_f...
static bool kvm_mmu_zap_collapsible_spte(struct kvm *kvm, struct kvm_rmap_head *rmap_head, const struct kvm_memory_slot *slot) { u64 *sptep; struct rmap_iterator iter; int need_tlb_flush = 0; kvm_pfn_t pfn; struct kvm_mmu_page *sp; restart: for_each_rmap_spte(rmap_head, &iter, sptep) { sp = sptep_t...
0
[ "CWE-476" ]
linux
9f46c187e2e680ecd9de7983e4d081c3391acc76
172,299,754,102,868,130,000,000,000,000,000,000,000
39
KVM: x86/mmu: fix NULL pointer dereference on guest INVPCID With shadow paging enabled, the INVPCID instruction results in a call to kvm_mmu_invpcid_gva. If INVPCID is executed with CR0.PG=0, the invlpg callback is not set and the result is a NULL pointer dereference. Fix it trivially by checking for mmu->invlpg befo...
irc_server_set_send_default_tags (const char *tags) { irc_server_send_default_tags = tags; }
0
[ "CWE-20" ]
weechat
c265cad1c95b84abfd4e8d861f25926ef13b5d91
157,659,757,956,845,470,000,000,000,000,000,000,000
4
Fix verification of SSL certificates by calling gnutls verify callback (patch #7459)
static bool typeValid(uint16_t type) { return type >= 1 && type <= 13 ; }
0
[ "CWE-125" ]
exiv2
6e3855aed7ba8bb4731fc4087ca7f9078b2f3d97
226,671,787,458,052,500,000,000,000,000,000,000,000
4
Fix https://github.com/Exiv2/exiv2/issues/55
ikev1_sub_print(netdissect_options *ndo, u_char np, const struct isakmp_gen *ext, const u_char *ep, uint32_t phase, uint32_t doi, uint32_t proto, int depth) { const u_char *cp; int i; struct isakmp_gen e; cp = (const u_char *)ext; while (np) { ND_TCHECK(*ext); UNALIGNED_MEMCPY(&e, ext, sizeof(e)); ND...
1
[ "CWE-125", "CWE-787" ]
tcpdump
8dca25d26c7ca2caf6138267f6f17111212c156e
97,415,850,352,925,940,000,000,000,000,000,000,000
39
CVE-2017-13690/IKEv2: Fix some bounds checks. Use a pointer of the correct type in ND_TCHECK(), or use ND_TCHECK2() and provide the correct length. While we're at it, remove the blank line between some checks and the UNALIGNED_MEMCPY()s they protect. Also, note the places where we print the entire payload. This fix...
void __init sched_init(void) { int i, j; unsigned long alloc_size = 0, ptr; #ifdef CONFIG_FAIR_GROUP_SCHED alloc_size += 2 * nr_cpu_ids * sizeof(void **); #endif #ifdef CONFIG_RT_GROUP_SCHED alloc_size += 2 * nr_cpu_ids * sizeof(void **); #endif if (alloc_size) { ptr = (unsigned long)kzalloc(alloc_size, GFP_NOW...
0
[ "CWE-119" ]
linux
29d6455178a09e1dc340380c582b13356227e8df
314,878,365,348,594,500,000,000,000,000,000,000,000
175
sched: panic on corrupted stack end Until now, hitting this BUG_ON caused a recursive oops (because oops handling involves do_exit(), which calls into the scheduler, which in turn raises an oops), which caused stuff below the stack to be overwritten until a panic happened (e.g. via an oops in interrupt context, cause...
static void tm_reclaim_thread(struct thread_struct *thr, struct thread_info *ti, uint8_t cause) { unsigned long msr_diff = 0; /* * If FP/VSX registers have been already saved to the * thread_struct, move them to the transact_fp array. * We clear the TIF_RESTORE_TM bit since after the reclaim * the t...
0
[ "CWE-284" ]
linux
7f821fc9c77a9b01fe7b1d6e72717b33d8d64142
273,905,706,489,264,020,000,000,000,000,000,000,000
51
powerpc/tm: Check for already reclaimed tasks Currently we can hit a scenario where we'll tm_reclaim() twice. This results in a TM bad thing exception because the second reclaim occurs when not in suspend mode. The scenario in which this can happen is the following. We attempt to deliver a signal to userspace. To ...
f_getcharmod(typval_T *argvars UNUSED, typval_T *rettv) { rettv->vval.v_number = mod_mask; }
0
[ "CWE-78" ]
vim
8c62a08faf89663e5633dc5036cd8695c80f1075
135,265,195,614,672,440,000,000,000,000,000,000,000
4
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 void mutt_decode_uuencoded (STATE *s, LOFF_T len, int istext, iconv_t cd) { char tmps[SHORT_STRING]; char linelen, c, l, out; char *pt; char bufi[BUFI_SIZE]; size_t k = 0; if (istext) state_set_prefix(s); while (len > 0) { if ((fgets(tmps, sizeof(tmps), s->fpin)) == NULL) return; ...
1
[ "CWE-120" ]
mutt
e5ed080c00e59701ca62ef9b2a6d2612ebf765a5
47,003,853,769,966,260,000,000,000,000,000,000,000
51
Fix uudecode buffer overflow. mutt_decode_uuencoded() used each line's initial "length character" without any validation. It would happily read past the end of the input line, and with a suitable value even past the length of the input buffer. As I noted in ticket 404, there are several other changes that could be a...
u16 channel_to_chanspec(struct brcmu_d11inf *d11inf, struct ieee80211_channel *ch) { struct brcmu_chan ch_inf; ch_inf.chnum = ieee80211_frequency_to_channel(ch->center_freq); ch_inf.bw = BRCMU_CHAN_BW_20; d11inf->encchspec(&ch_inf); return ch_inf.chspec; }
0
[ "CWE-119", "CWE-703" ]
linux
ded89912156b1a47d940a0c954c43afbabd0c42c
180,250,678,441,065,150,000,000,000,000,000,000,000
11
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...
int ldb_kv_modify_internal(struct ldb_module *module, const struct ldb_message *msg, struct ldb_request *req) { struct ldb_context *ldb = ldb_module_get_ctx(module); void *data = ldb_module_get_private(module); struct ldb_kv_private *ldb_kv = talloc_get_type(data, struct ldb_kv_private); struct ldb...
0
[ "CWE-20" ]
samba
3c1fbb18321f61df44d7b0f0c7452ae230960293
309,546,533,630,442,240,000,000,000,000,000,000,000
331
CVE-2018-1140 ldb_tdb: Check for DN validity in add, rename and search This ensures we fail with a good error code before an eventual ldb_dn_get_casefold() which would otherwise fail. Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz> BUG: https://bugzil...
httpGetVersion(http_t *http) /* I - HTTP connection */ { return (http ? http->version : HTTP_VERSION_1_0); }
0
[ "CWE-120" ]
cups
f24e6cf6a39300ad0c3726a41a4aab51ad54c109
8,482,366,448,120,431,000,000,000,000,000,000,000
4
Fix multiple security/disclosure issues: - CVE-2019-8696 and CVE-2019-8675: Fixed SNMP buffer overflows (rdar://51685251) - Fixed IPP buffer overflow (rdar://50035411) - Fixed memory disclosure issue in the scheduler (rdar://51373853) - Fixed DoS issues in the scheduler (rdar://51373929)