VYPR
Moderate severityNVD Advisory· Published Sep 16, 2022· Updated Apr 23, 2025

`CHECK` fail in `AudioSummaryV2` in TensorFlow

CVE-2022-35995

Description

TensorFlow is an open source platform for machine learning. When AudioSummaryV2 receives an input sample_rate with more than one element, it gives a CHECK fails that can be used to trigger a denial of service attack. We have patched the issue in GitHub commit bf6b45244992e2ee543c258e519489659c99fb7f. The fix will be included in TensorFlow 2.10.0. We will also cherrypick this commit on TensorFlow 2.9.1, TensorFlow 2.8.1, and TensorFlow 2.7.2, as these are also affected and still in supported range. There are no known workarounds for this issue.

Affected packages

Versions sourced from the GitHub Security Advisory.

PackageAffected versionsPatched versions
tensorflowPyPI
< 2.7.22.7.2
tensorflowPyPI
>= 2.8.0, < 2.8.12.8.1
tensorflowPyPI
>= 2.9.0, < 2.9.12.9.1
tensorflow-cpuPyPI
< 2.7.22.7.2
tensorflow-cpuPyPI
>= 2.8.0, < 2.8.12.8.1
tensorflow-cpuPyPI
>= 2.9.0, < 2.9.12.9.1
tensorflow-gpuPyPI
< 2.7.22.7.2
tensorflow-gpuPyPI
>= 2.8.0, < 2.8.12.8.1
tensorflow-gpuPyPI
>= 2.9.0, < 2.9.12.9.1

Affected products

1

Patches

1
bf6b45244992

Fix tf.raw_ops.AudioSummaryV2 vulnerability with invalid `sample_rate`.

https://github.com/tensorflow/tensorflowAlan LiuJul 13, 2022via ghsa
2 files changed · +11 0
  • tensorflow/core/kernels/summary_audio_op.cc+5 0 modified
    @@ -49,6 +49,11 @@ class SummaryAudioOp : public OpKernel {
         float sample_rate = sample_rate_attr_;
         if (!has_sample_rate_attr_) {
           const Tensor& sample_rate_tensor = c->input(2);
    +      OP_REQUIRES(c,
    +                  sample_rate_tensor.IsAligned() &&
    +                      sample_rate_tensor.NumElements() == 1,
    +                  errors::InvalidArgument(
    +                      "sample_rate must be rank-0 or contain a single value"));
           sample_rate = sample_rate_tensor.scalar<float>()();
         }
         OP_REQUIRES(c, sample_rate > 0.0f,
    
  • tensorflow/python/summary/summary_test.py+6 0 modified
    @@ -23,6 +23,7 @@
     from tensorflow.core.framework import summary_pb2
     from tensorflow.python.framework import constant_op
     from tensorflow.python.framework import dtypes
    +from tensorflow.python.framework import errors
     from tensorflow.python.framework import meta_graph
     from tensorflow.python.framework import ops
     from tensorflow.python.framework import test_util
    @@ -183,6 +184,11 @@ def testAudioSummaryWithFamily(self):
             'family/outer/family/inner/audio/{}'.format(i) for i in range(3))
         self.assertEqual(tags, expected)
     
    +  def testAudioSummaryWithInvalidSampleRate(self):
    +    with self.assertRaises(errors.InvalidArgumentError):
    +      invalid_sample_rate = [22000.0, 22000.0]
    +      self.evaluate(summary_lib.audio('', [[1.0]], invalid_sample_rate))
    +
       @test_util.run_deprecated_v1
       def testTextSummary(self):
         with self.cached_session():
    

Vulnerability mechanics

Generated by null/stub on May 9, 2026. Inputs: CWE entries + fix-commit diffs from this CVE's patches. Citations validated against bundle.

References

5

News mentions

0

No linked articles in our index yet.