# CVE-2020-36067: GO-2021-0054 - Panic due to improper input validation in ForEach in github.com/tidwall/gjson

Source: https://junglewise.ai/threats/cve-2020-36067-improper-validation-of-array-index-in-gjson  
Publisher: Junglewise Threat Intelligence, https://junglewise.ai/threats  
Published: 2021-04-14  
License: CC BY 4.0 with a link back

CVE-2020-36067 · Severity: low · CVSS 3.1 · Published 2021-04-14

Panic due to improper input validation in ForEach in github.com/tidwall/gjson

Technologies: [github.com/tidwall/gjson (Go)](https://junglewise.ai/threats/technologies/github-com-tidwall-gjson). Vendors: [Go](https://junglewise.ai/threats/vendors/go).

## Quick answers

**Is CVE-2020-36067 exploited in the wild?** No. Junglewise Threat Intelligence has no report of CVE-2020-36067 being exploited in the wild.

**How severe is CVE-2020-36067?** Low severity, with a CVSS score of 3.1, published 14 April 2021.

**Which products and versions are affected?** github.com/tidwall/gjson (Go) SEMVER:introduced=0,fixed=1.6.6.

**Is there a fix for CVE-2020-36067?** Yes. github.com/tidwall/gjson (Go): upgrade to 1.6.6 or later. Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.

**Am I affected by CVE-2020-36067?** Check whether you run github.com/tidwall/gjson (Go) at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

## How to fix

- github.com/tidwall/gjson (Go): upgrade to 1.6.6 or later

  ```sh
  go get github.com/tidwall/gjson@v1.6.6
  ```


## Affected products

- github.com/tidwall/gjson (Go) SEMVER:introduced=0,fixed=1.6.6

## Identifiers

- CVE-2020-36067
- GHSA-p64j-r5f4-pwwx
- GO-2021-0054

## Related threats

- [GO-2022-0957 - Denial of service via maliciously crafted JSON in github.com/tidwall/gjson](https://junglewise.ai/threats/cve-2020-36066-github-com-tidwall-gjson-is-vulnerable-to-denial-of-service)
- [GO-2021-0265 - Denial of service via maliciously crafted path in github.com/tidwall/gjson](https://junglewise.ai/threats/cve-2021-42248-duplicate-advisory-redos-via-crafted-json-input-in-gjson)
- [GO-2022-0592 - A maliciously crafted path can cause Get and other query functions
to consume excessive amounts of CPU and time.](https://junglewise.ai/threats/go-2022-0592-a-maliciously-crafted-path-can-cause-get-and-other-query-8d2fb414)
- [GO-2021-0059 - Panic due to improper input validation in Get in github.com/tidwall/gjson](https://junglewise.ai/threats/cve-2020-35380-denial-of-service-in-gjson)
