USN-9148-1: Mechanize vulnerability
It was discovered that Mechanize used Kernel#open to open local files in several methods. If an application passed untrusted input as a local file name to one of these methods, an attacker could possibly use this issue to execute arbitrary commands.
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Upgrade
Upgrade
ubuntu/ruby-mechanizeto a version that resolves this vulnerability.Fixed in Ubuntu Pro - Upgrade
Upgrade
ubuntu/ruby-mechanizeto a version that resolves this vulnerability.Fixed in 2.7.3-1ubuntu0.1~esm1
Event History
Frequently Asked Questions
What conditions are required for exploitation?
An application must pass attacker-controlled input as a local file name to one of the affected Mechanize methods. The issue may then allow the attacker to execute arbitrary commands.
Which deployments are exposed?
Ubuntu systems using the ruby-mechanize package may be exposed if their applications use the affected local-file handling methods with untrusted file-name input.