|
{ |
|
"idx": 195017, |
|
"project": "gpac", |
|
"commit_id": "ad18ece95fa064efc0995c4ab2c985f77fb166ec", |
|
"project_url": "https://github.com/gpac/gpac", |
|
"commit_url": "https://github.com/gpac/gpac/commit/ad18ece95fa064efc0995c4ab2c985f77fb166ec", |
|
"commit_message": "fixed #1904", |
|
"target": 1, |
|
"func": "u32 GetHintFormat(GF_TrackBox *trak)\n{\n\tGF_HintMediaHeaderBox *hmhd = (GF_HintMediaHeaderBox *)trak->Media->information->InfoHeader;\n\tif (hmhd->type != GF_ISOM_BOX_TYPE_HMHD)\n\t\treturn 0;\n\t\t\n\tif (!hmhd || !hmhd->subType) {\n\t\tGF_Box *a = (GF_Box *)gf_list_get(trak->Media->information->sampleTable->SampleDescription->child_boxes, 0);\n\t\tif (!hmhd) return a ? a->type : 0;\n\t\tif (a) hmhd->subType = a->type;\n\t\treturn hmhd->subType;\n\t}\n\treturn hmhd->subType;\n}", |
|
"func_hash": 9.121826884968644e+37, |
|
"file_name": "hint_track.c", |
|
"file_hash": 6.017689527465478e+37, |
|
"cwe": [ |
|
"CWE-476" |
|
], |
|
"cve": "CVE-2021-40576", |
|
"cve_desc": "The binary MP4Box in Gpac 1.0.1 has a null pointer dereference vulnerability in the gf_isom_get_payt_count function in hint_track.c, which allows attackers to cause a denial of service.", |
|
"nvd_url": "https://nvd.nist.gov/vuln/detail/CVE-2021-40576" |
|
} |
|
{ |
|
"idx": 219032, |
|
"project": "tensorflow", |
|
"commit_id": "240655511cd3e701155f944a972db71b6c0b1bb6", |
|
"project_url": "https://github.com/tensorflow/tensorflow", |
|
"commit_url": "https://github.com/tensorflow/tensorflow/commit/240655511cd3e701155f944a972db71b6c0b1bb6", |
|
"commit_message": "Eliminate `CHECK`-fails from `IsSimplifiableReshape` via `MakeShape(<invalid shape>)`\n\nPiperOrigin-RevId: 409166738\nChange-Id: I7f0a3590b8acae3f3e3e2fe636e1f5ef285693cf", |
|
"target": 0, |
|
"func": "Status ConstantFolding::IsSimplifiableReshape(\n const NodeDef& node, const GraphProperties& properties) const {\n if (!IsReshape(node)) {\n return errors::Internal(\"Node \", node.name(), \" is not a Reshape node\");\n }\n if (2 > node.input_size()) {\n return errors::Internal(\"Node \", node.name(),\n \" must have at most 2 inputs but has \",\n node.input_size());\n }\n const NodeDef* new_shape = node_map_->GetNode(node.input(1));\n if (!IsReallyConstant(*new_shape)) {\n return errors::Internal(\"Node \", node.name(), \" has shape \",\n new_shape->DebugString(),\n \" which is not a constant\");\n }\n TensorVector outputs;\n auto outputs_cleanup = gtl::MakeCleanup([&outputs] {\n for (const auto& output : outputs) {\n delete output.tensor;\n }\n });\n\n Status s = EvaluateNode(*new_shape, TensorVector(), &outputs);\n if (!s.ok()) {\n return errors::Internal(\"Could not evaluate node \", node.name());\n }\n if (outputs.size() != 1) {\n return errors::Internal(\"Node \", node.name(),\n \" must have exactly 1 output but has \",\n outputs.size());\n }\n\n const std::vector<OpInfo::TensorProperties>& props =\n properties.GetInputProperties(node.name());\n if (props.empty()) {\n return errors::Internal(\"Node \", node.name(), \" has no properties\");\n }\n const OpInfo::TensorProperties& prop = props[0];\n if (prop.dtype() == DT_INVALID) {\n return errors::Internal(\"Node \", node.name(), \" has property \",\n prop.DebugString(), \" with invalid dtype\");\n }\n const PartialTensorShape shape(prop.shape());\n if (!shape.IsFullyDefined()) {\n return errors::Internal(\"Node \", node.name(), \" has property \",\n prop.DebugString(), \" with shape \",\n shape.DebugString(), \" which is not fully defined\");\n }\n\n PartialTensorShape new_dims;\n if (outputs[0]->dtype() == DT_INT32) {\n std::vector<int32> shp;\n for (int i = 0; i < outputs[0]->NumElements(); ++i) {\n int32_t dim = outputs[0]->flat<int32>()(i);\n shp.push_back(dim);\n }\n s = TensorShapeUtils::MakeShape(shp, &new_dims);\n if (!s.ok()) return s;\n } else {\n std::vector<int64_t> shp;\n for (int i = 0; i < outputs[0]->NumElements(); ++i) {\n int64_t dim = outputs[0]->flat<int64_t>()(i);\n shp.push_back(dim);\n }\n s = TensorShapeUtils::MakeShape(shp, &new_dims);\n if (!s.ok()) return s;\n }\n\n if (!shape.IsCompatibleWith(new_dims)) {\n return errors::Internal(\"Expected shape \", shape.DebugString(),\n \"to be compatible with \", new_dims.DebugString());\n }\n\n return Status::OK();\n}", |
|
"func_hash": 2.627609075267344e+38, |
|
"file_name": "constant_folding.cc", |
|
"file_hash": 2.716066943752777e+38, |
|
"cwe": [ |
|
"CWE-617" |
|
], |
|
"cve": "CVE-2022-23581", |
|
"cve_desc": "Tensorflow is an Open Source Machine Learning Framework. The Grappler optimizer in TensorFlow can be used to cause a denial of service by altering a `SavedModel` such that `IsSimplifiableReshape` would trigger `CHECK` failures. The fix will be included in TensorFlow 2.8.0. We will also cherrypick this commit on TensorFlow 2.7.1, TensorFlow 2.6.3, and TensorFlow 2.5.3, as these are also affected and still in supported range.", |
|
"nvd_url": "https://nvd.nist.gov/vuln/detail/CVE-2022-23581" |
|
} |