func string | target int64 | cwe list | project string | commit_id string | hash float64 | size int64 | message string |
|---|---|---|---|---|---|---|---|
sv_seqtimeout (value)
const char *value;
{
int nval;
nval = 0;
if (value && *value)
{
nval = atoi (value);
if (nval < 0)
nval = 0;
}
_rl_keyseq_timeout = nval;
return 0;
} | 0 | [] | bash | 955543877583837c85470f7fb8a97b7aa8d45e6c | 26,669,916,120,261,170,000,000,000,000,000,000,000 | 15 | bash-4.4-rc2 release |
static void autoconfig(struct mp_port *mtpt, unsigned int probeflags)
{
unsigned char status1, scratch, scratch2, scratch3;
unsigned char save_lcr, save_mcr;
unsigned long flags;
unsigned char u_type;
unsigned char b_ret = 0;
if (!mtpt->port.iobase && !mtpt->port.mapbase && !mtpt->port.membase)
return;
DEBU... | 0 | [
"CWE-200"
] | linux | a8b33654b1e3b0c74d4a1fed041c9aae50b3c427 | 104,628,688,240,650,560,000,000,000,000,000,000,000 | 131 | Staging: sb105x: info leak in mp_get_count()
The icount.reserved[] array isn't initialized so it leaks stack
information to userspace.
Reported-by: Nico Golde <nico@ngolde.de>
Reported-by: Fabian Yamaguchi <fabs@goesec.de>
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Cc: stable@kernel.org
Signed-off-by: Li... |
static int __cil_resolve_name_with_root(struct cil_db *db, char *name, enum cil_sym_index sym_index, struct cil_symtab_datum **datum)
{
symtab_t *symtab = &((struct cil_root *)db->ast->root->data)->symtab[sym_index];
return cil_symtab_get_datum(symtab, name, datum);
} | 0 | [
"CWE-125"
] | selinux | 340f0eb7f3673e8aacaf0a96cbfcd4d12a405521 | 126,457,650,438,211,750,000,000,000,000,000,000,000 | 6 | libsepol/cil: Check for statements not allowed in optional blocks
While there are some checks for invalid statements in an optional
block when resolving the AST, there are no checks when building the
AST.
OSS-Fuzz found the following policy which caused a null dereference
in cil_tree_get_next_path().
(blockinherit ... |
static int unmap_ref_private(struct mm_struct *mm, struct vm_area_struct *vma,
struct page *page, unsigned long address)
{
struct hstate *h = hstate_vma(vma);
struct vm_area_struct *iter_vma;
struct address_space *mapping;
struct prio_tree_iter iter;
pgoff_t pgoff;
/*
* vm_pgoff is in PAGE_SIZE units, henc... | 0 | [
"CWE-399"
] | linux | 90481622d75715bfcb68501280a917dbfe516029 | 223,832,971,820,663,060,000,000,000,000,000,000,000 | 44 | hugepages: fix use after free bug in "quota" handling
hugetlbfs_{get,put}_quota() are badly named. They don't interact with the
general quota handling code, and they don't much resemble its behaviour.
Rather than being about maintaining limits on on-disk block usage by
particular users, they are instead about maintai... |
static int p54u_init_urbs(struct ieee80211_hw *dev)
{
struct p54u_priv *priv = dev->priv;
struct urb *entry = NULL;
struct sk_buff *skb;
struct p54u_rx_info *info;
int ret = 0;
while (skb_queue_len(&priv->rx_queue) < 32) {
skb = __dev_alloc_skb(priv->common.rx_mtu + 32, GFP_KERNEL);
if (!skb) {
ret = -ENO... | 0 | [
"CWE-416"
] | linux | 6e41e2257f1094acc37618bf6c856115374c6922 | 279,441,503,297,768,480,000,000,000,000,000,000,000 | 48 | p54usb: Fix race between disconnect and firmware loading
The syzbot fuzzer found a bug in the p54 USB wireless driver. The
issue involves a race between disconnect and the firmware-loader
callback routine, and it has several aspects.
One big problem is that when the firmware can't be loaded, the
callback routine tri... |
ves_icall_System_Reflection_Module_ResolveStringToken (MonoImage *image, guint32 token, MonoResolveTokenError *error)
{
int index = mono_metadata_token_index (token);
*error = ResolveTokenError_Other;
/* Validate token */
if (mono_metadata_token_code (token) != MONO_TOKEN_STRING) {
*error = ResolveTokenError_Ba... | 0 | [
"CWE-264"
] | mono | 035c8587c0d8d307e45f1b7171a0d337bb451f1e | 282,301,872,817,051,530,000,000,000,000,000,000,000 | 24 | Allow only primitive types/enums in RuntimeHelpers.InitializeArray (). |
static int geneve_fill_metadata_dst(struct net_device *dev, struct sk_buff *skb)
{
struct ip_tunnel_info *info = skb_tunnel_info(skb);
struct geneve_dev *geneve = netdev_priv(dev);
if (ip_tunnel_info_af(info) == AF_INET) {
struct rtable *rt;
struct flowi4 fl4;
struct geneve_sock *gs4 = rcu_dereference(geneve-... | 0 | [] | net | 6c8991f41546c3c472503dff1ea9daaddf9331c2 | 273,291,428,102,351,550,000,000,000,000,000,000,000 | 38 | net: ipv6_stub: use ip6_dst_lookup_flow instead of ip6_dst_lookup
ipv6_stub uses the ip6_dst_lookup function to allow other modules to
perform IPv6 lookups. However, this function skips the XFRM layer
entirely.
All users of ipv6_stub->ip6_dst_lookup use ip_route_output_flow (via the
ip_route_output_key and ip_route_o... |
static void CloseTags( GooString *htext, bool &finish_a, bool &finish_italic, bool &finish_bold )
{
const char *last_italic = finish_italic && ( finish_bold || finish_a ) ? strrstr( htext->c_str(), "<i>" ) : nullptr;
const char *last_bold = finish_bold && ( finish_italic || finish_a ) ? strrstr( htext->... | 0 | [
"CWE-824"
] | poppler | 30c731b487190c02afff3f036736a392eb60cd9a | 150,533,060,577,961,090,000,000,000,000,000,000,000 | 20 | Properly initialize HtmlOutputDev::page to avoid SIGSEGV upon error exit.
Closes #742 |
e1000_receive_iov(NetClientState *nc, const struct iovec *iov, int iovcnt)
{
E1000State *s = qemu_get_nic_opaque(nc);
PCIDevice *d = PCI_DEVICE(s);
struct e1000_rx_desc desc;
dma_addr_t base;
unsigned int n, rdt;
uint32_t rdh_start;
uint16_t vlan_special = 0;
uint8_t vlan_status = 0;
... | 0 | [
"CWE-835"
] | qemu | 1caff0340f49c93d535c6558a5138d20d475315c | 91,230,174,143,866,340,000,000,000,000,000,000,000 | 142 | e1000: switch to use qemu_receive_packet() for loopback
This patch switches to use qemu_receive_packet() which can detect
reentrancy and return early.
This is intended to address CVE-2021-3416.
Cc: Prasad J Pandit <ppandit@redhat.com>
Cc: qemu-stable@nongnu.org
Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>... |
dissect_kafka_create_acls_response(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, int offset,
kafka_api_version_t api_version)
{
proto_item *subti;
proto_tree *subtree;
offset = dissect_kafka_throttle_time(tvb, pinfo, tree, offset);
subtree = proto_tree_a... | 0 | [
"CWE-401"
] | wireshark | f4374967bbf9c12746b8ec3cd54dddada9dd353e | 327,377,622,712,523,500,000,000,000,000,000,000,000 | 21 | Kafka: Limit our decompression size.
Don't assume that the Internet has our best interests at heart when it
gives us the size of our decompression buffer. Assign an arbitrary limit
of 50 MB.
This fixes #16739 in that it takes care of
** (process:17681): WARNING **: 20:03:07.440: Dissector bug, protocol Kafka, in pac... |
static void put_amf_double(AVIOContext *pb, double d)
{
avio_w8(pb, AMF_DATA_TYPE_NUMBER);
avio_wb64(pb, av_double2int(d));
} | 0 | [
"CWE-617",
"CWE-703"
] | FFmpeg | 6b67d7f05918f7a1ee8fc6ff21355d7e8736aa10 | 85,532,454,452,821,690,000,000,000,000,000,000,000 | 5 | avformat/flvenc: Check audio packet size
Fixes: Assertion failure
Fixes: assert_flvenc.c:941_1.swf
Found-by: #CHEN HONGXU# <HCHEN017@e.ntu.edu.sg>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc> |
static int server_mpvio_read_packet(MYSQL_PLUGIN_VIO *param, uchar **buf)
{
MPVIO_EXT *mpvio= (MPVIO_EXT *) param;
ulong pkt_len;
DBUG_ENTER("server_mpvio_read_packet");
if (mpvio->packets_written == 0)
{
/*
plugin wants to read the data without sending anything first.
send an empty packet to... | 0 | [] | mysql-server | 25d1b7e03b9b375a243fabdf0556c063c7282361 | 310,025,191,180,754,360,000,000,000,000,000,000,000 | 88 | Bug #22722946: integer overflow may lead to wrong results in get_56_lenc_string |
full_path_write (const struct url *url, char *where)
{
#define FROB(el, chr) do { \
char *f_el = url->el; \
if (f_el) { \
int l = strlen (f_el); \
*where++ = chr; \
memcpy (whe... | 0 | [] | wget | 59b920874daa565a1323ffa1e756e80493190686 | 32,967,083,017,631,290,000,000,000,000,000,000,000 | 18 | Support non-ASCII URLs
* src/url.c [HAVE_ICONV]: Include iconv.h and langinfo.h.
(convert_fname): New function.
[HAVE_ICONV]: Convert file name from remote encoding to local
encoding.
(url_file_name): Call convert_fname.
(filechr_table): Don't consider bytes in 128..159 as control
characters.
* tests/Test-ftp-iri.px:... |
yaml_parser_fetch_anchor(yaml_parser_t *parser, yaml_token_type_t type)
{
yaml_token_t token;
/* An anchor or an alias could be a simple key. */
if (!yaml_parser_save_simple_key(parser))
return 0;
/* A simple key cannot follow an anchor or an alias. */
parser->simple_key_allowed = 0;
... | 0 | [
"CWE-20"
] | libyaml | e6aa721cc0e5a48f408c52355559fd36780ba32a | 235,016,834,471,081,000,000,000,000,000,000,000,000 | 24 | Fix for https://bitbucket.org/xi/libyaml/issue/10/
https://bitbucket.org/xi/libyaml/issue/10/wrapped-strings-cause-assert-failure
Commenting out the assert makes the scanner do the right thing and
results in just a simple parse failure. |
void CLASS parseFujiMakernotes(unsigned tag, unsigned type, unsigned len, unsigned dng_writer)
{
if ((dng_writer == nonDNG) && (tag == 0x0010)) {
char FujiSerial[sizeof(imgdata.shootinginfo.InternalBodySerial)];
char *words[4];
char yy[2], mm[3], dd[3], ystr[16], ynum[16];
int year, nwords, ynum_len;
... | 0 | [
"CWE-703",
"CWE-835"
] | LibRaw | e47384546b43d0fd536e933249047bc397a4d88b | 146,122,755,635,945,490,000,000,000,000,000,000,000 | 137 | Secunia Advisory SA83050: possible infinite loop in parse_minolta() |
PHP_FUNCTION(filter_var)
{
long filter = FILTER_DEFAULT;
zval **filter_args = NULL, *data;
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "z/|lZ", &data, &filter, &filter_args) == FAILURE) {
return;
}
if (!PHP_FILTER_ID_EXISTS(filter)) {
RETURN_FALSE;
}
MAKE_COPY_ZVAL(&data, return_value);
php_fil... | 0 | [
"CWE-190"
] | php-src | a5b5743d71fbd5ae944469a1ca443a1cdb30663a | 183,970,898,517,155,970,000,000,000,000,000,000,000 | 17 | full_special_chars filter from trunk - approved by johannes |
static int ieee80211_testmode_cmd(struct wiphy *wiphy,
struct wireless_dev *wdev,
void *data, int len)
{
struct ieee80211_local *local = wiphy_priv(wiphy);
struct ieee80211_vif *vif = NULL;
if (!local->ops->testmode_cmd)
return -EOPNOTSUPP;
if (wdev) {
struct ieee80211_sub_if_data *sdata;
sdata... | 0 | [
"CWE-287"
] | linux | 3e493173b7841259a08c5c8e5cbe90adb349da7e | 70,452,894,110,651,420,000,000,000,000,000,000,000 | 20 | mac80211: Do not send Layer 2 Update frame before authorization
The Layer 2 Update frame is used to update bridges when a station roams
to another AP even if that STA does not transmit any frames after the
reassociation. This behavior was described in IEEE Std 802.11F-2003 as
something that would happen based on MLME-... |
int main(int argc, char *argv[])
{
int i, num4bf = 5;
#ifdef _WIN32
srand((unsigned int)time(NULL));
#endif
if (argc > 1) {
for (i = 1; i < argc; i++) {
if (!strcasecmp(argv[i], "-yuv")) doYUV = 1;
else if (!strcasecmp(argv[i], "-noyuvpad")) pad = 1;
else if (!strcasecmp(argv[i], "-alloc"))... | 1 | [
"CWE-787"
] | libjpeg-turbo | 2a9e3bd7430cfda1bc812d139e0609c6aca0b884 | 199,337,700,204,898,520,000,000,000,000,000,000,000 | 45 | TurboJPEG: Properly handle gigapixel images
Prevent several integer overflow issues and subsequent segfaults that
occurred when attempting to compress or decompress gigapixel images with
the TurboJPEG API:
- Modify tjBufSize(), tjBufSizeYUV2(), and tjPlaneSizeYUV() to avoid
integer overflow when computing the retur... |
static bool check_service_path(GDBusProxy *proxy,
struct external_service *service)
{
const char *service_path;
if (!parse_path(proxy, "Service", &service_path))
return false;
return g_strcmp0(service_path, service->path) == 0;
} | 0 | [
"CWE-416"
] | bluez | 838c0dc7641e1c991c0f3027bf94bee4606012f8 | 250,238,380,818,014,560,000,000,000,000,000,000,000 | 10 | gatt: Fix not cleaning up when disconnected
There is a current use after free possible on a gatt server if a client
disconnects while a WriteValue call is being processed with dbus.
This patch includes the addition of a pending disconnect callback to handle
cleanup better if a disconnect occurs during a write, an acq... |
png_set_option(png_structrp png_ptr, int option, int onoff)
{
if (png_ptr != NULL && option >= 0 && option < PNG_OPTION_NEXT &&
(option & 1) == 0)
{
int mask = 3 << option;
int setting = (2 + (onoff != 0)) << option;
int current = png_ptr->options;
png_ptr->options = (png_byte)(((cu... | 0 | [
"CWE-476"
] | libpng | 812768d7a9c973452222d454634496b25ed415eb | 25,673,858,235,629,044,000,000,000,000,000,000,000 | 16 | [libpng16] Fixed a potential null pointer dereference in png_set_text_2()
(bug report and patch by Patrick Keshishian). |
void ConnectionManagerImpl::ActiveStream::decodeTrailers(ActiveStreamDecoderFilter* filter,
HeaderMap& trailers) {
// If we previously decided to decode only the headers, do nothing here.
if (decoding_headers_only_) {
return;
}
// See decodeData() ab... | 0 | [
"CWE-400",
"CWE-703"
] | envoy | afc39bea36fd436e54262f150c009e8d72db5014 | 241,795,271,758,415,850,000,000,000,000,000,000,000 | 39 | 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 int hugetlbfs_migrate_page(struct address_space *mapping,
struct page *newpage, struct page *page,
enum migrate_mode mode)
{
int rc;
rc = migrate_huge_page_move_mapping(mapping, newpage, page);
if (rc)
return rc;
migrate_page_copy(newpage, page);
return 0;
} | 0 | [
"CWE-399"
] | linux | 90481622d75715bfcb68501280a917dbfe516029 | 73,221,856,591,877,890,000,000,000,000,000,000,000 | 13 | hugepages: fix use after free bug in "quota" handling
hugetlbfs_{get,put}_quota() are badly named. They don't interact with the
general quota handling code, and they don't much resemble its behaviour.
Rather than being about maintaining limits on on-disk block usage by
particular users, they are instead about maintai... |
static int __init ip6_tables_init(void)
{
int ret;
ret = register_pernet_subsys(&ip6_tables_net_ops);
if (ret < 0)
goto err1;
/* Noone else will be downing sem now, so we won't sleep */
ret = xt_register_targets(ip6t_builtin_tg, ARRAY_SIZE(ip6t_builtin_tg));
if (ret < 0)
goto err2;
ret = xt_register_matche... | 0 | [
"CWE-200"
] | linux-2.6 | 6a8ab060779779de8aea92ce3337ca348f973f54 | 101,763,713,712,331,560,000,000,000,000,000,000,000 | 33 | ipv6: netfilter: ip6_tables: fix infoleak to userspace
Structures ip6t_replace, compat_ip6t_replace, and xt_get_revision are
copied from userspace. Fields of these structs that are
zero-terminated strings are not checked. When they are used as argument
to a format string containing "%s" in request_module(), some sen... |
CImg<T> get_rol(const CImg<t>& img) const {
return (+*this).rol(img);
} | 0 | [
"CWE-770"
] | cimg | 619cb58dd90b4e03ac68286c70ed98acbefd1c90 | 230,653,627,298,718,100,000,000,000,000,000,000,000 | 3 | CImg<>::load_bmp() and CImg<>::load_pandore(): Check that dimensions encoded in file does not exceed file size. |
dissect_DEVMODE(tvbuff_t *tvb, int offset, packet_info *pinfo,
proto_tree *tree, dcerpc_info *di, guint8 *drep)
{
proto_item *item;
proto_tree *subtree;
guint16 driver_extra;
gint16 print_quality;
guint32 fields;
int struct_start = offset;
if (di->conformant_run)
return offset;
subtree = proto_tree_ad... | 0 | [
"CWE-399"
] | wireshark | b4d16b4495b732888e12baf5b8a7e9bf2665e22b | 27,824,040,520,233,848,000,000,000,000,000,000,000 | 175 | SPOOLSS: Try to avoid an infinite loop.
Use tvb_reported_length_remaining in dissect_spoolss_uint16uni. Make
sure our offset always increments in dissect_spoolss_keybuffer.
Change-Id: I7017c9685bb2fa27161d80a03b8fca4ef630e793
Reviewed-on: https://code.wireshark.org/review/14687
Reviewed-by: Gerald Combs <gerald@wires... |
static inline uint32_t vmsvga_fifo_read_raw(struct vmsvga_state_s *s)
{
uint32_t cmd = s->fifo[s->fifo_stop >> 2];
s->fifo_stop += 4;
if (s->fifo_stop >= s->fifo_max) {
s->fifo_stop = s->fifo_min;
}
s->fifo[SVGA_FIFO_STOP] = cpu_to_le32(s->fifo_stop);
return cmd;
} | 0 | [] | qemu | fa892e9abb728e76afcf27323ab29c57fb0fe7aa | 195,920,648,174,254,200,000,000,000,000,000,000,000 | 11 | ui/cursor: fix integer overflow in cursor_alloc (CVE-2021-4206)
Prevent potential integer overflow by limiting 'width' and 'height' to
512x512. Also change 'datasize' type to size_t. Refer to security
advisory https://starlabs.sg/advisories/22-4206/ for more information.
Fixes: CVE-2021-4206
Signed-off-by: Mauro Matt... |
static int __vsock_bind_stream(struct vsock_sock *vsk,
struct sockaddr_vm *addr)
{
static u32 port;
struct sockaddr_vm new_addr;
if (!port)
port = LAST_RESERVED_PORT + 1 +
prandom_u32_max(U32_MAX - LAST_RESERVED_PORT);
vsock_addr_init(&new_addr, addr->svm_cid, addr->svm_port);
if (addr->svm_port ... | 0 | [
"CWE-667"
] | linux | c518adafa39f37858697ac9309c6cf1805581446 | 77,478,694,733,632,050,000,000,000,000,000,000,000 | 54 | vsock: fix the race conditions in multi-transport support
There are multiple similar bugs implicitly introduced by the
commit c0cfa2d8a788fcf4 ("vsock: add multi-transports support") and
commit 6a2c0962105ae8ce ("vsock: prevent transport modules unloading").
The bug pattern:
[1] vsock_sock.transport pointer is copie... |
static bool page_address_valid(struct kvm_vcpu *vcpu, gpa_t gpa)
{
return PAGE_ALIGNED(gpa) && !(gpa >> cpuid_maxphyaddr(vcpu));
} | 0 | [
"CWE-284"
] | linux | 727ba748e110b4de50d142edca9d6a9b7e6111d8 | 235,797,365,023,443,820,000,000,000,000,000,000,000 | 4 | 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... |
static void __net_exit ovs_exit_net(struct net *net)
{
struct datapath *dp, *dp_next;
struct ovs_net *ovs_net = net_generic(net, ovs_net_id);
ovs_lock();
list_for_each_entry_safe(dp, dp_next, &ovs_net->dps, list_node)
__dp_destroy(dp);
ovs_unlock();
cancel_work_sync(&ovs_net->dp_notify_work);
} | 0 | [
"CWE-416"
] | net | 36d5fe6a000790f56039afe26834265db0a3ad4c | 288,711,969,848,933,380,000,000,000,000,000,000,000 | 12 | core, nfqueue, openvswitch: Orphan frags in skb_zerocopy and handle errors
skb_zerocopy can copy elements of the frags array between skbs, but it doesn't
orphan them. Also, it doesn't handle errors, so this patch takes care of that
as well, and modify the callers accordingly. skb_tx_error() is also added to
the caller... |
COND *Item_func::build_equal_items(THD *thd, COND_EQUAL *inherited,
bool link_item_fields,
COND_EQUAL **cond_equal_ref)
{
/*
For each field reference in cond, not from equal item predicates,
set a pointer to the multiple equality it belong... | 0 | [] | server | ff77a09bda884fe6bf3917eb29b9d3a2f53f919b | 190,689,693,721,988,000,000,000,000,000,000,000,000 | 16 | MDEV-22464 Server crash on UPDATE with nested subquery
Uninitialized ref_pointer_array[] because setup_fields() got empty
fields list. mysql_multi_update() for some reason does that by
substituting the fields list with empty total_list for the
mysql_select() call (looks like wrong merge since total_list is not
used a... |
PHP_MSHUTDOWN_FUNCTION(curl)
{
#ifdef PHP_CURL_URL_WRAPPERS
php_unregister_url_stream_wrapper("http" TSRMLS_CC);
php_unregister_url_stream_wrapper("https" TSRMLS_CC);
php_unregister_url_stream_wrapper("ftp" TSRMLS_CC);
php_unregister_url_stream_wrapper("ldap" TSRMLS_CC);
#endif
curl_global_cleanup();
#ifdef PHP_CU... | 0 | [] | php-src | 0ea75af9be8a40836951fc89f723dd5390b8b46f | 80,040,938,739,960,200,000,000,000,000,000,000,000 | 27 | Fixed bug #69316 (Use-after-free in php_curl related to CURLOPT_FILE/_INFILE/_WRITEHEADER) |
static void unlock_fdc(void)
{
if (!test_bit(0, &fdc_busy))
DPRINT("FDC access conflict!\n");
raw_cmd = NULL;
command_status = FD_COMMAND_NONE;
cancel_delayed_work(&fd_timeout);
do_floppy = NULL;
cont = NULL;
clear_bit(0, &fdc_busy);
wake_up(&fdc_wait);
} | 0 | [
"CWE-264",
"CWE-754"
] | linux | ef87dbe7614341c2e7bfe8d32fcb7028cc97442c | 141,425,856,750,568,090,000,000,000,000,000,000,000 | 13 | floppy: ignore kernel-only members in FDRAWCMD ioctl input
Always clear out these floppy_raw_cmd struct members after copying the
entire structure from userspace so that the in-kernel version is always
valid and never left in an interdeterminate state.
Signed-off-by: Matthew Daley <mattd@bugfuzz.com>
Signed-off-by: L... |
static int io_provide_buffers(struct io_kiocb *req, unsigned int issue_flags)
{
struct io_provide_buf *p = &req->pbuf;
struct io_ring_ctx *ctx = req->ctx;
struct io_buffer_list *bl;
int ret = 0;
bool needs_lock = issue_flags & IO_URING_F_UNLOCKED;
io_ring_submit_lock(ctx, needs_lock);
lockdep_assert_held(&ctx-... | 0 | [
"CWE-416"
] | linux | e677edbcabee849bfdd43f1602bccbecf736a646 | 118,276,912,615,882,290,000,000,000,000,000,000,000 | 31 | io_uring: fix race between timeout flush and removal
io_flush_timeouts() assumes the timeout isn't in progress of triggering
or being removed/canceled, so it unconditionally removes it from the
timeout list and attempts to cancel it.
Leave it on the list and let the normal timeout cancelation take care
of it.
Cc: st... |
static struct buffer_head *ext4_append(handle_t *handle,
struct inode *inode,
ext4_lblk_t *block)
{
struct buffer_head *bh;
int err;
if (unlikely(EXT4_SB(inode->i_sb)->s_max_dir_size_kb &&
((inode->i_size >> 10) >=
EXT4_SB(inode->i_sb)->s_max_dir_size_kb)))
return ERR_PTR(-ENOSPC);
*blo... | 0 | [
"CWE-125"
] | linux | 5872331b3d91820e14716632ebb56b1399b34fe1 | 335,555,794,053,873,430,000,000,000,000,000,000,000 | 28 | ext4: fix potential negative array index in do_split()
If for any reason a directory passed to do_split() does not have enough
active entries to exceed half the size of the block, we can end up
iterating over all "count" entries without finding a split point.
In this case, count == move, and split will be zero, and w... |
sg_alloc(struct gendisk *disk, struct scsi_device *scsidp)
{
struct request_queue *q = scsidp->request_queue;
Sg_device *sdp;
unsigned long iflags;
int error;
u32 k;
sdp = kzalloc(sizeof(Sg_device), GFP_KERNEL);
if (!sdp) {
sdev_printk(KERN_WARNING, scsidp, "%s: kmalloc Sg_device "
"failure\n", __func_... | 0 | [
"CWE-190",
"CWE-189"
] | linux | fdc81f45e9f57858da6351836507fbcf1b7583ee | 233,000,759,049,976,540,000,000,000,000,000,000,000 | 60 | sg_start_req(): use import_iovec()
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> |
stbi_inline static unsigned int stbi__zreceive(stbi__zbuf *z, int n)
{
unsigned int k;
if (z->num_bits < n) stbi__fill_bits(z);
k = z->code_buffer & ((1 << n) - 1);
z->code_buffer >>= n;
z->num_bits -= n;
return k;
} | 0 | [
"CWE-787"
] | stb | 5ba0baaa269b3fd681828e0e3b3ac0f1472eaf40 | 168,374,040,932,237,780,000,000,000,000,000,000,000 | 9 | stb_image: Reject fractional JPEG component subsampling ratios
The component resamplers are not written to support this and I've
never seen it happen in a real (non-crafted) JPEG file so I'm
fine rejecting this as outright corrupt.
Fixes issue #1178. |
flatpak_dir_mark_changed (FlatpakDir *self,
GError **error)
{
g_autoptr(GFile) changed_file = NULL;
g_autofree char * changed_path = NULL;
changed_file = flatpak_dir_get_changed_path (self);
changed_path = g_file_get_path (changed_file);
if (!g_utime (changed_path, NULL))
re... | 0 | [
"CWE-668"
] | flatpak | cd2142888fc4c199723a0dfca1f15ea8788a5483 | 120,094,833,131,713,280,000,000,000,000,000,000,000 | 21 | Don't expose /proc when running apply_extra
As shown by CVE-2019-5736, it is sometimes possible for the sandbox
app to access outside files using /proc/self/exe. This is not
typically an issue for flatpak as the sandbox runs as the user which
has no permissions to e.g. modify the host files.
However, when installing ... |
const SeekHead::VoidElement* SeekHead::GetVoidElement(int idx) const {
if (idx < 0)
return 0;
if (idx >= m_void_element_count)
return 0;
return m_void_elements + idx;
} | 0 | [
"CWE-20"
] | libvpx | 34d54b04e98dd0bac32e9aab0fbda0bf501bc742 | 68,337,234,817,725,630,000,000,000,000,000,000,000 | 9 | update libwebm to libwebm-1.0.0.27-358-gdbf1d10
changelog:
https://chromium.googlesource.com/webm/libwebm/+log/libwebm-1.0.0.27-351-g9f23fbc..libwebm-1.0.0.27-358-gdbf1d10
Change-Id: I28a6b3ae02a53fb1f2029eee11e9449afb94c8e3 |
static int nvme_addr_write(NvmeCtrl *n, hwaddr addr, void *buf, int size)
{
hwaddr hi = addr + size - 1;
if (hi < addr) {
return 1;
}
if (n->bar.cmbsz && nvme_addr_is_cmb(n, addr) && nvme_addr_is_cmb(n, hi)) {
memcpy(nvme_addr_to_cmb(n, addr), buf, size);
return 0;
}
if... | 0 | [] | qemu | 736b01642d85be832385063f278fe7cd4ffb5221 | 110,182,171,504,810,200,000,000,000,000,000,000,000 | 19 | hw/nvme: fix CVE-2021-3929
This fixes CVE-2021-3929 "locally" by denying DMA to the iomem of the
device itself. This still allows DMA to MMIO regions of other devices
(e.g. doing P2P DMA to the controller memory buffer of another NVMe
device).
Fixes: CVE-2021-3929
Reported-by: Qiuhao Li <Qiuhao.Li@outlook.com>
Review... |
static void vmx_queue_exception(struct kvm_vcpu *vcpu, unsigned nr,
bool has_error_code, u32 error_code)
{
struct vcpu_vmx *vmx = to_vmx(vcpu);
u32 intr_info = nr | INTR_INFO_VALID_MASK;
if (has_error_code) {
vmcs_write32(VM_ENTRY_EXCEPTION_ERROR_CODE, error_code);
intr_info |= INTR_INFO_DELIVER_CODE_MASK;
... | 0 | [
"CWE-20"
] | linux-2.6 | 16175a796d061833aacfbd9672235f2d2725df65 | 194,507,345,523,284,350,000,000,000,000,000,000,000 | 32 | KVM: VMX: Don't allow uninhibited access to EFER on i386
vmx_set_msr() does not allow i386 guests to touch EFER, but they can still
do so through the default: label in the switch. If they set EFER_LME, they
can oops the host.
Fix by having EFER access through the normal channel (which will check for
EFER_LME) even o... |
static void __exit esp6_fini(void)
{
if (inet6_del_protocol(&esp6_protocol, IPPROTO_ESP) < 0)
printk(KERN_INFO "ipv6 esp close: can't remove protocol\n");
if (xfrm_unregister_type(&esp6_type, AF_INET6) < 0)
printk(KERN_INFO "ipv6 esp close: can't remove xfrm type\n");
} | 0 | [
"CWE-16"
] | linux-2.6 | 920fc941a9617f95ccb283037fe6f8a38d95bb69 | 233,015,870,800,650,370,000,000,000,000,000,000,000 | 7 | [ESP]: Ensure IV is in linear part of the skb to avoid BUG() due to OOB access
ESP does not account for the IV size when calling pskb_may_pull() to
ensure everything it accesses directly is within the linear part of a
potential fragment. This results in a BUG() being triggered when the
both the IPv4 and IPv6 ESP stack... |
static void _php_image_output(INTERNAL_FUNCTION_PARAMETERS, int image_type, char *tn, void (*func_p)())
{
zval *imgind;
char *file = NULL;
long quality = 0, type = 0;
gdImagePtr im;
char *fn = NULL;
FILE *fp;
int file_len = 0, argc = ZEND_NUM_ARGS();
int q = -1, i, t = 1;
/* The quality parameter for Wbmp sta... | 0 | [
"CWE-703",
"CWE-189"
] | php-src | 2938329ce19cb8c4197dec146c3ec887c6f61d01 | 10,116,163,344,802,622,000,000,000,000,000,000,000 | 148 | Fixed bug #66356 (Heap Overflow Vulnerability in imagecrop())
And also fixed the bug: arguments are altered after some calls |
static int io_linkat_prep(struct io_kiocb *req,
const struct io_uring_sqe *sqe)
{
struct io_hardlink *lnk = &req->hardlink;
const char __user *oldf, *newf;
if (sqe->rw_flags || sqe->buf_index || sqe->splice_fd_in)
return -EINVAL;
if (unlikely(req->flags & REQ_F_FIXED_FILE))
return -EBADF;
lnk->old_dfd... | 0 | [
"CWE-416"
] | linux | 9cae36a094e7e9d6e5fe8b6dcd4642138b3eb0c7 | 175,809,640,621,028,200,000,000,000,000,000,000,000 | 30 | io_uring: reinstate the inflight tracking
After some debugging, it was realized that we really do still need the
old inflight tracking for any file type that has io_uring_fops assigned.
If we don't, then trivial circular references will mean that we never get
the ctx cleaned up and hence it'll leak.
Just bring back t... |
static Image *ReadSUNImage(const ImageInfo *image_info,ExceptionInfo *exception)
{
#define RMT_EQUAL_RGB 1
#define RMT_NONE 0
#define RMT_RAW 2
#define RT_STANDARD 1
#define RT_ENCODED 2
#define RT_FORMAT_RGB 3
typedef struct _SUNInfo
{
unsigned int
magic,
width,
height,
depth,
... | 0 | [
"CWE-401"
] | ImageMagick6 | 210474b2fac6a661bfa7ed563213920e93e76395 | 290,686,165,939,084,430,000,000,000,000,000,000,000 | 442 | Fix ultra rare but potential memory-leak |
bool CClient::PutClientRaw(const CString& sLine) {
CString sCopy = sLine;
bool bReturn = false;
NETWORKMODULECALL(OnSendToClient(sCopy, *this), m_pUser, m_pNetwork, this,
&bReturn);
if (bReturn) return false;
DEBUG("(" << GetFullName() << ") ZNC -> CLI ["
<< CDebug::Fi... | 0 | [
"CWE-476"
] | znc | 2390ad111bde16a78c98ac44572090b33c3bd2d8 | 309,878,425,904,325,770,000,000,000,000,000,000,000 | 12 | Fix null pointer dereference in echo-message
The bug was introduced while fixing #1705. If a client did not enable
echo-message, and doesn't have a network, it crashes.
Thanks to LunarBNC for reporting this |
null_in_flight (struct rw *rw, uintptr_t index)
{
return 0;
} | 0 | [
"CWE-252"
] | libnbd | 8d444b41d09a700c7ee6f9182a649f3f2d325abb | 33,914,664,455,653,583,000,000,000,000,000,000,000 | 4 | copy: CVE-2022-0485: Fail nbdcopy if NBD read or write fails
nbdcopy has a nasty bug when performing multi-threaded copies using
asynchronous nbd calls - it was blindly treating the completion of an
asynchronous command as successful, rather than checking the *error
parameter. This can result in the silent creation o... |
static unsigned char *get_params(unsigned char *p, int *param, int *len)
{
int n;
*len = 0;
while (*p != '\0') {
while (*p == ' ' || *p == '\t') {
p++;
}
if (isdigit((int) ((unsigned char) *p))) {
for (n = 0; isdigit((int) ((unsigned char) *p)); p++) {
... | 0 | [
"CWE-399",
"CWE-401"
] | ImageMagick | 748a03651e5b138bcaf160d15133de2f4b1b89ce | 113,248,177,769,510,100,000,000,000,000,000,000,000 | 32 | https://github.com/ImageMagick/ImageMagick/issues/1452 |
static int mod_detach (void *arg)
{
eap_pwd_t *inst;
inst = (eap_pwd_t *) arg;
return 0;
} | 0 | [
"CWE-662"
] | freeradius-server | 6b522f8780813726799e6b8cf0f1f8e0ce2c8ebf | 258,033,824,424,575,400,000,000,000,000,000,000,000 | 8 | EAP-pwd: fix DoS due to multithreaded BN_CTX access
The EAP-pwd module created one global OpenSSL BN_CTX instance, and
used this instance in all incoming requests. This means that different
threads used the same BN_CTX instance, which can result in a crash.
An adversary can trigger these crashes by concurrently initia... |
sg_new_write(Sg_fd *sfp, struct file *file, const char __user *buf,
size_t count, int blocking, int read_only, int sg_io_owned,
Sg_request **o_srp)
{
int k;
Sg_request *srp;
sg_io_hdr_t *hp;
unsigned char cmnd[SG_MAX_CDB_SIZE];
int timeout;
unsigned long ul_timeout;
if (count < SZ_SG_IO_HDR)
return -EIN... | 0 | [
"CWE-200"
] | linux | 3e0097499839e0fe3af380410eababe5a47c4cf9 | 262,527,313,177,645,300,000,000,000,000,000,000,000 | 71 | scsi: sg: fixup infoleak when using SG_GET_REQUEST_TABLE
When calling SG_GET_REQUEST_TABLE ioctl only a half-filled table is
returned; the remaining part will then contain stale kernel memory
information. This patch zeroes out the entire table to avoid this
issue.
Signed-off-by: Hannes Reinecke <hare@suse.com>
Revie... |
f_tempname(typval_T *argvars UNUSED, typval_T *rettv)
{
static int x = 'A';
rettv->v_type = VAR_STRING;
rettv->vval.v_string = vim_tempname(x, FALSE);
// Advance 'x' to use A-Z and 0-9, so that there are at least 34 different
// names. Skip 'I' and 'O', they are used for shell redirection.
do... | 0 | [
"CWE-823",
"CWE-703"
] | vim | 5921aeb5741fc6e84c870d68c7c35b93ad0c9f87 | 229,738,439,691,341,000,000,000,000,000,000,000,000 | 19 | patch 8.2.4418: crash when using special multi-byte character
Problem: Crash when using special multi-byte character.
Solution: Don't use isalpha() for an arbitrary character. |
static struct urb *uas_alloc_cmd_urb(struct uas_dev_info *devinfo, gfp_t gfp,
struct scsi_cmnd *cmnd)
{
struct usb_device *udev = devinfo->udev;
struct scsi_device *sdev = cmnd->device;
struct uas_cmd_info *cmdinfo = (void *)&cmnd->SCp;
struct urb *urb = usb_alloc_urb(0, gfp);
struct command_iu *iu;
int len;... | 0 | [
"CWE-125"
] | linux | 786de92b3cb26012d3d0f00ee37adf14527f35c4 | 250,822,622,712,389,030,000,000,000,000,000,000,000 | 37 | USB: uas: fix bug in handling of alternate settings
The uas driver has a subtle bug in the way it handles alternate
settings. The uas_find_uas_alt_setting() routine returns an
altsetting value (the bAlternateSetting number in the descriptor), but
uas_use_uas_driver() then treats that value as an index to the
intf->al... |
int git_index_conflict_get(
const git_index_entry **ancestor_out,
const git_index_entry **our_out,
const git_index_entry **their_out,
git_index *index,
const char *path)
{
size_t pos;
int len = 0;
assert(ancestor_out && our_out && their_out && index && path);
*ancestor_out = NULL;
*our_out = NULL;
*their_o... | 0 | [
"CWE-415",
"CWE-190"
] | libgit2 | 3db1af1f370295ad5355b8f64b865a2a357bcac0 | 11,065,233,869,167,875,000,000,000,000,000,000,000 | 27 | index: error out on unreasonable prefix-compressed path lengths
When computing the complete path length from the encoded
prefix-compressed path, we end up just allocating the complete path
without ever checking what the encoded path length actually is. This can
easily lead to a denial of service by just encoding an un... |
void tcp_synack_rtt_meas(struct sock *sk, struct request_sock *req)
{
long rtt_us = -1L;
if (req && !req->num_retrans && tcp_rsk(req)->snt_synack.v64) {
struct skb_mstamp now;
skb_mstamp_get(&now);
rtt_us = skb_mstamp_us_delta(&now, &tcp_rsk(req)->snt_synack);
}
tcp_ack_update_rtt(sk, FLAG_SYN_ACKED, rtt_u... | 0 | [
"CWE-703",
"CWE-189"
] | linux | 8b8a321ff72c785ed5e8b4cf6eda20b35d427390 | 99,820,445,458,584,140,000,000,000,000,000,000,000 | 13 | tcp: fix zero cwnd in tcp_cwnd_reduction
Patch 3759824da87b ("tcp: PRR uses CRB mode by default and SS mode
conditionally") introduced a bug that cwnd may become 0 when both
inflight and sndcnt are 0 (cwnd = inflight + sndcnt). This may lead
to a div-by-zero if the connection starts another cwnd reduction
phase by set... |
com_status(String *buffer __attribute__((unused)),
char *line __attribute__((unused)))
{
const char *status_str;
char buff[40];
ulonglong id;
MYSQL_RES *result;
LINT_INIT(result);
if (mysql_real_query_for_lazy(
C_STRING_WITH_LEN("select DATABASE(), USER() limit 1")))
return 0;
tee_puts("... | 0 | [
"CWE-295"
] | mysql-server | b3e9211e48a3fb586e88b0270a175d2348935424 | 163,761,938,388,146,180,000,000,000,000,000,000,000 | 123 | WL#9072: Backport WL#8785 to 5.5 |
static int hfsplus_fill_cat_thread(struct super_block *sb,
hfsplus_cat_entry *entry, int type,
u32 parentid, struct qstr *str)
{
entry->type = cpu_to_be16(type);
entry->thread.reserved = 0;
entry->thread.parentID = cpu_to_be32(parentid);
hfsplus_asc2uni(sb, &entry->thread.nodeName, str->name, str->len... | 0 | [
"CWE-119"
] | linux-2.6 | efc7ffcb4237f8cb9938909041c4ed38f6e1bf40 | 281,449,374,081,262,570,000,000,000,000,000,000,000 | 10 | hfsplus: fix Buffer overflow with a corrupted image
When an hfsplus image gets corrupted it might happen that the catalog
namelength field gets b0rked. If we mount such an image the memcpy() in
hfsplus_cat_build_key_uni() writes more than the 255 that fit in the name
field. Depending on the size of the overwritten d... |
TEST_F(OptimizePipeline, ProjectThenMetaMatchPushedDown) {
auto pipeline = Pipeline::parse(
makeVector(fromjson("{$_internalUnpackBucket: { exclude: [], timeField: 'time', metaField: "
"'myMeta', bucketMaxSpanSeconds: 3600}}"),
fromjson("{$project: {x: 0}}"),
... | 0 | [] | mongo | b3107d73a2c58d7e016b834dae0acfd01c0db8d7 | 101,498,183,228,772,150,000,000,000,000,000,000,000 | 19 | SERVER-59299: Flatten top-level nested $match stages in doOptimizeAt
(cherry picked from commit 4db5eceda2cff697f35c84cd08232bac8c33beec) |
interp16(const uint16_t *table, uint16_t idx)
{
byte top = idx>>8;
uint16_t a = table[top];
int b = table[top+1]-a;
return a + ((0x80 + b*(idx & 0xff))>>8);
} | 0 | [
"CWE-476"
] | ghostpdl | 7870f4951bcc6a153f317e3439e14d0e929fd231 | 213,133,708,973,467,820,000,000,000,000,000,000,000 | 8 | Bug 701795: Segv due to image mask issue |
pg_stat_get_wal_senders(PG_FUNCTION_ARGS)
{
#define PG_STAT_GET_WAL_SENDERS_COLS 8
ReturnSetInfo *rsinfo = (ReturnSetInfo *) fcinfo->resultinfo;
TupleDesc tupdesc;
Tuplestorestate *tupstore;
MemoryContext per_query_ctx;
MemoryContext oldcontext;
WalSnd *sync_standby;
int i;
/* check to see if caller suppo... | 0 | [
"CWE-89"
] | postgres | 2b3a8b20c2da9f39ffecae25ab7c66974fbc0d3b | 202,881,409,562,254,500,000,000,000,000,000,000,000 | 125 | Be more careful to not lose sync in the FE/BE protocol.
If any error occurred while we were in the middle of reading a protocol
message from the client, we could lose sync, and incorrectly try to
interpret a part of another message as a new protocol message. That will
usually lead to an "invalid frontend message" erro... |
TfLiteRegistration* Register_NUMERIC_VERIFY_REF() {
static TfLiteRegistration r = {
numeric_verify::Init, numeric_verify::Free, numeric_verify::Prepare,
numeric_verify::Eval<builtin::dequantize::kReference>};
return &r;
} | 0 | [
"CWE-125",
"CWE-787"
] | tensorflow | 1970c2158b1ffa416d159d03c3370b9a462aee35 | 334,752,079,290,098,300,000,000,000,000,000,000,000 | 6 | [tflite]: Insert `nullptr` checks when obtaining tensors.
As part of ongoing refactoring, `tflite::GetInput`, `tflite::GetOutput`, `tflite::GetTemporary` and `tflite::GetIntermediates` will return `nullptr` in some cases. Hence, we insert the `nullptr` checks on all usages.
We also insert `nullptr` checks on usages o... |
static u64 vmci_transport_get_max_buffer_size(struct vsock_sock *vsk)
{
return vmci_trans(vsk)->queue_pair_max_size;
} | 0 | [
"CWE-20",
"CWE-269"
] | linux | f3d3342602f8bcbf37d7c46641cb9bca7618eb1c | 69,004,395,481,547,610,000,000,000,000,000,000,000 | 4 | 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... |
*/
void
xmlXPathDivValues(xmlXPathParserContextPtr ctxt) {
xmlXPathObjectPtr arg;
double val;
arg = valuePop(ctxt);
if (arg == NULL)
XP_ERROR(XPATH_INVALID_OPERAND);
val = xmlXPathCastToNumber(arg);
xmlXPathReleaseObject(ctxt->context, arg);
CAST_TO_NUMBER;
CHECK_TYPE(XPATH_NUMBER);
... | 0 | [
"CWE-119"
] | libxml2 | 91d19754d46acd4a639a8b9e31f50f31c78f8c9c | 81,480,803,483,768,270,000,000,000,000,000,000,000 | 31 | Fix the semantic of XPath axis for namespace/attribute context nodes
The processing of namespace and attributes nodes was not compliant
to the XPath-1.0 specification |
static int hci_sock_setsockopt(struct socket *sock, int level, int optname,
char __user *optval, unsigned int len)
{
struct hci_ufilter uf = { .opcode = 0 };
struct sock *sk = sock->sk;
int err = 0, opt = 0;
BT_DBG("sk %p, opt %d", sk, optname);
lock_sock(sk);
if (hci_pi(sk)->channel != HCI_CHANNEL_R... | 0 | [
"CWE-20",
"CWE-269"
] | linux | f3d3342602f8bcbf37d7c46641cb9bca7618eb1c | 25,228,954,842,389,050,000,000,000,000,000,000,000 | 82 | 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... |
VideoTrack::VideoTrack(Segment* pSegment, long long element_start,
long long element_size)
: Track(pSegment, element_start, element_size),
m_colour(NULL),
m_projection(NULL) {} | 1 | [
"CWE-20"
] | libvpx | f00890eecdf8365ea125ac16769a83aa6b68792d | 126,507,987,349,444,600,000,000,000,000,000,000,000 | 5 | update libwebm to libwebm-1.0.0.27-352-g6ab9fcf
https://chromium.googlesource.com/webm/libwebm/+log/af81f26..6ab9fcf
Change-Id: I9d56e1fbaba9b96404b4fbabefddc1a85b79c25d |
static int nested_ept_init_mmu_context(struct kvm_vcpu *vcpu)
{
WARN_ON(mmu_is_nested(vcpu));
if (!valid_ept_address(vcpu, nested_ept_get_cr3(vcpu)))
return 1;
kvm_mmu_unload(vcpu);
kvm_init_shadow_ept_mmu(vcpu,
to_vmx(vcpu)->nested.msrs.ept_caps &
VMX_EPT_EXECUTE_ONLY_BIT,
nested_ept_ad_enabled(vcpu));... | 0 | [
"CWE-284"
] | linux | 727ba748e110b4de50d142edca9d6a9b7e6111d8 | 28,228,998,008,965,020,000,000,000,000,000,000,000 | 18 | 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... |
UsbHubCtrlClearHubFeature (
IN USB_DEVICE *HubDev,
IN UINT16 Feature
)
{
EFI_STATUS Status;
Status = UsbCtrlRequest (
HubDev,
EfiUsbNoData,
USB_REQ_TYPE_CLASS,
USB_HUB_TARGET_HUB,
USB_HUB_REQ_CLE... | 0 | [
"CWE-787"
] | edk2 | acebdf14c985c5c9f50b37ece0b15ada87767359 | 116,054,815,860,583,830,000,000,000,000,000,000,000 | 21 | MdeModulePkg UsbBusDxe: Fix wrong buffer length used to read hub desc
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=973
HUB descriptor has variable length.
But the code uses stack (HubDesc in UsbHubInit) with fixed length
sizeof(EFI_USB_HUB_DESCRIPTOR) to hold HUB descriptor data.
It uses hard code length value... |
static void ms_adpcm_reset1 (_AFmoduleinst *i)
{
ms_adpcm_data *d = (ms_adpcm_data *) i->modspec;
AFframecount nextTrackFrame;
int framesPerBlock;
framesPerBlock = d->samplesPerBlock / d->track->f.channelCount;
nextTrackFrame = d->track->nextfframe;
d->track->nextfframe = (nextTrackFrame / framesPerBlock) *
... | 1 | [
"CWE-119"
] | audiofile | e8cf0095b3f319739f9aa1ab5a1aa52b76be8cdd | 13,601,916,536,781,198,000,000,000,000,000,000,000 | 15 | Fix decoding of multi-channel ADPCM audio files. |
void Compute(OpKernelContext* context) override {
const Tensor& indices = context->input(0);
const Tensor& values = context->input(1);
const Tensor& shape = context->input(2);
const Tensor& weights = context->input(3);
bool use_weights = weights.NumElements() > 0;
OP_REQUIRES(context, TensorS... | 1 | [
"CWE-125",
"CWE-131"
] | tensorflow | c57c0b9f3a4f8684f3489dd9a9ec627ad8b599f5 | 63,539,342,529,614,990,000,000,000,000,000,000,000 | 72 | Fix the segfault in `tf.raw_ops.SparseCountSparseOutput`.
PiperOrigin-RevId: 369264941
Change-Id: I23a96a15b8370c01ee21ba3841e1c7dcbf55e93d |
static int snd_pcm_mmap_status(struct snd_pcm_substream *substream, struct file *file,
struct vm_area_struct *area)
{
long size;
if (!(area->vm_flags & VM_READ))
return -EINVAL;
size = area->vm_end - area->vm_start;
if (size != PAGE_ALIGN(sizeof(struct snd_pcm_mmap_status)))
return -EINVAL;
area->vm_... | 0 | [
"CWE-125"
] | linux | 92ee3c60ec9fe64404dc035e7c41277d74aa26cb | 315,758,911,513,170,070,000,000,000,000,000,000,000 | 14 | ALSA: pcm: Fix races among concurrent hw_params and hw_free calls
Currently we have neither proper check nor protection against the
concurrent calls of PCM hw_params and hw_free ioctls, which may result
in a UAF. Since the existing PCM stream lock can't be used for
protecting the whole ioctl operations, we need a new... |
virDomainDeviceValidateAliasForHotplug(virDomainObjPtr vm,
virDomainDeviceDefPtr dev,
unsigned int flags)
{
virDomainDefPtr persDef = NULL;
virDomainDefPtr liveDef = NULL;
if (virDomainObjGetDefs(vm, flags, &liveDef, &persDef) < ... | 0 | [
"CWE-212"
] | libvirt | a5b064bf4b17a9884d7d361733737fb614ad8979 | 77,627,159,446,839,930,000,000,000,000,000,000,000 | 20 | conf: Don't format http cookies unless VIR_DOMAIN_DEF_FORMAT_SECURE is used
Starting with 3b076391befc3fe72deb0c244ac6c2b4c100b410
(v6.1.0-122-g3b076391be) we support http cookies. Since they may contain
somewhat sensitive information we should not format them into the XML
unless VIR_DOMAIN_DEF_FORMAT_SECURE is assert... |
propagate_constants_topo (class ipa_topo_info *topo)
{
int i;
for (i = topo->nnodes - 1; i >= 0; i--)
{
unsigned j;
struct cgraph_node *v, *node = topo->order[i];
vec<cgraph_node *> cycle_nodes = ipa_get_nodes_in_cycle (node);
/* First, iteratively propagate within the strongly connect... | 0 | [
"CWE-20"
] | gcc | a09ccc22459c565814f79f96586fe4ad083fe4eb | 170,195,169,797,174,300,000,000,000,000,000,000,000 | 77 | Avoid segfault when doing IPA-VRP but not IPA-CP (PR 93015)
2019-12-21 Martin Jambor <mjambor@suse.cz>
PR ipa/93015
* ipa-cp.c (ipcp_store_vr_results): Check that info exists
testsuite/
* gcc.dg/lto/pr93015_0.c: New test.
From-SVN: r279695 |
ExpressionMap::ExpressionMap(ExpressionContext* const expCtx,
const string& varName,
Variables::Id varId,
intrusive_ptr<Expression> input,
intrusive_ptr<Expression> each)
: Expression(expCtx, {std::mo... | 0 | [] | mongo | 1772b9a0393b55e6a280a35e8f0a1f75c014f301 | 139,552,980,114,681,940,000,000,000,000,000,000,000 | 10 | SERVER-49404 Enforce additional checks in $arrayToObject |
static struct pmu_hw_events *armpmu_get_cpu_events(void)
{
return this_cpu_ptr(&cpu_hw_events);
} | 0 | [
"CWE-284",
"CWE-264"
] | linux | 8fff105e13041e49b82f92eef034f363a6b1c071 | 333,727,219,828,020,970,000,000,000,000,000,000,000 | 4 | arm64: perf: reject groups spanning multiple HW PMUs
The perf core implicitly rejects events spanning multiple HW PMUs, as in
these cases the event->ctx will differ. However this validation is
performed after pmu::event_init() is called in perf_init_event(), and
thus pmu::event_init() may be called with a group leader... |
int ftrace_regex_release(struct inode *inode, struct file *file)
{
struct seq_file *m = (struct seq_file *)file->private_data;
struct ftrace_iterator *iter;
struct ftrace_hash **orig_hash;
struct trace_parser *parser;
int filter_hash;
int ret;
mutex_lock(&ftrace_regex_lock);
if (file->f_mode & FMODE_READ) {
... | 0 | [
"CWE-703"
] | linux | 6a76f8c0ab19f215af2a3442870eeb5f0e81998d | 166,044,834,356,412,150,000,000,000,000,000,000,000 | 48 | tracing: Fix possible NULL pointer dereferences
Currently set_ftrace_pid and set_graph_function files use seq_lseek
for their fops. However seq_open() is called only for FMODE_READ in
the fops->open() so that if an user tries to seek one of those file
when she open it for writing, it sees NULL seq_file and then panic... |
*/
PHPAPI void php_info_print_table_row(int num_cols, ...)
{
va_list row_elements;
va_start(row_elements, num_cols);
php_info_print_table_row_internal(num_cols, "v", row_elements);
va_end(row_elements); | 0 | [
"CWE-200"
] | php-src | 3804c0d00fa6e629173fb1c8c61f8f88d5fe39b9 | 255,249,132,732,242,070,000,000,000,000,000,000,000 | 8 | Fix bug #67498 - phpinfo() Type Confusion Information Leak Vulnerability |
static long iowarrior_ioctl(struct file *file, unsigned int cmd,
unsigned long arg)
{
struct iowarrior *dev = NULL;
__u8 *buffer;
__u8 __user *user_buffer;
int retval;
int io_res; /* checks for bytes read/written and copy_to/from_user results */
dev = file->private_data;
if (dev == NULL) {
return -ENO... | 0 | [
"CWE-703"
] | linux | 4ec0ef3a82125efc36173062a50624550a900ae0 | 218,973,212,534,413,100,000,000,000,000,000,000,000 | 116 | USB: iowarrior: fix oops with malicious USB descriptors
The iowarrior driver expects at least one valid endpoint. If given
malicious descriptors that specify 0 for the number of endpoints,
it will crash in the probe function. Ensure there is at least
one endpoint on the interface before using it.
The full report of... |
zend_object_value pdo_dbstmt_new(zend_class_entry *ce TSRMLS_DC)
{
zend_object_value retval;
pdo_stmt_t *stmt;
stmt = emalloc(sizeof(*stmt));
memset(stmt, 0, sizeof(*stmt));
zend_object_std_init(&stmt->std, ce TSRMLS_CC);
object_properties_init(&stmt->std, ce);
stmt->refcount = 1;
retval.handle = zend_object... | 0 | [
"CWE-476"
] | php-src | 6045de69c7dedcba3eadf7c4bba424b19c81d00d | 188,116,751,471,763,350,000,000,000,000,000,000,000 | 16 | Fix bug #73331 - do not try to serialize/unserialize objects wddx can not handle
Proper soltion would be to call serialize/unserialize and deal with the result,
but this requires more work that should be done by wddx maintainer (not me). |
int icmp_rcv(struct sk_buff *skb)
{
struct icmphdr *icmph;
struct rtable *rt = skb_rtable(skb);
struct net *net = dev_net(rt->dst.dev);
if (!xfrm4_policy_check(NULL, XFRM_POLICY_IN, skb)) {
struct sec_path *sp = skb_sec_path(skb);
int nh;
if (!(sp && sp->xvec[sp->len - 1]->props.flags &
XFRM_STATE_ICMP... | 0 | [
"CWE-362"
] | linux-2.6 | f6d8bd051c391c1c0458a30b2a7abcd939329259 | 281,854,590,696,398,960,000,000,000,000,000,000,000 | 88 | inet: add RCU protection to inet->opt
We lack proper synchronization to manipulate inet->opt ip_options
Problem is ip_make_skb() calls ip_setup_cork() and
ip_setup_cork() possibly makes a copy of ipc->opt (struct ip_options),
without any protection against another thread manipulating inet->opt.
Another thread can ch... |
dissect_rpcap_startcap_reply (tvbuff_t *tvb, packet_info *pinfo _U_,
proto_tree *parent_tree, gint offset)
{
proto_tree *tree;
proto_item *ti;
ti = proto_tree_add_item (parent_tree, hf_startcap_reply, tvb, offset, -1, ENC_NA);
tree = proto_item_add_subtree (ti, ett_startcap_reply)... | 0 | [
"CWE-20"
] | wireshark | 2c13e97d656c1c0ac4d76eb9d307664aae0e0cf7 | 302,848,675,271,357,000,000,000,000,000,000,000,000 | 17 | The WTAP_ENCAP_ETHERNET dissector needs to be passed a struct eth_phdr.
We now require that. Make it so.
Bug: 12440
Change-Id: Iffee520976b013800699bde3c6092a3e86be0d76
Reviewed-on: https://code.wireshark.org/review/15424
Reviewed-by: Guy Harris <guy@alum.mit.edu> |
static inline int tftp_session_in_use(struct tftp_session *spt)
{
return (spt->slirp != NULL);
} | 0 | [
"CWE-22"
] | libslirp | 14ec36e107a8c9af7d0a80c3571fe39b291ff1d4 | 178,037,322,272,618,130,000,000,000,000,000,000,000 | 4 | slirp: tftp: restrict relative path access
tftp restricts relative or directory path access on Linux systems.
Apply same restrictions on Windows systems too. It helps to avoid
directory traversal issue.
Fixes: https://bugs.launchpad.net/qemu/+bug/1812451
Reported-by: Peter Maydell <peter.maydell@linaro.org>
Signed-of... |
write_coefs_to_file(int valid,time_t ref_time,double offset,double rate)
{
char *temp_coefs_file_name;
FILE *out;
int r1, r2;
/* Create a temporary file with a '.tmp' extension. */
temp_coefs_file_name = (char*) Malloc(strlen(coefs_file_name)+8);
if(!temp_coefs_file_name) {
return RTC_ST_BADFILE;
}... | 1 | [
"CWE-59"
] | chrony | e18903a6b56341481a2e08469c0602010bf7bfe3 | 109,835,309,572,963,470,000,000,000,000,000,000,000 | 50 | switch to new util file functions
Replace all fopen(), rename(), and unlink() calls with the new util
functions. |
hostkey_method_ssh_ed25519_initPEMFromMemory(LIBSSH2_SESSION * session,
const char *privkeyfiledata,
size_t privkeyfiledata_len,
unsigned const char *passphrase,
... | 0 | [
"CWE-787"
] | libssh2 | dc109a7f518757741590bb993c0c8412928ccec2 | 170,862,034,046,930,020,000,000,000,000,000,000,000 | 26 | Security fixes (#315)
* Bounds checks
Fixes for CVEs
https://www.libssh2.org/CVE-2019-3863.html
https://www.libssh2.org/CVE-2019-3856.html
* Packet length bounds check
CVE
https://www.libssh2.org/CVE-2019-3855.html
* Response length check
CVE
https://www.libssh2.org/CVE-2019-3859.html
* Bounds ch... |
int32_t nghttp2_session_get_stream_local_window_size(nghttp2_session *session,
int32_t stream_id) {
nghttp2_stream *stream;
int32_t size;
stream = nghttp2_session_get_stream(session, stream_id);
if (stream == NULL) {
return -1;
}
size = stream->local... | 0 | [] | nghttp2 | 0a6ce87c22c69438ecbffe52a2859c3a32f1620f | 158,430,150,405,444,920,000,000,000,000,000,000,000 | 19 | Add nghttp2_option_set_max_outbound_ack |
static CURLcode run_all_transfers(struct GlobalConfig *global,
CURLSH *share,
CURLcode result)
{
/* Save the values of noprogress and isatty to restore them later on */
bool orig_noprogress = global->noprogress;
bool orig_isatty = global->isatty;... | 0 | [] | curl | 8c7ee9083d0d719d0a77ab20d9cc2ae84eeea7f3 | 315,131,674,234,955,230,000,000,000,000,000,000,000 | 39 | 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 inline void timer_stats_hrtimer_set_start_info(struct hrtimer *timer)
{
#ifdef CONFIG_TIMER_STATS
if (timer->start_site)
return;
timer->start_site = __builtin_return_address(0);
memcpy(timer->start_comm, current->comm, TASK_COMM_LEN);
timer->start_pid = current->pid;
#endif
} | 1 | [
"CWE-200"
] | tip | dfb4357da6ddbdf57d583ba64361c9d792b0e0b1 | 69,595,883,181,546,700,000,000,000,000,000,000,000 | 10 | time: Remove CONFIG_TIMER_STATS
Currently CONFIG_TIMER_STATS exposes process information across namespaces:
kernel/time/timer_list.c print_timer():
SEQ_printf(m, ", %s/%d", tmp, timer->start_pid);
/proc/timer_list:
#11: <0000000000000000>, hrtimer_wakeup, S:01, do_nanosleep, cron/2570
Given that the trac... |
void qdisc_put_stab(struct qdisc_size_table *tab)
{
if (!tab)
return;
spin_lock(&qdisc_stab_lock);
if (--tab->refcnt == 0) {
list_del(&tab->list);
kfree(tab);
}
spin_unlock(&qdisc_stab_lock);
} | 0 | [
"CWE-909"
] | linux-2.6 | 16ebb5e0b36ceadc8186f71d68b0c4fa4b6e781b | 246,953,739,700,085,930,000,000,000,000,000,000,000 | 14 | tc: Fix unitialized kernel memory leak
Three bytes of uninitialized kernel memory are currently leaked to user
Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
Reviewed-by: Jiri Pirko <jpirko@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net> |
mono_TypedReference_ToObjectInternal (MonoType *type, gpointer value, MonoClass *klass)
{
MONO_ARCH_SAVE_REGS;
if (MONO_TYPE_IS_REFERENCE (type)) {
MonoObject** objp = value;
return *objp;
}
return mono_value_box (mono_domain_get (), klass, value);
} | 0 | [
"CWE-264"
] | mono | 035c8587c0d8d307e45f1b7171a0d337bb451f1e | 319,631,819,458,372,460,000,000,000,000,000,000,000 | 11 | Allow only primitive types/enums in RuntimeHelpers.InitializeArray (). |
static int append(uint8_t **dst, unsigned *dst_size, const unsigned char *src, unsigned src_size)
{
*dst = _asn1_realloc(*dst, *dst_size+src_size);
if (*dst == NULL)
return ASN1_MEM_ERROR;
memcpy(*dst + *dst_size, src, src_size);
*dst_size += src_size;
return ASN1_SUCCESS;
} | 0 | [
"CWE-399"
] | libtasn1 | f435825c0f527a8e52e6ffbc3ad0bc60531d537e | 264,065,742,996,848,100,000,000,000,000,000,000,000 | 9 | _asn1_extract_der_octet: catch invalid input cases early
That is, check the calculated lengths for validity prior
to entering a loop. This avoids an infinite recursion.
Reported by Pascal Cuoq. |
queue_session_reset (GdmManager *manager,
GdmSession *session)
{
ResetSessionOperation *operation;
operation = g_object_get_data (G_OBJECT (session), "reset-session-operation");
if (operation != NULL) {
return;
}
operation = g_slice_new0 (R... | 0 | [] | gdm | ff98b2817014684ae1acec78ff06f0f461a56a9f | 258,488,323,361,300,200,000,000,000,000,000,000,000 | 18 | manager: if falling back to X11 retry autologin
Right now, we get one shot to autologin. If it fails, we fall back to
the greeter. We should give it another go if the reason for the failure
was wayland fallback to X.
https://bugzilla.gnome.org/show_bug.cgi?id=780520 |
int kvm_clear_guest(struct kvm *kvm, gpa_t gpa, unsigned long len)
{
gfn_t gfn = gpa >> PAGE_SHIFT;
int seg;
int offset = offset_in_page(gpa);
int ret;
while ((seg = next_segment(len, offset)) != 0) {
ret = kvm_clear_guest_page(kvm, gfn, offset, seg);
if (ret < 0)
return ret;
offset = 0;
len -= seg;
... | 0 | [
"CWE-416"
] | linux | 0774a964ef561b7170d8d1b1bfe6f88002b6d219 | 336,849,056,307,501,800,000,000,000,000,000,000,000 | 17 | KVM: Fix out of range accesses to memslots
Reset the LRU slot if it becomes invalid when deleting a memslot to fix
an out-of-bounds/use-after-free access when searching through memslots.
Explicitly check for there being no used slots in search_memslots(), and
in the caller of s390's approximation variant.
Fixes: 369... |
set_ownership(struct archive_write_disk *a)
{
#if !defined(__CYGWIN__) && !defined(__linux__)
/*
* On Linux, a process may have the CAP_CHOWN capability.
* On Windows there is no 'root' user with uid 0.
* Elsewhere we can skip calling chown if we are not root and the desired
* user id does not match the current use... | 0 | [
"CWE-59",
"CWE-269"
] | libarchive | b41daecb5ccb4c8e3b2c53fd6147109fc12c3043 | 261,691,295,381,876,100,000,000,000,000,000,000,000 | 46 | Do not follow symlinks when processing the fixup list
Use lchmod() instead of chmod() and tell the remaining functions that the
real file to be modified is a symbolic link.
Fixes #1566 |
static int decode_open_confirm(struct xdr_stream *xdr, struct nfs_open_confirmres *res)
{
int status;
status = decode_op_hdr(xdr, OP_OPEN_CONFIRM);
if (status != -EIO)
nfs_increment_open_seqid(status, res->seqid);
if (!status)
status = decode_open_stateid(xdr, &res->stateid);
return status;
} | 0 | [
"CWE-787"
] | linux | b4487b93545214a9db8cbf32e86411677b0cca21 | 302,171,317,509,767,660,000,000,000,000,000,000,000 | 11 | nfs: Fix getxattr kernel panic and memory overflow
Move the buffer size check to decode_attr_security_label() before memcpy()
Only call memcpy() if the buffer is large enough
Fixes: aa9c2669626c ("NFS: Client implementation of Labeled-NFS")
Signed-off-by: Jeffrey Mitchell <jeffrey.mitchell@starlab.io>
[Trond: clean u... |
static int io_import_fixed(struct io_ring_ctx *ctx, int rw,
const struct io_uring_sqe *sqe,
struct iov_iter *iter)
{
size_t len = READ_ONCE(sqe->len);
struct io_mapped_ubuf *imu;
unsigned index, buf_index;
size_t offset;
u64 buf_addr;
/* attempt to use fixed buffers without having provided iovecs */
... | 0 | [] | linux | 181e448d8709e517c9c7b523fcd209f24eb38ca7 | 87,651,621,943,808,050,000,000,000,000,000,000,000 | 73 | io_uring: async workers should inherit the user creds
If we don't inherit the original task creds, then we can confuse users
like fuse that pass creds in the request header. See link below on
identical aio issue.
Link: https://lore.kernel.org/linux-fsdevel/26f0d78e-99ca-2f1b-78b9-433088053a61@scylladb.com/T/#u
Signed... |
int kvm_x2apic_msr_read(struct kvm_vcpu *vcpu, u32 msr, u64 *data)
{
struct kvm_lapic *apic = vcpu->arch.apic;
u32 reg = (msr - APIC_BASE_MSR) << 4;
if (!lapic_in_kernel(vcpu) || !apic_x2apic_mode(apic))
return 1;
if (reg == APIC_DFR)
return 1;
return kvm_lapic_msr_read(apic, reg, data);
} | 0 | [
"CWE-476"
] | linux | 00b5f37189d24ac3ed46cb7f11742094778c46ce | 172,725,060,680,508,780,000,000,000,000,000,000,000 | 13 | KVM: x86: Avoid theoretical NULL pointer dereference in kvm_irq_delivery_to_apic_fast()
When kvm_irq_delivery_to_apic_fast() is called with APIC_DEST_SELF
shorthand, 'src' must not be NULL. Crash the VM with KVM_BUG_ON()
instead of crashing the host.
Signed-off-by: Vitaly Kuznetsov <vkuznets@redhat.com>
Message-Id: <... |
void initialize() {
codec_ = std::make_unique<ClientConnectionImpl>(connection_, http1CodecStats(), callbacks_,
codec_settings_, max_response_headers_count_);
} | 0 | [
"CWE-770"
] | envoy | 7ca28ff7d46454ae930e193d97b7d08156b1ba59 | 193,350,518,874,456,900,000,000,000,000,000,000,000 | 4 | [http1] Include request URL in request header size computation, and reject partial headers that exceed configured limits (#145)
Signed-off-by: antonio <avd@google.com> |
_peekURL(int only_img)
{
Anchor *a;
ParsedURL pu;
static Str s = NULL;
#ifdef USE_M17N
static Lineprop *p = NULL;
Lineprop *pp;
#endif
static int offset = 0, n;
if (Currentbuf->firstLine == NULL)
return;
if (CurrentKey == prev_key && s != NULL) {
if (s->length - offset >= COLS)
... | 0 | [
"CWE-59",
"CWE-241"
] | w3m | 18dcbadf2771cdb0c18509b14e4e73505b242753 | 319,334,147,586,446,200,000,000,000,000,000,000,000 | 57 | Make temporary directory safely when ~/.w3m is unwritable |
static int samldb_prim_group_users_check(struct samldb_ctx *ac)
{
struct ldb_context *ldb;
struct dom_sid *sid;
uint32_t rid;
NTSTATUS status;
int ret;
struct ldb_result *res = NULL;
struct ldb_result *res_users = NULL;
const char * const attrs[] = { "objectSid", "isDeleted", NULL };
const char * const noattrs... | 0 | [
"CWE-200"
] | samba | 0a3aa5f908e351201dc9c4d4807b09ed9eedff77 | 203,110,902,371,977,480,000,000,000,000,000,000,000 | 73 | CVE-2022-32746 ldb: Make use of functions for appending to an ldb_message
This aims to minimise usage of the error-prone pattern of searching for
a just-added message element in order to make modifications to it (and
potentially finding the wrong element).
BUG: https://bugzilla.samba.org/show_bug.cgi?id=15009
Signed... |
xmlExpParseExpr(xmlExpCtxtPtr ctxt) {
xmlExpNodePtr ret, right;
ret = xmlExpParseSeq(ctxt);
SKIP_BLANKS
while (CUR == ',') {
NEXT
right = xmlExpParseSeq(ctxt);
if (right == NULL) {
xmlExpFree(ctxt, ret);
return(NULL);
}
ret = xmlExpHashGetEntry(ctxt, XML_EXP_SEQ, ret, right, NULL,... | 0 | [
"CWE-119"
] | libxml2 | cbb271655cadeb8dbb258a64701d9a3a0c4835b4 | 12,477,032,812,425,562,000,000,000,000,000,000,000 | 18 | Bug 757711: heap-buffer-overflow in xmlFAParsePosCharGroup <https://bugzilla.gnome.org/show_bug.cgi?id=757711>
* xmlregexp.c:
(xmlFAParseCharRange): Only advance to the next character if
there is no error. Advancing to the next character in case of
an error while parsing regexp leads to an out of bounds access. |
PackNetBSDElf32x86::~PackNetBSDElf32x86()
{
} | 0 | [
"CWE-476"
] | upx | ef336dbcc6dc8344482f8cf6c909ae96c3286317 | 282,492,802,854,202,840,000,000,000,000,000,000,000 | 3 | Protect against bad crafted input.
https://github.com/upx/upx/issues/128
modified: p_lx_elf.cpp |
static int get_base_info(struct hfi1_filedata *fd, unsigned long arg, u32 len)
{
struct hfi1_base_info binfo;
struct hfi1_ctxtdata *uctxt = fd->uctxt;
struct hfi1_devdata *dd = uctxt->dd;
unsigned offset;
trace_hfi1_uctxtdata(uctxt->dd, uctxt, fd->subctxt);
if (sizeof(binfo) != len)
return -EINVAL;
memset(&... | 0 | [
"CWE-416"
] | linux | 3d2a9d642512c21a12d19b9250e7a835dcb41a79 | 312,307,039,910,154,600,000,000,000,000,000,000,000 | 76 | IB/hfi1: Ensure correct mm is used at all times
Two earlier bug fixes have created a security problem in the hfi1
driver. One fix aimed to solve an issue where current->mm was not valid
when closing the hfi1 cdev. It attempted to do this by saving a cached
value of the current->mm pointer at file open time. This is a ... |
int tls1_generate_master_secret(SSL *s, unsigned char *out, unsigned char *p,
int len)
{
unsigned char buff[SSL_MAX_MASTER_KEY_LENGTH];
const void *co = NULL, *so = NULL;
int col = 0, sol = 0;
#ifdef KSSL_DEBUG
printf ("tls1_generate_master_secret(%p,%p, %p, %d)\n", s,out, p,len);
#endif /* KSSL_DEBUG */
... | 0 | [] | openssl | 0294b2be5f4c11e60620c0018674ff0e17b14238 | 253,739,051,909,595,570,000,000,000,000,000,000,000 | 48 | Check EVP errors for handshake digests.
Partial mitigation of PR#3200 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.