GHSA-45w3-v3g4-54pm: Parsec service Chrono Has Potential Segfault Issue Vulnerability

LOW
CWE-476
Published
Advisory Summary

GHSA-45w3-v3g4-54pm is a LOW chrono has potential segfault issue vulnerability (CWE-476: NULL Pointer Dereference) affecting Parsec service libraries in the crates.io ecosystem. The issue involves chrono has potential segfault issue in spiffe authenticator. Remediation is available by upgrading affected packages to version 1.1.0.

GHSA-45w3-v3g4-54pm at a Glance

CVE Identifier N/A
GHSA Identifier GHSA-45w3-v3g4-54pm
Severity LOW
CVSS v3.1 Base Score N/A
CWE Classification CWE-476: NULL Pointer Dereference
Affected Product Parsec service
Package Ecosystem crates.io
Published Date
Last Updated

How to Fix GHSA-45w3-v3g4-54pm

To remediate this vulnerability, upgrade all affected Parsec service dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

parsec-service fixed: 1.1.0
Upgrade parsec-service to 1.1.0
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

inspect dependencies for parsec-service

How to Check if You Are Affected

To determine whether your application is affected by GHSA-45w3-v3g4-54pm, inspect your project dependencies for Parsec service:

inspect dependencies for parsec-service

Analyze the terminal output to locate any version of Parsec service in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 1.1.0), your application is affected.

Note: Verify declared build manifests and deployed runtime container environments.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-476: NULL Pointer Dereference, where the product dereferences a pointer that it expects to be valid but is null. In Parsec service, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

### Impact Several vulnerabilities have been reported in the `time` and `chrono` crates related to handling of calls to `localtime_r`. You can follow some of the discussions [here](https://github.com/chronotope/chrono/issues/602) and [here](https://github.com/time-rs/time/issues/293), and the associated CVE [here](https://nvd.nist.gov/vuln/detail/CVE-2020-26235). In our case, the issue with the dependency was flagged by our nightly CI build running [`cargo-audit`](https://github.com/parallaxsecond/parsec/issues/544). The vulnerability leads to a segfault in specific circumstances - namely, when one of a number of functions in the `time` crate is called while any other thread is setting an environment variable. Given that in the case of the Parsec service this affects the SPIFFE authenticator, Parsec service users can encounter the issue only when the JWT SVID authenticator is enabled and being used. We have not undergone any manual tracing to understand if the vulnerable methods are called anywhere in our stack, however it seems reasonable to expect that if that were to be the case, the issue would lie in JWT validation (i.e. when handling the dates found within a Json Web Token). JWT validation could thus fail, bringing down the thread in which the request happens. The rest of the threads continue to work. Since the threadpool implementation that we use [continues replenishing the pool](https://docs.rs/threadpool/latest/threadpool/) when one thread panics, the impact on the service should be minimal. ### Patches No current patches exist as the problems lie in a number of dependencies that are not under our control (see more details [here](https://github.com/parallaxsecond/parsec/issues/544#issuecomment-1024185688)). The issue tracking the required change in the `rust-spiffe` crate (through which the vulnerable dependencies are imported in Parsec) can be seen [here](https://github.com/maxlambrecht/rust-spiffe/issues/17). Once updates happen in our dependency chain that allow us to update beyond the vulnerable versions of `time` and `chrono`, a new version of the Parsec service will be tagged and released with the appropriate notifications. ### Workarounds The only complete workaround is to use a different type of authenticator with the Parsec service. ### References As quoted in the initial paragraph, you can find out more information: * in the `chrono` repo issue [here](https://github.com/chronotope/chrono/issues/602) * in the `time` repo issue [here](https://github.com/time-rs/time/issues/293) * in the official CVE report [here](https://nvd.nist.gov/vuln/detail/CVE-2020-26235) * in our tracking issue [here](https://github.com/parallaxsecond/parsec/issues/544) ### For more information: If you have any questions or comments about this advisory: * Open an issue in [the Parsec service repo](https://github.com/parallaxsecond/parsec) * Email us at [cncf-parsec-maintainers@lists.cncf.io](mailto:cncf-parsec-maintainers@lists.cncf.io)

GHSA-45w3-v3g4-54pm Affected Parsec service Versions

1 component(s)
Fixed Versions:
1.1.0
Product / Package Ecosystem Affected Versions Fixed Version
parsec-service
crates.io
≥ 0.8.0
< 1.1.0
1.1.0

References

Frequently Asked Questions

