Skip to content

GHSA-73xv-w5gp-frxh CVE-2020-28052

Logic error in Legion of the Bouncy Castle BC Java

High Maven
Severity
8.1 / 10
High · CVSS 3.1
Exploit chance (EPSS)
7.22%
Chance of exploitation in the next 30 days. Higher than 94.32% of scored vulnerabilities.
Known exploited
No
Not in CISA's catalog
Weakness
CWE-670 Always-Incorrect Control Flow Implementation
Fix
Available
7 packages have a fixed version

Description

An issue was discovered in Legion of the Bouncy Castle BC Java 1.65 and 1.66. The OpenBSDBCrypt.checkPassword utility method compared incorrect data when checking the password, allowing incorrect passwords to indicate they were matching with previously hashed ones that were different.

Affected versions

Maven

PackageVulnerableFixed in
org.bouncycastle:bcprov-ext-jdk15on
>= 1.65, < 1.67
1.67
org.bouncycastle:bcprov-ext-jdk16
>= 1.65, < 1.67
1.67
org.bouncycastle:bcprov-jdk14
>= 1.65, < 1.67
1.67
org.bouncycastle:bcprov-jdk15
>= 1.65, < 1.67
1.67
org.bouncycastle:bcprov-jdk15on
>= 1.65, < 1.67
1.67
org.bouncycastle:bcprov-jdk15to18
>= 1.65, < 1.67
1.67
org.bouncycastle:bcprov-jdk16
>= 1.65, < 1.67
1.67

How to fix

Move to the fixed version or later with your package manager, update the lockfile, and run your tests. If the package only arrives through another dependency, upgrade that dependency first. If none of its releases pulls a fixed version yet, force the version with your package manager's override.

org.bouncycastle:bcprov-ext-jdk15on Maven → 1.67

maven
<dependency><groupId>org.bouncycastle</groupId><artifactId>bcprov-ext-jdk15on</artifactId><version>1.67</version></dependency>
gradle
implementation("org.bouncycastle:bcprov-ext-jdk15on:1.67")

org.bouncycastle:bcprov-ext-jdk16 Maven → 1.67

maven
<dependency><groupId>org.bouncycastle</groupId><artifactId>bcprov-ext-jdk16</artifactId><version>1.67</version></dependency>
gradle
implementation("org.bouncycastle:bcprov-ext-jdk16:1.67")

org.bouncycastle:bcprov-jdk14 Maven → 1.67

maven
<dependency><groupId>org.bouncycastle</groupId><artifactId>bcprov-jdk14</artifactId><version>1.67</version></dependency>
gradle
implementation("org.bouncycastle:bcprov-jdk14:1.67")

org.bouncycastle:bcprov-jdk15 Maven → 1.67

maven
<dependency><groupId>org.bouncycastle</groupId><artifactId>bcprov-jdk15</artifactId><version>1.67</version></dependency>
gradle
implementation("org.bouncycastle:bcprov-jdk15:1.67")

org.bouncycastle:bcprov-jdk15on Maven → 1.67

maven
<dependency><groupId>org.bouncycastle</groupId><artifactId>bcprov-jdk15on</artifactId><version>1.67</version></dependency>
gradle
implementation("org.bouncycastle:bcprov-jdk15on:1.67")

org.bouncycastle:bcprov-jdk15to18 Maven → 1.67

maven
<dependency><groupId>org.bouncycastle</groupId><artifactId>bcprov-jdk15to18</artifactId><version>1.67</version></dependency>
gradle
implementation("org.bouncycastle:bcprov-jdk15to18:1.67")

org.bouncycastle:bcprov-jdk16 Maven → 1.67

maven
<dependency><groupId>org.bouncycastle</groupId><artifactId>bcprov-jdk16</artifactId><version>1.67</version></dependency>
gradle
implementation("org.bouncycastle:bcprov-jdk16:1.67")

Severity breakdown

CVSS 3.1 8.1

CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H

Attack vector
Network
Attack complexity
High
Privileges required
None
User interaction
None
Scope
Unchanged
Confidentiality
High
Integrity
High
Availability
High

Weakness

CWE-670: Always-Incorrect Control Flow Implementation

The code contains a control flow path that does not reflect the algorithm that the path is intended to implement, leading to incorrect behavior any time this path is navigated.

References

Advisories

Packages

Other links

Timeline

  1. Published
  2. Last updated by the source
  3. Latest EPSS score
AdvisorySeverityWhy it's related
GHSA-p93r-85wp-75v3
Bouncy Castle Has Covert Timing Channel Vulnerability
High Also affects org.bouncycastle:bcprov-jdk14
GHSA-c3fc-8qff-9hwx
Bouncy Castle has an LDAP injection
Medium Also affects org.bouncycastle:bcprov-jdk14
GHSA-574f-3g2m-x479
Bouncy Castle for Java GOST 28147 CTR mode reuses keystream after 255 blocks
High Also affects org.bouncycastle:bcprov-jdk14
GHSA-67mf-3cr5-8w23
Bouncy Castle for Java on All (API modules) allows Excessive Allocation
Medium Also affects org.bouncycastle:bcprov-jdk14
GHSA-m44j-cfrm-g8qc
Bouncy Castle crafted signature and public key can be used to trigger an infinite loop
High Also affects org.bouncycastle:bcprov-jdk14
GHSA-v435-xc8x-wvr9
Bouncy Castle affected by timing side-channel for RSA key exchange ("The Marvin Attack")
Medium Also affects org.bouncycastle:bcprov-jdk14
GHSA-8xfc-gm6g-vgpv
Bouncy Castle certificate parsing issues cause high CPU usage during parameter evaluation.
High Also affects org.bouncycastle:bcprov-jdk14
GHSA-4h8f-2wvx-gg5w
Bouncy Castle Java Cryptography API vulnerable to DNS poisoning
High Also affects org.bouncycastle:bcprov-jdk14
Is this in your code?

MergeHarbor checks every repository's dependencies against this database, ranks what matters by exploitability and reachability, routes it to the owning team and opens the fix pull request.

Check your repos with MergeHarbor