func string | target int64 | cwe list | project string | commit_id string | hash float64 | size int64 | message string | is_vulnerable string | cwe_id_extracted string | cwe_details string |
|---|---|---|---|---|---|---|---|---|---|---|
static __inline__ int isdn_net_device_busy(isdn_net_local *lp)
{
isdn_net_local *nlp;
isdn_net_dev *nd;
unsigned long flags;
if (!isdn_net_lp_busy(lp))
return 0;
if (lp->master)
nd = ISDN_MASTER_PRIV(lp)->netdev;
else
nd = lp->netdev;
spin_lock_irqsave(&nd->queue_lock, flags);
nlp = lp->next;
while (n... | 0 | [
"CWE-119"
] | linux | 9f5af546e6acc30f075828cb58c7f09665033967 | 111,784,512,268,787,210,000,000,000,000,000,000,000 | 26 | isdn/i4l: fix buffer overflow
This fixes a potential buffer overflow in isdn_net.c caused by an
unbounded strcpy.
[ ISDN seems to be effectively unmaintained, and the I4L driver in
particular is long deprecated, but in case somebody uses this..
- Linus ]
Signed-off-by: Jiten Thakkar <jitenmt@gmail.com>
Signed-... | Safe | 119 | {"cwe_id": "CWE-119", "vulnerability_type": "Improper Restriction of Operations within the Bounds of a Memory Buffer", "description": "The product performs operations on a memory buffer, but it reads from or writes to a memory location outside the buffer's intended boundary. This may result in read or write operations ... |
nm_gconf_get_stringlist_helper (GConfClient *client,
const char *path,
const char *key,
const char *setting,
GSList **value)
{
char *gc_key;
GConfValue *gc_value;
gboolean success = FALSE;
... | 0 | [
"CWE-310"
] | network-manager-applet | 4020594dfbf566f1852f0acb36ad631a9e73a82b | 310,681,619,484,564,530,000,000,000,000,000,000,000 | 39 | core: fix CA cert mishandling after cert file deletion (deb #560067) (rh #546793)
If a connection was created with a CA certificate, but the user later
moved or deleted that CA certificate, the applet would simply provide the
connection to NetworkManager without any CA certificate. This could cause
NM to connect to t... | Safe | 310 | null |
bgp_attr_unknown (struct bgp_attr_parser_args *args)
{
bgp_size_t total = args->total;
struct transit *transit;
struct attr_extra *attre;
struct peer *const peer = args->peer;
struct attr *const attr = args->attr;
u_char *const startp = args->startp;
const u_char type = args->type;
const u_char flag = ... | 0 | [] | quagga | 8794e8d229dc9fe29ea31424883433d4880ef408 | 123,570,805,515,841,710,000,000,000,000,000,000,000 | 63 | bgpd: Fix regression in args consolidation, total should be inited from args
* bgp_attr.c: (bgp_attr_unknown) total should be initialised from the args. | Safe | null | null |
int set_unit_path(const char *p) {
/* This is mostly for debug purposes */
if (setenv("SYSTEMD_UNIT_PATH", p, 1) < 0)
return -errno;
return 0;
} | 0 | [
"CWE-269"
] | systemd | bf65b7e0c9fc215897b676ab9a7c9d1c688143ba | 156,325,964,314,063,430,000,000,000,000,000,000,000 | 7 | core: imply NNP and SUID/SGID restriction for DynamicUser=yes service
Let's be safe, rather than sorry. This way DynamicUser=yes services can
neither take benefit of, nor create SUID/SGID binaries.
Given that DynamicUser= is a recent addition only we should be able to
get away with turning this on, even though this i... | Safe | 269 | {"cwe_id": "CWE-269", "vulnerability_type": "Improper Privilege Management", "description": "The product does not properly assign, modify, track, or check privileges for an actor, creating an unintended sphere of control for that actor.", "severity": "Medium", "category": null, "impact": ["Gain Privileges or Assume Ide... |
static int lsql_handle_request(struct ldb_module *module, struct ldb_request *req)
{
struct ldb_context *ldb;
struct tevent_context *ev;
struct lsql_context *ac;
struct tevent_timer *te;
struct timeval tv;
if (ldb_check_critical_controls(req->controls)) {
return LDB_ERR_UNSUPPORTED_CRITICAL_EXTENSION;
}
if ... | 0 | [
"CWE-20"
] | samba | 3f95957d6de321c803a66f3ec67a8ff09befd16d | 183,004,076,862,395,670,000,000,000,000,000,000,000 | 47 | CVE-2018-1140 ldb: Check for ldb_dn_get_casefold() failure in ldb_sqlite
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
BUG: https://bugzilla.samba.org/show_bug.cgi?id=13374 | Safe | 20 | {"cwe_id": "CWE-20", "vulnerability_type": "Improper Input Validation", "description": "The product receives input or data, but it does\n not validate or incorrectly validates that the input has the\n properties that are required to process the data safely and\n correctly.", "severity": "High", "ca... |
quicklistBookmark *_quicklistBookmarkFindByNode(quicklist *ql, quicklistNode *node) {
unsigned i;
for (i=0; i<ql->bookmark_count; i++) {
if (ql->bookmarks[i].node == node) {
return &ql->bookmarks[i];
}
}
return NULL;
} | 0 | [
"CWE-190"
] | redis | f6a40570fa63d5afdd596c78083d754081d80ae3 | 94,118,480,846,494,360,000,000,000,000,000,000,000 | 9 | Fix ziplist and listpack overflows and truncations (CVE-2021-32627, CVE-2021-32628)
- fix possible heap corruption in ziplist and listpack resulting by trying to
allocate more than the maximum size of 4GB.
- prevent ziplist (hash and zset) from reaching size of above 1GB, will be
converted to HT encoding, that's n... | Safe | 190 | {"cwe_id": "CWE-190", "vulnerability_type": "Integer Overflow or Wraparound", "description": "The product performs a calculation that can\n produce an integer overflow or wraparound when the logic\n assumes that the resulting value will always be larger than\n the original value. This occurs whe... |
static int vnc_display_listen(VncDisplay *vd,
SocketAddress **saddr,
size_t nsaddr,
SocketAddress **wsaddr,
size_t nwsaddr,
Error **errp)
{
size_t i;
if (nsaddr)... | 0 | [
"CWE-401"
] | qemu | 6bf21f3d83e95bcc4ba35a7a07cc6655e8b010b0 | 333,110,236,540,480,400,000,000,000,000,000,000,000 | 41 | vnc: fix memory leak when vnc disconnect
Currently when qemu receives a vnc connect, it creates a 'VncState' to
represent this connection. In 'vnc_worker_thread_loop' it creates a
local 'VncState'. The connection 'VcnState' and local 'VncState' exchange
data in 'vnc_async_encoding_start' and 'vnc_async_encoding_end'.
... | Safe | 401 | {"cwe_id": "CWE-401", "vulnerability_type": "Missing Release of Memory after Effective Lifetime", "description": "The product does not sufficiently track and release allocated memory after it has been used, making the memory unavailable for reallocation and reuse.", "severity": "Medium", "category": "Memory Leak", "imp... |
static void ComputeWeightedCovariance(const size_t count,
const DDSVector4 *points, float *covariance)
{
DDSVector3
centroid;
float
total;
size_t
i;
total = 0.0f;
VectorInit3(centroid,0.0f);
for (i=0; i < count; i++)
{
total += points[i].w;
centroid.x += (points[i].x * points[i].... | 0 | [
"CWE-20",
"CWE-617"
] | ImageMagick | 0c5b1e430a83ef793a7334bbbee408cf3c628699 | 18,010,107,548,755,503,000,000,000,000,000,000,000 | 55 | Added check to prevent image being 0x0 (reported in #489). | Safe | 20 | {"cwe_id": "CWE-20", "vulnerability_type": "Improper Input Validation", "description": "The product receives input or data, but it does\n not validate or incorrectly validates that the input has the\n properties that are required to process the data safely and\n correctly.", "severity": "High", "ca... |
static int snd_ctl_elem_info(struct snd_ctl_file *ctl,
struct snd_ctl_elem_info *info)
{
struct snd_card *card = ctl->card;
struct snd_kcontrol *kctl;
struct snd_kcontrol_volatile *vd;
unsigned int index_offset;
int result;
down_read(&card->controls_rwsem);
kctl = snd_ctl_find_id(card, &info->id);
if ... | 0 | [
"CWE-190",
"CWE-189"
] | linux | ac902c112d90a89e59916f751c2745f4dbdbb4bd | 336,423,899,676,039,130,000,000,000,000,000,000,000 | 37 | ALSA: control: Handle numid overflow
Each control gets automatically assigned its numids when the control is created.
The allocation is done by incrementing the numid by the amount of allocated
numids per allocation. This means that excessive creation and destruction of
controls (e.g. via SNDRV_CTL_IOCTL_ELEM_ADD/REMO... | Safe | 190 | {"cwe_id": "CWE-190", "vulnerability_type": "Integer Overflow or Wraparound", "description": "The product performs a calculation that can\n produce an integer overflow or wraparound when the logic\n assumes that the resulting value will always be larger than\n the original value. This occurs whe... |
static void XMLCDECL xmlNoValidityErr(void *ctx ATTRIBUTE_UNUSED,
const char *msg ATTRIBUTE_UNUSED, ...) {
return;
} | 0 | [] | libxml2 | 932cc9896ab41475d4aa429c27d9afd175959d74 | 328,159,744,379,274,340,000,000,000,000,000,000,000 | 4 | Fix buffer size checks in xmlSnprintfElementContent
xmlSnprintfElementContent failed to correctly check the available
buffer space in two locations.
Fixes bug 781333 (CVE-2017-9047) and bug 781701 (CVE-2017-9048).
Thanks to Marcel Böhme and Thuan Pham for the report. | Safe | null | null |
static GF_Err do_dump_iod()
{
GF_Err e = GF_OK;
GF_InitialObjectDescriptor *iod = (GF_InitialObjectDescriptor *)gf_isom_get_root_od(file);
if (!iod) {
M4_LOG(GF_LOG_WARNING, ("File %s has no IOD\n", inName));
} else {
char szName[GF_MAX_PATH+10];
FILE *iodf;
sprintf(szName, "%s.iod", outfile);
iodf = gf_... | 0 | [
"CWE-787"
] | gpac | 4e56ad72ac1afb4e049a10f2d99e7512d7141f9d | 80,095,396,322,084,310,000,000,000,000,000,000,000 | 32 | fixed #2216 | Safe | 787 | {"cwe_id": "CWE-787", "vulnerability_type": "Out-of-bounds Write", "description": "The product writes data past the end, or before the beginning, of the intended buffer.", "severity": "High", "category": "Memory Corruption", "impact": ["Modify Memory", "Execute Unauthorized Code or Commands", "DoS: Crash, Exit, or Rest... |
double Magick::Image::strokeWidth(void) const
{
return(constOptions()->strokeWidth());
} | 0 | [
"CWE-416"
] | ImageMagick | 8c35502217c1879cb8257c617007282eee3fe1cc | 10,715,611,914,507,335,000,000,000,000,000,000,000 | 4 | Added missing return to avoid use after free. | Safe | 416 | {"cwe_id": "CWE-416", "vulnerability_type": "Use After Free", "description": "The product reuses or references memory after it has been freed. At some point afterward, the memory may be allocated again and saved in another pointer, while the original pointer references a location somewhere within the new allocation. An... |
static uint8_t att_ecode_from_error(int err)
{
/*
* If the error fits in a single byte, treat it as an ATT protocol
* error as is. Since "0" is not a valid ATT protocol error code, we map
* that to UNLIKELY below.
*/
if (err > 0 && err < UINT8_MAX)
return err;
/*
* Since we allow UNIX errnos, map them t... | 0 | [
"CWE-415"
] | bluez | 1cd644db8c23a2f530ddb93cebed7dacc5f5721a | 255,105,058,756,210,040,000,000,000,000,000,000,000 | 27 | shared/att: Fix possible crash on disconnect
If there are pending request while disconnecting they would be notified
but clients may endup being freed in the proccess which will then be
calling bt_att_cancel to cancal its requests causing the following
trace:
Invalid read of size 4
at 0x1D894C: enable_ccc_callback... | Safe | 415 | {"cwe_id": "CWE-415", "vulnerability_type": "Double Free", "description": "The product calls free() twice on the same memory address.", "severity": "High", "category": "Double-free", "impact": ["Modify Memory", "Execute Unauthorized Code or Commands"], "languages": [null, "C", "C++"], "example": "Example not extracted"... |
TEST(BasicFlatBufferModel, TestWithNumThreads) {
TestErrorReporter reporter;
auto model = FlatBufferModel::BuildFromFile(
"tensorflow/lite/testdata/test_model.bin", &reporter);
ASSERT_TRUE(model);
TrivialResolver resolver(&dummy_reg);
InterpreterBuilder builder(*model, resolver);
std::unique_ptr<Inte... | 0 | [
"CWE-703",
"CWE-835"
] | tensorflow | c6173f5fe66cdbab74f4f869311fe6aae2ba35f4 | 147,570,642,751,304,060,000,000,000,000,000,000,000 | 32 | TFLite: Error out when the graph has a recurion.
Recursion is currently unsupported.
PiperOrigin-RevId: 371708957
Change-Id: I8dfad0d85cbfe08e39ae8ea7bad21254ddee5003 | Safe | 703 | {"cwe_id": "CWE-703", "vulnerability_type": "Improper Check or Handling of Exceptional Conditions", "description": "The product does not properly anticipate or handle exceptional conditions that rarely occur during normal operation of the product.", "severity": null, "category": null, "impact": ["Read Application Data"... |
static int ZEND_FASTCALL ZEND_EXT_FCALL_END_SPEC_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
{
if (!EG(no_extensions)) {
zend_llist_apply_with_argument(&zend_extensions, (llist_apply_with_arg_func_t) zend_extension_fcall_end_handler, EX(op_array) TSRMLS_CC);
}
ZEND_VM_NEXT_OPCODE();
} | 0 | [] | php-src | ce96fd6b0761d98353761bf78d5bfb55291179fd | 200,691,991,468,112,740,000,000,000,000,000,000,000 | 7 | - fix #39863, do not accept paths with NULL in them. See http://news.php.net/php.internals/50191, trunk will have the patch later (adding a macro and/or changing (some) APIs. Patch by Rasmus | Safe | null | null |
bool MainWindow::eventFilter(QObject* target, QEvent* event)
{
if (event->type() == QEvent::DragEnter && target == MLT.videoWidget()) {
dragEnterEvent(static_cast<QDragEnterEvent*>(event));
return true;
} else if (event->type() == QEvent::Drop && target == MLT.videoWidget()) {
dropEvent(... | 0 | [
"CWE-89",
"CWE-327",
"CWE-295"
] | shotcut | f008adc039642307f6ee3378d378cdb842e52c1d | 60,473,514,690,351,200,000,000,000,000,000,000,000 | 29 | fix upgrade check is not using TLS correctly | Safe | 89 | {"cwe_id": "CWE-89", "vulnerability_type": "Improper Neutralization of Special Elements used in an SQL Command ('SQL Injection')", "description": "The product constructs all or part of an SQL command using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes spec... |
static int vmx_vcpu_setup(struct vcpu_vmx *vmx)
{
u32 host_sysenter_cs, msr_low, msr_high;
u32 junk;
u64 host_pat, tsc_this, tsc_base;
unsigned long a;
struct desc_ptr dt;
int i;
unsigned long kvm_vmx_return;
u32 exec_control;
/* I/O */
vmcs_write64(IO_BITMAP_A, __pa(vmx_io_bitmap_a));
vmcs_write64(IO_BITMA... | 0 | [
"CWE-400"
] | linux-2.6 | 9581d442b9058d3699b4be568b6e5eae38a41493 | 121,815,912,626,513,040,000,000,000,000,000,000,000 | 154 | KVM: Fix fs/gs reload oops with invalid ldt
kvm reloads the host's fs and gs blindly, however the underlying segment
descriptors may be invalid due to the user modifying the ldt after loading
them.
Fix by using the safe accessors (loadsegment() and load_gs_index()) instead
of home grown unsafe versions.
This is CVE-... | Safe | 400 | {"cwe_id": "CWE-400", "vulnerability_type": "Uncontrolled Resource Consumption", "description": "The product does not properly control the allocation and maintenance of a limited resource.", "severity": "High", "category": "Resource Exhaustion", "impact": ["DoS: Crash, Exit, or Restart", "DoS: Resource Consumption (CPU... |
static void rxrpc_free_preparse(struct key_preparsed_payload *prep)
{
rxrpc_free_token_list(prep->payload.data[0]);
} | 0 | [
"CWE-190"
] | linux | 5f2f97656ada8d811d3c1bef503ced266fcd53a0 | 313,809,915,415,046,580,000,000,000,000,000,000,000 | 4 | rxrpc: Fix several cases where a padded len isn't checked in ticket decode
This fixes CVE-2017-7482.
When a kerberos 5 ticket is being decoded so that it can be loaded into an
rxrpc-type key, there are several places in which the length of a
variable-length field is checked to make sure that it's not going to
overrun... | Safe | 190 | {"cwe_id": "CWE-190", "vulnerability_type": "Integer Overflow or Wraparound", "description": "The product performs a calculation that can\n produce an integer overflow or wraparound when the logic\n assumes that the resulting value will always be larger than\n the original value. This occurs whe... |
**/
CImg<T>& load_camera(const unsigned int camera_index=0, const unsigned int skip_frames=0,
const bool release_camera=true, const unsigned int capture_width=0,
const unsigned int capture_height=0) {
#ifdef cimg_use_opencv
if (camera_index>99)
thr... | 0 | [
"CWE-125"
] | CImg | 10af1e8c1ad2a58a0a3342a856bae63e8f257abb | 105,139,628,113,721,000,000,000,000,000,000,000,000 | 67 | Fix other issues in 'CImg<T>::load_bmp()'. | Safe | 125 | {"cwe_id": "CWE-125", "vulnerability_type": "Out-of-bounds Read", "description": "The product reads data past the end, or before the beginning, of the intended buffer.", "severity": null, "category": "OOB read", "impact": ["Read Memory", "Bypass Protection Mechanism", "DoS: Crash, Exit, or Restart", "Varies by Context"... |
PHP_FUNCTION(exif_read_data)
{
char *p_name, *p_sections_needed = NULL;
size_t p_name_len, p_sections_needed_len = 0;
zend_bool sub_arrays=0, read_thumbnail=0, read_all=0;
int i, ret, sections_needed=0;
image_info_type ImageInfo;
char tmp[64], *sections_str, *s;
if (zend_parse_parameters(ZEND_NUM_ARGS(), "p|sb... | 1 | [
"CWE-125"
] | php-src | 887a7b571407f7a49a5e7cf1e612d21ef83fedb4 | 309,824,927,946,323,100,000,000,000,000,000,000,000 | 174 | Fixed bug #77831 - Heap-buffer-overflow in exif_iif_add_value in EXIF | Vulnerable | 125 | {"cwe_id": "CWE-125", "vulnerability_type": "Out-of-bounds Read", "description": "The product reads data past the end, or before the beginning, of the intended buffer.", "severity": null, "category": "OOB read", "impact": ["Read Memory", "Bypass Protection Mechanism", "DoS: Crash, Exit, or Restart", "Varies by Context"... |
static char *strdup(const char *str)
{
size_t len;
char *dup;
len = strlen(str) + 1;
dup = calloc(len, sizeof(char));
if (!dup)
return NULL;
memcpy(dup, str, len);
return dup;
} | 0 | [] | libconfuse | d73777c2c3566fb2647727bb56d9a2295b81669b | 261,133,547,165,674,520,000,000,000,000,000,000,000 | 14 | Fix #163: unterminated username used with getpwnam()
Signed-off-by: Joachim Wiberg <troglobit@gmail.com> | Safe | null | null |
RGWOpType get_type() override { return RGW_OP_PUT_LC; } | 0 | [
"CWE-770"
] | ceph | ab29bed2fc9f961fe895de1086a8208e21ddaddc | 72,034,991,451,829,730,000,000,000,000,000,000,000 | 1 | rgw: fix issues with 'enforce bounds' patch
The patch to enforce bounds on max-keys/max-uploads/max-parts had a few
issues that would prevent us from compiling it. Instead of changing the
code provided by the submitter, we're addressing them in a separate
commit to maintain the DCO.
Signed-off-by: Joao Eduardo Luis <... | Safe | 770 | {"cwe_id": "CWE-770", "vulnerability_type": "Allocation of Resources Without Limits or Throttling", "description": "The product allocates a reusable resource or group of resources on behalf of an actor without imposing any intended restrictions on the size or number of resources that can be allocated.", "severity": "Hi... |
sockaddr_setport(struct sockaddr *sa, ev_uint16_t port)
{
if (sa->sa_family == AF_INET) {
((struct sockaddr_in *)sa)->sin_port = htons(port);
} else if (sa->sa_family == AF_INET6) {
((struct sockaddr_in6 *)sa)->sin6_port = htons(port);
}
} | 0 | [
"CWE-125"
] | libevent | 96f64a022014a208105ead6c8a7066018449d86d | 49,592,091,596,307,560,000,000,000,000,000,000,000 | 8 | evdns: name_parse(): fix remote stack overread
@asn-the-goblin-slayer:
"the name_parse() function in libevent's DNS code is vulnerable to a buffer overread.
971 if (cp != name_out) {
972 if (cp + 1 >= end) return -1;
973 *cp++ = '.';
974 }
975 if (cp + ... | Safe | 125 | {"cwe_id": "CWE-125", "vulnerability_type": "Out-of-bounds Read", "description": "The product reads data past the end, or before the beginning, of the intended buffer.", "severity": null, "category": "OOB read", "impact": ["Read Memory", "Bypass Protection Mechanism", "DoS: Crash, Exit, or Restart", "Varies by Context"... |
static int udf_check_anchor_block(struct super_block *sb, sector_t block,
struct kernel_lb_addr *fileset)
{
struct buffer_head *bh;
uint16_t ident;
int ret;
if (UDF_QUERY_FLAG(sb, UDF_FLAG_VARCONV) &&
udf_fixed_to_variable(block) >=
sb->s_bdev->bd_inode->i_size >> sb->s_blocksize_bits)
return 0;
... | 0 | [
"CWE-119",
"CWE-787"
] | linux | 1df2ae31c724e57be9d7ac00d78db8a5dabdd050 | 268,115,529,422,204,400,000,000,000,000,000,000,000 | 23 | udf: Fortify loading of sparing table
Add sanity checks when loading sparing table from disk to avoid accessing
unallocated memory or writing to it.
Signed-off-by: Jan Kara <jack@suse.cz> | Safe | 119 | {"cwe_id": "CWE-119", "vulnerability_type": "Improper Restriction of Operations within the Bounds of a Memory Buffer", "description": "The product performs operations on a memory buffer, but it reads from or writes to a memory location outside the buffer's intended boundary. This may result in read or write operations ... |
int ida_pre_get(struct ida *ida, gfp_t gfp_mask)
{
/* allocate idr_layers */
if (!idr_pre_get(&ida->idr, gfp_mask))
return 0;
/* allocate free_bitmap */
if (!ida->free_bitmap) {
struct ida_bitmap *bitmap;
bitmap = kmalloc(sizeof(struct ida_bitmap), gfp_mask);
if (!bitmap)
return 0;
free_bitmap(ida, ... | 0 | [] | linux | 2dcb22b346be7b7b7e630a8970d69cf3f1111ec1 | 297,893,465,646,270,800,000,000,000,000,000,000,000 | 19 | idr: fix backtrack logic in idr_remove_all
Currently idr_remove_all will fail with a use after free error if
idr::layers is bigger than 2, which on 32 bit systems corresponds to items
more than 1024. This is due to stepping back too many levels during
backtracking. For simplicity let's assume that IDR_BITS=1 -> we h... | Safe | null | null |
int kvm_arch_hardware_enable(void)
{
/* every s390 is virtualization enabled ;-) */
return 0;
} | 0 | [
"CWE-416"
] | linux | 0774a964ef561b7170d8d1b1bfe6f88002b6d219 | 143,943,492,953,819,730,000,000,000,000,000,000,000 | 5 | 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... | Safe | 416 | {"cwe_id": "CWE-416", "vulnerability_type": "Use After Free", "description": "The product reuses or references memory after it has been freed. At some point afterward, the memory may be allocated again and saved in another pointer, while the original pointer references a location somewhere within the new allocation. An... |
rdata2sockaddr(const struct packed_rrset_data* rd, uint16_t rtype, size_t i,
struct sockaddr_storage* ss, socklen_t* addrlenp)
{
/* unbound can accept and cache odd-length AAAA/A records, so we have
* to validate the length. */
if(rtype == LDNS_RR_TYPE_A && rd->rr_len[i] == 6) {
struct sockaddr_in* sa4 = (struct... | 0 | [
"CWE-190"
] | unbound | 02080f6b180232f43b77f403d0c038e9360a460f | 303,698,028,139,607,500,000,000,000,000,000,000,000 | 26 | - Fix Integer Overflows in Size Calculations,
reported by X41 D-Sec. | Safe | 190 | {"cwe_id": "CWE-190", "vulnerability_type": "Integer Overflow or Wraparound", "description": "The product performs a calculation that can\n produce an integer overflow or wraparound when the logic\n assumes that the resulting value will always be larger than\n the original value. This occurs whe... |
ere_char (c)
int c;
{
switch (c)
{
case '.':
case '[':
case '\\':
case '(':
case ')':
case '*':
case '+':
case '?':
case '{':
case '|':
case '^':
case '$':
return 1;
default:
return 0;
}
return (0);
} | 0 | [
"CWE-273",
"CWE-787"
] | bash | 951bdaad7a18cc0dc1036bba86b18b90874d39ff | 183,740,538,309,757,080,000,000,000,000,000,000,000 | 23 | commit bash-20190628 snapshot | Safe | 273 | {"cwe_id": "CWE-273", "vulnerability_type": "Improper Check for Dropped Privileges", "description": "The product attempts to drop privileges but does not check or incorrectly checks to see if the drop succeeded.", "severity": "Medium", "category": null, "impact": ["Gain Privileges or Assume Identity", "Gain Privileges ... |
xmlSchemaGetFreshElemInfo(xmlSchemaValidCtxtPtr vctxt)
{
xmlSchemaNodeInfoPtr info = NULL;
if (vctxt->depth > vctxt->sizeElemInfos) {
VERROR_INT("xmlSchemaGetFreshElemInfo",
"inconsistent depth encountered");
return (NULL);
}
if (vctxt->elemInfos == NULL) {
vctxt->elemInfos = (xmlSchemaNodeInfo... | 0 | [
"CWE-134"
] | libxml2 | 4472c3a5a5b516aaf59b89be602fbce52756c3e9 | 338,720,293,883,197,180,000,000,000,000,000,000,000 | 62 | Fix some format string warnings with possible format string vulnerability
For https://bugzilla.gnome.org/show_bug.cgi?id=761029
Decorate every method in libxml2 with the appropriate
LIBXML_ATTR_FORMAT(fmt,args) macro and add some cleanups
following the reports. | Safe | 134 | {"cwe_id": "CWE-134", "vulnerability_type": "Use of Externally-Controlled Format String", "description": "The product uses a function that accepts a format string as an argument, but the format string originates from an external source.", "severity": "High", "category": null, "impact": ["Read Memory", "Modify Memory", ... |
static int jpc_dec_process_siz(jpc_dec_t *dec, jpc_ms_t *ms)
{
jpc_siz_t *siz = &ms->parms.siz;
int compno;
int tileno;
jpc_dec_tile_t *tile;
jpc_dec_tcomp_t *tcomp;
int htileno;
int vtileno;
jpc_dec_cmpt_t *cmpt;
dec->xstart = siz->xoff;
dec->ystart = siz->yoff;
dec->xend = siz->width;
dec->yend = siz->he... | 1 | [
"CWE-476"
] | jasper | 69a1439a5381e42b06ec6a06ed2675eb793babee | 234,174,810,931,667,000,000,000,000,000,000,000,000 | 96 | The member (pi) in tiles was not properly initialized.
This is now corrected.
Also, each tile is now only cleaned up once. | Vulnerable | 476 | {"cwe_id": "CWE-476", "vulnerability_type": "NULL Pointer Dereference", "description": "The product dereferences a pointer that it expects to be valid but is NULL.", "severity": "Medium", "category": "NPD", "impact": ["DoS: Crash, Exit, or Restart", "Execute Unauthorized Code or Commands", "Read Memory", "Modify Memory... |
fd_ispipe (fd)
int fd;
{
errno = 0;
return ((lseek (fd, 0L, SEEK_CUR) < 0) && (errno == ESPIPE));
} | 0 | [] | bash | 955543877583837c85470f7fb8a97b7aa8d45e6c | 334,518,582,614,410,180,000,000,000,000,000,000,000 | 6 | bash-4.4-rc2 release | Safe | null | null |
archive_read_format_rar_bid(struct archive_read *a, int best_bid)
{
const char *p;
/* If there's already a bid > 30, we'll never win. */
if (best_bid > 30)
return (-1);
if ((p = __archive_read_ahead(a, 7, NULL)) == NULL)
return (-1);
if (memcmp(p, RAR_SIGNATURE, 7) == 0)
return (30);
if ((p[0... | 0 | [
"CWE-119",
"CWE-787"
] | libarchive | 05caadc7eedbef471ac9610809ba683f0c698700 | 325,194,919,359,807,600,000,000,000,000,000,000,000 | 39 | Issue 719: Fix for TALOS-CAN-154
A RAR file with an invalid zero dictionary size was not being
rejected, leading to a zero-sized allocation for the dictionary
storage which was then overwritten during the dictionary initialization.
Thanks to the Open Source and Threat Intelligence project at Cisco for
reporting this... | Safe | 119 | {"cwe_id": "CWE-119", "vulnerability_type": "Improper Restriction of Operations within the Bounds of a Memory Buffer", "description": "The product performs operations on a memory buffer, but it reads from or writes to a memory location outside the buffer's intended boundary. This may result in read or write operations ... |
static u8 dccp_feat_is_valid_nn_val(u8 feat_num, u64 val)
{
switch (feat_num) {
case DCCPF_ACK_RATIO:
return val <= DCCPF_ACK_RATIO_MAX;
case DCCPF_SEQUENCE_WINDOW:
return val >= DCCPF_SEQ_WMIN && val <= DCCPF_SEQ_WMAX;
}
return 0; /* feature unknown - so we can't tell */
} | 0 | [
"CWE-401"
] | linux | 1d3ff0950e2b40dc861b1739029649d03f591820 | 109,978,286,394,121,220,000,000,000,000,000,000,000 | 10 | dccp: Fix memleak in __feat_register_sp
If dccp_feat_push_change fails, we forget free the mem
which is alloced by kmemdup in dccp_feat_clone_sp_val.
Reported-by: Hulk Robot <hulkci@huawei.com>
Fixes: e8ef967a54f4 ("dccp: Registration routines for changing feature values")
Reviewed-by: Mukesh Ojha <mojha@codeaurora.o... | Safe | 401 | {"cwe_id": "CWE-401", "vulnerability_type": "Missing Release of Memory after Effective Lifetime", "description": "The product does not sufficiently track and release allocated memory after it has been used, making the memory unavailable for reallocation and reuse.", "severity": "Medium", "category": "Memory Leak", "imp... |
virtual bool hash_join_is_possible() { return TRUE; } | 0 | [
"CWE-416",
"CWE-703"
] | server | 08c7ab404f69d9c4ca6ca7a9cf7eec74c804f917 | 233,125,636,710,575,900,000,000,000,000,000,000,000 | 1 | 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... | Safe | 416 | {"cwe_id": "CWE-416", "vulnerability_type": "Use After Free", "description": "The product reuses or references memory after it has been freed. At some point afterward, the memory may be allocated again and saved in another pointer, while the original pointer references a location somewhere within the new allocation. An... |
Media_Block_Obj Parser::parse_media_block()
{
stack.push_back(Scope::Media);
Media_Block_Obj media_block = SASS_MEMORY_NEW(Media_Block, pstate, {}, {});
media_block->media_queries(parse_media_queries());
Media_Block_Obj prev_media_block = last_media_block;
last_media_block = media_block;
m... | 0 | [
"CWE-125"
] | libsass | eb15533b07773c30dc03c9d742865604f47120ef | 86,906,958,244,780,800,000,000,000,000,000,000,000 | 14 | Fix memory leak in `parse_ie_keyword_arg`
`kwd_arg` would never get freed when there was a parse error in
`parse_ie_keyword_arg`.
Closes #2656 | Safe | 125 | {"cwe_id": "CWE-125", "vulnerability_type": "Out-of-bounds Read", "description": "The product reads data past the end, or before the beginning, of the intended buffer.", "severity": null, "category": "OOB read", "impact": ["Read Memory", "Bypass Protection Mechanism", "DoS: Crash, Exit, or Restart", "Varies by Context"... |
m4_dnl (struct obstack *obs, int argc, token_data **argv)
{
if (bad_argc (argv[0], argc, 1, 1))
return;
skip_line ();
} | 0 | [] | m4 | 5345bb49077bfda9fabd048e563f9e7077fe335d | 45,773,817,996,351,510,000,000,000,000,000,000,000 | 7 | Minor security fix: Quote output of mkstemp.
* src/builtin.c (mkstemp_helper): Produce quoted output.
* doc/m4.texinfo (Mkstemp): Update the documentation and tests.
* NEWS: Document this change.
Signed-off-by: Eric Blake <ebb9@byu.net>
(cherry picked from commit bd9900d65eb9cd5add0f107e94b513fa267495ba) | Safe | null | null |
maybe_autotrim(void)
{
/* Trim only when in normal mode, the coefficients are fresh, the current
offset is above the threshold and the system clock is synchronized */
if (operating_mode != OM_NORMAL || !coefs_valid || n_samples_since_regression)
return;
if (autotrim_threshold <= 0.0 || fabs(coef_seco... | 0 | [
"CWE-59"
] | chrony | e18903a6b56341481a2e08469c0602010bf7bfe3 | 63,798,458,850,200,890,000,000,000,000,000,000,000 | 16 | switch to new util file functions
Replace all fopen(), rename(), and unlink() calls with the new util
functions. | Safe | 59 | {"cwe_id": "CWE-59", "vulnerability_type": "Improper Link Resolution Before File Access ('Link Following')", "description": "The product attempts to access a file based on the filename, but it does not properly prevent that filename from identifying a link or shortcut that resolves to an unintended resource.", "severit... |
static int ext4_ext_zeroout(struct inode *inode, struct ext4_extent *ex)
{
int ret = -EIO;
struct bio *bio;
int blkbits, blocksize;
sector_t ee_pblock;
struct completion event;
unsigned int ee_len, len, done, offset;
blkbits = inode->i_blkbits;
blocksize = inode->i_sb->s_blocksize;
ee_len = ext4_ext_get... | 0 | [
"CWE-703"
] | linux | 744692dc059845b2a3022119871846e74d4f6e11 | 209,351,751,417,402,960,000,000,000,000,000,000,000 | 65 | ext4: use ext4_get_block_write in buffer write
Allocate uninitialized extent before ext4 buffer write and
convert the extent to initialized after io completes.
The purpose is to make sure an extent can only be marked
initialized after it has been written with new data so
we can safely drop the i_mutex lock in ext4 DIO... | Safe | 703 | {"cwe_id": "CWE-703", "vulnerability_type": "Improper Check or Handling of Exceptional Conditions", "description": "The product does not properly anticipate or handle exceptional conditions that rarely occur during normal operation of the product.", "severity": null, "category": null, "impact": ["Read Application Data"... |
static inline int cipso_v4_cache_add(const struct sk_buff *skb,
const struct netlbl_lsm_secattr *secattr)
{
return 0;
} | 0 | [
"CWE-400",
"CWE-703"
] | linux | f2e5ddcc0d12f9c4c7b254358ad245c9dddce13b | 197,385,820,593,892,170,000,000,000,000,000,000,000 | 5 | net: fix cipso packet validation when !NETLABEL
When CONFIG_NETLABEL is disabled, the cipso_v4_validate() function could loop
forever in the main loop if opt[opt_iter +1] == 0, this will causing a kernel
crash in an SMP system, since the CPU executing this function will
stall /not respond to IPIs.
This problem can be... | Safe | 400 | {"cwe_id": "CWE-400", "vulnerability_type": "Uncontrolled Resource Consumption", "description": "The product does not properly control the allocation and maintenance of a limited resource.", "severity": "High", "category": "Resource Exhaustion", "impact": ["DoS: Crash, Exit, or Restart", "DoS: Resource Consumption (CPU... |
static int thread_cpu_timer_create(struct k_itimer *timer)
{
timer->it_clock = THREAD_CLOCK;
return posix_cpu_timer_create(timer);
} | 0 | [
"CWE-189"
] | linux | f8bd2258e2d520dff28c855658bd24bdafb5102d | 60,582,985,285,644,390,000,000,000,000,000,000,000 | 5 | remove div_long_long_rem
x86 is the only arch right now, which provides an optimized for
div_long_long_rem and it has the downside that one has to be very careful that
the divide doesn't overflow.
The API is a little akward, as the arguments for the unsigned divide are
signed. The signed version also doesn't handle ... | Safe | 189 | null |
xmlDOMWrapAdoptBranch(xmlDOMWrapCtxtPtr ctxt,
xmlDocPtr sourceDoc,
xmlNodePtr node,
xmlDocPtr destDoc,
xmlNodePtr destParent,
int options ATTRIBUTE_UNUSED)
{
int ret = 0;
xmlNodePtr cur, curElem = NULL;
xmlNsMapPtr nsMap = NULL;
xmlNsMapItemPtr mi;
xmlNsPtr ns... | 0 | [
"CWE-190"
] | libxml2 | 6c283d83eccd940bcde15634ac8c7f100e3caefd | 277,769,405,091,900,840,000,000,000,000,000,000,000 | 336 | [CVE-2022-29824] Fix integer overflows in xmlBuf and xmlBuffer
In several places, the code handling string buffers didn't check for
integer overflow or used wrong types for buffer sizes. This could
result in out-of-bounds writes or other memory errors when working on
large, multi-gigabyte buffers.
Thanks to Felix Wil... | Safe | 190 | {"cwe_id": "CWE-190", "vulnerability_type": "Integer Overflow or Wraparound", "description": "The product performs a calculation that can\n produce an integer overflow or wraparound when the logic\n assumes that the resulting value will always be larger than\n the original value. This occurs whe... |
struct yang_data *yang_data_new_enum(const char *xpath, int value)
{
const struct lysc_node *snode;
const struct lysc_node_leaf *sleaf;
const struct lysc_type_enum *type;
const struct lysc_type_bitenum_item *enums;
snode = lys_find_path(ly_native_ctx, NULL, xpath, 0);
if (snode == NULL) {
flog_err(EC_LIB_YANG_... | 0 | [
"CWE-119",
"CWE-787"
] | frr | ac3133450de12ba86c051265fc0f1b12bc57b40c | 53,522,425,083,760,420,000,000,000,000,000,000,000 | 33 | isisd: fix #10505 using base64 encoding
Using base64 instead of the raw string to encode
the binary data.
Signed-off-by: whichbug <whichbug@github.com> | Safe | 119 | {"cwe_id": "CWE-119", "vulnerability_type": "Improper Restriction of Operations within the Bounds of a Memory Buffer", "description": "The product performs operations on a memory buffer, but it reads from or writes to a memory location outside the buffer's intended boundary. This may result in read or write operations ... |
static void setup_pdev_dma_masks(struct platform_device *pdev)
{
pdev->dev.dma_parms = &pdev->dma_parms;
if (!pdev->dev.coherent_dma_mask)
pdev->dev.coherent_dma_mask = DMA_BIT_MASK(32);
if (!pdev->dev.dma_mask) {
pdev->platform_dma_mask = DMA_BIT_MASK(32);
pdev->dev.dma_mask = &pdev->platform_dma_mask;
}
}; | 0 | [
"CWE-787"
] | linux | aa838896d87af561a33ecefea1caa4c15a68bc47 | 80,760,806,944,455,880,000,000,000,000,000,000,000 | 11 | drivers core: Use sysfs_emit and sysfs_emit_at for show(device *...) functions
Convert the various sprintf fmaily calls in sysfs device show functions
to sysfs_emit and sysfs_emit_at for PAGE_SIZE buffer safety.
Done with:
$ spatch -sp-file sysfs_emit_dev.cocci --in-place --max-width=80 .
And cocci script:
$ cat s... | Safe | 787 | {"cwe_id": "CWE-787", "vulnerability_type": "Out-of-bounds Write", "description": "The product writes data past the end, or before the beginning, of the intended buffer.", "severity": "High", "category": "Memory Corruption", "impact": ["Modify Memory", "Execute Unauthorized Code or Commands", "DoS: Crash, Exit, or Rest... |
void session_set_recv_data_notify(Session *session, RecvDataNotify notify_func,
gpointer data)
{
session->recv_data_notify = notify_func;
session->recv_data_notify_data = data;
} | 0 | [] | claws | fcc25329049b6f9bd8d890f1197ed61eb12e14d5 | 131,937,310,772,790,420,000,000,000,000,000,000,000 | 6 | fix STARTTLS protocol violation
with thanks to, and patch by Damian Poddebniak and Hanno Böck | Safe | null | null |
static inline bool proc_inode_is_dead(struct inode *inode)
{
return !proc_pid(inode)->tasks[PIDTYPE_PID].first;
} | 0 | [
"CWE-362"
] | linux | 8148a73c9901a8794a50f950083c00ccf97d43b3 | 46,675,180,788,086,800,000,000,000,000,000,000,000 | 4 | proc: prevent accessing /proc/<PID>/environ until it's ready
If /proc/<PID>/environ gets read before the envp[] array is fully set up
in create_{aout,elf,elf_fdpic,flat}_tables(), we might end up trying to
read more bytes than are actually written, as env_start will already be
set but env_end will still be zero, makin... | Safe | 362 | {"cwe_id": "CWE-362", "vulnerability_type": "Concurrent Execution using Shared Resource with Improper Synchronization ('Race Condition')", "description": "The product contains a concurrent code sequence that requires temporary, exclusive access to a shared resource, but a timing window exists in which the shared resour... |
static int cookie_output(struct CookieInfo *c, const char *dumphere)
{
struct Cookie *co;
FILE *out;
bool use_stdout=FALSE;
if((NULL == c) || (0 == c->numcookies))
/* If there are no known cookies, we don't write or even create any
destination file */
return 0;
/* at first, remove expired coo... | 0 | [
"CWE-119"
] | curl | b5f947b8ac0e282c61c75b69cd5b9d37dafc6959 | 9,756,049,655,808,969,000,000,000,000,000,000,000 | 53 | cookie: cookie parser out of boundary memory access
The internal libcurl function called sanitize_cookie_path() that cleans
up the path element as given to it from a remote site or when read from
a file, did not properly validate the input. If given a path that
consisted of a single double-quote, libcurl would index a... | Safe | 119 | {"cwe_id": "CWE-119", "vulnerability_type": "Improper Restriction of Operations within the Bounds of a Memory Buffer", "description": "The product performs operations on a memory buffer, but it reads from or writes to a memory location outside the buffer's intended boundary. This may result in read or write operations ... |
read_string_decrypt(bufinfo_T *bi, int len)
{
char_u *ptr = alloc((unsigned)len + 1);
if (ptr != NULL)
{
if (len > 0 && undo_read(bi, ptr, len) == FAIL)
{
vim_free(ptr);
return NULL;
}
ptr[len] = NUL;
#ifdef FEAT_CRYPT
if (bi->bi_state != NULL && bi->bi_buffer == NULL)
crypt_decode_inp... | 0 | [
"CWE-190"
] | vim | 3eb1637b1bba19519885dd6d377bd5596e91d22c | 179,518,463,830,872,100,000,000,000,000,000,000,000 | 19 | patch 8.0.0377: possible overflow when reading corrupted undo file
Problem: Possible overflow when reading corrupted undo file.
Solution: Check if allocated size is not too big. (King) | Safe | 190 | {"cwe_id": "CWE-190", "vulnerability_type": "Integer Overflow or Wraparound", "description": "The product performs a calculation that can\n produce an integer overflow or wraparound when the logic\n assumes that the resulting value will always be larger than\n the original value. This occurs whe... |
static s32 brcmf_inform_single_bss(struct brcmf_cfg80211_info *cfg,
struct brcmf_bss_info_le *bi)
{
struct wiphy *wiphy = cfg_to_wiphy(cfg);
struct ieee80211_channel *notify_channel;
struct cfg80211_bss *bss;
struct ieee80211_supported_band *band;
struct brcmu_chan ch;
u16 channel;
u32 freq;
u16 notify_c... | 0 | [
"CWE-119",
"CWE-703"
] | linux | ded89912156b1a47d940a0c954c43afbabd0c42c | 43,736,178,386,282,590,000,000,000,000,000,000,000 | 63 | 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... | Safe | 119 | {"cwe_id": "CWE-119", "vulnerability_type": "Improper Restriction of Operations within the Bounds of a Memory Buffer", "description": "The product performs operations on a memory buffer, but it reads from or writes to a memory location outside the buffer's intended boundary. This may result in read or write operations ... |
Field_timestamp_with_dec(uchar *ptr_arg,
uchar *null_ptr_arg, uchar null_bit_arg,
enum utype unireg_check_arg,
const LEX_CSTRING *field_name_arg,
TABLE_SHARE *share, uint dec_arg) :
Field_timestamp(ptr_arg,
... | 0 | [
"CWE-416",
"CWE-703"
] | server | 08c7ab404f69d9c4ca6ca7a9cf7eec74c804f917 | 11,225,444,394,341,265,000,000,000,000,000,000,000 | 12 | 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... | Safe | 416 | {"cwe_id": "CWE-416", "vulnerability_type": "Use After Free", "description": "The product reuses or references memory after it has been freed. At some point afterward, the memory may be allocated again and saved in another pointer, while the original pointer references a location somewhere within the new allocation. An... |
static int __init fail_page_alloc_debugfs(void)
{
umode_t mode = S_IFREG | S_IRUSR | S_IWUSR;
struct dentry *dir;
dir = fault_create_debugfs_attr("fail_page_alloc", NULL,
&fail_page_alloc.attr);
if (IS_ERR(dir))
return PTR_ERR(dir);
if (!debugfs_create_bool("ignore-gfp-wait", mode, dir,
&fail_page_all... | 0 | [] | linux | 400e22499dd92613821374c8c6c88c7225359980 | 267,852,747,163,332,600,000,000,000,000,000,000,000 | 26 | mm: don't warn about allocations which stall for too long
Commit 63f53dea0c98 ("mm: warn about allocations which stall for too
long") was a great step for reducing possibility of silent hang up
problem caused by memory allocation stalls. But this commit reverts it,
for it is possible to trigger OOM lockup and/or soft... | Safe | null | null |
TEST_F(QueryPlannerTest, AndWithUnindexedOrChild) {
addIndex(BSON("a" << 1));
runQuery(fromjson("{a:20, $or: [{b:1}, {c:7}]}"));
ASSERT_EQUALS(getNumSolutions(), 2U);
assertSolutionExists("{cscan: {dir: 1}}");
// Logical rewrite means we could get one of these two outcomes:
size_t matches = 0;... | 0 | [] | mongo | ee97c0699fd55b498310996ee002328e533681a3 | 217,071,064,264,483,460,000,000,000,000,000,000,000 | 20 | SERVER-36993 Fix crash due to incorrect $or pushdown for indexed $expr. | Safe | null | null |
int security_get_user_sids(u32 fromsid,
char *username,
u32 **sids,
u32 *nel)
{
struct context *fromcon, usercon;
u32 *mysids = NULL, *mysids2, sid;
u32 mynel = 0, maxnel = SIDS_NEL;
struct user_datum *user;
struct role_datum *role;
struct ebitmap_node *rnode, *tnode;
int rc = 0, i, j;
*sids ... | 0 | [
"CWE-20"
] | linux | 2172fa709ab32ca60e86179dc67d0857be8e2c98 | 333,744,064,539,753,160,000,000,000,000,000,000,000 | 98 | SELinux: Fix kernel BUG on empty security contexts.
Setting an empty security context (length=0) on a file will
lead to incorrectly dereferencing the type and other fields
of the security context structure, yielding a kernel BUG.
As a zero-length security context is never valid, just reject
all such security contexts... | Safe | 20 | {"cwe_id": "CWE-20", "vulnerability_type": "Improper Input Validation", "description": "The product receives input or data, but it does\n not validate or incorrectly validates that the input has the\n properties that are required to process the data safely and\n correctly.", "severity": "High", "ca... |
format_defaults(struct format_tree *ft, struct client *c, struct session *s,
struct winlink *wl, struct window_pane *wp)
{
if (c != NULL && s != NULL && c->session != s)
log_debug("%s: session does not match", __func__);
format_add(ft, "session_format", "%d", s != NULL);
format_add(ft, "window_format", "%d", ... | 0 | [] | src | b32e1d34e10a0da806823f57f02a4ae6e93d756e | 208,576,814,512,764,900,000,000,000,000,000,000,000 | 26 | evbuffer_new and bufferevent_new can both fail (when malloc fails) and
return NULL. GitHub issue 1547. | Safe | null | null |
CImgDisplay& resize(const int nwidth, const int nheight, const bool force_redraw=true) {
if (!nwidth || !nheight || (is_empty() && (nwidth<0 || nheight<0))) return assign();
if (is_empty()) return assign(nwidth,nheight);
Display *const dpy = cimg::X11_attr().display;
const unsigned int
... | 0 | [
"CWE-125"
] | CImg | 10af1e8c1ad2a58a0a3342a856bae63e8f257abb | 37,753,063,558,683,190,000,000,000,000,000,000,000 | 34 | Fix other issues in 'CImg<T>::load_bmp()'. | Safe | 125 | {"cwe_id": "CWE-125", "vulnerability_type": "Out-of-bounds Read", "description": "The product reads data past the end, or before the beginning, of the intended buffer.", "severity": null, "category": "OOB read", "impact": ["Read Memory", "Bypass Protection Mechanism", "DoS: Crash, Exit, or Restart", "Varies by Context"... |
lacks_top_left (NautilusFile *file)
{
return file->details->file_info_is_up_to_date &&
!file->details->top_left_text_is_up_to_date
&& nautilus_file_should_get_top_left_text (file);
} | 0 | [] | nautilus | 7632a3e13874a2c5e8988428ca913620a25df983 | 287,148,820,882,153,800,000,000,000,000,000,000,000 | 6 | Check for trusted desktop file launchers.
2009-02-24 Alexander Larsson <alexl@redhat.com>
* libnautilus-private/nautilus-directory-async.c:
Check for trusted desktop file launchers.
* libnautilus-private/nautilus-file-private.h:
* libnautilus-private/nautilus-file.c:
* libnautilus-... | Safe | null | null |
static void hrtimer_force_reprogram(struct hrtimer_cpu_base *cpu_base)
{
int i;
struct hrtimer_clock_base *base = cpu_base->clock_base;
ktime_t expires;
cpu_base->expires_next.tv64 = KTIME_MAX;
for (i = 0; i < HRTIMER_MAX_CLOCK_BASES; i++, base++) {
struct hrtimer *timer;
if (!base->first)
continue;
ti... | 0 | [
"CWE-189"
] | linux-2.6 | 13788ccc41ceea5893f9c747c59bc0b28f2416c2 | 269,429,321,497,458,460,000,000,000,000,000,000,000 | 22 | [PATCH] hrtimer: prevent overrun DoS in hrtimer_forward()
hrtimer_forward() does not check for the possible overflow of
timer->expires. This can happen on 64 bit machines with large interval
values and results currently in an endless loop in the softirq because the
expiry value becomes negative and therefor the timer... | Safe | 189 | null |
unsigned long X509_issuer_name_hash_old(X509 *x)
{
return X509_NAME_hash_old(x->cert_info.issuer);
} | 0 | [
"CWE-476"
] | openssl | 8130d654d1de922ea224fa18ee3bc7262edc39c0 | 232,088,158,901,127,230,000,000,000,000,000,000,000 | 4 | Fix Null pointer deref in X509_issuer_and_serial_hash()
The OpenSSL public API function X509_issuer_and_serial_hash() attempts
to create a unique hash value based on the issuer and serial number data
contained within an X509 certificate. However it fails to correctly
handle any errors that may occur while parsing the ... | Safe | 476 | {"cwe_id": "CWE-476", "vulnerability_type": "NULL Pointer Dereference", "description": "The product dereferences a pointer that it expects to be valid but is NULL.", "severity": "Medium", "category": "NPD", "impact": ["DoS: Crash, Exit, or Restart", "Execute Unauthorized Code or Commands", "Read Memory", "Modify Memory... |
mrb_mod_module_function(mrb_state *mrb, mrb_value mod)
{
mrb_value *argv;
mrb_int argc, i;
mrb_sym mid;
mrb_method_t m;
struct RClass *rclass;
int ai;
mrb_check_type(mrb, mod, MRB_TT_MODULE);
mrb_get_args(mrb, "*", &argv, &argc);
if (argc == 0) {
/* set MODFUNC SCOPE if implemented */
return... | 0 | [
"CWE-476",
"CWE-415"
] | mruby | faa4eaf6803bd11669bc324b4c34e7162286bfa3 | 10,014,386,302,644,207,000,000,000,000,000,000,000 | 35 | `mrb_class_real()` did not work for `BasicObject`; fix #4037 | Safe | 476 | {"cwe_id": "CWE-476", "vulnerability_type": "NULL Pointer Dereference", "description": "The product dereferences a pointer that it expects to be valid but is NULL.", "severity": "Medium", "category": "NPD", "impact": ["DoS: Crash, Exit, or Restart", "Execute Unauthorized Code or Commands", "Read Memory", "Modify Memory... |
static void write_bin_miss_response(conn *c, char *key, size_t nkey) {
if (nkey) {
char *ofs = c->wbuf + sizeof(protocol_binary_response_header);
add_bin_header(c, PROTOCOL_BINARY_RESPONSE_KEY_ENOENT,
0, nkey, nkey);
memcpy(ofs, key, nkey);
add_iov(c, ofs, nkey);
... | 0 | [
"CWE-20",
"CWE-703",
"CWE-400"
] | memcached | dbb7a8af90054bf4ef51f5814ef7ceb17d83d974 | 319,244,128,557,796,950,000,000,000,000,000,000,000 | 14 | disable UDP port by default
As reported, UDP amplification attacks have started to use insecure
internet-exposed memcached instances. UDP used to be a lot more popular as a
transport for memcached many years ago, but I'm not aware of many recent
users.
Ten years ago, the TCP connection overhead from many clients was ... | Safe | 20 | {"cwe_id": "CWE-20", "vulnerability_type": "Improper Input Validation", "description": "The product receives input or data, but it does\n not validate or incorrectly validates that the input has the\n properties that are required to process the data safely and\n correctly.", "severity": "High", "ca... |
tsize_t t2p_readwrite_pdf_image(T2P* t2p, TIFF* input, TIFF* output){
tsize_t written=0;
unsigned char* buffer=NULL;
unsigned char* samplebuffer=NULL;
tsize_t bufferoffset=0;
tsize_t samplebufferoffset=0;
tsize_t read=0;
tstrip_t i=0;
tstrip_t j=0;
tstrip_t stripcount=0;
tsize_t stripsize=0;
tsize_t sepstri... | 0 | [
"CWE-787"
] | libtiff | 7be2e452ddcf6d7abca88f41d3761e6edab72b22 | 84,052,621,455,541,960,000,000,000,000,000,000,000 | 618 | tiff2pdf.c: properly calculate datasize when saving to JPEG YCbCr
fixes #220 | Safe | 787 | {"cwe_id": "CWE-787", "vulnerability_type": "Out-of-bounds Write", "description": "The product writes data past the end, or before the beginning, of the intended buffer.", "severity": "High", "category": "Memory Corruption", "impact": ["Modify Memory", "Execute Unauthorized Code or Commands", "DoS: Crash, Exit, or Rest... |
static int rawv6_sendmsg(struct sock *sk, struct msghdr *msg, size_t len)
{
struct ipv6_txoptions opt_space;
DECLARE_SOCKADDR(struct sockaddr_in6 *, sin6, msg->msg_name);
struct in6_addr *daddr, *final_p, final;
struct inet_sock *inet = inet_sk(sk);
struct ipv6_pinfo *np = inet6_sk(sk);
struct raw6_sock *rp = raw... | 1 | [
"CWE-416",
"CWE-284",
"CWE-264"
] | linux | 45f6fad84cc305103b28d73482b344d7f5b76f39 | 62,975,981,226,886,950,000,000,000,000,000,000,000 | 183 | ipv6: add complete rcu protection around np->opt
This patch addresses multiple problems :
UDP/RAW sendmsg() need to get a stable struct ipv6_txoptions
while socket is not locked : Other threads can change np->opt
concurrently. Dmitry posted a syzkaller
(http://github.com/google/syzkaller) program desmonstrating
use-a... | Vulnerable | 416 | {"cwe_id": "CWE-416", "vulnerability_type": "Use After Free", "description": "The product reuses or references memory after it has been freed. At some point afterward, the memory may be allocated again and saved in another pointer, while the original pointer references a location somewhere within the new allocation. An... |
rb_str_free(VALUE str)
{
if (!STR_EMBED_P(str) && !STR_SHARED_P(str)) {
xfree(RSTRING(str)->as.heap.ptr);
}
} | 0 | [
"CWE-119"
] | ruby | 1c2ef610358af33f9ded3086aa2d70aac03dcac5 | 303,421,660,796,663,160,000,000,000,000,000,000,000 | 6 | * string.c (rb_str_justify): CVE-2009-4124.
Fixes a bug reported by
Emmanouel Kellinis <Emmanouel.Kellinis AT kpmg.co.uk>, KPMG London;
Patch by nobu.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@26038 b2dd03c8-39d4-4d8f-98ff-823fe69b080e | Safe | 119 | {"cwe_id": "CWE-119", "vulnerability_type": "Improper Restriction of Operations within the Bounds of a Memory Buffer", "description": "The product performs operations on a memory buffer, but it reads from or writes to a memory location outside the buffer's intended boundary. This may result in read or write operations ... |
void perf_event_output(struct perf_event *event,
struct perf_sample_data *data,
struct pt_regs *regs)
{
struct perf_output_handle handle;
struct perf_event_header header;
/* protect the callchain buffers */
rcu_read_lock();
perf_prepare_sample(&header, data, event, regs);
if (perf_output_begin(&handle, e... | 0 | [
"CWE-416",
"CWE-362"
] | linux | 12ca6ad2e3a896256f086497a7c7406a547ee373 | 338,122,020,030,358,080,000,000,000,000,000,000,000 | 22 | perf: Fix race in swevent hash
There's a race on CPU unplug where we free the swevent hash array
while it can still have events on. This will result in a
use-after-free which is BAD.
Simply do not free the hash array on unplug. This leaves the thing
around and no use-after-free takes place.
When the last swevent die... | Safe | 416 | {"cwe_id": "CWE-416", "vulnerability_type": "Use After Free", "description": "The product reuses or references memory after it has been freed. At some point afterward, the memory may be allocated again and saved in another pointer, while the original pointer references a location somewhere within the new allocation. An... |
void lua_text_pattern::pre_pattern(string &pat, string &fn) const
{
// Trim trailing spaces
pat.erase(pat.find_last_not_of(" \t\n\r") + 1);
fn += " pmatch([[";
fn += pat;
fn += "]], text, false) ";
pat.clear();
} | 0 | [
"CWE-434"
] | crawl | fc522ff6eb1bbb85e3de60c60a45762571e48c28 | 37,986,387,477,684,810,000,000,000,000,000,000,000 | 11 | Disable lua load(), loadstring() bytcode loading | Safe | 434 | {"cwe_id": "CWE-434", "vulnerability_type": "Unrestricted Upload of File with Dangerous Type", "description": "The product allows the upload or transfer of dangerous file types that are automatically processed within its environment.", "severity": "Medium", "category": "Unrestricted File Upload", "impact": ["Execute Un... |
void Compute(OpKernelContext* const context) override {
core::RefCountPtr<BoostedTreesEnsembleResource> resource;
// Get the resource.
OP_REQUIRES_OK(context, LookupResource(context, HandleFromInput(context, 0),
&resource));
// Get the inputs.
OpInputLis... | 1 | [
"CWE-703",
"CWE-197"
] | tensorflow | ca8c013b5e97b1373b3bb1c97ea655e69f31a575 | 237,230,056,782,568,400,000,000,000,000,000,000,000 | 85 | Prevent integer truncation from 64 to 32 bits.
The `tensorflow::Shard` functions last argument must be a 2 argument function where both arguments are `int64` (`long long`, 64 bits). However, there are usages where code passes in a function where arguments are `int` or `int32` (32 bits). In these cases, it is possible ... | Vulnerable | 703 | {"cwe_id": "CWE-703", "vulnerability_type": "Improper Check or Handling of Exceptional Conditions", "description": "The product does not properly anticipate or handle exceptional conditions that rarely occur during normal operation of the product.", "severity": null, "category": null, "impact": ["Read Application Data"... |
MagickExport MagickBooleanType WhiteThresholdImage(Image *image,
const char *threshold)
{
MagickBooleanType
status;
status=WhiteThresholdImageChannel(image,DefaultChannels,threshold,
&image->exception);
return(status);
} | 0 | [
"CWE-125"
] | ImageMagick6 | 35c7032723d85eee7318ff6c82f031fa2666b773 | 51,040,632,848,233,640,000,000,000,000,000,000,000 | 10 | https://github.com/ImageMagick/ImageMagick/issues/1609 | Safe | 125 | {"cwe_id": "CWE-125", "vulnerability_type": "Out-of-bounds Read", "description": "The product reads data past the end, or before the beginning, of the intended buffer.", "severity": null, "category": "OOB read", "impact": ["Read Memory", "Bypass Protection Mechanism", "DoS: Crash, Exit, or Restart", "Varies by Context"... |
static double Bohman(const double x,
const ResizeFilter *magick_unused(resize_filter))
{
/*
Bohman: 2rd Order cosine windowing function:
(1-x) cos(pi x) + sin(pi x) / pi.
Refactored by Nicolas Robidoux to one trig call, one sqrt call, and 7 flops,
taking advantage of the fact that the support of ... | 0 | [
"CWE-125"
] | ImageMagick | c5402b6e0fcf8b694ae2af6a6652ebb8ce0ccf46 | 155,879,351,359,528,500,000,000,000,000,000,000,000 | 16 | https://github.com/ImageMagick/ImageMagick/issues/717 | Safe | 125 | {"cwe_id": "CWE-125", "vulnerability_type": "Out-of-bounds Read", "description": "The product reads data past the end, or before the beginning, of the intended buffer.", "severity": null, "category": "OOB read", "impact": ["Read Memory", "Bypass Protection Mechanism", "DoS: Crash, Exit, or Restart", "Varies by Context"... |
ActiveUdpListener::ActiveUdpListener(Network::ConnectionHandler& parent,
Event::Dispatcher& dispatcher, Network::ListenerConfig& config)
: ActiveUdpListener(parent, dispatcher.createUdpListener(config.socket(), *this), config) {} | 0 | [
"CWE-835"
] | envoy | c8de199e2971f79cbcbc6b5eadc8c566b28705d1 | 81,639,348,146,584,000,000,000,000,000,000,000,000 | 3 | listener: clean up accept filter before creating connection (#8922)
Signed-off-by: Yuchen Dai <silentdai@gmail.com> | Safe | 835 | {"cwe_id": "CWE-835", "vulnerability_type": "Loop with Unreachable Exit Condition ('Infinite Loop')", "description": "The product contains an iteration or loop with an exit condition that cannot be reached, i.e., an infinite loop.", "severity": null, "category": null, "impact": ["DoS: Resource Consumption (CPU)", "DoS:... |
static void coroutine_fn mirror_iteration_done(MirrorOp *op, int ret)
{
MirrorBlockJob *s = op->s;
struct iovec *iov;
int64_t chunk_num;
int i, nb_chunks;
trace_mirror_iteration_done(s, op->offset, op->bytes, ret);
s->in_flight--;
s->bytes_in_flight -= op->bytes;
iov = op->qiov.iov;
... | 0 | [
"CWE-476"
] | qemu | 66fed30c9cd11854fc878a4eceb507e915d7c9cd | 57,058,758,342,823,880,000,000,000,000,000,000,000 | 36 | block/mirror: fix NULL pointer dereference in mirror_wait_on_conflicts()
In mirror_iteration() we call mirror_wait_on_conflicts() with
`self` parameter set to NULL.
Starting from commit d44dae1a7c we dereference `self` pointer in
mirror_wait_on_conflicts() without checks if it is not NULL.
Backtrace:
Program termi... | Safe | 476 | {"cwe_id": "CWE-476", "vulnerability_type": "NULL Pointer Dereference", "description": "The product dereferences a pointer that it expects to be valid but is NULL.", "severity": "Medium", "category": "NPD", "impact": ["DoS: Crash, Exit, or Restart", "Execute Unauthorized Code or Commands", "Read Memory", "Modify Memory... |
MagickExport MagickRealType DecodePixelGamma(const MagickRealType pixel)
{
if (pixel <= (0.0404482362771076*QuantumRange))
return(pixel/12.92f);
return((MagickRealType) (QuantumRange*DecodeGamma((double) (QuantumScale*
pixel+0.055)/1.055)));
} | 0 | [
"CWE-190"
] | ImageMagick | 406da3af9e09649cda152663c179902edf5ab3ac | 32,686,613,171,207,920,000,000,000,000,000,000,000 | 7 | https://github.com/ImageMagick/ImageMagick/issues/1732 | Safe | 190 | {"cwe_id": "CWE-190", "vulnerability_type": "Integer Overflow or Wraparound", "description": "The product performs a calculation that can\n produce an integer overflow or wraparound when the logic\n assumes that the resulting value will always be larger than\n the original value. This occurs whe... |
status WAVEFile::parseList(const Tag &id, uint32_t size)
{
Tag typeID;
readTag(&typeID);
size-=4;
if (typeID == "adtl")
{
/* Handle adtl sub-chunks. */
return parseADTLSubChunk(typeID, size);
}
else if (typeID == "INFO")
{
/* Handle INFO sub-chunks. */
return parseINFOSubChunk(typeID, size);
}
else
... | 0 | [
"CWE-119",
"CWE-284"
] | audiofile | a2e9eab8ea87c4ffc494d839ebb4ea145eb9f2e6 | 101,892,721,401,770,390,000,000,000,000,000,000,000 | 24 | Actually fail when error occurs in parseFormat
When there's an unsupported number of bits per sample or an invalid
number of samples per block, don't only print an error message using
the error handler, but actually stop parsing the file.
This fixes #35 (also reported at
https://bugzilla.opensuse.org/show_bug.cgi?id=... | Safe | 119 | {"cwe_id": "CWE-119", "vulnerability_type": "Improper Restriction of Operations within the Bounds of a Memory Buffer", "description": "The product performs operations on a memory buffer, but it reads from or writes to a memory location outside the buffer's intended boundary. This may result in read or write operations ... |
INST_HANDLER (nop) { // NOP
ESIL_A (",,");
} | 0 | [
"CWE-125"
] | radare2 | 041e53cab7ca33481ae45ecd65ad596976d78e68 | 147,993,186,058,158,830,000,000,000,000,000,000,000 | 3 | Fix crash in anal.avr | Safe | 125 | {"cwe_id": "CWE-125", "vulnerability_type": "Out-of-bounds Read", "description": "The product reads data past the end, or before the beginning, of the intended buffer.", "severity": null, "category": "OOB read", "impact": ["Read Memory", "Bypass Protection Mechanism", "DoS: Crash, Exit, or Restart", "Varies by Context"... |
ssize_t qemu_sendv_packet_async(NetClientState *sender,
const struct iovec *iov, int iovcnt,
NetPacketSent *sent_cb)
{
NetQueue *queue;
int ret;
if (sender->link_down || !sender->peer) {
return iov_size(iov, iovcnt);
}
/* Let ... | 1 | [
"CWE-190"
] | qemu | 25c01bd19d0e4b66f357618aeefda1ef7a41e21a | 131,551,872,594,448,400,000,000,000,000,000,000,000 | 30 | net: drop too large packet early
We try to detect and drop too large packet (>INT_MAX) in 1592a9947036
("net: ignore packet size greater than INT_MAX") during packet
delivering. Unfortunately, this is not sufficient as we may hit
another integer overflow when trying to queue such large packet in
qemu_net_queue_append_... | Vulnerable | 190 | {"cwe_id": "CWE-190", "vulnerability_type": "Integer Overflow or Wraparound", "description": "The product performs a calculation that can\n produce an integer overflow or wraparound when the logic\n assumes that the resulting value will always be larger than\n the original value. This occurs whe... |
static int ntop_interface_host_disable_alerts(lua_State* vm) {
return ntop_interface_host_trigger_alerts(vm, false);
} | 0 | [
"CWE-476"
] | ntopng | 01f47e04fd7c8d54399c9e465f823f0017069f8f | 170,859,749,144,007,800,000,000,000,000,000,000,000 | 3 | Security fix: prevents empty host from being used | Safe | 476 | {"cwe_id": "CWE-476", "vulnerability_type": "NULL Pointer Dereference", "description": "The product dereferences a pointer that it expects to be valid but is NULL.", "severity": "Medium", "category": "NPD", "impact": ["DoS: Crash, Exit, or Restart", "Execute Unauthorized Code or Commands", "Read Memory", "Modify Memory... |
static inline void list_del_leaf_cfs_rq(struct cfs_rq *cfs_rq)
{
} | 0 | [
"CWE-400",
"CWE-703",
"CWE-835"
] | linux | c40f7d74c741a907cfaeb73a7697081881c497d0 | 309,134,663,043,767,840,000,000,000,000,000,000,000 | 3 | sched/fair: Fix infinite loop in update_blocked_averages() by reverting a9e7f6544b9c
Zhipeng Xie, Xie XiuQi and Sargun Dhillon reported lockups in the
scheduler under high loads, starting at around the v4.18 time frame,
and Zhipeng Xie tracked it down to bugs in the rq->leaf_cfs_rq_list
manipulation.
Do a (manual) re... | Safe | 400 | {"cwe_id": "CWE-400", "vulnerability_type": "Uncontrolled Resource Consumption", "description": "The product does not properly control the allocation and maintenance of a limited resource.", "severity": "High", "category": "Resource Exhaustion", "impact": ["DoS: Crash, Exit, or Restart", "DoS: Resource Consumption (CPU... |
AnyP::Uri::authority(bool requirePort) const
{
if (authorityHttp_.isEmpty()) {
// both formats contain Host/IP
authorityWithPort_.append(host());
authorityHttp_ = authorityWithPort_;
// authorityForm_ only has :port if it is non-default
authorityWithPort_.appendf(":%u",port... | 0 | [
"CWE-20"
] | squid | dfd818595b54942cb1adc45f6aed95c9b706e3a8 | 18,009,694,788,378,307,000,000,000,000,000,000,000 | 16 | Merge pull request from GHSA-jvf6-h9gj-pmj6
* Add slash prefix to path-rootless or path-noscheme URLs
* Update src/anyp/Uri.cc
Co-authored-by: Alex Rousskov <rousskov@measurement-factory.com>
* restore file trailer GH auto-removes
* Remove redundant path-empty check
* Removed stale comment left behind by b2ab59a
... | Safe | 20 | {"cwe_id": "CWE-20", "vulnerability_type": "Improper Input Validation", "description": "The product receives input or data, but it does\n not validate or incorrectly validates that the input has the\n properties that are required to process the data safely and\n correctly.", "severity": "High", "ca... |
static double mp_log(_cimg_math_parser& mp) {
return std::log(_mp_arg(2)); | 0 | [
"CWE-125"
] | CImg | 10af1e8c1ad2a58a0a3342a856bae63e8f257abb | 293,787,921,317,984,100,000,000,000,000,000,000,000 | 3 | Fix other issues in 'CImg<T>::load_bmp()'. | Safe | 125 | {"cwe_id": "CWE-125", "vulnerability_type": "Out-of-bounds Read", "description": "The product reads data past the end, or before the beginning, of the intended buffer.", "severity": null, "category": "OOB read", "impact": ["Read Memory", "Bypass Protection Mechanism", "DoS: Crash, Exit, or Restart", "Varies by Context"... |
void j2k_destroy_cstr_index (opj_codestream_index_t *p_cstr_ind)
{
if (p_cstr_ind) {
if (p_cstr_ind->marker) {
opj_free(p_cstr_ind->marker);
p_cstr_ind->marker = NULL;
}
if (p_cstr_ind->tile_index) {
... | 0 | [
"CWE-416"
] | openjpeg | 940100c28ae28931722290794889cf84a92c5f6f | 48,347,480,743,119,770,000,000,000,000,000,000,000 | 38 | Fix potential use-after-free in opj_j2k_write_mco function
Fixes #563 | Safe | 416 | {"cwe_id": "CWE-416", "vulnerability_type": "Use After Free", "description": "The product reuses or references memory after it has been freed. At some point afterward, the memory may be allocated again and saved in another pointer, while the original pointer references a location somewhere within the new allocation. An... |
TIFFWriteDirectoryTagCheckedRational(TIFF* tif, uint32* ndir, TIFFDirEntry* dir, uint16 tag, double value)
{
static const char module[] = "TIFFWriteDirectoryTagCheckedRational";
uint32 m[2];
assert(sizeof(uint32)==4);
if( value < 0 )
{
TIFFErrorExt(tif->tif_clientdata,module,"Negat... | 0 | [
"CWE-617"
] | libtiff | de144fd228e4be8aa484c3caf3d814b6fa88c6d9 | 126,887,220,786,262,760,000,000,000,000,000,000,000 | 42 | TIFFWriteDirectorySec: avoid assertion. Fixes http://bugzilla.maptools.org/show_bug.cgi?id=2795. CVE-2018-10963 | Safe | 617 | {"cwe_id": "CWE-617", "vulnerability_type": "Reachable Assertion", "description": "The product contains an assert() or similar statement that can be triggered by an attacker, which leads to an application exit or other behavior that is more severe than necessary.", "severity": null, "category": "assertion failure", "im... |
static inline bool tcp_checksum_complete_user(struct sock *sk,
struct sk_buff *skb)
{
return !skb_csum_unnecessary(skb) &&
__tcp_checksum_complete_user(sk, skb);
} | 0 | [
"CWE-703",
"CWE-189"
] | linux | 8b8a321ff72c785ed5e8b4cf6eda20b35d427390 | 3,222,312,604,093,309,600,000,000,000,000,000,000 | 6 | 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... | Safe | 703 | {"cwe_id": "CWE-703", "vulnerability_type": "Improper Check or Handling of Exceptional Conditions", "description": "The product does not properly anticipate or handle exceptional conditions that rarely occur during normal operation of the product.", "severity": null, "category": null, "impact": ["Read Application Data"... |
gst_qtdemux_check_seekability (GstQTDemux * demux)
{
GstQuery *query;
gboolean seekable = FALSE;
gint64 start = -1, stop = -1;
if (demux->upstream_size)
return;
query = gst_query_new_seeking (GST_FORMAT_BYTES);
if (!gst_pad_peer_query (demux->sinkpad, query)) {
GST_DEBUG_OBJECT (demux, "seeking qu... | 0 | [
"CWE-125"
] | gst-plugins-good | d0949baf3dadea6021d54abef6802fed5a06af75 | 18,780,583,147,319,070,000,000,000,000,000,000,000 | 38 | qtdemux: Fix out of bounds read in tag parsing code
We can't simply assume that the length of the tag value as given
inside the stream is correct but should also check against the amount of
data we have actually available.
https://bugzilla.gnome.org/show_bug.cgi?id=775451 | Safe | 125 | {"cwe_id": "CWE-125", "vulnerability_type": "Out-of-bounds Read", "description": "The product reads data past the end, or before the beginning, of the intended buffer.", "severity": null, "category": "OOB read", "impact": ["Read Memory", "Bypass Protection Mechanism", "DoS: Crash, Exit, or Restart", "Varies by Context"... |
rfbReleaseClientIterator(rfbClientIteratorPtr iterator)
{
IF_PTHREADS(if(iterator->next) rfbDecrClientRef(iterator->next));
free(iterator);
} | 0 | [] | libvncserver | 804335f9d296440bb708ca844f5d89b58b50b0c6 | 93,815,069,329,153,030,000,000,000,000,000,000,000 | 5 | Thread safety for zrle, zlib, tight.
Proposed tight security type fix for debian bug 517422. | Safe | null | null |
RegexMatchExpression::RegexMatchExpression(StringData path, const BSONElement& e)
: LeafMatchExpression(REGEX, path),
_regex(e.regex()),
_flags(e.regexFlags()),
_re(new pcrecpp::RE(_regex.c_str(), flags2options(_flags.c_str()))) {
uassert(ErrorCodes::BadValue, "regex not a regex", e.type() == ... | 0 | [] | mongo | 64095239f41e9f3841d8be9088347db56d35c891 | 70,858,585,662,722,590,000,000,000,000,000,000,000 | 8 | SERVER-51083 Reject invalid UTF-8 from $regex match expressions | Safe | null | null |
void tr_variantDictReserve(tr_variant* dict, size_t reserve_count)
{
TR_ASSERT(tr_variantIsDict(dict));
containerReserve(dict, reserve_count);
} | 0 | [
"CWE-416",
"CWE-284"
] | transmission | 2123adf8e5e1c2b48791f9d22fc8c747e974180e | 202,267,512,580,951,760,000,000,000,000,000,000,000 | 6 | CVE-2018-10756: Fix heap-use-after-free in tr_variantWalk
In libtransmission/variant.c, function tr_variantWalk, when the variant
stack is reallocated, a pointer to the previously allocated memory
region is kept. This address is later accessed (heap use-after-free)
while walking back down the stack, causing the applic... | Safe | 416 | {"cwe_id": "CWE-416", "vulnerability_type": "Use After Free", "description": "The product reuses or references memory after it has been freed. At some point afterward, the memory may be allocated again and saved in another pointer, while the original pointer references a location somewhere within the new allocation. An... |
static int cit_init_model0(struct gspca_dev *gspca_dev)
{
cit_write_reg(gspca_dev, 0x0000, 0x0100); /* turn on led */
cit_write_reg(gspca_dev, 0x0001, 0x0112); /* turn on autogain ? */
cit_write_reg(gspca_dev, 0x0000, 0x0400);
cit_write_reg(gspca_dev, 0x0001, 0x0400);
cit_write_reg(gspca_dev, 0x0000, 0x0420);
cit... | 0 | [
"CWE-476"
] | linux | a246b4d547708f33ff4d4b9a7a5dbac741dc89d8 | 130,520,637,817,376,440,000,000,000,000,000,000,000 | 23 | media: xirlink_cit: add missing descriptor sanity checks
Make sure to check that we have two alternate settings and at least one
endpoint before accessing the second altsetting structure and
dereferencing the endpoint arrays.
This specifically avoids dereferencing NULL-pointers or corrupting
memory when a device does... | Safe | 476 | {"cwe_id": "CWE-476", "vulnerability_type": "NULL Pointer Dereference", "description": "The product dereferences a pointer that it expects to be valid but is NULL.", "severity": "Medium", "category": "NPD", "impact": ["DoS: Crash, Exit, or Restart", "Execute Unauthorized Code or Commands", "Read Memory", "Modify Memory... |
static int lock_extent_direct(struct inode *inode, u64 lockstart, u64 lockend,
struct extent_state **cached_state, int writing)
{
struct btrfs_ordered_extent *ordered;
int ret = 0;
while (1) {
lock_extent_bits(&BTRFS_I(inode)->io_tree, lockstart, lockend,
0, cached_state);
/*
* We're concerned ... | 0 | [
"CWE-200"
] | linux | 0305cd5f7fca85dae392b9ba85b116896eb7c1c7 | 143,499,239,910,932,380,000,000,000,000,000,000,000 | 62 | Btrfs: fix truncation of compressed and inlined extents
When truncating a file to a smaller size which consists of an inline
extent that is compressed, we did not discard (or made unusable) the
data between the new file size and the old file size, wasting metadata
space and allowing for the truncated data to be leaked... | Safe | 200 | {"cwe_id": "CWE-200", "vulnerability_type": "Exposure of Sensitive Information to an Unauthorized Actor", "description": "The product exposes sensitive information to an actor that is not explicitly authorized to have access to that information.", "severity": "High", "category": "Information Disclosure", "impact": ["Re... |
static inline bool gic_irq_signaling_enabled(GICState *s, int cpu, bool virt,
int group_mask)
{
int cpu_iface = virt ? (cpu + GIC_NCPU) : cpu;
if (!virt && !(s->ctlr & group_mask)) {
return false;
}
if (virt && !(s->h_hcr[cpu] & R_GICH_HCR_EN_MASK)) {
... | 0 | [
"CWE-787"
] | qemu | edfe2eb4360cde4ed5d95bda7777edcb3510f76a | 116,769,049,765,328,400,000,000,000,000,000,000,000 | 19 | hw/intc/arm_gic: Fix interrupt ID in GICD_SGIR register
Per the ARM Generic Interrupt Controller Architecture specification
(document "ARM IHI 0048B.b (ID072613)"), the SGIINTID field is 4 bit,
not 10:
- 4.3 Distributor register descriptions
- 4.3.15 Software Generated Interrupt Register, GICD_SG
- Table 4-2... | Safe | 787 | {"cwe_id": "CWE-787", "vulnerability_type": "Out-of-bounds Write", "description": "The product writes data past the end, or before the beginning, of the intended buffer.", "severity": "High", "category": "Memory Corruption", "impact": ["Modify Memory", "Execute Unauthorized Code or Commands", "DoS: Crash, Exit, or Rest... |
archive_acl_types(struct archive_acl *acl)
{
return (acl->acl_types);
} | 0 | [
"CWE-476"
] | libarchive | 15bf44fd2c1ad0e3fd87048b3fcc90c4dcff1175 | 227,188,760,898,172,750,000,000,000,000,000,000,000 | 4 | Skip 0-length ACL fields
Currently, it is possible to create an archive that crashes bsdtar
with a malformed ACL:
Program received signal SIGSEGV, Segmentation fault.
archive_acl_from_text_l (acl=<optimised out>, text=0x7e2e92 "", want_type=<optimised out>, sc=<optimised out>) at libarchive/archive_acl.c:1726
1726 ... | Safe | 476 | {"cwe_id": "CWE-476", "vulnerability_type": "NULL Pointer Dereference", "description": "The product dereferences a pointer that it expects to be valid but is NULL.", "severity": "Medium", "category": "NPD", "impact": ["DoS: Crash, Exit, or Restart", "Execute Unauthorized Code or Commands", "Read Memory", "Modify Memory... |
_lookup_passwd_info (const char *username,
uid_t *uidp,
gid_t *gidp,
char **homep,
char **shellp)
{
gboolean ret;
struct passwd *passwd_entry;
struct passwd passwd_buffer;
char ... | 0 | [
"CWE-362"
] | gdm | dcdbaaa04012541ad2813cf83559d91d52f208b9 | 229,408,553,744,642,930,000,000,000,000,000,000,000 | 88 | session-worker: Don't switch back VTs until session is fully exited
There's a race condition on shutdown where the session worker is
switching VTs back to the initial VT at the same time as the session
exit is being processed.
This means that manager may try to start a login screen (because of
the VT switch) when aut... | Safe | 362 | {"cwe_id": "CWE-362", "vulnerability_type": "Concurrent Execution using Shared Resource with Improper Synchronization ('Race Condition')", "description": "The product contains a concurrent code sequence that requires temporary, exclusive access to a shared resource, but a timing window exists in which the shared resour... |
Uz_Globs *globalsCtor()
{
#ifdef REENTRANT
Uz_Globs *pG = (Uz_Globs *)malloc(sizeof(Uz_Globs));
if (!pG)
return (Uz_Globs *)NULL;
#endif /* REENTRANT */
/* for REENTRANT version, G is defined as (*pG) */
memzero(&G, sizeof(Uz_Globs));
#ifndef FUNZIP
#ifdef CMS_MVS
uO.aflag=1;
uO.C_fl... | 0 | [
"CWE-400"
] | unzip | 47b3ceae397d21bf822bc2ac73052a4b1daf8e1c | 16,443,669,056,023,774,000,000,000,000,000,000,000 | 65 | Detect and reject a zip bomb using overlapped entries.
This detects an invalid zip file that has at least one entry that
overlaps with another entry or with the central directory to the
end of the file. A Fifield zip bomb uses overlapped local entries
to vastly increase the potential inflation ratio. Such an invalid
z... | Safe | 400 | {"cwe_id": "CWE-400", "vulnerability_type": "Uncontrolled Resource Consumption", "description": "The product does not properly control the allocation and maintenance of a limited resource.", "severity": "High", "category": "Resource Exhaustion", "impact": ["DoS: Crash, Exit, or Restart", "DoS: Resource Consumption (CPU... |
static int insn_def_regno(const struct bpf_insn *insn)
{
switch (BPF_CLASS(insn->code)) {
case BPF_JMP:
case BPF_JMP32:
case BPF_ST:
return -1;
case BPF_STX:
if (BPF_MODE(insn->code) == BPF_ATOMIC &&
(insn->imm & BPF_FETCH)) {
if (insn->imm == BPF_CMPXCHG)
return BPF_REG_0;
else
return insn... | 0 | [
"CWE-307"
] | linux | 350a5c4dd2452ea999cc5e1d4a8dbf12de2f97ef | 26,704,950,220,146,160,000,000,000,000,000,000,000 | 21 | bpf: Dont allow vmlinux BTF to be used in map_create and prog_load.
The syzbot got FD of vmlinux BTF and passed it into map_create which caused
crash in btf_type_id_size() when it tried to access resolved_ids. The vmlinux
BTF doesn't have 'resolved_ids' and 'resolved_sizes' initialized to save
memory. To avoid such is... | Safe | 307 | {"cwe_id": "CWE-307", "vulnerability_type": "Improper Restriction of Excessive Authentication Attempts", "description": "The product does not implement sufficient measures to prevent multiple failed authentication attempts within a short time frame.", "severity": null, "category": null, "impact": ["Bypass Protection Me... |
QUtil::is_utf16(std::string const& val)
{
return ((val.length() >= 2) &&
(val.at(0) == '\xfe') && (val.at(1) == '\xff'));
} | 0 | [
"CWE-787"
] | qpdf | d71f05ca07eb5c7cfa4d6d23e5c1f2a800f52e8e | 193,833,783,349,485,300,000,000,000,000,000,000,000 | 5 | Fix sign and conversion warnings (major)
This makes all integer type conversions that have potential data loss
explicit with calls that do range checks and raise an exception. After
this commit, qpdf builds with no warnings when -Wsign-conversion
-Wconversion is used with gcc or clang or when -W3 -Wd4800 is used
with ... | Safe | 787 | {"cwe_id": "CWE-787", "vulnerability_type": "Out-of-bounds Write", "description": "The product writes data past the end, or before the beginning, of the intended buffer.", "severity": "High", "category": "Memory Corruption", "impact": ["Modify Memory", "Execute Unauthorized Code or Commands", "DoS: Crash, Exit, or Rest... |
char *keychain_delete(struct Server *server) {
SecKeychainItemRef item;
OSStatus status = SecKeychainFindInternetPassword(
NULL,
strlen(server->host), server->host,
0, NULL,
0, NULL,
strlen(server->path), server->path,
server->port,
server->proto,
kSecAuthenticationTypeDefault,
... | 0 | [
"CWE-415"
] | docker-credential-helpers | 87c80bfba583eadc087810d17aa631ef4e405efc | 101,721,586,400,521,400,000,000,000,000,000,000,000 | 25 | Fix a double free in the List functions
The code was set up so that it would free the individual items and the data
in `freeListData`, but there was already a Go `defer` to free the data item,
resulting in a double free.
Remove the `free` in `freeListData` and leave the original one.
In addition, move the `defer` fo... | Safe | 415 | {"cwe_id": "CWE-415", "vulnerability_type": "Double Free", "description": "The product calls free() twice on the same memory address.", "severity": "High", "category": "Double-free", "impact": ["Modify Memory", "Execute Unauthorized Code or Commands"], "languages": [null, "C", "C++"], "example": "Example not extracted"... |
SpoolssGetForm_q(tvbuff_t *tvb, int offset, packet_info *pinfo,
proto_tree *tree, dcerpc_info *di, guint8 *drep _U_)
{
dcerpc_call_value *dcv = (dcerpc_call_value *)di->call_data;
proto_item *hidden_item;
guint32 level;
char *name;
hidden_item = proto_tree_add_uint(
tree, hf_form, tvb, offset, 0, 1);
PR... | 0 | [
"CWE-399"
] | wireshark | b4d16b4495b732888e12baf5b8a7e9bf2665e22b | 85,908,087,045,116,590,000,000,000,000,000,000,000 | 42 | 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... | Safe | 399 | null |
convert_to_decimal (mpn_t a, size_t extra_zeroes)
{
mp_limb_t *a_ptr = a.limbs;
size_t a_len = a.nlimbs;
/* 0.03345 is slightly larger than log(2)/(9*log(10)). */
size_t c_len = 9 * ((size_t)(a_len * (GMP_LIMB_BITS * 0.03345f)) + 1);
/* We need extra_zeroes bytes for zeroes, followed by c_len bytes for the
... | 0 | [
"CWE-119",
"CWE-787"
] | gnulib | 278b4175c9d7dd47c1a3071554aac02add3b3c35 | 77,915,899,001,834,150,000,000,000,000,000,000,000 | 48 | vasnprintf: Fix heap memory overrun bug.
Reported by Ben Pfaff <blp@cs.stanford.edu> in
<https://lists.gnu.org/archive/html/bug-gnulib/2018-09/msg00107.html>.
* lib/vasnprintf.c (convert_to_decimal): Allocate one more byte of
memory.
* tests/test-vasnprintf.c (test_function): Add another test. | Safe | 119 | {"cwe_id": "CWE-119", "vulnerability_type": "Improper Restriction of Operations within the Bounds of a Memory Buffer", "description": "The product performs operations on a memory buffer, but it reads from or writes to a memory location outside the buffer's intended boundary. This may result in read or write operations ... |
static NTSTATUS cli_ulogoff_recv(struct tevent_req *req)
{
return tevent_req_simple_recv_ntstatus(req);
} | 0 | [
"CWE-94"
] | samba | 94295b7aa22d2544af5323bca70d3dcb97fd7c64 | 294,873,634,133,569,600,000,000,000,000,000,000,000 | 4 | CVE-2016-2019: s3:libsmb: add comment regarding smbXcli_session_is_guest() with mandatory signing
BUG: https://bugzilla.samba.org/show_bug.cgi?id=11860
Signed-off-by: Stefan Metzmacher <metze@samba.org> | Safe | 94 | {"cwe_id": "CWE-94", "vulnerability_type": "Improper Control of Generation of Code ('Code Injection')", "description": "The product constructs all or part of a code segment using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could mod... |
static void *reloc_iomap(struct drm_i915_gem_object *obj,
struct reloc_cache *cache,
unsigned long page)
{
struct i915_ggtt *ggtt = cache_to_ggtt(cache);
unsigned long offset;
void *vaddr;
if (cache->vaddr) {
io_mapping_unmap_atomic((void __force __iomem *) unmask_page(cache->vaddr));
} else {
struct ... | 0 | [
"CWE-20"
] | linux | 594cc251fdd0d231d342d88b2fdff4bc42fb0690 | 143,926,763,958,505,960,000,000,000,000,000,000,000 | 63 | make 'user_access_begin()' do 'access_ok()'
Originally, the rule used to be that you'd have to do access_ok()
separately, and then user_access_begin() before actually doing the
direct (optimized) user access.
But experience has shown that people then decide not to do access_ok()
at all, and instead rely on it being i... | Safe | 20 | {"cwe_id": "CWE-20", "vulnerability_type": "Improper Input Validation", "description": "The product receives input or data, but it does\n not validate or incorrectly validates that the input has the\n properties that are required to process the data safely and\n correctly.", "severity": "High", "ca... |
TEST_F(ConnectionManagerUtilityTest, MtlsSanitizeSetClientCertPeerSanEmpty) {
auto ssl = std::make_shared<NiceMock<Ssl::MockConnectionInfo>>();
ON_CALL(*ssl, peerCertificatePresented()).WillByDefault(Return(true));
const std::vector<std::string> local_uri_sans{"test://foo.com/be"};
EXPECT_CALL(*ssl, uriSanLocal... | 0 | [
"CWE-22"
] | envoy | 5333b928d8bcffa26ab19bf018369a835f697585 | 172,506,146,545,528,350,000,000,000,000,000,000,000 | 27 | Implement handling of escaped slash characters in URL path
Fixes: CVE-2021-29492
Signed-off-by: Yan Avlasov <yavlasov@google.com> | Safe | 22 | {"cwe_id": "CWE-22", "vulnerability_type": "Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal')", "description": "The product uses external input to construct a pathname that is intended to identify a file or directory that is located underneath a restricted parent directory, but the product ... |
static inline void kvm_vcpu_flush_tlb_current(struct kvm_vcpu *vcpu)
{
++vcpu->stat.tlb_flush;
static_call(kvm_x86_flush_tlb_current)(vcpu);
} | 0 | [
"CWE-459"
] | linux | 683412ccf61294d727ead4a73d97397396e69a6b | 137,159,493,833,856,570,000,000,000,000,000,000,000 | 5 | KVM: SEV: add cache flush to solve SEV cache incoherency issues
Flush the CPU caches when memory is reclaimed from an SEV guest (where
reclaim also includes it being unmapped from KVM's memslots). Due to lack
of coherency for SEV encrypted memory, failure to flush results in silent
data corruption if userspace is mal... | Safe | 459 | {"cwe_id": "CWE-459", "vulnerability_type": "Incomplete Cleanup", "description": "The product does not properly \"clean up\" and remove temporary or supporting resources after they have been used.", "severity": null, "category": "Insufficient Cleanup", "impact": ["Other", "Read Application Data", "Modify Application Da... |
static int robots_fsio_access(pr_fs_t *fs, const char *path, int mode,
uid_t uid, gid_t gid, array_header *suppl_gids) {
if (mode != R_OK) {
errno = EACCES;
return -1;
}
return 0;
} | 0 | [
"CWE-59",
"CWE-295"
] | proftpd | 349addc3be4fcdad9bd4ec01ad1ccd916c898ed8 | 51,684,855,670,653,690,000,000,000,000,000,000,000 | 9 | Walk the entire DefaultRoot path, checking for symlinks of any component,
when AllowChrootSymlinks is disabled. | Safe | 59 | {"cwe_id": "CWE-59", "vulnerability_type": "Improper Link Resolution Before File Access ('Link Following')", "description": "The product attempts to access a file based on the filename, but it does not properly prevent that filename from identifying a link or shortcut that resolves to an unintended resource.", "severit... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.