func string | target int64 | cwe list | project string | commit_id string | hash float64 | size int64 | message string |
|---|---|---|---|---|---|---|---|
bool CudnnSupport::DoNormalizeBackwardWithDimensions(
Stream* stream, const dnn::NormalizeDescriptor& normalize_descriptor,
const dnn::BatchDescriptor& dimensions, const DeviceMemory<float>& raw_data,
const DeviceMemory<float>& normalized_data,
const DeviceMemory<float>& normalized_variable_gradient,
... | 0 | [
"CWE-20"
] | tensorflow | 14755416e364f17fb1870882fa778c7fec7f16e3 | 155,756,765,969,992,840,000,000,000,000,000,000,000 | 34 | Prevent CHECK-fail in LSTM/GRU with zero-length input.
PiperOrigin-RevId: 346239181
Change-Id: I5f233dbc076aab7bb4e31ba24f5abd4eaf99ea4f |
template<typename tf>
static CImg<floatT> sphere3d(CImgList<tf>& primitives,
const float radius=50, const unsigned int subdivisions=3) {
// Create initial icosahedron
primitives.assign();
const double tmp = (1 + std::sqrt(5.0f))/2, a = 1.0/std::sqrt(1 + tmp*tm... | 0 | [
"CWE-125"
] | CImg | 10af1e8c1ad2a58a0a3342a856bae63e8f257abb | 146,845,292,542,094,890,000,000,000,000,000,000,000 | 54 | Fix other issues in 'CImg<T>::load_bmp()'. |
static int io_submit_one(struct kioctx *ctx, struct iocb __user *user_iocb,
struct iocb *iocb, struct kiocb_batch *batch,
bool compat)
{
struct kiocb *req;
struct file *file;
ssize_t ret;
/* enforce forwards compatibility on users */
if (unlikely(iocb->aio_reserved1 || iocb->aio_reserved2)) {
pr_debug("... | 0 | [
"CWE-200"
] | linux | a70b52ec1aaeaf60f4739edb1b422827cb6f3893 | 115,115,155,847,843,700,000,000,000,000,000,000,000 | 102 | vfs: make AIO use the proper rw_verify_area() area helpers
We had for some reason overlooked the AIO interface, and it didn't use
the proper rw_verify_area() helper function that checks (for example)
mandatory locking on the file, and that the size of the access doesn't
cause us to overflow the provided offset limits ... |
static void
php_mysqlnd_chg_user_free_mem(void * _packet, zend_bool stack_allocation TSRMLS_DC)
{
MYSQLND_PACKET_CHG_USER_RESPONSE * p = (MYSQLND_PACKET_CHG_USER_RESPONSE *) _packet;
if (p->new_auth_protocol) {
mnd_efree(p->new_auth_protocol);
p->new_auth_protocol = NULL;
}
p->new_auth_protocol_len = 0;
if (... | 0 | [
"CWE-119",
"CWE-787"
] | php-src | 28f80baf3c53e267c9ce46a2a0fadbb981585132 | 258,378,452,850,843,660,000,000,000,000,000,000,000 | 20 | Fix bug #72293 - Heap overflow in mysqlnd related to BIT fields |
const char *urlGetQuery(struct URL *url) {
return url->query;
} | 0 | [
"CWE-400",
"CWE-703",
"CWE-835"
] | shellinabox | 4f0ecc31ac6f985e0dd3f5a52cbfc0e9251f6361 | 1,641,546,450,449,619,500,000,000,000,000,000,000 | 3 | Rolling code for version 2.21 |
static int mailimf_dot_atom_parse(const char * message, size_t length,
size_t * indx, char ** result)
{
return mailimf_atom_parse(message, length, indx, result);
} | 0 | [
"CWE-476"
] | libetpan | 1fe8fbc032ccda1db9af66d93016b49c16c1f22d | 86,146,127,772,417,660,000,000,000,000,000,000,000 | 5 | Fixed crash #274 |
char *enl_send_and_wait(char *msg)
{
char *reply = IPC_TIMEOUT;
sighandler_t old_alrm;
/*
* Shortcut this func and return IPC_FAKE
* If the IPC Window is the E17 fake
*/
if (e17_fake_ipc)
return IPC_FAKE;
if (ipc_win == None) {
/* The IPC window is missing. Wait for it to return or feh to be killed. *... | 0 | [
"CWE-61",
"CWE-787"
] | feh | f7a547b7ef8fc8ebdeaa4c28515c9d72e592fb6d | 223,099,528,383,396,350,000,000,000,000,000,000,000 | 37 | Fix double-free/OOB-write while receiving IPC data
If a malicious client pretends to be the E17 window manager, it is
possible to trigger an out of boundary heap write while receiving an
IPC message.
The length of the already received message is stored in an unsigned
short, which overflows after receiving 64 KB of da... |
int MqttClient_Subscribe(MqttClient *client, MqttSubscribe *subscribe)
{
int rc, len, i;
MqttTopic* topic;
/* Validate required arguments */
if (client == NULL || subscribe == NULL) {
return MQTT_CODE_ERROR_BAD_ARG;
}
#ifdef WOLFMQTT_V5
/* Use specified protocol version if set */
s... | 0 | [
"CWE-787"
] | wolfMQTT | 84d4b53122e0fa0280c7872350b89d5777dabbb2 | 282,018,884,147,377,870,000,000,000,000,000,000,000 | 101 | Fix wolfmqtt-fuzzer: Null-dereference WRITE in MqttProps_Free |
static inline int compute_score(struct sock *sk, struct net *net,
unsigned short hnum,
const struct in6_addr *saddr, __be16 sport,
const struct in6_addr *daddr, __be16 dport,
int dif)
{
int score = -1;
if (net_eq(sock_net(sk), net) && udp_sk(sk)->udp_port_hash == hnum &&
sk->sk_family == PF_INET6)... | 0 | [
"CWE-20"
] | net | bceaa90240b6019ed73b49965eac7d167610be69 | 8,064,990,832,623,758,000,000,000,000,000,000,000 | 36 | inet: prevent leakage of uninitialized memory to user in recv syscalls
Only update *addr_len when we actually fill in sockaddr, otherwise we
can return uninitialized memory from the stack to the caller in the
recvfrom, recvmmsg and recvmsg syscalls. Drop the the (addr_len == NULL)
checks because we only get called wit... |
int sum_end(char *sum)
{
switch (cursum_type) {
case CSUM_MD5:
md5_result(&md, (uchar *)sum);
break;
case CSUM_MD4:
case CSUM_MD4_OLD:
mdfour_update(&md, (uchar *)md.buffer, sumresidue);
mdfour_result(&md, (uchar *)sum);
break;
case CSUM_MD4_BUSTED:
if (sumresidue)
mdfour_update(&md, (uchar ... | 1 | [
"CWE-354"
] | rsync | 7b8a4ecd6ff9cdf4e5d3850ebf822f1e989255b3 | 290,854,236,316,981,640,000,000,000,000,000,000,000 | 23 | Handle archaic checksums properly. |
expand_prompt (pmt, flags, lp, lip, niflp, vlp)
char *pmt;
int flags;
int *lp, *lip, *niflp, *vlp;
{
char *r, *ret, *p, *igstart, *nprompt, *ms;
int l, rl, last, ignoring, ninvis, invfl, invflset, ind, pind, physchars;
int mlen;
/* We only expand the mode string for the last line of a multiline ... | 0 | [] | bash | 955543877583837c85470f7fb8a97b7aa8d45e6c | 60,073,060,920,862,225,000,000,000,000,000,000,000 | 126 | bash-4.4-rc2 release |
static bool __rbd_obj_handle_request(struct rbd_obj_request *obj_req,
int *result)
{
struct rbd_img_request *img_req = obj_req->img_request;
struct rbd_device *rbd_dev = img_req->rbd_dev;
bool done;
mutex_lock(&obj_req->state_mutex);
if (!rbd_img_is_write(img_req))
done = rbd_obj_advance_read(obj_req, ... | 0 | [
"CWE-863"
] | linux | f44d04e696feaf13d192d942c4f14ad2e117065a | 205,819,281,590,245,930,000,000,000,000,000,000,000 | 22 | rbd: require global CAP_SYS_ADMIN for mapping and unmapping
It turns out that currently we rely only on sysfs attribute
permissions:
$ ll /sys/bus/rbd/{add*,remove*}
--w------- 1 root root 4096 Sep 3 20:37 /sys/bus/rbd/add
--w------- 1 root root 4096 Sep 3 20:37 /sys/bus/rbd/add_single_major
--w------- 1 ro... |
static int rtnetlink_event(struct notifier_block *this, unsigned long event, void *ptr)
{
struct net_device *dev = ptr;
switch (event) {
case NETDEV_UP:
case NETDEV_DOWN:
case NETDEV_PRE_UP:
case NETDEV_POST_INIT:
case NETDEV_REGISTER:
case NETDEV_CHANGE:
case NETDEV_PRE_TYPE_CHANGE:
case NETDEV_GOING_DOWN:
... | 0 | [
"CWE-399"
] | linux-2.6 | 84d73cd3fb142bf1298a8c13fd4ca50fd2432372 | 238,686,193,239,354,900,000,000,000,000,000,000,000 | 24 | rtnl: fix info leak on RTM_GETLINK request for VF devices
Initialize the mac address buffer with 0 as the driver specific function
will probably not fill the whole buffer. In fact, all in-kernel drivers
fill only ETH_ALEN of the MAX_ADDR_LEN bytes, i.e. 6 of the 32 possible
bytes. Therefore we currently leak 26 bytes ... |
bool ldb_msg_element_equal_ordered(const struct ldb_message_element *el1,
const struct ldb_message_element *el2)
{
unsigned i;
if (el1->num_values != el2->num_values) {
return false;
}
for (i=0;i<el1->num_values;i++) {
if (ldb_val_equal_exact(&el1->values[i],
&el2->values[i]) != 1) {
return false... | 0 | [
"CWE-200"
] | samba | 7efe8182c165fbf17d2f88c173527a7a554e214b | 184,209,536,262,633,540,000,000,000,000,000,000,000 | 15 | CVE-2022-32746 ldb: Add flag to mark message element values as shared
When making a shallow copy of an ldb message, mark the message elements
of the copy as sharing their values with the message elements in the
original message.
This flag value will be heeded in the next commit.
BUG: https://bugzilla.samba.org/show_... |
nwfilterConnectListAllNWFilterBindings(virConnectPtr conn,
virNWFilterBindingPtr **bindings,
unsigned int flags)
{
virCheckFlags(0, -1);
if (virConnectListAllNWFilterBindingsEnsureACL(conn) < 0)
return -1;
return virNWFi... | 0 | [
"CWE-667"
] | libvirt | a4947e8f63c3e6b7b067b444f3d6cf674c0d7f36 | 233,233,419,330,456,550,000,000,000,000,000,000,000 | 12 | nwfilter: fix crash when counting number of network filters
The virNWFilterObjListNumOfNWFilters method iterates over the
driver->nwfilters, accessing virNWFilterObj instances. As such
it needs to be protected against concurrent modification of
the driver->nwfilters object.
This API allows unprivileged users to conne... |
gather_time_entropy(void) {
# ifdef _WIN32
FILETIME ft;
GetSystemTimeAsFileTime(&ft); /* never fails */
return ft.dwHighDateTime ^ ft.dwLowDateTime;
# else
struct timeval tv;
int gettimeofday_res;
gettimeofday_res = gettimeofday(&tv, NULL);
# if defined(NDEBUG)
(void)gettimeofday_res;
# else
a... | 0 | [
"CWE-611",
"CWE-776",
"CWE-415",
"CWE-125"
] | libexpat | c20b758c332d9a13afbbb276d30db1d183a85d43 | 338,889,180,087,129,170,000,000,000,000,000,000,000 | 21 | xmlparse.c: Deny internal entities closing the doctype |
bool mysql_routine_grant(THD *thd, TABLE_LIST *table_list, bool is_proc,
List <LEX_USER> &user_list, ulong rights,
bool revoke_grant, bool write_to_binlog)
{
List_iterator <LEX_USER> str_list (user_list);
LEX_USER *Str, *tmp_Str;
TABLE_LIST tables[2];
bool create_new_users=0, result=0;
char *db_name, ... | 0 | [] | mysql-server | 25d1b7e03b9b375a243fabdf0556c063c7282361 | 256,970,786,451,281,700,000,000,000,000,000,000,000 | 204 | Bug #22722946: integer overflow may lead to wrong results in get_56_lenc_string |
PackLinuxElf64ppcle::getFilters() const
{
static const int filters[] = {
0xd0,
FT_END };
return filters;
} | 0 | [
"CWE-476"
] | upx | ef336dbcc6dc8344482f8cf6c909ae96c3286317 | 273,892,049,430,755,730,000,000,000,000,000,000,000 | 7 | Protect against bad crafted input.
https://github.com/upx/upx/issues/128
modified: p_lx_elf.cpp |
u16 gf_mp3_frame_size(u32 hdr)
{
u8 version = gf_mp3_version(hdr);
u8 layer = gf_mp3_layer(hdr);
u32 pad = ( (hdr >> 9) & 0x1) ? 1 : 0;
u32 bitrate = gf_mp3_bit_rate(hdr);
u32 samplerate = gf_mp3_sampling_rate(hdr);
u32 frameSize = 0;
if (!samplerate || !bitrate) return 0;
if (layer==1) {
frameSize = (( 12 ... | 0 | [
"CWE-119",
"CWE-787"
] | gpac | 90dc7f853d31b0a4e9441cba97feccf36d8b69a4 | 97,800,964,842,890,950,000,000,000,000,000,000,000 | 20 | fix some exploitable overflows (#994, #997) |
static inline void nohz_newidle_balance(struct rq *this_rq) { } | 0 | [
"CWE-400",
"CWE-703",
"CWE-835"
] | linux | c40f7d74c741a907cfaeb73a7697081881c497d0 | 11,614,170,038,849,869,000,000,000,000,000,000,000 | 1 | 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... |
int msPostGISHexDecode(unsigned char *dest, const char *src, int srclen)
{
if (src && *src && (srclen % 2 == 0) ) {
unsigned char *p = dest;
int i;
for ( i=0; i<srclen; i+=2 ) {
register unsigned char b1=0, b2=0;
register unsigned char c1 = src[i];
register unsigned char c2 = src[i + ... | 0 | [
"CWE-89"
] | mapserver | 3a10f6b829297dae63492a8c63385044bc6953ed | 31,405,110,228,726,267,000,000,000,000,000,000,000 | 23 | Fix potential SQL Injection with postgis TIME filters (#4834) |
bool CModule::MoveRegistry(const CString& sPath) {
if (m_sSavePath != sPath) {
CFile fOldNVFile = CFile(m_sSavePath + "/.registry");
if (!fOldNVFile.Exists()) {
return false;
}
if (!CFile::Exists(sPath) && !CDir::MakeDir(sPath)) {
return false;
}
... | 0 | [
"CWE-20",
"CWE-264"
] | znc | 8de9e376ce531fe7f3c8b0aa4876d15b479b7311 | 91,371,362,631,114,530,000,000,000,000,000,000,000 | 15 | Fix remote code execution and privilege escalation vulnerability.
To trigger this, need to have a user already.
Thanks for Jeriko One <jeriko.one@gmx.us> for finding and reporting this.
CVE-2019-12816 |
void kernel_sigaction(int sig, __sighandler_t action)
{
spin_lock_irq(¤t->sighand->siglock);
current->sighand->action[sig - 1].sa.sa_handler = action;
if (action == SIG_IGN) {
sigset_t mask;
sigemptyset(&mask);
sigaddset(&mask, sig);
flush_sigqueue_mask(&mask, ¤t->signal->shared_pending);
flu... | 0 | [
"CWE-119",
"CWE-787"
] | linux | 4ea77014af0d6205b05503d1c7aac6eace11d473 | 323,021,497,661,370,650,000,000,000,000,000,000,000 | 16 | kernel/signal.c: avoid undefined behaviour in kill_something_info
When running kill(72057458746458112, 0) in userspace I hit the following
issue.
UBSAN: Undefined behaviour in kernel/signal.c:1462:11
negation of -2147483648 cannot be represented in type 'int':
CPU: 226 PID: 9849 Comm: test Tainted: G B ... |
static bool load_buffer(RzBinFile *bf, RzBinObject *obj, RzBuffer *buf, Sdb *sdb) {
lmf_record lrec;
lmf_resource lres;
lmf_data ldata;
ut64 offset = QNX_RECORD_SIZE;
QnxObj *qo = RZ_NEW0(QnxObj);
if (!qo) {
return false;
}
RzList *sections = rz_list_newf((RzListFree)rz_bin_section_free);
RzList *maps = rz... | 0 | [
"CWE-415"
] | rizin | 58926dffbe819fe9ebf5062f7130e026351cae01 | 272,786,681,223,032,100,000,000,000,000,000,000,000 | 121 | fix #2964 - double-free in bin_qnx.c |
ptvcursor_tvbuff(ptvcursor_t *ptvc)
{
return ptvc->tvb;
} | 0 | [
"CWE-401"
] | wireshark | a9fc769d7bb4b491efb61c699d57c9f35269d871 | 73,802,656,732,878,380,000,000,000,000,000,000,000 | 4 | epan: Fix a memory leak.
Make sure _proto_tree_add_bits_ret_val allocates a bits array using the
packet scope, otherwise we leak memory. Fixes #17032. |
static void php_ldap_do_translate(INTERNAL_FUNCTION_PARAMETERS, int way)
{
char *value;
int result, ldap_len;
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &value, &value_len) != SUCCESS) {
return;
}
if (value_len == 0) {
RETURN_FALSE;
}
if (way == 1) {
result = ldap_8859_to_t61(&value, &val... | 0 | [
"CWE-476"
] | php-src | 49782c54994ecca2ef2a061063bd5a7079c43527 | 269,391,510,926,509,470,000,000,000,000,000,000,000 | 27 | Fix bug #76248 - Malicious LDAP-Server Response causes Crash |
return _save_yuv(file,0,chroma_subsampling,is_rgb);
}
const CImgList<T>& _save_yuv(std::FILE *const file, const char *const filename,
const unsigned int chroma_subsampling,
const bool is_rgb) const {
if (!file && !filename)
t... | 0 | [
"CWE-770"
] | cimg | 619cb58dd90b4e03ac68286c70ed98acbefd1c90 | 250,770,252,220,759,280,000,000,000,000,000,000,000 | 45 | CImg<>::load_bmp() and CImg<>::load_pandore(): Check that dimensions encoded in file does not exceed file size. |
void set_invoker(const LEX_STRING *user, const LEX_STRING *host)
{
invoker_user= *user;
invoker_host= *host;
} | 0 | [
"CWE-416"
] | server | 4681b6f2d8c82b4ec5cf115e83698251963d80d5 | 88,462,185,160,683,800,000,000,000,000,000,000,000 | 5 | MDEV-26281 ASAN use-after-poison when complex conversion is involved in blob
the bug was that in_vector array in Item_func_in was allocated in the
statement arena, not in the table->expr_arena.
revert part of the 5acd391e8b2d. Instead, change the arena correctly
in fix_all_session_vcol_exprs().
Remove TABLE_ARENA, t... |
void FIFOSampleBuffer::rewind()
{
if (buffer && bufferPos)
{
memmove(buffer, ptrBegin(), sizeof(SAMPLETYPE) * channels * samplesInBuffer);
bufferPos = 0;
}
}
| 0 | [
"CWE-617"
] | soundtouch | 107f2c5d201a4dfea1b7f15c5957ff2ac9e5f260 | 144,542,874,665,127,620,000,000,000,000,000,000,000 | 8 | Replaced illegal-number-of-channel assertions with run-time exception |
array_new_indexed_plist_write(dict_param_list * plist, ref * parray,
const ref * pwanted, gs_ref_memory_t *imem)
{
check_array(*parray);
check_write(*parray);
plist->u.w.write = array_new_indexed_param_write;
ref_param_write_init((iparam_list *) plist, pwanted, imem);
p... | 0 | [] | ghostpdl | bfa6b2ecbe48edc69a7d9d22a12419aed25960b8 | 315,930,094,110,792,200,000,000,000,000,000,000,000 | 11 | Bug 697548: use the correct param list enumerator
When we encountered dictionary in a ref_param_list, we were using the enumerator
for the "parent" param_list, rather than the enumerator for the param_list
we just created for the dictionary. That parent was usually the stack
list enumerator, and caused a segfault.
Us... |
PHP_FUNCTION(openssl_encrypt)
{
zend_bool raw_output = 0;
char *data, *method, *password, *iv = "";
int data_len, method_len, password_len, iv_len = 0, max_iv_len;
const EVP_CIPHER *cipher_type;
EVP_CIPHER_CTX cipher_ctx;
int i, outlen, keylen;
unsigned char *outbuf, *key;
zend_bool free_iv;
if (zend_parse_pa... | 1 | [
"CWE-200"
] | php-src | 270a406ac94b5fc5cc9ef59fc61e3b4b95648a3e | 271,654,406,369,642,060,000,000,000,000,000,000,000 | 72 | Fix bug #61413 ext\openssl\tests\openssl_encrypt_crash.phpt fails 5.3 only |
static void flatviews_init(struct uc_struct *uc)
{
if (uc->flat_views) {
return;
}
uc->flat_views = g_hash_table_new_full(NULL, NULL, NULL,
(GDestroyNotify) flatview_unref);
if (!uc->empty_view) {
uc->empty_view = generate_memory_topology(uc, NULL... | 0 | [
"CWE-476"
] | unicorn | 3d3deac5e6d38602b689c4fef5dac004f07a2e63 | 99,417,896,862,942,590,000,000,000,000,000,000,000 | 16 | Fix crash when mapping a big memory and calling uc_close |
static void ok_png_decode_filter(uint8_t * RESTRICT curr, const uint8_t * RESTRICT prev,
size_t length, int filter, uint8_t bpp) {
switch (filter) {
case OK_PNG_FILTER_NONE:
// Do nothing
break;
case OK_PNG_FILTER_SUB: {
// Input =... | 0 | [
"CWE-787"
] | ok-file-formats | e49cdfb84fb5eca2a6261f3c51a3c793fab9f62e | 120,080,150,628,654,620,000,000,000,000,000,000,000 | 47 | ok_png: Disallow multiple IHDR chunks (#15) |
Http::Status ConnectionImpl::dispatch(Buffer::Instance& data) {
// Add self to the Dispatcher's tracked object stack.
ScopeTrackerScopeState scope(this, connection_.dispatcher());
ENVOY_CONN_LOG(trace, "parsing {} bytes", connection_, data.length());
// Make sure that dispatching_ is set to false after dispatch... | 0 | [
"CWE-416"
] | envoy | fe7c69c248f4fe5a9080c7ccb35275b5218bb5ab | 207,269,993,011,409,900,000,000,000,000,000,000,000 | 60 | internal redirect: fix a lifetime bug (#785)
Signed-off-by: Alyssa Wilk <alyssar@chromium.org>
Signed-off-by: Matt Klein <mklein@lyft.com>
Signed-off-by: Pradeep Rao <pcrao@google.com> |
static int print_connection_info( pjmedia_sdp_conn *c, char *buf, int len)
{
int printed;
printed = pj_ansi_snprintf(buf, len, "c=%.*s %.*s %.*s\r\n",
(int)c->net_type.slen,
c->net_type.ptr,
(int)c->addr_type.slen,
c->addr_type.ptr,
(int)c->addr.slen,
... | 0 | [
"CWE-121",
"CWE-120",
"CWE-787"
] | pjproject | 560a1346f87aabe126509bb24930106dea292b00 | 232,293,826,928,095,770,000,000,000,000,000,000,000 | 16 | Merge pull request from GHSA-f5qg-pqcg-765m |
void *hashtable_get(hashtable_t *hashtable, const char *key)
{
pair_t *pair;
size_t hash;
bucket_t *bucket;
hash = hash_str(key);
bucket = &hashtable->buckets[hash % num_buckets(hashtable)];
pair = hashtable_find_pair(hashtable, bucket, key, hash);
if(!pair)
return NULL;
retur... | 1 | [
"CWE-310"
] | jansson | 8f80c2d83808150724d31793e6ade92749b1faa4 | 335,212,237,673,718,530,000,000,000,000,000,000,000 | 15 | CVE-2013-6401: Change hash function, randomize hashes
Thanks to Florian Weimer and Eric Sesterhenn for reporting, reviewing
and testing. |
void __init tcp_init(void)
{
int max_rshare, max_wshare, cnt;
unsigned long limit;
unsigned int i;
BUILD_BUG_ON(TCP_MIN_SND_MSS <= MAX_TCP_OPTION_SPACE);
BUILD_BUG_ON(sizeof(struct tcp_skb_cb) >
FIELD_SIZEOF(struct sk_buff, cb));
percpu_counter_init(&tcp_sockets_allocated, 0, GFP_KERNEL);
percpu_counter... | 0 | [
"CWE-190"
] | net | 3b4929f65b0d8249f19a50245cd88ed1a2f78cff | 151,588,671,589,385,460,000,000,000,000,000,000,000 | 83 | tcp: limit payload size of sacked skbs
Jonathan Looney reported that TCP can trigger the following crash
in tcp_shifted_skb() :
BUG_ON(tcp_skb_pcount(skb) < pcount);
This can happen if the remote peer has advertized the smallest
MSS that linux TCP accepts : 48
An skb can hold 17 fragments, and each fragment can ho... |
static int tda9873_checkit(struct CHIPSTATE *chip)
{
int rc;
if (-1 == (rc = chip_read2(chip,254)))
return 0;
return (rc & ~0x1f) == 0x80;
} | 0 | [
"CWE-399"
] | linux-2.6 | 01a1a3cc1e3fbe718bd06a2a5d4d1a2d0fb4d7d9 | 58,821,798,794,400,400,000,000,000,000,000,000,000 | 8 | V4L/DVB (9624): CVE-2008-5033: fix OOPS on tvaudio when controlling bass/treble
This bug were supposed to be fixed by 5ba2f67afb02c5302b2898949ed6fc3b3d37dcf1,
where a call to NULL happens.
Not all tvaudio chips allow controlling bass/treble. So, the driver
has a table with a flag to indicate if the chip does support... |
static void hci_req_start_scan(struct hci_request *req, u8 type, u16 interval,
u16 window, u8 own_addr_type, u8 filter_policy,
bool addr_resolv)
{
struct hci_dev *hdev = req->hdev;
if (hdev->scanning_paused) {
bt_dev_dbg(hdev, "Scanning is paused for suspend");
return;
}
if (use_ll_privacy... | 0 | [
"CWE-362"
] | linux | e2cb6b891ad2b8caa9131e3be70f45243df82a80 | 46,261,537,342,179,160,000,000,000,000,000,000,000 | 91 | bluetooth: eliminate the potential race condition when removing the HCI controller
There is a possible race condition vulnerability between issuing a HCI
command and removing the cont. Specifically, functions hci_req_sync()
and hci_dev_do_close() can race each other like below:
thread-A in hci_req_sync() | th... |
lookup_nsap(netdissect_options *ndo, register const u_char *nsap,
register u_int nsap_length)
{
register u_int i, j, k;
struct enamemem *tp;
const u_char *ensap;
if (nsap_length > 6) {
ensap = nsap + nsap_length - 6;
k = (ensap[0] << 8) | ensap[1];
j = (ensap[2] << 8) | ensap[3];
i = (ensap[4] << 8) |... | 0 | [
"CWE-125",
"CWE-787"
] | tcpdump | 730fc35968c5433b9e2a829779057f4f9495dc51 | 203,463,868,776,802,850,000,000,000,000,000,000,000 | 41 | CVE-2017-12894/In lookup_bytestring(), take the length of the byte string into account.
Otherwise, if, in our search of the hash table, we come across a byte
string that's shorter than the string we're looking for, we'll search
past the end of the string in the hash table.
This fixes a buffer over-read discovered by ... |
CImgList<T>& operator=(const CImg<t>& img) {
return assign(img);
} | 0 | [
"CWE-770"
] | cimg | 619cb58dd90b4e03ac68286c70ed98acbefd1c90 | 30,983,071,659,820,740,000,000,000,000,000,000,000 | 3 | CImg<>::load_bmp() and CImg<>::load_pandore(): Check that dimensions encoded in file does not exceed file size. |
static int bond_ioctl(struct net *net, unsigned int cmd,
struct compat_ifreq __user *ifr32)
{
struct ifreq kifr;
mm_segment_t old_fs;
int err;
switch (cmd) {
case SIOCBONDENSLAVE:
case SIOCBONDRELEASE:
case SIOCBONDSETHWADDR:
case SIOCBONDCHANGEACTIVE:
if (copy_from_user(&kifr, ifr32, sizeof(struct compa... | 0 | [
"CWE-264"
] | net | 4de930efc23b92ddf88ce91c405ee645fe6e27ea | 270,309,408,621,640,840,000,000,000,000,000,000,000 | 26 | net: validate the range we feed to iov_iter_init() in sys_sendto/sys_recvfrom
Cc: stable@vger.kernel.org # v3.19
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: David S. Miller <davem@davemloft.net> |
bounded_iostream::~bounded_iostream(){
} | 0 | [
"CWE-1187"
] | lepton | 82167c144a322cc956da45407f6dce8d4303d346 | 189,776,422,680,161,400,000,000,000,000,000,000,000 | 2 | fix #87 : always check that threads_required set up the appropriate number of threads---fire off nop functions on unused threads for consistency |
virDomainFSRemove(virDomainDefPtr def, size_t i)
{
virDomainFSDefPtr fs = def->fss[i];
VIR_DELETE_ELEMENT(def->fss, i, def->nfss);
return fs;
} | 0 | [
"CWE-212"
] | libvirt | a5b064bf4b17a9884d7d361733737fb614ad8979 | 131,906,061,382,849,030,000,000,000,000,000,000,000 | 7 | 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... |
static void l2cap_add_conf_opt(void **ptr, u8 type, u8 len, unsigned long val, size_t size)
{
struct l2cap_conf_opt *opt = *ptr;
BT_DBG("type 0x%2.2x len %u val 0x%lx", type, len, val);
if (size < L2CAP_CONF_OPT_SIZE + len)
return;
opt->type = type;
opt->len = len;
switch (len) {
case 1:
*((u8 *) opt->v... | 0 | [
"CWE-787"
] | linux | e860d2c904d1a9f38a24eb44c9f34b8f915a6ea3 | 274,965,608,603,991,100,000,000,000,000,000,000,000 | 32 | Bluetooth: Properly check L2CAP config option output buffer length
Validate the output buffer length for L2CAP config requests and responses
to avoid overflowing the stack buffer used for building the option blocks.
Cc: stable@vger.kernel.org
Signed-off-by: Ben Seri <ben@armis.com>
Signed-off-by: Marcel Holtmann <mar... |
Table *sqlite3LocateTable(
Parse *pParse, /* context in which to report errors */
u32 flags, /* LOCATE_VIEW or LOCATE_NOERR */
const char *zName, /* Name of the table we are looking for */
const char *zDbase /* Name of the database. Might be NULL */
){
Table *p;
sqlite3 *db = pP... | 0 | [
"CWE-674",
"CWE-787"
] | sqlite | 38096961c7cd109110ac21d3ed7dad7e0cb0ae06 | 73,070,559,496,324,650,000,000,000,000,000,000,000 | 50 | Avoid infinite recursion in the ALTER TABLE code when a view contains an unused CTE that references, directly or indirectly, the view itself.
FossilOrigin-Name: 1d2e53a39b87e364685e21de137655b6eee725e4c6d27fc90865072d7c5892b5 |
void r_pkcs7_free_signerinfos (RPKCS7SignerInfos *ss) {
ut32 i;
if (ss) {
for (i = 0; i < ss->length; i++) {
r_pkcs7_free_signerinfo (ss->elements[i]);
ss->elements[i] = NULL;
}
R_FREE (ss->elements);
// Used internally pkcs #7, so it should't free ss.
}
} | 0 | [
"CWE-476"
] | radare2 | 7ab66cca5bbdf6cb2d69339ef4f513d95e532dbf | 158,318,618,471,505,230,000,000,000,000,000,000,000 | 11 | Fix #7152 - Null deref in cms |
void TABLE::mark_columns_per_binlog_row_image()
{
THD *thd= in_use;
DBUG_ENTER("mark_columns_per_binlog_row_image");
DBUG_ASSERT(read_set->bitmap);
DBUG_ASSERT(write_set->bitmap);
/* If not using row format */
rpl_write_set= write_set;
/**
If in RBR we may need to mark some extra columns,
depend... | 0 | [
"CWE-416"
] | server | 4681b6f2d8c82b4ec5cf115e83698251963d80d5 | 51,538,377,574,666,880,000,000,000,000,000,000,000 | 87 | MDEV-26281 ASAN use-after-poison when complex conversion is involved in blob
the bug was that in_vector array in Item_func_in was allocated in the
statement arena, not in the table->expr_arena.
revert part of the 5acd391e8b2d. Instead, change the arena correctly
in fix_all_session_vcol_exprs().
Remove TABLE_ARENA, t... |
const char* oidc_util_hdr_in_user_agent_get(const request_rec *r) {
return oidc_util_hdr_in_get(r, OIDC_HTTP_HDR_USER_AGENT);
} | 0 | [
"CWE-79"
] | mod_auth_openidc | 55ea0a085290cd2c8cdfdd960a230cbc38ba8b56 | 173,096,663,903,560,400,000,000,000,000,000,000,000 | 3 | Add a function to escape Javascript characters |
void dummy_error_processor(THD *thd, void *data)
{} | 0 | [] | server | b000e169562697aa072600695d4f0c0412f94f4f | 268,748,471,095,297,620,000,000,000,000,000,000,000 | 2 | Bug#26361149 MYSQL SERVER CRASHES AT: COL IN(IFNULL(CONST, COL), NAME_CONST('NAME', NULL))
based on:
commit f7316aa0c9a
Author: Ajo Robert <ajo.robert@oracle.com>
Date: Thu Aug 24 17:03:21 2017 +0530
Bug#26361149 MYSQL SERVER CRASHES AT: COL IN(IFNULL(CONST,
COL), NAME_CONST('NAME'... |
ast_type_reduce(PyObject *self, PyObject *unused)
{
_Py_IDENTIFIER(__dict__);
PyObject *dict;
if (_PyObject_LookupAttrId(self, &PyId___dict__, &dict) < 0) {
return NULL;
}
if (dict) {
return Py_BuildValue("O()N", Py_TYPE(self), dict);
}
return Py_BuildValue("O()", Py_TYPE(sel... | 0 | [
"CWE-125"
] | cpython | dcfcd146f8e6fc5c2fc16a4c192a0c5f5ca8c53c | 202,738,277,468,256,230,000,000,000,000,000,000,000 | 12 | bpo-35766: Merge typed_ast back into CPython (GH-11645) |
static int entersafe_gen_random(sc_card_t *card,u8 *buff,size_t size)
{
int r=SC_SUCCESS;
u8 rbuf[SC_MAX_APDU_BUFFER_SIZE]={0};
sc_apdu_t apdu;
SC_FUNC_CALLED(card->ctx, SC_LOG_DEBUG_VERBOSE);
sc_format_apdu(card,&apdu,SC_APDU_CASE_2_SHORT,0x84,0x00,0x00);
apdu.resp=rbuf;
apdu.le=size;
apdu.resplen=... | 0 | [
"CWE-125"
] | OpenSC | 8fe377e93b4b56060e5bbfb6f3142ceaeca744fa | 34,551,213,651,366,667,000,000,000,000,000,000,000 | 22 | fixed out of bounds reads
Thanks to Eric Sesterhenn from X41 D-SEC GmbH
for reporting and suggesting security fixes. |
static int xudc_ep0_queue(struct usb_ep *_ep, struct usb_request *_req,
gfp_t gfp_flags)
{
struct xusb_req *req = to_xusb_req(_req);
struct xusb_ep *ep0 = to_xusb_ep(_ep);
struct xusb_udc *udc = ep0->udc;
unsigned long flags;
int ret;
spin_lock_irqsave(&udc->lock, flags);
ret = __xudc_ep0_queue(ep0, req);
... | 0 | [
"CWE-20",
"CWE-129"
] | linux | 7f14c7227f342d9932f9b918893c8814f86d2a0d | 329,744,147,308,637,540,000,000,000,000,000,000,000 | 15 | USB: gadget: validate endpoint index for xilinx udc
Assure that host may not manipulate the index to point
past endpoint array.
Signed-off-by: Szymon Heidrich <szymon.heidrich@gmail.com>
Cc: stable <stable@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> |
void gdImagePolygon (gdImagePtr im, gdPointPtr p, int n, int c)
{
int i;
int lx, ly;
typedef void (*image_line)(gdImagePtr im, int x1, int y1, int x2, int y2, int color);
image_line draw_line;
if (n <= 0) {
return;
}
/* Let it be known that we are drawing a polygon so that the opacity
* mask doesn't get cl... | 0 | [
"CWE-119"
] | php-src | e7f2356665c2569191a946b6fc35b437f0ae1384 | 267,302,351,505,100,460,000,000,000,000,000,000,000 | 38 | Fix #66387: Stack overflow with imagefilltoborder
The stack overflow is caused by the recursive algorithm in combination with a
very large negative coordinate passed to gdImageFillToBorder(). As there is
already a clipping for large positive coordinates to the width and height of
the image, it seems to be consequent t... |
static void unassigned_mem_write(void *opaque, hwaddr addr,
uint64_t val, unsigned size)
{
#ifdef DEBUG_UNASSIGNED
printf("Unassigned mem write " TARGET_FMT_plx " = 0x%"PRIx64"\n", addr, val);
#endif
} | 0 | [
"CWE-476"
] | unicorn | 3d3deac5e6d38602b689c4fef5dac004f07a2e63 | 250,703,112,796,316,050,000,000,000,000,000,000,000 | 7 | Fix crash when mapping a big memory and calling uc_close |
SpoolssEnumPrinters_r(tvbuff_t *tvb, int offset, packet_info *pinfo,
proto_tree *tree, dcerpc_info *di, guint8 *drep _U_)
{
guint32 num_drivers;
dcerpc_call_value *dcv = (dcerpc_call_value *)di->call_data;
gint16 level = GPOINTER_TO_INT(dcv->se_data);
BUFFER buffer;
proto_item *item;
proto_tree *subtree = NU... | 0 | [
"CWE-399"
] | wireshark | b4d16b4495b732888e12baf5b8a7e9bf2665e22b | 109,347,112,857,920,340,000,000,000,000,000,000,000 | 59 | 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... |
call_plugin_register_handoff(gpointer data, gpointer user_data _U_)
{
proto_plugin *plug = (proto_plugin *)data;
if (plug->register_handoff) {
plug->register_handoff();
}
} | 0 | [
"CWE-401"
] | wireshark | a9fc769d7bb4b491efb61c699d57c9f35269d871 | 149,676,048,998,842,000,000,000,000,000,000,000,000 | 8 | epan: Fix a memory leak.
Make sure _proto_tree_add_bits_ret_val allocates a bits array using the
packet scope, otherwise we leak memory. Fixes #17032. |
static int tls1_check_cert_param(SSL *s, X509 *x, int set_ee_md)
{
return 1;
} | 0 | [] | openssl | 76343947ada960b6269090638f5391068daee88d | 99,631,854,547,087,150,000,000,000,000,000,000,000 | 4 | Fix for CVE-2015-0291
If a client renegotiates using an invalid signature algorithms extension
it will crash a server with a NULL pointer dereference.
Thanks to David Ramos of Stanford University for reporting this bug.
CVE-2015-0291
Reviewed-by: Tim Hudson <tjh@openssl.org>
Conflicts:
ssl/t1_lib.c |
int can_nice(const struct task_struct *p, const int nice)
{
/* convert nice value [19,-20] to rlimit style value [1,40] */
int nice_rlim = nice_to_rlimit(nice);
return (nice_rlim <= task_rlimit(p, RLIMIT_NICE) ||
capable(CAP_SYS_NICE));
} | 0 | [
"CWE-119"
] | linux | 29d6455178a09e1dc340380c582b13356227e8df | 257,673,714,909,382,670,000,000,000,000,000,000,000 | 8 | sched: panic on corrupted stack end
Until now, hitting this BUG_ON caused a recursive oops (because oops
handling involves do_exit(), which calls into the scheduler, which in
turn raises an oops), which caused stuff below the stack to be
overwritten until a panic happened (e.g. via an oops in interrupt
context, cause... |
static ssize_t ucma_set_option(struct ucma_file *file, const char __user *inbuf,
int in_len, int out_len)
{
struct rdma_ucm_set_option cmd;
struct ucma_context *ctx;
void *optval;
int ret;
if (copy_from_user(&cmd, inbuf, sizeof(cmd)))
return -EFAULT;
if (unlikely(cmd.optlen > KMALLOC_MAX_SIZE))
re... | 0 | [
"CWE-416",
"CWE-703"
] | linux | cb2595c1393b4a5211534e6f0a0fbad369e21ad8 | 173,677,570,042,259,970,000,000,000,000,000,000,000 | 33 | infiniband: fix a possible use-after-free bug
ucma_process_join() will free the new allocated "mc" struct,
if there is any error after that, especially the copy_to_user().
But in parallel, ucma_leave_multicast() could find this "mc"
through idr_find() before ucma_process_join() frees it, since it
is already published... |
static ssize_t os_desc_b_vendor_code_show(struct config_item *item, char *page)
{
return sprintf(page, "0x%02x\n",
os_desc_item_to_gadget_info(item)->b_vendor_code);
} | 0 | [
"CWE-125"
] | linux | 15753588bcd4bbffae1cca33c8ced5722477fe1f | 678,744,087,823,528,000,000,000,000,000,000,000 | 5 | USB: gadget: fix illegal array access in binding with UDC
FuzzUSB (a variant of syzkaller) found an illegal array access
using an incorrect index while binding a gadget with UDC.
Reference: https://www.spinics.net/lists/linux-usb/msg194331.html
This bug occurs when a size variable used for a buffer
is misused to acc... |
static int ZEND_FASTCALL ZEND_FETCH_OBJ_FUNC_ARG_SPEC_VAR_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARGS)
{
zend_op *opline = EX(opline);
if (ARG_SHOULD_BE_SENT_BY_REF(EX(fbc), opline->extended_value)) {
/* Behave like FETCH_OBJ_W */
zend_free_op free_op1, free_op2;
zval *property = _get_zval_ptr_var(&opline->op2, EX(T... | 0 | [] | php-src | ce96fd6b0761d98353761bf78d5bfb55291179fd | 259,389,887,754,288,630,000,000,000,000,000,000,000 | 36 | - 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 |
ResolveStateAndPredicate(ExprDef *expr, enum xkb_match_operation *pred_rtrn,
xkb_mod_mask_t *mods_rtrn, CompatInfo *info)
{
if (expr == NULL) {
*pred_rtrn = MATCH_ANY_OR_NONE;
*mods_rtrn = MOD_REAL_MASK_ALL;
return true;
}
*pred_rtrn = MATCH_EXACTLY;
if ... | 1 | [
"CWE-476"
] | libxkbcommon | 96df3106d49438e442510c59acad306e94f3db4d | 83,102,121,602,074,450,000,000,000,000,000,000,000 | 31 | xkbcomp: Don't crash on no-op modmask expressions
If we have an expression of the form 'l1' in an interp section, we
unconditionally try to dereference its args, even if it has none.
Signed-off-by: Daniel Stone <daniels@collabora.com> |
static apr_bucket *h2_beam_bucket(h2_bucket_beam *beam,
apr_bucket_brigade *dest,
const apr_bucket *src)
{
apr_bucket *b = NULL;
int i;
if (beamers) {
for (i = 0; i < beamers->nelts && b == NULL; ++i) {
h2_bucket_beamer... | 0 | [
"CWE-400"
] | mod_h2 | 83a2e3866918ce6567a683eb4c660688d047ee81 | 173,931,924,711,814,470,000,000,000,000,000,000,000 | 16 | * fixes a race condition where aborting streams triggers an unnecessary timeout. |
static int proc_do_uuid(ctl_table *table, int write, struct file *filp,
void __user *buffer, size_t *lenp, loff_t *ppos)
{
ctl_table fake_table;
unsigned char buf[64], tmp_uuid[16], *uuid;
uuid = table->data;
if (!uuid) {
uuid = tmp_uuid;
uuid[8] = 0;
}
if (uuid[8] == 0)
generate_random_uuid(uuid);
sp... | 0 | [
"CWE-310"
] | linux-2.6 | 8a0a9bd4db63bc45e3017bedeafbd88d0eb84d02 | 144,146,377,664,895,140,000,000,000,000,000,000,000 | 25 | random: make get_random_int() more random
It's a really simple patch that basically just open-codes the current
"secure_ip_id()" call, but when open-coding it we now use a _static_
hashing area, so that it gets updated every time.
And to make sure somebody can't just start from the same original seed of
all-zeroes, a... |
static void __exit af_unix_exit(void)
{
sock_unregister(PF_UNIX);
proto_unregister(&unix_proto);
unregister_pernet_subsys(&unix_net_ops);
} | 0 | [] | linux-2.6 | 6209344f5a3795d34b7f2c0061f49802283b6bdd | 148,117,133,148,292,500,000,000,000,000,000,000,000 | 6 | net: unix: fix inflight counting bug in garbage collector
Previously I assumed that the receive queues of candidates don't
change during the GC. This is only half true, nothing can be received
from the queues (see comment in unix_gc()), but buffers could be added
through the other half of the socket pair, which may s... |
static int rm_read_packet(AVFormatContext *s, AVPacket *pkt)
{
RMDemuxContext *rm = s->priv_data;
AVStream *st = NULL; // init to silence compiler warning
int i, len, res, seq = 1;
int64_t timestamp, pos;
int flags;
for (;;) {
if (rm->audio_pkt_cnt) {
// If there are queued ... | 0 | [
"CWE-399",
"CWE-834"
] | FFmpeg | 124eb202e70678539544f6268efc98131f19fa49 | 135,674,987,400,030,200,000,000,000,000,000,000,000 | 57 | avformat/rmdec: Fix DoS due to lack of eof check
Fixes: loop.ivr
Found-by: Xiaohei and Wangchu from Alibaba Security Team
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc> |
R_API int r_core_bin_set_env(RCore *r, RBinFile *binfile) {
RBinObject *binobj = binfile ? binfile->o: NULL;
RBinInfo *info = binobj ? binobj->info: NULL;
if (info) {
int va = info->has_va;
char * arch = strdup(info->arch);
char * cpu = info->cpu? strdup(info->cpu): NULL;
ut16 bits = info->bits;
ut64 basea... | 0 | [
"CWE-416"
] | radare2 | f85bc674b2a2256a364fe796351bc1971e106005 | 118,152,545,355,194,880,000,000,000,000,000,000,000 | 30 | Fix #7698 - UAF in r_config_set when loading a dex |
static double mp_list_jxyzc(_cimg_math_parser& mp) {
const unsigned int
ind = (unsigned int)cimg::mod((int)_mp_arg(2),mp.listin.width()),
interpolation = (unsigned int)_mp_arg(7),
boundary_conditions = (unsigned int)_mp_arg(8);
const CImg<T> &img = mp.listin[ind];
... | 0 | [
"CWE-119",
"CWE-787"
] | CImg | ac8003393569aba51048c9d67e1491559877b1d1 | 44,421,093,620,334,490,000,000,000,000,000,000,000 | 80 | . |
Tags::Tags(Segment* pSegment, long long payload_start, long long payload_size,
long long element_start, long long element_size)
: m_pSegment(pSegment),
m_start(payload_start),
m_size(payload_size),
m_element_start(element_start),
m_element_size(element_size),
m_tags(NULL),
... | 0 | [
"CWE-20"
] | libvpx | 34d54b04e98dd0bac32e9aab0fbda0bf501bc742 | 11,241,489,040,502,217,000,000,000,000,000,000,000 | 10 | 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 APR_INLINE int do_double_reverse (int double_reverse,
const char *remote_host,
apr_sockaddr_t *client_addr,
apr_pool_t *pool)
{
apr_sockaddr_t *sa;
apr_status_t rv;
if (double_r... | 0 | [
"CWE-416",
"CWE-284"
] | httpd | 4cc27823899e070268b906ca677ee838d07cf67a | 221,916,509,894,004,900,000,000,000,000,000,000,000 | 31 | core: Disallow Methods' registration at run time (.htaccess), they may be
used only if registered at init time (httpd.conf).
Calling ap_method_register() in children processes is not the right scope
since it won't be shared for all requests.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1807655 13f7... |
void **lxc_append_null_to_array(void **array, size_t count)
{
void **temp;
/* Append NULL to the array */
if (count) {
temp = realloc(array, (count + 1) * sizeof(*array));
if (!temp) {
size_t i;
for (i = 0; i < count; i++)
free(array[i]);
free(array);
return NULL;
}
array = temp;
array[co... | 0 | [
"CWE-417"
] | lxc | c1cf54ebf251fdbad1e971679614e81649f1c032 | 81,970,768,903,092,500,000,000,000,000,000,000,000 | 21 | CVE 2018-6556: verify netns fd in lxc-user-nic
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com> |
get_ownertrust_string (PKT_public_key *pk)
{
return trust_value_to_string (get_ownertrust_with_min (pk));
} | 0 | [
"CWE-20"
] | gnupg | 2183683bd633818dd031b090b5530951de76f392 | 101,431,181,571,625,800,000,000,000,000,000,000,000 | 4 | Use inline functions to convert buffer data to scalars.
* common/host2net.h (buf16_to_ulong, buf16_to_uint): New.
(buf16_to_ushort, buf16_to_u16): New.
(buf32_to_size_t, buf32_to_ulong, buf32_to_uint, buf32_to_u32): New.
--
Commit 91b826a38880fd8a989318585eb502582636ddd8 was not enough to
avoid all sign extension on ... |
void ecdsa_verify_prepare_legacy(ecdsa_verify_context_t *ctx, const ecc_int256_t *hash, const ecdsa_signature_t *signature) {
ecc_int256_t w, u1, tmp;
if (ecc_25519_gf_is_zero(&signature->s) || ecc_25519_gf_is_zero(&signature->r)) {
// Signature is invalid, mark by setting ctx->r to an invalid value
memset... | 0 | [
"CWE-347"
] | ecdsautils | 1d4b091abdf15ad7b2312535b5b95ad70f6dbd08 | 213,784,456,067,823,520,000,000,000,000,000,000,000 | 17 | verify: fix signature verification (CVE-2022-24884)
Verify that r and s are non-zero. Without these checks, an all-zero
signature is always considered valid.
While it would be nicer to error out in ecdsa_verify_prepare_legacy()
already, that would require users of libecdsautil to check a return value
of the prepare s... |
int inet6_bind(struct socket *sock, struct sockaddr *uaddr, int addr_len)
{
struct sockaddr_in6 *addr=(struct sockaddr_in6 *)uaddr;
struct sock *sk = sock->sk;
struct inet_sock *inet = inet_sk(sk);
struct ipv6_pinfo *np = inet6_sk(sk);
struct net *net = sock_net(sk);
__be32 v4addr = 0;
unsigned short snum;
int ... | 0 | [] | linux-2.6 | 2e761e0532a784816e7e822dbaaece8c5d4be14d | 5,626,402,264,830,379,000,000,000,000,000,000,000 | 110 | ipv6 netns: init net is used to set bindv6only for new sock
The bindv6only is tuned via sysctl. It is already on a struct net
and per-net sysctls allow for its modification (ipv6_sysctl_net_init).
Despite this the value configured in the init net is used for the
rest of them.
Signed-off-by: Pavel Emelyanov <xemul@op... |
static int gfar_alloc_skb_resources(struct net_device *ndev)
{
void *vaddr;
dma_addr_t addr;
int i, j;
struct gfar_private *priv = netdev_priv(ndev);
struct device *dev = priv->dev;
struct gfar_priv_tx_q *tx_queue = NULL;
struct gfar_priv_rx_q *rx_queue = NULL;
priv->total_tx_ring_size = 0;
for (i = 0; i < pr... | 0 | [] | linux | d8861bab48b6c1fc3cdbcab8ff9d1eaea43afe7f | 69,284,806,662,988,170,000,000,000,000,000,000,000 | 80 | gianfar: fix jumbo packets+napi+rx overrun crash
When using jumbo packets and overrunning rx queue with napi enabled,
the following sequence is observed in gfar_add_rx_frag:
| lstatus | | skb |
t | lstatus, size, flags | first | len, data_len, *... |
char *__acpi_map_table(unsigned long phys_addr, unsigned long size)
{
if (!phys_addr || !size)
return NULL;
if (phys_addr+size <= (end_pfn_map << PAGE_SHIFT) + PAGE_SIZE)
return __va(phys_addr);
return NULL;
} | 0 | [] | linux-2.6 | f0f4c3432e5e1087b3a8c0e6bd4113d3c37497ff | 167,750,726,663,374,830,000,000,000,000,000,000,000 | 10 | [PATCH] i386: add HPET(s) into resource map
Add HPET(s) into resource map. This will allow for the HPET(s) to be
visibile within /proc/iomem.
Signed-off-by: Aaron Durbin <adurbin@google.com>
Signed-off-by: Andi Kleen <ak@suse.de> |
QPDFWriter::setExtraHeaderText(std::string const& text)
{
this->extra_header_text = text;
if ((this->extra_header_text.length() > 0) &&
(*(this->extra_header_text.rbegin()) != '\n'))
{
QTC::TC("qpdf", "QPDFWriter extra header text add newline");
this->extra_header_text += "\n";
}... | 0 | [
"CWE-399",
"CWE-835"
] | qpdf | 8249a26d69f72b9cda584c14cc3f12769985e481 | 211,807,918,614,047,100,000,000,000,000,000,000,000 | 14 | Fix infinite loop in QPDFWriter (fixes #143) |
TEST_F(EncryptedRecordTest, TestReadSeqNum) {
for (int i = 0; i < 10; i++) {
addToQueue("17030100050123456789");
EXPECT_CALL(*readAead_, _decrypt(_, _, i))
.WillOnce(
Invoke([](std::unique_ptr<IOBuf>& buf, const IOBuf*, uint64_t) {
expectSame(buf, "0123456789");
... | 0 | [
"CWE-400",
"CWE-703",
"CWE-770"
] | fizz | 6bf67137ef1ee5cd70c842b014c322b7deaf994b | 320,337,427,965,853,400,000,000,000,000,000,000,000 | 12 | Reject zero length handshake records.
Summary:
Zero length (all padding) handshake are forbidden by RFC. Allowing
these was a regression in D13754697 (2c6f78a).
This is a partial fix for CVE-2019-11924
Reviewed By: xybu
Differential Revision: D16285100
fbshipit-source-id: 05a19d31ad74601ce89156a0e59517aaad8dd928 |
static void drop_mountpoint(struct fs_pin *p)
{
struct mount *m = container_of(p, struct mount, mnt_umount);
dput(m->mnt_ex_mountpoint);
pin_remove(p);
mntput(&m->mnt);
} | 0 | [
"CWE-703"
] | linux | cd4a40174b71acd021877341684d8bb1dc8ea4ae | 302,973,587,931,488,650,000,000,000,000,000,000,000 | 7 | mnt: Fail collect_mounts when applied to unmounted mounts
The only users of collect_mounts are in audit_tree.c
In audit_trim_trees and audit_add_tree_rule the path passed into
collect_mounts is generated from kern_path passed an audit_tree
pathname which is guaranteed to be an absolute path. In those cases
collect_... |
void CLASS vng_interpolate()
{
static const signed char *cp, terms[] = {
-2,-2,+0,-1,0,0x01, -2,-2,+0,+0,1,0x01, -2,-1,-1,+0,0,0x01,
-2,-1,+0,-1,0,0x02, -2,-1,+0,+0,0,0x03, -2,-1,+0,+1,1,0x01,
-2,+0,+0,-1,0,0x06, -2,+0,+0,+0,1,0x02, -2,+0,+0,+1,0,0x03,
-2,+1,-1,+0,0,0x04, -2,+1,+0,-1,1,0x04, -2,+1,+0,... | 0 | [
"CWE-119",
"CWE-125",
"CWE-787"
] | LibRaw | d13e8f6d1e987b7491182040a188c16a395f1d21 | 8,225,712,500,650,511,000,000,000,000,000,000,000 | 131 | CVE-2017-1438 credits; fix for Kodak 65000 out of bounds access |
mysql_declare_plugin(myisam)
{
MYSQL_STORAGE_ENGINE_PLUGIN,
&myisam_storage_engine,
"MyISAM",
"MySQL AB",
"MyISAM storage engine",
PLUGIN_LICENSE_GPL,
myisam_init, /* Plugin Init */
NULL, /* Plugin Deinit */
0x0100, /* 1.0 */
NULL, /* status variables */
myisam... | 0 | [
"CWE-362"
] | mysql-server | 4e5473862e6852b0f3802b0cd0c6fa10b5253291 | 296,955,401,815,182,720,000,000,000,000,000,000,000 | 16 | Bug#24388746: PRIVILEGE ESCALATION AND RACE CONDITION USING CREATE TABLE
During REPAIR TABLE of a MyISAM table, a temporary data file (.TMD)
is created. When repair finishes, this file is renamed to the original
.MYD file. The problem was that during this rename, we copied the
stats from the old file to the new file w... |
static bool hidpp_application_equals(struct hid_device *hdev,
unsigned int application)
{
struct list_head *report_list;
struct hid_report *report;
report_list = &hdev->report_enum[HID_INPUT_REPORT].report_list;
report = list_first_entry_or_null(report_list, struct hid_report, list);
return report && rep... | 0 | [
"CWE-787"
] | linux | d9d4b1e46d9543a82c23f6df03f4ad697dab361b | 327,107,311,723,589,130,000,000,000,000,000,000,000 | 10 | HID: Fix assumption that devices have inputs
The syzbot fuzzer found a slab-out-of-bounds write bug in the hid-gaff
driver. The problem is caused by the driver's assumption that the
device must have an input report. While this will be true for all
normal HID input devices, a suitably malicious device can violate the... |
static void WriteFooterHTMLTable( SQLHSTMT hStmt )
{
printf( "</table>\n" );
} | 0 | [
"CWE-119",
"CWE-369"
] | unixODBC | 45ef78e037f578b15fc58938a3a3251655e71d6f | 309,926,730,016,471,950,000,000,000,000,000,000,000 | 4 | New Pre Source |
int reset(void) { bzero(ptr,sizeof(float)); return 0; } | 0 | [
"CWE-416",
"CWE-703"
] | server | 08c7ab404f69d9c4ca6ca7a9cf7eec74c804f917 | 80,800,076,556,356,370,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... |
lys_node_dup_recursion(struct lys_module *module, struct lys_node *parent, const struct lys_node *node,
struct unres_schema *unres, int shallow, int finalize)
{
struct lys_node *retval = NULL, *iter, *p;
struct ly_ctx *ctx = module->ctx;
int i, j, rc;
unsigned int size, size1, siz... | 0 | [
"CWE-119"
] | libyang | 32fb4993bc8bb49e93e84016af3c10ea53964be5 | 212,416,581,287,108,730,000,000,000,000,000,000,000 | 447 | schema tree BUGFIX do not check features while still resolving schema
Fixes #723 |
Item *st_select_lex::build_cond_for_grouping_fields(THD *thd, Item *cond,
bool no_top_clones)
{
if (cond->get_extraction_flag() == FULL_EXTRACTION_FL)
{
if (no_top_clones)
return cond;
cond->clear_extraction_flag();
return cond->build_clone(thd, thd->mem_root);
}
if (cond->type() == ... | 0 | [
"CWE-476"
] | server | 3a52569499e2f0c4d1f25db1e81617a9d9755400 | 61,183,252,729,361,370,000,000,000,000,000,000,000 | 62 | MDEV-25636: Bug report: abortion in sql/sql_parse.cc:6294
The asserion failure was caused by this query
select /*id=1*/ from t1
where
col= ( select /*id=2*/ from ... where corr_cond1
union
select /*id=4*/ from ... where corr_cond2)
Here,
- select with id=2 was correlated due to corr_cond1.... |
win_strncat_from_utf16le(struct archive_string *as, const void *_p,
size_t bytes, struct archive_string_conv *sc)
{
return (win_strncat_from_utf16(as, _p, bytes, sc, 0));
} | 0 | [
"CWE-476"
] | libarchive | 42a3408ac7df1e69bea9ea12b72e14f59f7400c0 | 315,726,763,790,705,340,000,000,000,000,000,000,000 | 5 | archive_strncat_l(): allocate and do not convert if length == 0
This ensures e.g. that archive_mstring_copy_mbs_len_l() does not set
aes_set = AES_SET_MBS with aes_mbs.s == NULL.
Resolves possible null-pointer dereference reported by OSS-Fuzz.
Reported-By: OSS-Fuzz issue 286 |
virDomainMigratePrepare2(virConnectPtr dconn,
char **cookie,
int *cookielen,
const char *uri_in,
char **uri_out,
unsigned long flags,
const char *dname,
... | 0 | [
"CWE-254"
] | libvirt | 506e9d6c2d4baaf580d489fff0690c0ff2ff588f | 255,993,279,148,869,900,000,000,000,000,000,000,000 | 37 | virDomainGetTime: Deny on RO connections
We have a policy that if API may end up talking to a guest agent
it should require RW connection. We don't obey the rule in
virDomainGetTime().
Signed-off-by: Michal Privoznik <mprivozn@redhat.com> |
static inline void update_hiwater_vm(struct mm_struct *mm)
{
if (mm->hiwater_vm < mm->total_vm)
mm->hiwater_vm = mm->total_vm;
} | 0 | [
"CWE-119"
] | linux | 1be7107fbe18eed3e319a6c3e83c78254b693acb | 230,847,857,580,109,870,000,000,000,000,000,000,000 | 5 | mm: larger stack guard gap, between vmas
Stack guard page is a useful feature to reduce a risk of stack smashing
into a different mapping. We have been using a single page gap which
is sufficient to prevent having stack adjacent to a different mapping.
But this seems to be insufficient in the light of the stack usage ... |
channel_forward_listen(LIBSSH2_SESSION * session, const char *host,
int port, int *bound_port, int queue_maxsize)
{
unsigned char *s;
static const unsigned char reply_codes[3] =
{ SSH_MSG_REQUEST_SUCCESS, SSH_MSG_REQUEST_FAILURE, 0 };
int rc;
if(!host)
host = "0.0... | 1 | [
"CWE-787"
] | libssh2 | dc109a7f518757741590bb993c0c8412928ccec2 | 66,981,916,358,174,540,000,000,000,000,000,000,000 | 144 | 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... |
std::string Magick::Image::format(void) const
{
const MagickInfo
*magick_info;
GetPPException;
magick_info=GetMagickInfo(constImage()->magick,exceptionInfo);
ThrowImageException;
if ((magick_info != 0) && (*magick_info->description != '\0'))
return(std::string(magick_info->description));
if (!qui... | 0 | [
"CWE-416"
] | ImageMagick | 8c35502217c1879cb8257c617007282eee3fe1cc | 300,463,348,864,457,380,000,000,000,000,000,000,000 | 18 | Added missing return to avoid use after free. |
int ssl3_get_cert_verify(SSL *s)
{
EVP_PKEY *pkey = NULL;
unsigned char *p;
int al, ok, ret = 0;
long n;
int type = 0, i, j;
X509 *peer;
n = s->method->ssl_get_message(s,
SSL3_ST_SR_CERT_VRFY_A,
SSL3_ST_SR_CERT_VRFY_B,
... | 0 | [] | openssl | 1392c238657ec745af6a40def03d67d4ce02a082 | 93,208,236,473,275,560,000,000,000,000,000,000,000 | 159 | Fix PSK handling.
The PSK identity hint should be stored in the SSL_SESSION structure
and not in the parent context (which will overwrite values used
by other SSL structures with the same SSL_CTX).
Use BUF_strndup when copying identity as it may not be null terminated.
Reviewed-by: Tim Hudson <tjh@openssl.org>
(cher... |
static inline void SetPixelBlue(const Image *restrict image,const Quantum blue,
Quantum *restrict pixel)
{
pixel[image->channel_map[BluePixelChannel].offset]=blue;
} | 0 | [
"CWE-119",
"CWE-787"
] | ImageMagick | 450bd716ed3b9186dd10f9e60f630a3d9eeea2a4 | 144,782,264,076,001,240,000,000,000,000,000,000,000 | 5 | |
CJSON_PUBLIC(cJSON_bool) cJSON_IsInvalid(const cJSON * const item)
{
if (item == NULL)
{
return false;
}
return (item->type & 0xFF) == cJSON_Invalid;
} | 0 | [
"CWE-754",
"CWE-787"
] | cJSON | be749d7efa7c9021da746e685bd6dec79f9dd99b | 143,439,008,574,427,000,000,000,000,000,000,000,000 | 9 | Fix crash of cJSON_GetObjectItemCaseSensitive when calling it on arrays |
int num_layers() const { return num_layers_; } | 0 | [
"CWE-20"
] | tensorflow | 14755416e364f17fb1870882fa778c7fec7f16e3 | 220,058,437,684,229,800,000,000,000,000,000,000,000 | 1 | Prevent CHECK-fail in LSTM/GRU with zero-length input.
PiperOrigin-RevId: 346239181
Change-Id: I5f233dbc076aab7bb4e31ba24f5abd4eaf99ea4f |
SSL_CTX_use_certificate_blob(SSL_CTX *ctx, const struct curl_blob *blob,
int type, const char *key_passwd)
{
int ret = 0;
X509 *x = NULL;
/* the typecast of blob->len is fine since it is guaranteed to never be
larger than CURL_MAX_INPUT_LENGTH */
BIO *in = BIO_new_mem_buf(blob-... | 0 | [
"CWE-416",
"CWE-295"
] | curl | 7f4a9a9b2a49547eae24d2e19bc5c346e9026479 | 182,749,094,093,637,900,000,000,000,000,000,000,000 | 36 | openssl: associate/detach the transfer from connection
CVE-2021-22901
Bug: https://curl.se/docs/CVE-2021-22901.html |
int __init_or_module __platform_driver_probe(struct platform_driver *drv,
int (*probe)(struct platform_device *), struct module *module)
{
int retval, code;
if (drv->driver.probe_type == PROBE_PREFER_ASYNCHRONOUS) {
pr_err("%s: drivers registered with %s can not be probed asynchronously\n",
drv->driver.name,... | 0 | [
"CWE-362",
"CWE-284"
] | linux | 6265539776a0810b7ce6398c27866ddb9c6bd154 | 276,858,034,170,423,750,000,000,000,000,000,000,000 | 48 | driver core: platform: fix race condition with driver_override
The driver_override implementation is susceptible to race condition when
different threads are reading vs storing a different driver override.
Add locking to avoid race condition.
Fixes: 3d713e0e382e ("driver core: platform: add device binding path 'drive... |
dec(pos_T *lp)
{
char_u *p;
lp->coladd = 0;
if (lp->col == MAXCOL)
{
// past end of line
p = ml_get(lp->lnum);
lp->col = (colnr_T)STRLEN(p);
if (has_mbyte)
lp->col -= (*mb_head_off)(p, p + lp->col);
return 0;
}
if (lp->col > 0)
{
// still within line
lp->col--;
if (has_mbyte)
... | 0 | [
"CWE-120"
] | vim | 7ce5b2b590256ce53d6af28c1d203fb3bc1d2d97 | 96,244,270,285,422,380,000,000,000,000,000,000,000 | 41 | patch 8.2.4969: changing text in Visual mode may cause invalid memory access
Problem: Changing text in Visual mode may cause invalid memory access.
Solution: Check the Visual position after making a change. |
threadsTest(const char *filename ATTRIBUTE_UNUSED,
const char *resul ATTRIBUTE_UNUSED,
const char *err ATTRIBUTE_UNUSED,
int options ATTRIBUTE_UNUSED) {
return(testThread());
} | 0 | [
"CWE-125"
] | libxml2 | a820dbeac29d330bae4be05d9ecd939ad6b4aa33 | 200,151,292,924,879,800,000,000,000,000,000,000,000 | 6 | Bug 758605: Heap-based buffer overread in xmlDictAddString <https://bugzilla.gnome.org/show_bug.cgi?id=758605>
Reviewed by David Kilzer.
* HTMLparser.c:
(htmlParseName): Add bounds check.
(htmlParseNameComplex): Ditto.
* result/HTML/758605.html: Added.
* result/HTML/758605.html.err: Added.
* result/HTML/758605.html.s... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.