Cloudanix VulnDB

CVE-2017-6512

Medium · 5.9

CVSS

5.9

EPSS

2.4%

Published

Jun 1, 2017

CISA due date

—

Cloudanix analysis

Schedule a fix SSVC: Track

A timing flaw in a Perl library used to delete directories can let attackers change permissions on any files they choose.

Chainable
Exploitation
Remote Unauthenticated
Attacker needs
None
Complexity
High
Impact
Data Tampering
Component
Library
Class
Race Condition
Remediation
Upgrade
Effort
Medium
Patch risk
Low

What it actually does

Race condition in rmtree and remove_tree functions allows setting arbitrary file modes during directory-permission loosening logic.

Why it matters to the business

Attackers may alter file permissions on systems running vulnerable Perl installations, potentially leading to integrity violations, unauthorized access escalation, or disruption of file-based operations in long-lived deployments.

How an attack unfolds

An attacker identifies a process using vulnerable File-Path rmtree/remove_tree on a controllable path, then times a permission change operation within the race window created by the module's directory permission handling to affect target files.

How to fix it

Upgrade the File-Path Perl module to version 2.13 or later on all affected systems; apply current package updates from distribution maintainers for Ubuntu and Debian.

How to confirm the fix worked

Verify installed File-Path module version meets or exceeds 2.13; review application code for direct calls to rmtree or remove_tree and test under concurrent access conditions.

Typical attack path

  1. Locate Perl applications using File-Path versions before 2.13
  2. Prepare a directory structure that triggers rmtree or remove_tree
  3. Exploit the timing window during permission loosening to modify modes on chosen files
  4. Leverage resulting permission changes for follow-on access or tampering

How to detect it

Review system and application logs for Perl processes performing recursive directory removal; correlate with unexpected permission changes on files outside the intended target directories.

What your security team should do

  • Prioritize patching File-Path across all Perl environments due to multi-year exposure window
  • Scan for and replace legacy use of rmtree/remove_tree with safer alternatives where possible
  • Monitor package repositories for backported fixes in supported distributions

The record

Race condition in the rmtree and remove_tree functions in the File-Path module before 2.13 for Perl allows attackers to set the mode on arbitrary files via vectors involving directory-permission loosening logic.

Affected packages

Ecosystem Package Introduced Fixed
Debian:11 perl 0 5.24.1-3
Debian:12 perl 0 5.24.1-3
Debian:13 perl 0 5.24.1-3
Debian:14 perl 0 5.24.1-3
Debian:7 perl 0 5.14.2-21+deb7u5
Debian:8 perl 0 5.20.2-3+deb8u7
Mageia:5 perl 0 5.20.1-8.7.mga5
Mageia:5 perl-File-Path 0 2.90.0-4.1.mga5
Mageia:5 perl-MIME-Charset 0 1.11.1-4.1.mga5
Mageia:5 perl-MIME-EncWords 0 1.14.2-4.1.mga5
Mageia:5 perl-Module-Build 0 0.421.0-5.1.mga5
Mageia:5 perl-Module-Load-Conditional 0 0.680.0-1.mga5
Mageia:5 perl-Net-DNS 0 1.90.0-0.mga5
Mageia:5 perl-Sys-Syslog 0 0.330.0-7.1.mga5
Mageia:5 perl-Unicode-LineBreak 0 2014.60.0-5.1.mga5
Mageia:5 perl-libintl-perl 0 1.230.0-6.1.mga5
SUSE:Linux Enterprise Desktop 12 SP2 perl 0 5.18.2-12.3.1
SUSE:Linux Enterprise Desktop 12 SP3 perl 0 5.18.2-12.3.1
SUSE:Linux Enterprise High Performance Computing 15 SP2-LTSS perl 0 5.26.1-150000.7.18.1
SUSE:Linux Enterprise Micro 5.1 perl 0 5.26.1-150300.17.11.1
SUSE:Linux Enterprise Micro 5.2 perl 0 5.26.1-150300.17.11.1
SUSE:Linux Enterprise Module for Basesystem 15 SP3 perl 0 5.26.1-150300.17.11.1
SUSE:Linux Enterprise Module for Basesystem 15 SP4 perl 0 5.26.1-150300.17.11.1
SUSE:Linux Enterprise Module for Development Tools 15 SP3 perl 0 5.26.1-150300.17.11.1
SUSE:Linux Enterprise Module for Development Tools 15 SP4 perl 0 5.26.1-150300.17.11.1
SUSE:Linux Enterprise Module for Package Hub 15 SP3 perl 0 5.26.1-150300.17.11.1
SUSE:Linux Enterprise Module for Package Hub 15 SP4 perl 0 5.26.1-150300.17.11.1
SUSE:Linux Enterprise Server 11 SP4 perl 0 5.10.0-64.81.3.1
SUSE:Linux Enterprise Server 12 SP2 perl 0 5.18.2-12.3.1
SUSE:Linux Enterprise Server 12 SP3 perl 0 5.18.2-12.3.1
SUSE:Linux Enterprise Server 12 SP5 perl-File-Path 0 2.150000-8.3.1
SUSE:Linux Enterprise Server 15 SP2-LTSS perl 0 5.26.1-150000.7.18.1
SUSE:Linux Enterprise Server for Raspberry Pi 12 SP2 perl 0 5.18.2-12.3.1
SUSE:Linux Enterprise Server for SAP Applications 11 SP4 perl 0 5.10.0-64.81.3.1
SUSE:Linux Enterprise Server for SAP Applications 12 SP2 perl 0 5.18.2-12.3.1
SUSE:Linux Enterprise Server for SAP Applications 12 SP3 perl 0 5.18.2-12.3.1
SUSE:Linux Enterprise Server for SAP Applications 12 SP5 perl-File-Path 0 2.150000-8.3.1
SUSE:Linux Enterprise Server for SAP Applications 15 SP2 perl 0 5.26.1-150000.7.18.1
SUSE:Linux Enterprise Software Development Kit 11 SP4 perl 0 5.10.0-64.81.3.1
Ubuntu:14.04:LTS perl 0 5.18.2-2ubuntu1.4
Ubuntu:16.04:LTS perl 0 5.22.1-9ubuntu0.3
openSUSE:Leap 15.3 perl 0 5.26.1-150300.17.11.1
openSUSE:Leap 15.4 perl 0 5.26.1-150300.17.11.1
openSUSE:Leap Micro 5.2 perl 0 5.26.1-150300.17.11.1
openSUSE:Tumbleweed perl-File-Path 0 2.180000-1.15

Related vulnerabilities