func string | target int64 | cwe list | project string | commit_id string | hash float64 | size int64 | message string |
|---|---|---|---|---|---|---|---|
create_footnote_ref(struct footnote_list *list, const uint8_t *name, size_t name_size)
{
struct footnote_ref *ref = calloc(1, sizeof(struct footnote_ref));
if (!ref)
return NULL;
ref->id = hash_link_ref(name, name_size);
return ref;
} | 0 | [] | redcarpet | e5a10516d07114d582d13b9125b733008c61c242 | 80,420,070,848,556,740,000,000,000,000,000,000,000 | 10 | Avoid rewinding previous inline when auto-linking
When a bit like "_foo_1@bar.com" is processed, first the emphasis is
rendered, then the 1 is output verbatim. When the `@` is encountered,
Redcarpet tries to find the "local part" of the address and stops when
it encounters an invalid char (i.e. here the `!`).
The pro... |
static int php_cli_server_client_read_request_on_message_begin(php_http_parser *parser)
{
return 0;
} | 0 | [] | php-src | 2438490addfbfba51e12246a74588b2382caa08a | 235,222,942,945,654,800,000,000,000,000,000,000,000 | 4 | slim post data |
_gd2GetHeader (gdIOCtxPtr in, int *sx, int *sy,
int *cs, int *vers, int *fmt, int *ncx, int *ncy,
t_chunk_info ** chunkIdx)
{
int i;
int ch;
char id[5];
t_chunk_info *cidx;
int sidx;
int nc;
GD2_DBG (printf ("Reading gd2 header info\n"));
for (i = 0; i < 4; i++) {
ch = gdGetC (... | 0 | [
"CWE-415",
"CWE-190"
] | libgd | 69d2fd2c597ffc0c217de1238b9bf4d4bceba8e6 | 32,482,377,115,082,415,000,000,000,000,000,000,000 | 130 | Fix #354: Signed Integer Overflow gd_io.c
GD2 stores the number of horizontal and vertical chunks as words (i.e. 2
byte unsigned). These values are multiplied and assigned to an int when
reading the image, what can cause integer overflows. We have to avoid
that, and also make sure that either chunk count is actually g... |
exsltSaxonEvalFunction (xmlXPathParserContextPtr ctxt, int nargs) {
xmlXPathCompExprPtr expr;
xmlXPathObjectPtr ret;
if (nargs != 1) {
xmlXPathSetArityError(ctxt);
return;
}
if (!xmlXPathStackIsExternal(ctxt)) {
xmlXPathSetTypeError(ctxt);
return;
}
expr = (xmlXPathComp... | 0 | [
"CWE-119"
] | libxslt | 8b90c9a699e0eaa98bbeec63a473ddc73aaa238c | 160,658,948,293,205,700,000,000,000,000,000,000,000 | 24 | Fix saxon:line-number with namespace nodes
exsltSaxonLineNumberFunction must make sure not to pass namespace
"nodes" to xmlGetLineNo. Otherwise, an OOB heap read results which
typically leads to a segfault.
Found with afl-fuzz and ASan. |
void CalendarRegressionTest::TestT11632(void) {
UErrorCode status = U_ZERO_ERROR;
GregorianCalendar cal(TimeZone::createTimeZone("Pacific/Apia"), status);
if(U_FAILURE(status)) {
dataerrln("Error creating Calendar: %s", u_errorName(status));
return;
}
failure(status, "Calendar::creat... | 1 | [
"CWE-190"
] | icu | 71dd84d4ffd6600a70e5bca56a22b957e6642bd4 | 62,007,454,359,432,360,000,000,000,000,000,000,000 | 36 | ICU-12504 in ICU4C Persian cal, use int64_t math for one operation to avoid overflow; add tests in C and J
X-SVN-Rev: 40654 |
static bool cmd_identify(IDEState *s, uint8_t cmd)
{
if (s->bs && s->drive_kind != IDE_CD) {
if (s->drive_kind != IDE_CFATA) {
ide_identify(s);
} else {
ide_cfata_identify(s);
}
s->status = READY_STAT | SEEK_STAT;
ide_transfer_start(s, s->io_buffer, 51... | 0 | [
"CWE-189"
] | qemu | 940973ae0b45c9b6817bab8e4cf4df99a9ef83d7 | 330,734,498,269,851,950,000,000,000,000,000,000,000 | 21 | ide: Correct improper smart self test counter reset in ide core.
The SMART self test counter was incorrectly being reset to zero,
not 1. This had the effect that on every 21st SMART EXECUTE OFFLINE:
* We would write off the beginning of a dynamically allocated buffer
* We forgot the SMART history
Fix this.
Signed-o... |
STACK_OF(X509) *X509_chain_up_ref(STACK_OF(X509) *chain)
{
STACK_OF(X509) *ret = sk_X509_dup(chain);
int i;
if (ret == NULL)
return NULL;
for (i = 0; i < sk_X509_num(ret); i++) {
X509 *x = sk_X509_value(ret, i);
if (!X509_up_ref(x))
goto err;
}
return ret;
... | 0 | [
"CWE-476"
] | openssl | 8130d654d1de922ea224fa18ee3bc7262edc39c0 | 69,054,893,055,948,000,000,000,000,000,000,000,000 | 21 | 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 ... |
static int ssl_parse_client_hello( ssl_context *ssl )
{
int ret;
unsigned int i, j;
size_t n;
unsigned int ciph_len, sess_len;
unsigned int comp_len;
unsigned int ext_len = 0;
unsigned char *buf, *p, *ext;
int renegotiation_info_seen = 0;
int handshake_failure = 0;
SSL_DEBUG_MSG... | 0 | [
"CWE-310"
] | polarssl | 43f9799ce61c6392a014d0a2ea136b4b3a9ee194 | 86,688,058,331,029,580,000,000,000,000,000,000,000 | 365 | RSA blinding on CRT operations to counter timing attacks |
static int elo_probe(struct hid_device *hdev, const struct hid_device_id *id)
{
struct elo_priv *priv;
int ret;
struct usb_device *udev;
if (!hid_is_usb(hdev))
return -EINVAL;
priv = kzalloc(sizeof(*priv), GFP_KERNEL);
if (!priv)
return -ENOMEM;
INIT_DELAYED_WORK(&priv->work, elo_work);
udev = interface_... | 1 | [
"CWE-200",
"CWE-401"
] | linux | 817b8b9c5396d2b2d92311b46719aad5d3339dbe | 47,515,603,588,365,830,000,000,000,000,000,000,000 | 41 | HID: elo: fix memory leak in elo_probe
When hid_parse() in elo_probe() fails, it forgets to call usb_put_dev to
decrease the refcount.
Fix this by adding usb_put_dev() in the error handling code of elo_probe().
Fixes: fbf42729d0e9 ("HID: elo: update the reference count of the usb device structure")
Reported-by: syzk... |
QQueueItem(SQL::Query* Q, const std::string& S, SQLConnection* C) : q(Q), query(S), c(C) {} | 0 | [
"CWE-476"
] | inspircd | 8745660fcdac7c1b80c94cfc0ff60928cd4dd4b7 | 74,578,557,688,248,960,000,000,000,000,000,000,000 | 1 | Initialise and deallocate the MySQL library correctly. |
static void primaryexp (LexState *ls, expdesc *v) {
/* primaryexp -> NAME | '(' expr ')' */
switch (ls->t.token) {
case '(': {
int line = ls->linenumber;
luaX_next(ls);
expr(ls, v);
check_match(ls, ')', '(', line);
luaK_dischargevars(ls->fs, v);
return;
}
case TK_NAME... | 0 | [
"CWE-125"
] | lua | 1f3c6f4534c6411313361697d98d1145a1f030fa | 101,157,195,668,261,070,000,000,000,000,000,000,000 | 20 | Bug: Lua can generate wrong code when _ENV is <const> |
static int cuse_channel_release(struct inode *inode, struct file *file)
{
struct fuse_dev *fud = file->private_data;
struct cuse_conn *cc = fc_to_cc(fud->fc);
int rc;
/* remove from the conntbl, no more access from this point on */
mutex_lock(&cuse_lock);
list_del_init(&cc->list);
mutex_unlock(&cuse_lock);
/*... | 1 | [
"CWE-399"
] | linux | 2c5816b4beccc8ba709144539f6fdd764f8fa49c | 154,068,305,918,509,360,000,000,000,000,000,000,000 | 23 | cuse: fix memory leak
The problem is that fuse_dev_alloc() acquires an extra reference to cc.fc,
and the original ref count is never dropped.
Reported-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: Miklos Szeredi <miklos@szeredi.hu>
Fixes: cc080e9e9be1 ("fuse: introduce per-instance fuse_dev structure")... |
static bool fill_dynamic_entry(ELFOBJ *bin, ut64 entry_offset, Elf_(Dyn) *d) {
ut8 sdyn[sizeof (Elf_(Dyn))] = {0};
int j = 0;
int len = r_buf_read_at (bin->b, entry_offset, sdyn, sizeof (Elf_(Dyn)));
if (len < 1) {
return false;
}
d->d_tag = R_BIN_ELF_READWORD (sdyn, j);
d->d_un.d_ptr = R_BIN_ELF_READWORD (sd... | 0 | [
"CWE-787"
] | radare2 | 3ecdbf8e21186a9c5a4d3cfa3b1e9fd27045340e | 142,749,595,712,062,510,000,000,000,000,000,000,000 | 13 | Fix 4 byte oobread in msp430 disassembler ##crash
* Only crashes with asan builds
* Add missing =SN register
* Reported by cnitlrt via huntrdev
* BountyID: 1c22055b-b015-47a8-a57b-4982978751d0 |
static void d_wait_lookup(struct dentry *dentry)
{
if (d_in_lookup(dentry)) {
DECLARE_WAITQUEUE(wait, current);
add_wait_queue(dentry->d_wait, &wait);
do {
set_current_state(TASK_UNINTERRUPTIBLE);
spin_unlock(&dentry->d_lock);
schedule();
spin_lock(&dentry->d_lock);
} while (d_in_lookup(dentry));
... | 0 | [
"CWE-362",
"CWE-399"
] | linux | 49d31c2f389acfe83417083e1208422b4091cd9e | 57,211,178,282,332,080,000,000,000,000,000,000,000 | 13 | dentry name snapshots
take_dentry_name_snapshot() takes a safe snapshot of dentry name;
if the name is a short one, it gets copied into caller-supplied
structure, otherwise an extra reference to external name is grabbed
(those are never modified). In either case the pointer to stable
string is stored into the same st... |
static long vnc_client_read_plain(VncState *vs)
{
int ret;
VNC_DEBUG("Read plain %p size %zd offset %zd\n",
vs->input.buffer, vs->input.capacity, vs->input.offset);
buffer_reserve(&vs->input, 4096);
ret = vnc_client_read_buf(vs, buffer_end(&vs->input), 4096);
if (!ret)
return 0... | 0 | [
"CWE-125"
] | qemu | bea60dd7679364493a0d7f5b54316c767cf894ef | 221,613,960,545,921,560,000,000,000,000,000,000,000 | 12 | ui/vnc: fix potential memory corruption issues
this patch makes the VNC server work correctly if the
server surface and the guest surface have different sizes.
Basically the server surface is adjusted to not exceed VNC_MAX_WIDTH
x VNC_MAX_HEIGHT and additionally the width is rounded up to multiple of
VNC_DIRTY_PIXELS... |
int32_t FontData::BoundOffset(int32_t offset) {
return offset + bound_offset_;
} | 0 | [
"CWE-703",
"CWE-189"
] | sfntly | de776d4ef06ca29c240de3444348894f032b03ff | 265,764,298,529,319,840,000,000,000,000,000,000,000 | 3 | Check for integer overflow in sfntly::FontData::Bound().
Also delete dead code and cleanup some nits.
This is cl/96914065. |
mono_field_get_object (MonoDomain *domain, MonoClass *klass, MonoClassField *field)
{
MonoReflectionField *res;
static MonoClass *monofield_klass;
CHECK_OBJECT (MonoReflectionField *, field, klass);
if (!monofield_klass)
monofield_klass = mono_class_from_name (mono_defaults.corlib, "System.Reflection", "MonoFiel... | 0 | [
"CWE-20"
] | mono | 65292a69c837b8a5f7a392d34db63de592153358 | 262,571,583,432,090,400,000,000,000,000,000,000,000 | 23 | Handle invalid instantiation of generic methods.
* verify.c: Add new function to internal verifier API to check
method instantiations.
* reflection.c (mono_reflection_bind_generic_method_parameters):
Check the instantiation before returning it.
Fixes #655847 |
static void cbq_watchdog(unsigned long arg)
{
struct Qdisc *sch = (struct Qdisc*)arg;
sch->flags &= ~TCQ_F_THROTTLED;
netif_schedule(sch->dev);
} | 0 | [
"CWE-200"
] | linux-2.6 | 8a47077a0b5aa2649751c46e7a27884e6686ccbf | 155,497,662,974,472,300,000,000,000,000,000,000,000 | 7 | [NETLINK]: Missing padding fields in dumped structures
Plug holes with padding fields and initialized them to zero.
Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net> |
perf_event_set_output(struct perf_event *event, struct perf_event *output_event)
{
struct ring_buffer *rb = NULL, *old_rb = NULL;
int ret = -EINVAL;
if (!output_event)
goto set;
/* don't allow circular references */
if (event == output_event)
goto out;
/*
* Don't allow cross-cpu buffers
*/
if (output_... | 0 | [
"CWE-703",
"CWE-189"
] | linux | 8176cced706b5e5d15887584150764894e94e02f | 104,277,506,485,943,390,000,000,000,000,000,000,000 | 50 | perf: Treat attr.config as u64 in perf_swevent_init()
Trinity discovered that we fail to check all 64 bits of
attr.config passed by user space, resulting to out-of-bounds
access of the perf_swevent_enabled array in
sw_perf_event_destroy().
Introduced in commit b0a873ebb ("perf: Register PMU
implementations").
Signed... |
pkcs11dsa_isprivate(const dst_key_t *key) {
pk11_object_t *dsa = key->keydata.pkey;
CK_ATTRIBUTE *attr;
if (dsa == NULL)
return (false);
attr = pk11_attribute_bytype(dsa, CKA_VALUE2);
return (attr != NULL || dsa->ontoken);
} | 0 | [
"CWE-617"
] | bind9 | 8d807cc21655eaa6e6a08afafeec3682c0f3f2ab | 242,535,550,416,423,370,000,000,000,000,000,000,000 | 9 | Fix crash in pk11_numbits() when native-pkcs11 is used
When pk11_numbits() is passed a user provided input that contains all
zeroes (via crafted DNS message), it would crash with assertion
failure. Fix that by properly handling such input. |
static int tg3_ioctl(struct net_device *dev, struct ifreq *ifr, int cmd)
{
struct mii_ioctl_data *data = if_mii(ifr);
struct tg3 *tp = netdev_priv(dev);
int err;
if (tg3_flag(tp, USE_PHYLIB)) {
struct phy_device *phydev;
if (!(tp->phy_flags & TG3_PHYFLG_IS_CONNECTED))
return -EAGAIN;
phydev = tp->mdio_bus... | 0 | [
"CWE-476",
"CWE-119"
] | linux | 715230a44310a8cf66fbfb5a46f9a62a9b2de424 | 201,646,525,651,014,260,000,000,000,000,000,000,000 | 61 | tg3: fix length overflow in VPD firmware parsing
Commit 184b89044fb6e2a74611dafa69b1dce0d98612c6 ("tg3: Use VPD fw version
when present") introduced VPD parsing that contained a potential length
overflow.
Limit the hardware's reported firmware string length (max 255 bytes) to
stay inside the driver's firmware string ... |
GF_Box *gitn_New()
{
ISOM_DECL_BOX_ALLOC(GroupIdToNameBox, GF_ISOM_BOX_TYPE_GITN);
return (GF_Box *)tmp;
} | 0 | [
"CWE-125"
] | gpac | bceb03fd2be95097a7b409ea59914f332fb6bc86 | 315,418,981,447,605,520,000,000,000,000,000,000,000 | 5 | fixed 2 possible heap overflows (inc. #1088) |
TEST_F(ConnectionHandlerTest, TransportProtocolDefault) {
Network::ListenerCallbacks* listener_callbacks;
auto listener = new NiceMock<Network::MockListener>();
TestListener* test_listener =
addListener(1, true, false, "test_listener", listener, &listener_callbacks);
EXPECT_CALL(*socket_factory_, localAdd... | 0 | [
"CWE-400"
] | envoy | dfddb529e914d794ac552e906b13d71233609bf7 | 157,004,555,303,717,910,000,000,000,000,000,000,000 | 17 | listener: Add configurable accepted connection limits (#153)
Add support for per-listener limits on accepted connections.
Signed-off-by: Tony Allen <tony@allen.gg> |
zzip_mem_disk_load(ZZIP_MEM_DISK* dir, ZZIP_DISK* disk)
{
if (! dir || ! disk) { errno=EINVAL; return -1; }
if (dir->list) zzip_mem_disk_unload(dir);
___ long count = 0;
___ struct zzip_disk_entry* entry = zzip_disk_findfirst(disk);
for (; entry ; entry = zzip_disk_findnext(disk, entry)) {
ZZIP_MEM... | 0 | [
"CWE-119"
] | zziplib | 596d9dfce2624e849417d4301e8d67935608aa5e | 147,757,430,096,148,950,000,000,000,000,000,000,000 | 19 | memdisk
(.) |
MagickExport MagickBooleanType GetImageEntropy(const Image *image,
double *entropy,ExceptionInfo *exception)
{
ChannelStatistics
*channel_statistics;
assert(image != (Image *) NULL);
assert(image->signature == MagickCoreSignature);
if (image->debug != MagickFalse)
(void) LogMagickEvent(TraceEvent,Get... | 0 | [
"CWE-119",
"CWE-787"
] | ImageMagick | 025e77fcb2f45b21689931ba3bf74eac153afa48 | 179,885,456,324,776,730,000,000,000,000,000,000,000 | 18 | https://github.com/ImageMagick/ImageMagick/issues/1615 |
static int match_file(const void *p, struct file *file, unsigned fd)
{
return file_has_perm(p, file, file_to_av(file)) ? fd + 1 : 0;
} | 0 | [
"CWE-264"
] | linux | 7b0d0b40cd78cadb525df760ee4cac151533c2b5 | 63,473,617,946,073,450,000,000,000,000,000,000,000 | 4 | selinux: Permit bounded transitions under NO_NEW_PRIVS or NOSUID.
If the callee SID is bounded by the caller SID, then allowing
the transition to occur poses no risk of privilege escalation and we can
therefore safely allow the transition to occur. Add this exemption
for both the case where a transition was explicitl... |
preload_image(j_compress_ptr cinfo, cjpeg_source_ptr sinfo)
{
tga_source_ptr source = (tga_source_ptr)sinfo;
JDIMENSION row;
cd_progress_ptr progress = (cd_progress_ptr)cinfo->progress;
/* Read the data into a virtual array in input-file row order. */
for (row = 0; row < cinfo->image_height; row++) {
if ... | 0 | [
"CWE-834"
] | libjpeg-turbo | 909a8cfc7bca9b2e6707425bdb74da997e8fa499 | 306,336,154,109,201,200,000,000,000,000,000,000,000 | 26 | Fix CVE-2018-11813
Refer to change log for details.
Fixes #242 |
int unit_add_dependency_by_name_inverse(Unit *u, UnitDependency d, const char *name, const char *path, bool add_reference) {
Unit *other;
int r;
_cleanup_free_ char *s = NULL;
assert(u);
assert(name || path);
if (!(name = resolve_template(u, name, path, &s)))
... | 0 | [] | systemd | 5ba6985b6c8ef85a8bcfeb1b65239c863436e75b | 31,241,670,634,751,950,000,000,000,000,000,000,000 | 18 | core: allow PIDs to be watched by two units at the same time
In some cases it is interesting to map a PID to two units at the same
time. For example, when a user logs in via a getty, which is reexeced to
/sbin/login that binary will be explicitly referenced as main pid of the
getty service, as well as implicitly refer... |
static uint64_t toWire64(uint64_t x) {return htonll(x);} | 0 | [
"CWE-20"
] | thrift | cfaadcc4adcfde2a8232c62ec89870b73ef40df1 | 271,699,206,677,180,480,000,000,000,000,000,000,000 | 1 | THRIFT-3231 CPP: Limit recursion depth to 64
Client: cpp
Patch: Ben Craig <bencraig@apache.org> |
virDomainObjGetState(virDomainObjPtr dom, int *reason)
{
if (reason)
*reason = dom->state.reason;
return dom->state.state;
} | 0 | [
"CWE-212"
] | libvirt | a5b064bf4b17a9884d7d361733737fb614ad8979 | 94,567,746,335,057,750,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... |
explicit printer(ostream& os)
: out(os) {} | 0 | [
"CWE-770"
] | ceph | ab29bed2fc9f961fe895de1086a8208e21ddaddc | 34,812,138,172,673,350,000,000,000,000,000,000,000 | 2 | 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 <... |
extensions::ScriptExecutor* script_executor() {
return script_executor_.get();
} | 0 | [] | electron | e9fa834757f41c0b9fe44a4dffe3d7d437f52d34 | 109,073,670,362,603,720,000,000,000,000,000,000,000 | 3 | fix: ensure ElectronBrowser mojo service is only bound to appropriate render frames (#33344)
* fix: ensure ElectronBrowser mojo service is only bound to authorized render frames
Notes: no-notes
* refactor: extract electron API IPC to its own mojo interface
* fix: just check main frame not primary main frame
... |
static llparse_match_t llparse__match_sequence_to_lower(
llhttp__internal_t* s, const unsigned char* p,
const unsigned char* endp,
const unsigned char* seq, uint32_t seq_len) {
uint32_t index;
llparse_match_t res;
index = s->_index;
for (; p != endp; p++) {
unsigned char current;
current =... | 0 | [
"CWE-444"
] | node | 641f786bb1a1f6eb1ff8750782ed939780f2b31a | 221,493,400,566,688,900,000,000,000,000,000,000,000 | 31 | http: unset `F_CHUNKED` on new `Transfer-Encoding`
Duplicate `Transfer-Encoding` header should be a treated as a single,
but with original header values concatenated with a comma separator. In
the light of this, even if the past `Transfer-Encoding` ended with
`chunked`, we should be not let the `F_CHUNKED` to leak int... |
DEFUN (no_ip_community_list_name_expanded,
no_ip_community_list_name_expanded_cmd,
"no ip community-list expanded WORD (deny|permit) .LINE",
NO_STR
IP_STR
COMMUNITY_LIST_STR
"Specify an expanded community-list\n"
"Community list name\n"
"Specify community to rejec... | 0 | [
"CWE-125"
] | frr | 6d58272b4cf96f0daa846210dd2104877900f921 | 225,316,903,838,927,620,000,000,000,000,000,000,000 | 14 | [bgpd] cleanup, compact and consolidate capability parsing code
2007-07-26 Paul Jakma <paul.jakma@sun.com>
* (general) Clean up and compact capability parsing slightly.
Consolidate validation of length and logging of generic TLV, and
memcpy of capability data, thus removing such from cap specifc
code (not a... |
static int smack_ptrace_access_check(struct task_struct *ctp, unsigned int mode)
{
struct smack_known *skp;
skp = smk_of_task_struct_obj(ctp);
return smk_ptrace_rule_check(current, skp, mode, __func__);
} | 0 | [
"CWE-416"
] | linux | a3727a8bac0a9e77c70820655fd8715523ba3db7 | 248,234,029,095,336,000,000,000,000,000,000,000,000 | 8 | selinux,smack: fix subjective/objective credential use mixups
Jann Horn reported a problem with commit eb1231f73c4d ("selinux:
clarify task subjective and objective credentials") where some LSM
hooks were attempting to access the subjective credentials of a task
other than the current task. Generally speaking, it is ... |
*/
static void _cimg_blur_box_apply(T *ptr, const float boxsize, const int N, const ulongT off,
const int order, const bool boundary_conditions,
const unsigned int nb_iter) {
// Smooth.
if (boxsize>1 && nb_iter) {
cons... | 0 | [
"CWE-119",
"CWE-787"
] | CImg | ac8003393569aba51048c9d67e1491559877b1d1 | 70,679,817,756,522,345,000,000,000,000,000,000,000 | 67 | . |
CheckPredicate(Expr *predicate)
{
/*
* transformExpr() should have already rejected subqueries, aggregates,
* and window functions, based on the EXPR_KIND_ for a predicate.
*/
/*
* A predicate using mutable functions is probably wrong, for the same
* reasons that we don't allow an index expression to use o... | 0 | [
"CWE-362"
] | postgres | 5f173040e324f6c2eebb90d86cf1b0cdb5890f0a | 294,856,541,015,474,500,000,000,000,000,000,000,000 | 16 | Avoid repeated name lookups during table and index DDL.
If the name lookups come to different conclusions due to concurrent
activity, we might perform some parts of the DDL on a different table
than other parts. At least in the case of CREATE INDEX, this can be
used to cause the permissions checks to be performed aga... |
crypto_cert_get_count(pkinit_identity_crypto_context id_cryptoctx,
int *cert_count)
{
int count;
*cert_count = 0;
if (id_cryptoctx == NULL || id_cryptoctx->creds[0] == NULL)
return EINVAL;
for (count = 0;
count <= MAX_CREDS_ALLOWED && id_cryptoctx->creds[count] !... | 0 | [
"CWE-119",
"CWE-787"
] | krb5 | fbb687db1088ddd894d975996e5f6a4252b9a2b4 | 291,265,076,214,624,450,000,000,000,000,000,000,000 | 15 | Fix PKINIT cert matching data construction
Rewrite X509_NAME_oneline_ex() and its call sites to use dynamic
allocation and to perform proper error checking.
ticket: 8617
target_version: 1.16
target_version: 1.15-next
target_version: 1.14-next
tags: pullup |
SPICE_GNUC_VISIBLE int spice_server_migrate_start(SpiceServer *reds)
{
spice_debug("trace");
if (!reds->config->mig_spice) {
return -1;
}
return 0;
} | 0 | [] | spice | ca5bbc5692e052159bce1a75f55dc60b36078749 | 20,306,059,763,767,928,000,000,000,000,000,000,000 | 8 | With OpenSSL 1.1: Disable client-initiated renegotiation.
Fixes issue #49
Fixes BZ#1904459
Signed-off-by: Julien Ropé <jrope@redhat.com>
Reported-by: BlackKD
Acked-by: Frediano Ziglio <fziglio@redhat.com> |
CAMLprim value caml_fill_string(value s, value offset, value len, value init)
{
memset(&Byte(s, Long_val(offset)), Int_val(init), Long_val(len));
return Val_unit;
} | 0 | [
"CWE-200"
] | ocaml | 659615c7b100a89eafe6253e7a5b9d84d0e8df74 | 71,299,743,578,244,670,000,000,000,000,000,000,000 | 5 | fix PR#7003 and a few other bugs caused by misuse of Int_val
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@16525 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02 |
auth_server_connection_add_request(struct auth_server_connection *conn,
struct auth_client_request *request)
{
unsigned int id;
i_assert(conn->handshake_received);
id = ++conn->client->request_id_counter;
if (id == 0) {
/* wrapped - ID 0 not allowed */
id = ++conn->client->request_id_counter;
}
i_ass... | 0 | [] | core | a9b135760aea6d1790d447d351c56b78889dac22 | 148,152,109,430,448,310,000,000,000,000,000,000,000 | 16 | lib-auth: Remove request after abort
Otherwise the request will still stay in hash table
and get dereferenced when all requests are aborted
causing an attempt to access free'd memory.
Found by Apollon Oikonomopoulos <apoikos@debian.org>
Broken in 1a29ed2f96da1be22fa5a4d96c7583aa81b8b060 |
ext4_fsblk_t ext4_inode_bitmap(struct super_block *sb,
struct ext4_group_desc *bg)
{
return le32_to_cpu(bg->bg_inode_bitmap_lo) |
(EXT4_DESC_SIZE(sb) >= EXT4_MIN_DESC_SIZE_64BIT ?
(ext4_fsblk_t)le32_to_cpu(bg->bg_inode_bitmap_hi) << 32 : 0);
} | 0 | [
"CWE-703"
] | linux | 744692dc059845b2a3022119871846e74d4f6e11 | 257,554,268,072,047,800,000,000,000,000,000,000,000 | 7 | 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... |
static void prepare_vmcs12(struct kvm_vcpu *vcpu, struct vmcs12 *vmcs12,
u32 exit_reason, u32 exit_intr_info,
unsigned long exit_qualification)
{
/* update guest state fields: */
vmcs12->guest_cr0 = vmcs12_guest_cr0(vcpu, vmcs12);
vmcs12->guest_cr4 = vmcs12_guest_cr4(vcpu, vmcs12);
vmcs12->guest_rsp = ... | 0 | [
"CWE-399"
] | linux | 54a20552e1eae07aa240fa370a0293e006b5faed | 280,190,975,402,851,140,000,000,000,000,000,000,000 | 143 | KVM: x86: work around infinite loop in microcode when #AC is delivered
It was found that a guest can DoS a host by triggering an infinite
stream of "alignment check" (#AC) exceptions. This causes the
microcode to enter an infinite loop where the core never receives
another interrupt. The host kernel panics pretty qu... |
ProcGlobalSemas(void)
{
/*
* We need a sema per backend (including autovacuum), plus one for each
* auxiliary process.
*/
return MaxBackends + NUM_AUXILIARY_PROCS;
} | 0 | [
"CWE-89"
] | postgres | 2b3a8b20c2da9f39ffecae25ab7c66974fbc0d3b | 242,526,343,581,117,200,000,000,000,000,000,000,000 | 8 | Be more careful to not lose sync in the FE/BE protocol.
If any error occurred while we were in the middle of reading a protocol
message from the client, we could lose sync, and incorrectly try to
interpret a part of another message as a new protocol message. That will
usually lead to an "invalid frontend message" erro... |
static long kvm_dev_ioctl(struct file *filp,
unsigned int ioctl, unsigned long arg)
{
long r = -EINVAL;
switch (ioctl) {
case KVM_GET_API_VERSION:
if (arg)
goto out;
r = KVM_API_VERSION;
break;
case KVM_CREATE_VM:
r = kvm_dev_ioctl_create_vm(arg);
break;
case KVM_CHECK_EXTENSION:
r = kvm_vm_io... | 0 | [
"CWE-416",
"CWE-284"
] | linux | a0f1d21c1ccb1da66629627a74059dd7f5ac9c61 | 296,430,333,705,776,700,000,000,000,000,000,000,000 | 39 | KVM: use after free in kvm_ioctl_create_device()
We should move the ops->destroy(dev) after the list_del(&dev->vm_node)
so that we don't use "dev" after freeing it.
Fixes: a28ebea2adc4 ("KVM: Protect device ops->create and list_add with kvm->lock")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Reviewed-by: ... |
void addReplyHumanLongDouble(client *c, long double d) {
robj *o = createStringObjectFromLongDouble(d,1);
addReplyBulk(c,o);
decrRefCount(o);
} | 0 | [
"CWE-254"
] | redis | 874804da0c014a7d704b3d285aa500098a931f50 | 293,775,133,833,592,800,000,000,000,000,000,000,000 | 5 | Security: Cross Protocol Scripting protection.
This is an attempt at mitigating problems due to cross protocol
scripting, an attack targeting services using line oriented protocols
like Redis that can accept HTTP requests as valid protocol, by
discarding the invalid parts and accepting the payloads sent, for
example, ... |
flatpak_dir_get_system_default (void)
{
g_autoptr(GFile) path = flatpak_get_system_default_base_dir_location ();
return flatpak_dir_new_full (path, FALSE, NULL);
} | 0 | [
"CWE-668"
] | flatpak | cd2142888fc4c199723a0dfca1f15ea8788a5483 | 220,310,967,116,927,430,000,000,000,000,000,000,000 | 5 | Don't expose /proc when running apply_extra
As shown by CVE-2019-5736, it is sometimes possible for the sandbox
app to access outside files using /proc/self/exe. This is not
typically an issue for flatpak as the sandbox runs as the user which
has no permissions to e.g. modify the host files.
However, when installing ... |
static const char *columnTypeImpl(
NameContext *pNC,
#ifndef SQLITE_ENABLE_COLUMN_METADATA
Expr *pExpr
#else
Expr *pExpr,
const char **pzOrigDb,
const char **pzOrigTab,
const char **pzOrigCol
#endif
){
char const *zType = 0;
int j;
#ifdef SQLITE_ENABLE_COLUMN_METADATA
char const *zOrigDb = 0;
char ... | 0 | [
"CWE-20"
] | sqlite | e59c562b3f6894f84c715772c4b116d7b5c01348 | 110,967,134,761,565,830,000,000,000,000,000,000,000 | 138 | Fix a crash that could occur if a sub-select that uses both DISTINCT and window functions also used an ORDER BY that is the same as its select list.
FossilOrigin-Name: bcdd66c1691955c697f3d756c2b035acfe98f6aad72e90b0021bab6e9023b3ba |
static irqreturn_t xudc_irq(int irq, void *_udc)
{
struct xusb_udc *udc = _udc;
u32 intrstatus;
u32 ier;
u8 index;
u32 bufintr;
unsigned long flags;
spin_lock_irqsave(&udc->lock, flags);
/*
* Event interrupts are level sensitive hence first disable
* IER, read ISR and figure out active interrupts.
*/
i... | 0 | [
"CWE-20",
"CWE-129"
] | linux | 7f14c7227f342d9932f9b918893c8814f86d2a0d | 188,303,936,376,683,160,000,000,000,000,000,000,000 | 60 | 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> |
static int de_thread(struct task_struct *tsk)
{
struct signal_struct *sig = tsk->signal;
struct sighand_struct *oldsighand = tsk->sighand;
spinlock_t *lock = &oldsighand->siglock;
if (thread_group_empty(tsk))
goto no_thread_group;
/*
* Kill all other threads in the thread group.
*/
spin_lock_irq(lock);
i... | 0 | [
"CWE-264"
] | linux | 259e5e6c75a910f3b5e656151dc602f53f9d7548 | 114,399,256,879,819,810,000,000,000,000,000,000,000 | 145 | Add PR_{GET,SET}_NO_NEW_PRIVS to prevent execve from granting privs
With this change, calling
prctl(PR_SET_NO_NEW_PRIVS, 1, 0, 0, 0)
disables privilege granting operations at execve-time. For example, a
process will not be able to execute a setuid binary to change their uid
or gid if this bit is set. The same is t... |
input_osc_104(struct input_ctx *ictx, const char *p)
{
struct window_pane *wp = ictx->wp;
char *copy, *s;
long idx;
if (wp == NULL)
return;
if (*p == '\0') {
window_pane_reset_palette(wp);
return;
}
copy = s = xstrdup(p);
while (*s != '\0') {
idx = strtol(s, &s, 10);
if (*s != '\0' && *s != ';... | 0 | [
"CWE-787"
] | tmux | a868bacb46e3c900530bed47a1c6f85b0fbe701c | 57,203,727,889,777,520,000,000,000,000,000,000,000 | 33 | Do not write after the end of the array and overwrite the stack when
colon-separated SGR sequences contain empty arguments. Reported by Sergey
Nizovtsev. |
static int timezone_initialize(php_timezone_obj *tzobj, /*const*/ char *tz TSRMLS_DC)
{
timelib_time *dummy_t = ecalloc(1, sizeof(timelib_time));
int dst, not_found;
char *orig_tz = tz;
dummy_t->z = timelib_parse_zone(&tz, &dst, dummy_t, ¬_found, DATE_TIMEZONEDB, php_date_parse_tzfile_wrapper... | 0 | [] | php-src | c377f1a715476934133f3254d1e0d4bf3743e2d2 | 283,262,877,432,479,700,000,000,000,000,000,000,000 | 18 | Fix bug #68942 (Use after free vulnerability in unserialize() with DateTimeZone) |
bool has_type_information () const
{
return false;
} | 0 | [
"CWE-284"
] | Fast-DDS | d2aeab37eb4fad4376b68ea4dfbbf285a2926384 | 93,999,101,374,204,520,000,000,000,000,000,000,000 | 4 | check remote permissions (#1387)
* Refs 5346. Blackbox test
Signed-off-by: Iker Luengo <ikerluengo@eprosima.com>
* Refs 5346. one-way string compare
Signed-off-by: Iker Luengo <ikerluengo@eprosima.com>
* Refs 5346. Do not add partition separator on last partition
Signed-off-by: Iker Luengo <ikerluengo@e... |
static void free_variant_list(HLSContext *c)
{
int i;
for (i = 0; i < c->n_variants; i++) {
struct variant *var = c->variants[i];
av_freep(&var->playlists);
av_free(var);
}
av_freep(&c->variants);
c->n_variants = 0;
} | 0 | [
"CWE-703"
] | FFmpeg | 7ba100d3e6e8b1e5d5342feb960a7f081d6e15af | 334,609,251,894,488,900,000,000,000,000,000,000,000 | 11 | avformat/hls: Fix DoS due to infinite loop
Fixes: loop.m3u
The default max iteration count of 1000 is arbitrary and ideas for a better solution are welcome
Found-by: Xiaohei and Wangchu from Alibaba Security Team
Previous version reviewed-by: Steven Liu <lingjiujianke@gmail.com>
Signed-off-by: Michael Niedermayer <... |
ModuleExport size_t RegisterSVGImage(void)
{
char
version[MagickPathExtent];
MagickInfo
*entry;
*version='\0';
#if defined(LIBXML_DOTTED_VERSION)
(void) CopyMagickString(version,"XML " LIBXML_DOTTED_VERSION,
MagickPathExtent);
#endif
#if defined(MAGICKCORE_RSVG_DELEGATE)
#if !GLIB_CHECK_VERSION(2,... | 0 | [
"CWE-20",
"CWE-674",
"CWE-787"
] | ImageMagick | ec9c8944af2bfc65c697ca44f93a727a99b405f1 | 98,214,514,292,574,200,000,000,000,000,000,000,000 | 60 | [FG-VD-19-136] ImageMagick Convert SVG MacOS Denial Of Service |
void replace_all(std::string & subject, const std::string & search, const std::string & replace) {
size_t pos = 0;
while ((pos = subject.find(search, pos)) != std::string::npos) {
subject.replace(pos, search.length(), replace);
pos += replace.length();
}
} | 1 | [
"CWE-284"
] | Fast-DDS | d2aeab37eb4fad4376b68ea4dfbbf285a2926384 | 274,974,469,713,376,750,000,000,000,000,000,000,000 | 7 | check remote permissions (#1387)
* Refs 5346. Blackbox test
Signed-off-by: Iker Luengo <ikerluengo@eprosima.com>
* Refs 5346. one-way string compare
Signed-off-by: Iker Luengo <ikerluengo@eprosima.com>
* Refs 5346. Do not add partition separator on last partition
Signed-off-by: Iker Luengo <ikerluengo@e... |
static int check_trust(X509_STORE_CTX *ctx, int num_untrusted)
{
int i;
X509 *x = NULL;
X509 *mx;
SSL_DANE *dane = ctx->dane;
int num = sk_X509_num(ctx->chain);
int trust;
/*
* Check for a DANE issuer at depth 1 or greater, if it is a DANE-TA(2)
* match, we're done, otherwise we'l... | 0 | [
"CWE-295"
] | openssl | 2a40b7bc7b94dd7de897a74571e7024f0cf0d63b | 192,816,346,217,656,520,000,000,000,000,000,000,000 | 96 | check_chain_extensions: Do not override error return value by check_curve
The X509_V_FLAG_X509_STRICT flag enables additional security checks of the
certificates present in a certificate chain. It is not set by default.
Starting from OpenSSL version 1.1.1h a check to disallow certificates with
explicitly encoded elli... |
int LibRaw::copy_mem_image(void* scan0, int stride, int bgr)
{
// the image memory pointed to by scan0 is assumed to be in the format returned by get_mem_image_format
if((imgdata.progress_flags & LIBRAW_PROGRESS_THUMB_MASK) < LIBRAW_PROGRESS_PRE_INTERPOLATE)
return LIBRAW_OUT_OF_ORDER_CALL;
if(lib... | 0 | [
"CWE-119",
"CWE-787"
] | LibRaw | 2f912f5b33582961b1cdbd9fd828589f8b78f21d | 152,808,223,174,303,570,000,000,000,000,000,000,000 | 76 | fixed wrong data_maximum calcluation; prevent out-of-buffer in exp_bef |
PHP_FUNCTION(stream_get_contents)
{
php_stream *stream;
zval *zsrc;
long maxlen = PHP_STREAM_COPY_ALL,
desiredpos = -1L;
long len;
char *contents = NULL;
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "r|ll", &zsrc, &maxlen, &desiredpos) == FAILURE) {
RETURN_FALSE;
}
php_stream_from_zval(stre... | 0 | [
"CWE-20"
] | php-src | 52b93f0cfd3cba7ff98cc5198df6ca4f23865f80 | 5,625,363,537,531,280,000,000,000,000,000,000,000 | 47 | Fixed bug #69353 (Missing null byte checks for paths in various PHP extensions) |
ZEND_VM_COLD_CONST_HANDLER(46, ZEND_JMPZ_EX, CONST|TMPVAR|CV, JMP_ADDR)
{
USE_OPLINE
zend_free_op free_op1;
zval *val;
int ret;
val = GET_OP1_ZVAL_PTR_UNDEF(BP_VAR_R);
if (Z_TYPE_INFO_P(val) == IS_TRUE) {
ZVAL_TRUE(EX_VAR(opline->result.var));
ZEND_VM_NEXT_OPCODE();
} else if (EXPECTED(Z_TYPE_INFO_P(val) <... | 0 | [
"CWE-787"
] | php-src | f1ce8d5f5839cb2069ea37ff424fb96b8cd6932d | 14,497,612,277,121,296,000,000,000,000,000,000,000 | 36 | Fix #73122: Integer Overflow when concatenating strings
We must avoid integer overflows in memory allocations, so we introduce
an additional check in the VM, and bail out in the rare case of an
overflow. Since the recent fix for bug #74960 still doesn't catch all
possible overflows, we fix that right away. |
bool is_comp_vector(const unsigned int arg) const {
unsigned int siz = _cimg_mp_size(arg);
if (siz>128) return false;
const int *ptr = memtype.data(arg + 1);
bool is_tmp = true;
while (siz-->0) if (*(ptr++)) { is_tmp = false; break; }
return is_tmp;
} | 0 | [
"CWE-770"
] | cimg | 619cb58dd90b4e03ac68286c70ed98acbefd1c90 | 319,986,062,029,805,580,000,000,000,000,000,000,000 | 8 | CImg<>::load_bmp() and CImg<>::load_pandore(): Check that dimensions encoded in file does not exceed file size. |
static long fuse_dir_ioctl(struct file *file, unsigned int cmd,
unsigned long arg)
{
struct fuse_conn *fc = get_fuse_conn(file->f_mapping->host);
/* FUSE_IOCTL_DIR only supported for API version >= 7.18 */
if (fc->minor < 18)
return -ENOTTY;
return fuse_ioctl_common(file, cmd, arg, FUSE_IOCTL_DIR);
} | 0 | [
"CWE-459"
] | linux | 5d069dbe8aaf2a197142558b6fb2978189ba3454 | 121,253,100,841,537,320,000,000,000,000,000,000,000 | 11 | fuse: fix bad inode
Jan Kara's analysis of the syzbot report (edited):
The reproducer opens a directory on FUSE filesystem, it then attaches
dnotify mark to the open directory. After that a fuse_do_getattr() call
finds that attributes returned by the server are inconsistent, and calls
make_bad_inode() which,... |
static unsigned int find_best_mtu(const struct t3c_data *d, unsigned short mtu)
{
int i = 0;
while (i < d->nmtus - 1 && d->mtus[i + 1] <= mtu)
++i;
return i;
} | 0 | [
"CWE-703"
] | linux | 67f1aee6f45059fd6b0f5b0ecb2c97ad0451f6b3 | 163,222,296,668,433,120,000,000,000,000,000,000,000 | 8 | iw_cxgb3: Fix incorrectly returning error on success
The cxgb3_*_send() functions return NET_XMIT_ values, which are
positive integers values. So don't treat positive return values
as an error.
Signed-off-by: Steve Wise <swise@opengridcomputing.com>
Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com>
Signed-off... |
static RTSPTransportField *find_transport(RTSPMessageHeader *h, enum RTSPLowerTransport lower_transport)
{
RTSPTransportField *th;
int i;
for(i=0;i<h->nb_transports;i++) {
th = &h->transports[i];
if (th->lower_transport == lower_transport)
return th;
}
return NULL;
} | 0 | [
"CWE-119",
"CWE-787"
] | FFmpeg | a5d25faa3f4b18dac737fdb35d0dd68eb0dc2156 | 324,549,268,478,093,500,000,000,000,000,000,000,000 | 12 | ffserver: Check chunk size
Fixes out of array access
Fixes: poc_ffserver.py
Found-by: Paul Cher <paulcher@icloud.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc> |
int kvm_arm_sys_reg_get_reg(struct kvm_vcpu *vcpu, const struct kvm_one_reg *reg)
{
const struct sys_reg_desc *r;
void __user *uaddr = (void __user *)(unsigned long)reg->addr;
if ((reg->id & KVM_REG_ARM_COPROC_MASK) == KVM_REG_ARM_DEMUX)
return demux_c15_get(reg->id, uaddr);
if (KVM_REG_SIZE(reg->id) != sizeof(... | 0 | [
"CWE-20",
"CWE-617"
] | linux | 9e3f7a29694049edd728e2400ab57ad7553e5aa9 | 277,046,693,583,979,880,000,000,000,000,000,000,000 | 20 | arm64: KVM: pmu: Fix AArch32 cycle counter access
We're missing the handling code for the cycle counter accessed
from a 32bit guest, leading to unexpected results.
Cc: stable@vger.kernel.org # 4.6+
Signed-off-by: Wei Huang <wei@redhat.com>
Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> |
static int scsi_disk_initfn(SCSIDevice *dev)
{
DriveInfo *dinfo;
uint8_t scsi_type;
if (!dev->conf.bs) {
scsi_type = TYPE_DISK; /* will die in scsi_initfn() */
} else {
dinfo = drive_get_by_blockdev(dev->conf.bs);
scsi_type = dinfo->media_cd ? TYPE_ROM : TYPE_DISK;
}
r... | 0 | [
"CWE-119",
"CWE-787"
] | qemu | 103b40f51e4012b3b0ad20f615562a1806d7f49a | 234,099,693,805,431,860,000,000,000,000,000,000,000 | 14 | scsi-disk: commonize iovec creation between reads and writes
Also, consistently use qiov.size instead of iov.iov_len.
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com> |
static MagickBooleanType HorizontalFilter(const ResizeFilter *resize_filter,
const Image *image,Image *resize_image,const double x_factor,
const MagickSizeType span,MagickOffsetType *offset,ExceptionInfo *exception)
{
#define ResizeImageTag "Resize/Image"
CacheView
*image_view,
*resize_view;
ClassTyp... | 0 | [
"CWE-125"
] | ImageMagick | c5402b6e0fcf8b694ae2af6a6652ebb8ce0ccf46 | 179,598,649,965,247,030,000,000,000,000,000,000,000 | 216 | https://github.com/ImageMagick/ImageMagick/issues/717 |
int virtio_queue_ready(VirtQueue *vq)
{
return vq->vring.avail != 0;
} | 0 | [
"CWE-94"
] | qemu | cc45995294b92d95319b4782750a3580cabdbc0c | 96,218,979,630,495,820,000,000,000,000,000,000,000 | 4 | virtio: out-of-bounds buffer write on invalid state load
CVE-2013-4151 QEMU 1.0 out-of-bounds buffer write in
virtio_load@hw/virtio/virtio.c
So we have this code since way back when:
num = qemu_get_be32(f);
for (i = 0; i < num; i++) {
vdev->vq[i].vring.num = qemu_get_be32(f);
array of vqs has size ... |
NCR_GetRemoteAddress(NCR_Instance inst)
{
return &inst->remote_addr;
} | 0 | [] | chrony | a78bf9725a7b481ebff0e0c321294ba767f2c1d8 | 339,928,670,303,856,780,000,000,000,000,000,000,000 | 4 | ntp: restrict authentication of server/peer to specified key
When a server/peer was specified with a key number to enable
authentication with a symmetric key, packets received from the
server/peer were accepted if they were authenticated with any of
the keys contained in the key file and not just the specified key.
T... |
int main(int argc, char** argv)
{
/* Kernel starts us with all fd's closed.
* But it's dangerous:
* fprintf(stderr) can dump messages into random fds, etc.
* Ensure that if any of fd 0,1,2 is closed, we open it to /dev/null.
*/
int fd = xopen("/dev/null", O_RDWR);
while (fd < 2)
fd = xd... | 1 | [
"CWE-200"
] | abrt | af945ff58a698ce00c45059a05994ef53a13e192 | 72,132,926,788,203,175,000,000,000,000,000,000,000 | 429 | ccpp: do not override existing files by compat cores
Implement all checks used in kernel's do_coredump() and require
non-relative path if suid_dumpable is 2.
Related: #1212818
Signed-off-by: Jakub Filak <jfilak@redhat.com> |
TfLiteStatus LogicalAndEval(TfLiteContext* context, TfLiteNode* node) {
return LogicalImpl(context, node, LogicalAnd);
} | 0 | [
"CWE-125",
"CWE-787"
] | tensorflow | 1970c2158b1ffa416d159d03c3370b9a462aee35 | 125,493,966,230,740,230,000,000,000,000,000,000,000 | 3 | [tflite]: Insert `nullptr` checks when obtaining tensors.
As part of ongoing refactoring, `tflite::GetInput`, `tflite::GetOutput`, `tflite::GetTemporary` and `tflite::GetIntermediates` will return `nullptr` in some cases. Hence, we insert the `nullptr` checks on all usages.
We also insert `nullptr` checks on usages o... |
TEST_F(RouterTest, NoRetryWithBodyLimit) {
NiceMock<Http::MockRequestEncoder> encoder1;
Http::ResponseDecoder* response_decoder = nullptr;
EXPECT_CALL(cm_.thread_local_cluster_.conn_pool_, newStream(_, _))
.WillOnce(Invoke(
[&](Http::ResponseDecoder& decoder,
Http::ConnectionPool::Ca... | 0 | [
"CWE-703"
] | envoy | 18871dbfb168d3512a10c78dd267ff7c03f564c6 | 70,807,064,220,949,615,000,000,000,000,000,000,000 | 30 | [1.18] CVE-2022-21655
Crash with direct_response
Signed-off-by: Otto van der Schaaf <ovanders@redhat.com> |
LibRaw_buffer_datastream::LibRaw_buffer_datastream(void *buffer, size_t bsize)
{
buf = (unsigned char*)buffer; streampos = 0; streamsize = bsize;
} | 0 | [
"CWE-703"
] | LibRaw | 11909cc59e712e09b508dda729b99aeaac2b29ad | 17,531,642,823,392,957,000,000,000,000,000,000,000 | 4 | cumulated data checks patch |
void setIsCodeWithScope(bool isCodeWithScope) {
if (isCodeWithScope) {
_startPosition |= 1 << 31;
}
else {
_startPosition &= ~(1 << 31);
}
} | 0 | [
"CWE-20"
] | mongo | 3a7e85ea1f672f702660e5472566234b1d19038e | 135,717,227,435,334,400,000,000,000,000,000,000,000 | 8 | SERVER-17264: improve bson validation for utf-8 strings
(cherry picked from commit 394a8569ff14a215c0691aa34440227b2e62a4de)
Conflicts:
src/mongo/bson/bson_validate_test.cpp |
static int path_init(int dfd, const struct filename *name, unsigned int flags,
struct nameidata *nd)
{
int retval = 0;
const char *s = name->name;
nd->last_type = LAST_ROOT; /* if there are only slashes... */
nd->flags = flags | LOOKUP_JUMPED | LOOKUP_PARENT;
nd->depth = 0;
nd->base = NULL;
if (flags & L... | 0 | [
"CWE-416"
] | linux | f15133df088ecadd141ea1907f2c96df67c729f0 | 257,045,125,992,217,740,000,000,000,000,000,000,000 | 101 | path_openat(): fix double fput()
path_openat() jumps to the wrong place after do_tmpfile() - it has
already done path_cleanup() (as part of path_lookupat() called by
do_tmpfile()), so doing that again can lead to double fput().
Cc: stable@vger.kernel.org # v3.11+
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> |
do_add_counters(struct net *net, const void __user *user, unsigned int len,
int compat)
{
unsigned int i;
struct xt_counters_info tmp;
struct xt_counters *paddc;
struct xt_table *t;
const struct xt_table_info *private;
int ret = 0;
struct ip6t_entry *iter;
unsigned int addend;
paddc = xt_copy_counters_from_... | 0 | [
"CWE-476"
] | linux | 57ebd808a97d7c5b1e1afb937c2db22beba3c1f8 | 211,555,614,847,694,970,000,000,000,000,000,000,000 | 47 | netfilter: add back stackpointer size checks
The rationale for removing the check is only correct for rulesets
generated by ip(6)tables.
In iptables, a jump can only occur to a user-defined chain, i.e.
because we size the stack based on number of user-defined chains we
cannot exceed stack size.
However, the underlyi... |
TEST(HeaderMapImplTest, Equality) {
TestHeaderMapImpl headers1;
TestHeaderMapImpl headers2;
EXPECT_EQ(headers1, headers2);
headers1.addCopy("hello", "world");
EXPECT_FALSE(headers1 == headers2);
headers2.addCopy("foo", "bar");
EXPECT_FALSE(headers1 == headers2);
} | 0 | [
"CWE-400",
"CWE-703"
] | envoy | afc39bea36fd436e54262f150c009e8d72db5014 | 57,258,938,247,125,220,000,000,000,000,000,000,000 | 11 | Track byteSize of HeaderMap internally.
Introduces a cached byte size updated internally in HeaderMap. The value
is stored as an optional, and is cleared whenever a non-const pointer or
reference to a HeaderEntry is accessed. The cached value can be set with
refreshByteSize() which performs an iteration over the Heade... |
struct file *open_exec(const char *name)
{
struct filename *filename = getname_kernel(name);
struct file *f = ERR_CAST(filename);
if (!IS_ERR(filename)) {
f = do_open_execat(AT_FDCWD, filename, 0);
putname(filename);
}
return f;
} | 0 | [
"CWE-362"
] | linux | 8b01fc86b9f425899f8a3a8fc1c47d73c2c20543 | 170,447,977,591,365,680,000,000,000,000,000,000,000 | 11 | fs: take i_mutex during prepare_binprm for set[ug]id executables
This prevents a race between chown() and execve(), where chowning a
setuid-user binary to root would momentarily make the binary setuid
root.
This patch was mostly written by Linus Torvalds.
Signed-off-by: Jann Horn <jann@thejh.net>
Signed-off-by: Linu... |
test_policies_getinfo_helper_policies(void *arg)
{
(void)arg;
int rv = 0;
size_t ipv4_len = 0, ipv6_len = 0;
char *answer = NULL;
const char *errmsg = NULL;
routerinfo_t mock_my_routerinfo;
memset(&mock_my_routerinfo, 0, sizeof(mock_my_routerinfo));
rv = getinfo_helper_policies(NULL, "exit-policy/defa... | 0 | [] | tor | 1afc2ed956a35b40dfd1d207652af5b50c295da7 | 10,980,865,872,106,732,000,000,000,000,000,000,000 | 144 | Fix policies.c instance of the "if (r=(a-b)) return r" pattern
I think this one probably can't underflow, since the input ranges
are small. But let's not tempt fate.
This patch also replaces the "cmp" functions here with just "eq"
functions, since nothing actually checked for anything besides 0 and
nonzero.
Related... |
int nfs_revalidate_mapping_nolock(struct inode *inode, struct address_space *mapping)
{
struct nfs_inode *nfsi = NFS_I(inode);
int ret = 0;
if ((nfsi->cache_validity & NFS_INO_REVAL_PAGECACHE)
|| nfs_attribute_timeout(inode) || NFS_STALE(inode)) {
ret = __nfs_revalidate_inode(NFS_SERVER(inode), inode);
if (r... | 0 | [
"CWE-703"
] | linux | dc0b027dfadfcb8a5504f7d8052754bf8d501ab9 | 88,644,495,348,454,980,000,000,000,000,000,000,000 | 16 | NFSv4: Convert the open and close ops to use fmode
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com> |
bracket(
const char *p, /* pattern (next to '[') */
const char *pend,
const char *s, /* string */
const char *send,
int flags,
rb_encoding *enc)
{
const int nocase = flags & FNM_CASEFOLD;
const int escape = !(flags & FNM_NOESCAPE);
unsigned int c1, c2;
int r;
int ok = 0, not ... | 0 | [
"CWE-22"
] | ruby | bd5661a3cbb38a8c3a3ea10cd76c88bbef7871b8 | 227,243,615,470,637,000,000,000,000,000,000,000,000 | 67 | dir.c: check NUL bytes
* dir.c (GlobPathValue): should be used in rb_push_glob only.
other methods should use FilePathValue.
https://hackerone.com/reports/302338
* dir.c (rb_push_glob): expand GlobPathValue
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62989 b2dd03c8-39d4-4d8f-98ff-823fe69b080e |
getlinecol(
long *cp, // pointer to columns
long *rp) // pointer to rows
{
char_u tbuf[TBUFSZ];
if (T_NAME != NULL && *T_NAME != NUL && invoke_tgetent(tbuf, T_NAME) == NULL)
{
if (*cp == 0)
*cp = tgetnum("co");
if (*rp == 0)
*rp = tgetnum("li");
}
} | 0 | [
"CWE-125",
"CWE-787"
] | vim | e178af5a586ea023622d460779fdcabbbfac0908 | 333,438,497,275,443,500,000,000,000,000,000,000,000 | 14 | patch 8.2.5160: accessing invalid memory after changing terminal size
Problem: Accessing invalid memory after changing terminal size.
Solution: Adjust cmdline_row and msg_row to the value of Rows. |
STATIC void GC_do_blocking_inner(ptr_t data, void * context GC_ATTR_UNUSED)
{
struct blocking_data * d = (struct blocking_data *) data;
GC_ASSERT(GC_is_initialized);
GC_ASSERT(GC_blocked_sp == NULL);
# ifdef SPARC
GC_blocked_sp = GC_save_regs_in_stack();
# else
GC_blocked_sp = (ptr_t) &d... | 0 | [
"CWE-119"
] | bdwgc | 7292c02fac2066d39dd1bcc37d1a7054fd1e32ee | 170,702,851,963,079,600,000,000,000,000,000,000,000 | 23 | Fix malloc routines to prevent size value wrap-around
See issue #135 on Github.
* allchblk.c (GC_allochblk, GC_allochblk_nth): Use
OBJ_SZ_TO_BLOCKS_CHECKED instead of OBJ_SZ_TO_BLOCKS.
* malloc.c (GC_alloc_large): Likewise.
* alloc.c (GC_expand_hp_inner): Type of "bytes" local variable changed
from word to size_t; ca... |
gc_test(mrb_state *mrb, mrb_value self)
{
test_mrb_field_write_barrier();
test_mrb_write_barrier();
test_add_gray_list();
test_gc_gray_mark();
test_incremental_gc();
test_incremental_sweep_phase();
return mrb_nil_value();
} | 0 | [
"CWE-416"
] | mruby | 5c114c91d4ff31859fcd84cf8bf349b737b90d99 | 78,788,240,209,628,740,000,000,000,000,000,000,000 | 10 | Clear unused stack region that may refer freed objects; fix #3596 |
static void *genunicodedata(void *_gt,int32 *len) {
GTextField *gt = _gt;
unichar_t *temp;
*len = gt->sel_end-gt->sel_start + 1;
temp = malloc((*len+2)*sizeof(unichar_t));
temp[0] = 0xfeff; /* KDE expects a byte order flag */
u_strncpy(temp+1,gt->text+gt->sel_start,gt->sel_end-gt->sel_start);
... | 0 | [
"CWE-119",
"CWE-787"
] | fontforge | 626f751752875a0ddd74b9e217b6f4828713573c | 236,815,847,732,770,640,000,000,000,000,000,000,000 | 10 | Warn users before discarding their unsaved scripts (#3852)
* Warn users before discarding their unsaved scripts
This closes #3846. |
GetCode(gdIOCtx *fd, CODE_STATIC_DATA *scd, int code_size, int flag, int *ZeroDataBlockP)
{
int rv;
rv = GetCode_(fd, scd, code_size,flag, ZeroDataBlockP);
if(VERBOSE) {
printf("[GetCode(,%d,%d) returning %d]\n",code_size,flag,rv);
}
return rv;
} | 0 | [
"CWE-681"
] | libgd | a11f47475e6443b7f32d21f2271f28f417e2ac04 | 111,383,781,829,771,710,000,000,000,000,000,000,000 | 12 | Fix #420: Potential infinite loop in gdImageCreateFromGifCtx
Due to a signedness confusion in `GetCode_` a corrupt GIF file can
trigger an infinite loop. Furthermore we make sure that a GIF without
any palette entries is treated as invalid *after* open palette entries
have been removed.
CVE-2018-5711
See also https... |
xfs_attr_fillstate(xfs_da_state_t *state)
{
xfs_da_state_path_t *path;
xfs_da_state_blk_t *blk;
int level;
trace_xfs_attr_fillstate(state->args);
/*
* Roll down the "path" in the state structure, storing the on-disk
* block number for those buffers in the "path".
*/
path = &state->path;
ASSERT((path->act... | 0 | [
"CWE-241",
"CWE-19"
] | linux | 8275cdd0e7ac550dcce2b3ef6d2fb3b808c1ae59 | 208,415,182,590,536,900,000,000,000,000,000,000,000 | 40 | xfs: remote attribute overwrite causes transaction overrun
Commit e461fcb ("xfs: remote attribute lookups require the value
length") passes the remote attribute length in the xfs_da_args
structure on lookup so that CRC calculations and validity checking
can be performed correctly by related code. This, unfortunately h... |
ecma_date_value_to_time_string (ecma_number_t datetime_number) /**<datetime */
{
return ecma_date_to_string_format (datetime_number, "$h:$m:$s GMT$z$Z");
} /* ecma_date_value_to_time_string */ | 0 | [
"CWE-416"
] | jerryscript | 3bcd48f72d4af01d1304b754ef19fe1a02c96049 | 48,169,004,609,168,620,000,000,000,000,000,000,000 | 4 | Improve parse_identifier (#4691)
Ascii string length is no longer computed during string allocation.
JerryScript-DCO-1.0-Signed-off-by: Daniel Batiz batizjob@gmail.com |
int hns_rcb_common_get_cfg(struct dsaf_device *dsaf_dev,
int comm_index)
{
struct rcb_common_cb *rcb_common;
enum dsaf_mode dsaf_mode = dsaf_dev->dsaf_mode;
u16 max_vfn;
u16 max_q_per_vf;
int ring_num = hns_rcb_get_ring_num(dsaf_dev);
rcb_common =
devm_kzalloc(dsaf_dev->dev, sizeof(*rcb_common) +
ring... | 0 | [
"CWE-119",
"CWE-703"
] | linux | 412b65d15a7f8a93794653968308fc100f2aa87c | 308,723,964,016,802,400,000,000,000,000,000,000,000 | 32 | net: hns: fix ethtool_get_strings overflow in hns driver
hns_get_sset_count() returns HNS_NET_STATS_CNT and the data space allocated
is not enough for ethtool_get_strings(), which will cause random memory
corruption.
When SLAB and DEBUG_SLAB are both enabled, memory corruptions like the
the following can be observed ... |
R_API void r_bin_java_print_constant_value_attr_summary(RBinJavaAttrInfo *attr) {
if (!attr) {
eprintf ("Attempting to print an invalid RBinJavaAttrInfo *ConstantValue.\n");
return;
}
printf ("Constant Value Attribute Information:\n");
printf (" Attribute Offset: 0x%08"PFMT64x "\n", attr->file_offset);
printf... | 0 | [
"CWE-119",
"CWE-788"
] | radare2 | 6c4428f018d385fc80a33ecddcb37becea685dd5 | 134,506,894,236,181,390,000,000,000,000,000,000,000 | 11 | Improve boundary checks to fix oobread segfaults ##crash
* Reported by Cen Zhang via huntr.dev
* Reproducer: bins/fuzzed/javaoob-havoc.class |
static NTSTATUS ldapsrv_CompareRequest(struct ldapsrv_call *call)
{
struct ldap_CompareRequest *req = &call->request->r.CompareRequest;
struct ldap_Result *compare;
struct ldapsrv_reply *compare_r;
TALLOC_CTX *local_ctx;
struct ldb_context *samdb = call->conn->ldb;
struct ldb_result *res = NULL;
struct ldb_dn *d... | 0 | [] | samba | 86fe9d48883f87c928bf31ccbd275db420386803 | 47,750,664,480,989,580,000,000,000,000,000,000,000 | 70 | CVE-2021-3670 ldap_server: Set timeout on requests based on MaxQueryDuration
BUG: https://bugzilla.samba.org/show_bug.cgi?id=14694
Signed-off-by: Joseph Sutton <josephsutton@catalyst.net.nz>
Reviewed-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz> |
h2_end_headers(struct worker *wrk, struct h2_sess *h2,
struct req *req, struct h2_req *r2)
{
h2_error h2e;
ssize_t cl;
ASSERT_RXTHR(h2);
assert(r2->state == H2_S_OPEN);
h2e = h2h_decode_fini(h2);
h2->new_req = NULL;
if (h2e != NULL) {
Lck_Lock(&h2->sess->mtx);
VSLb(h2->vsl, SLT_Debug, "HPACK/FINI %s", h... | 0 | [
"CWE-444"
] | varnish-cache | d4c67d2a1a05304598895c24663c58a2e2932708 | 105,786,925,817,631,430,000,000,000,000,000,000,000 | 69 | Take content length into account on H/2 request bodies
When receiving H/2 data frames, make sure to take the advertised content
length into account, and fail appropriately if the combined sum of the
data frames does not match the content length. |
do_ed_script (char const *inname, char const *outname,
bool *outname_needs_removal, FILE *ofp)
{
static char const editor_program[] = EDITOR_PROGRAM;
file_offset beginning_of_this_line;
size_t chars_read;
FILE *tmpfp = 0;
int tmpfd = -1; /* placate gcc's -Wmaybe-uninitialized */
int excl... | 0 | [
"CWE-415"
] | patch | 9c986353e420ead6e706262bf204d6e03322c300 | 114,287,915,870,181,740,000,000,000,000,000,000,000 | 110 | Fix swapping fake lines in pch_swap
* src/pch.c (pch_swap): Fix swapping p_bfake and p_efake when there is a
blank line in the middle of a context-diff hunk: that empty line stays
in the middle of the hunk and isn't swapped.
Fixes: https://savannah.gnu.org/bugs/index.php?53133 |
ZipStream(zip* z, const String& name) : m_zipFile(nullptr) {
if (name.empty()) {
return;
}
struct zip_stat zipStat;
if (zip_stat(z, name.c_str(), 0, &zipStat) != 0) {
return;
}
m_zipFile = zip_fopen(z, name.c_str(), 0);
} | 0 | [
"CWE-22"
] | hhvm | 65c95a01541dd2fbc9c978ac53bed235b5376686 | 172,481,323,188,526,800,000,000,000,000,000,000,000 | 12 | ZipArchive::extractTo bug 70350
Summary:Don't allow upward directory traversal when extracting zip archive files.
Files in zip files with `..` or starting at main root `/` should be normalized
to something where the file being extracted winds up within the directory or
a subdirectory where the actual extraction is ta... |
path_end (const char *url)
{
enum url_scheme scheme = url_scheme (url);
const char *seps;
if (scheme == SCHEME_INVALID)
scheme = SCHEME_HTTP; /* use http semantics for rel links */
/* +2 to ignore the first two separators ':' and '/' */
seps = init_seps (scheme) + 2;
return strpbrk_or_eos (url, se... | 0 | [] | wget | 59b920874daa565a1323ffa1e756e80493190686 | 113,017,514,559,027,920,000,000,000,000,000,000,000 | 10 | Support non-ASCII URLs
* src/url.c [HAVE_ICONV]: Include iconv.h and langinfo.h.
(convert_fname): New function.
[HAVE_ICONV]: Convert file name from remote encoding to local
encoding.
(url_file_name): Call convert_fname.
(filechr_table): Don't consider bytes in 128..159 as control
characters.
* tests/Test-ftp-iri.px:... |
TEST_F(QueryPlannerTest, OrBelowElemMatchInexactCovered) {
// true means multikey
addIndex(BSON("a.b" << 1), true);
runQuery(fromjson("{a: {$elemMatch: {$or: [{b: 'x'}, {b: /z/}]}}}"));
assertNumSolutions(2U);
assertSolutionExists("{cscan: {dir: 1}}");
assertSolutionExists(
"{fetch: {fi... | 0 | [] | mongo | ee97c0699fd55b498310996ee002328e533681a3 | 249,421,474,257,303,880,000,000,000,000,000,000,000 | 11 | SERVER-36993 Fix crash due to incorrect $or pushdown for indexed $expr. |
cma_select_ib_ps(struct rdma_id_private *id_priv)
{
enum rdma_ucm_port_space ps = 0;
struct sockaddr_ib *sib;
u64 sid_ps, mask, sid;
sib = (struct sockaddr_ib *) cma_src_addr(id_priv);
mask = be64_to_cpu(sib->sib_sid_mask) & RDMA_IB_IP_PS_MASK;
sid = be64_to_cpu(sib->sib_sid) & mask;
if ((id_priv->id.ps == RDM... | 0 | [
"CWE-416"
] | linux | bc0bdc5afaa740d782fbf936aaeebd65e5c2921d | 253,734,360,500,647,270,000,000,000,000,000,000,000 | 30 | RDMA/cma: Do not change route.addr.src_addr.ss_family
If the state is not idle then rdma_bind_addr() will immediately fail and
no change to global state should happen.
For instance if the state is already RDMA_CM_LISTEN then this will corrupt
the src_addr and would cause the test in cma_cancel_operation():
if (cma... |
static void delete_char(struct vc_data *vc, unsigned int nr)
{
unsigned short *p = (unsigned short *) vc->vc_pos;
vc_uniscr_delete(vc, nr);
scr_memcpyw(p, p + nr, (vc->vc_cols - vc->vc_x - nr) * 2);
scr_memsetw(p + vc->vc_cols - vc->vc_x - nr, vc->vc_video_erase_char,
nr * 2);
vc->vc_need_wrap = 0;
if (con_sh... | 0 | [
"CWE-416",
"CWE-362"
] | linux | ca4463bf8438b403596edd0ec961ca0d4fbe0220 | 85,952,579,391,231,360,000,000,000,000,000,000,000 | 13 | vt: vt_ioctl: fix VT_DISALLOCATE freeing in-use virtual console
The VT_DISALLOCATE ioctl can free a virtual console while tty_release()
is still running, causing a use-after-free in con_shutdown(). This
occurs because VT_DISALLOCATE considers a virtual console's
'struct vc_data' to be unused as soon as the correspond... |
uint32 get_partition_id_cols_range_for_endpoint(partition_info *part_info,
bool is_left_endpoint,
bool include_endpoint,
uint32 nparts)
{
uint min_part_id= 0, max_part_id= pa... | 0 | [] | mysql-server | be901b60ae59c93848c829d1b0b2cb523ab8692e | 123,427,431,703,679,250,000,000,000,000,000,000,000 | 47 | Bug#26390632: CREATE TABLE CAN CAUSE MYSQL TO EXIT.
Analysis
========
CREATE TABLE of InnoDB table with a partition name
which exceeds the path limit can cause the server
to exit.
During the preparation of the partition name,
there was no check to identify whether the complete
path name for partition exceeds the max ... |
TfLiteStatus Prepare(TfLiteContext* context, TfLiteNode* node) {
auto* params =
reinterpret_cast<TfLiteDepthwiseConvParams*>(node->builtin_data);
OpData* data = reinterpret_cast<OpData*>(node->user_data);
// TODO(ahentz): use could use GetOptionalInputTensor() here, but we need to
// decide whether we ar... | 1 | [
"CWE-125",
"CWE-787"
] | tensorflow | 1970c2158b1ffa416d159d03c3370b9a462aee35 | 225,061,722,387,927,900,000,000,000,000,000,000,000 | 174 | [tflite]: Insert `nullptr` checks when obtaining tensors.
As part of ongoing refactoring, `tflite::GetInput`, `tflite::GetOutput`, `tflite::GetTemporary` and `tflite::GetIntermediates` will return `nullptr` in some cases. Hence, we insert the `nullptr` checks on all usages.
We also insert `nullptr` checks on usages o... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.