What is GHSA-45w3-v3g4-54pm?
GHSA-45w3-v3g4-54pm is a security vulnerability in Parsec service involving Chrono has potential segfault issue in SPIFFE authenticator under CWE-476: NULL Pointer Dereference.
Which Parsec service versions are affected?
Affected versions include releases prior to 1.1.0 across affected packages: parsec-service.
What version fixes GHSA-45w3-v3g4-54pm?
Upgrading to 1.1.0 (or the latest patched release for your respective branch) resolves the vulnerability.
Is parsec-service affected?
Yes, parsec-service is affected in releases prior to 1.1.0. Upgrade your dependency to 1.1.0 or later.
What CWE is associated with GHSA-45w3-v3g4-54pm?
GHSA-45w3-v3g4-54pm is classified under CWE-476: NULL Pointer Dereference (The product dereferences a pointer that it expects to be valid but is NULL.).
How can I check crates.io dependencies for GHSA-45w3-v3g4-54pm?
Run the dependency tree command: 'inspect dependencies for parsec-service'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-45w3-v3g4-54pm",
  "modified" : "2022-09-12T20:44:49Z",
  "published" : "2022-02-11T19:11:36Z",
  "aliases" : [ ],
  "summary" : "Chrono has potential segfault issue in SPIFFE authenticator",
  "details" : "### Impact\nSeveral vulnerabilities have been reported in the `time` and `chrono` crates related to handling of calls to `localtime_r`. You can follow some of the discussions [here](https://github.com/chronotope/chrono/issues/602) and [here](https://github.com/time-rs/time/issues/293), and the associated CVE [here](https://nvd.nist.gov/vuln/detail/CVE-2020-26235). In our case, the issue with the dependency was flagged by our nightly CI build running [`cargo-audit`](https://github.com/parallaxsecond/parsec/issues/544). \n\nThe vulnerability leads to a segfault in specific circumstances - namely, when one of a number of functions in the `time` crate is called while any other thread is setting an environment variable. Given that in the case of the Parsec service this affects the SPIFFE authenticator, Parsec service users can encounter the issue only when the JWT SVID authenticator is enabled and being used. We have not undergone any manual tracing to understand if the vulnerable methods are called anywhere in our stack, however it seems reasonable to expect that if that were to be the case, the issue would lie in JWT validation (i.e. when handling the dates found within a Json Web Token). JWT validation could thus fail, bringing down the thread in which the request happens. The rest of the threads continue to work. Since the threadpool implementation that we use [continues replenishing the pool](https://docs.rs/threadpool/latest/threadpool/) when one thread panics, the impact on the service should be minimal.\n\n### Patches\nNo current patches exist as the problems lie in a number of dependencies that are not under our control (see more details [here](https://github.com/parallaxsecond/parsec/issues/544#issuecomment-1024185688)).\n\nThe issue tracking the required change in the `rust-spiffe` crate (through which the vulnerable dependencies are imported in Parsec) can be seen [here](https://github.com/maxlambrecht/rust-spiffe/issues/17). Once updates happen in our dependency chain that allow us to update beyond the vulnerable versions of `time` and `chrono`, a new version of the Parsec service will be tagged and released with the appropriate notifications.\n\n### Workarounds\nThe only complete workaround is to use a different type of authenticator with the Parsec service. \n\n### References\nAs quoted in the initial paragraph, you can find out more information:\n* in the `chrono` repo issue [here](https://github.com/chronotope/chrono/issues/602)\n* in the `time` repo issue [here](https://github.com/time-rs/time/issues/293)\n* in the official CVE report [here](https://nvd.nist.gov/vuln/detail/CVE-2020-26235)\n* in our tracking issue [here](https://github.com/parallaxsecond/parsec/issues/544)\n\n### For more information:\nIf you have any questions or comments about this advisory:\n* Open an issue in [the Parsec service repo](https://github.com/parallaxsecond/parsec)\n* Email us at [cncf-parsec-maintainers@lists.cncf.io](mailto:cncf-parsec-maintainers@lists.cncf.io)",
  "severity" : [ ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "crates.io",
      "name" : "parsec-service"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0.8.0"
      }, {
        "fixed" : "1.1.0"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/parallaxsecond/parsec/security/advisories/GHSA-45w3-v3g4-54pm"
  }, {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2020-26235"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/chronotope/chrono/issues/602"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/parallaxsecond/parsec/issues/544"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/parallaxsecond/parsec/issues/544#issuecomment-1024185688"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/time-rs/time/issues/293"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/parallaxsecond/parsec"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-476" ],
    "severity" : "LOW",
    "github_reviewed" : true,
    "github_reviewed_at" : "2022-02-11T19:11:36Z",
    "nvd_published_at" : null
  }
}