CVE-2016-2510: Improper Input Validation in BeanShell

Summary

13/05/2022
Yes i
High
8.1

CVE-2016-2510: Improper Input Validation in BeanShell. Affects org.apache-extras.beanshell:bsh versions < 2.0b6. Fixed in 2.0b6. How to fix ↓

Also tracked for

The same CVE-2016-2510 is tracked separately for each ecosystem and vendor. Its fix information is the same; the package and affected versions differ.

Free scan

Check if this vulnerability affects your application

Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.

Check my app free

No signup required · Results in about 60 seconds

Upload your dependency manifest or SBOM

Drag & drop your file here or

Java Javascript PHP Python Go Rust Ruby Dart C/C++ Elixir CycloneDX SPDX

Upload a supported dependency manifest or SBOM. No installation or source-code access required.

See supported files and SBOM formats
SBOM sbom.json · bom.json · bom.xml · *.spdx.json · *.cdx.json · *.cdx.xml
Java pom.xml · gradle.lockfile · buildscript-gradle.lockfile
Javascript package-lock.json · yarn.lock · pnpm-lock.yaml
PHP composer.lock
Python poetry.lock · requirements.txt · Pipfile.lock
Go go.mod
Rust Cargo.lock
Ruby Gemfile.lock
Dart pubspec.lock
C/C++ conan.lock
Elixir mix.lock
Enter your work email to receive your report link.

Verify your email to view the full report and start 30 days of continuous monitoring. No credit card required.

Sponsored Devnack Your last release was probably never penetration tested Manual testing by engineers who build software, not an auditor's checklist. Trusted by teams at Swift and Google Talk to Devnack

Background

BeanShell (bsh) is a scripting language for Java that provides a convenient way to execute Java code dynamically. It is often used as an embedded scripting language in Java applications. The vulnerability in question (CVE-2016-2510) affects versions of BeanShell prior to 2.0b6. This vulnerability arises when BeanShell is included on the classpath by an application that uses Java serialization or XStream. Attackers can exploit this vulnerability by sending crafted serialized data, leading to the execution of arbitrary code. The vulnerability is related to XThis.Handler.

Vulnerability Detail

The vulnerability allows remote attackers to execute arbitrary code by exploiting improper input validation in BeanShell. By sending specially crafted serialized data, an attacker can trigger the execution of arbitrary code on the target system. This can lead to various consequences, including unauthorized access, data theft, or system compromise. The vulnerability has a CVSS score of 8.1, indicating a high severity level.

How To Fix

Minimum fixed version

2.0b6

This is the first release that contains the fix.

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Workaround

If upgrading to the latest version of BeanShell is not immediately feasible, a possible workaround is to remove BeanShell from the classpath if it is not required by the application. This can help mitigate the risk of exploitation. However, it is strongly recommended to update to the latest version as soon as possible to fully address the vulnerability.

Conclusion

In conclusion, the vulnerability (CVE-2016-2510) in BeanShell allows remote attackers to execute arbitrary code by exploiting improper input validation. To mitigate this vulnerability, it is crucial to upgrade to BeanShell version 2.0b6 or later. If immediate upgrading is not possible, removing BeanShell from the classpath can serve as a temporary workaround. For further support and assistance in vulnerability remediation, please contact DevNack.com.

See every vulnerability recorded for org.apache-extras.beanshell:bsh →

Share this vulnerability

FAQ

BeanShell is a scripting language for Java that allows the execution of Java code dynamically. It is often used as an embedded scripting language in Java applications.

The vulnerability allows remote attackers to execute arbitrary code on the target system. This can lead to unauthorized access, data theft, or system compromise.

To fix this vulnerability, it is recommended to upgrade to BeanShell version 2.0b6 or later. Updating the BeanShell dependency in the application's Maven configuration or build file will ensure that the vulnerability is mitigated.

If upgrading to the latest version of BeanShell is not immediately feasible, a possible workaround is to remove BeanShell from the classpath if it is not required by the application. However, it is strongly recommended to update to the latest version as soon as possible.

The CVSS score of this vulnerability is 8.1, indicating a high severity level.

How To Fix

Minimum fixed version

2.0b6

This is the first release that contains the fix.

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback