Medium severity5.3NVD Advisory· Published Apr 4, 2017· Updated May 13, 2026
CVE-2017-0360
CVE-2017-0360
Description
file_open in Tryton 3.x and 4.x through 4.2.2 allows remote authenticated users with certain permissions to read arbitrary files via a "same root name but with a suffix" attack. NOTE: This vulnerability exists because of an incomplete fix for CVE-2016-1242.
Affected packages
Versions sourced from the GitHub Security Advisory.
| Package | Affected versions | Patched versions |
|---|---|---|
trytondPyPI | >= 3.0.0, <= 3.0.17 | — |
trytondPyPI | >= 3.2.0, <= 3.2.17 | — |
trytondPyPI | >= 3.4.0, <= 3.4.17 | — |
trytondPyPI | >= 3.6.0, <= 3.6.16 | — |
trytondPyPI | >= 3.8.0, <= 3.8.14 | — |
trytondPyPI | >= 4.0.0, <= 4.0.9 | — |
trytondPyPI | >= 4.2.0, < 4.2.3 | 4.2.3 |
Affected products
99cpe:2.3:a:tryton:tryton:3.0.0:*:*:*:*:*:*:*+ 98 more
- cpe:2.3:a:tryton:tryton:3.0.0:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.0.1:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.0.10:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.0.11:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.0.12:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.0.13:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.0.14:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.0.15:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.0.16:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.0.17:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.0.2:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.0.3:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.0.4:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.0.5:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.0.6:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.0.7:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.0.8:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.0.9:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.2.0:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.2.1:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.2.10:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.2.11:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.2.12:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.2.13:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.2.14:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.2.15:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.2.16:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.2.17:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.2.2:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.2.3:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.2.4:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.2.5:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.2.6:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.2.7:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.2.8:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.2.9:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.4.0:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.4.1:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.4.10:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.4.11:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.4.12:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.4.13:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.4.14:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.4.15:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.4.16:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.4.17:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.4.2:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.4.3:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.4.4:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.4.5:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.4.6:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.4.7:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.4.8:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.4.9:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.6.0:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.6.1:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.6.10:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.6.11:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.6.12:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.6.13:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.6.14:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.6.15:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.6.16:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.6.2:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.6.3:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.6.4:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.6.5:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.6.6:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.6.7:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.6.8:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.6.9:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.8.0:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.8.1:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.8.10:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.8.11:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.8.12:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.8.13:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.8.14:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.8.2:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.8.3:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.8.4:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.8.5:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.8.6:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.8.7:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.8.8:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:3.8.9:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:4.0.0:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:4.0.1:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:4.0.2:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:4.0.3:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:4.0.4:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:4.0.5:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:4.0.6:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:4.0.7:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:4.0.8:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:4.0.9:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:4.2.0:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:4.2.1:*:*:*:*:*:*:*
- cpe:2.3:a:tryton:tryton:4.2.2:*:*:*:*:*:*:*
Patches
230e978593733Sanitize path in file_open against suffix
3 files changed · +7 −1
CHANGELOG+1 −0 modified@@ -1,3 +1,4 @@ +* Sanitize path in file_open against suffix (CVE-2017-0360) * Add constraint on user password * Remove Property field * Add MultiValueMixin and ValueMixin
trytond/tests/test_tools.py+5 −0 modified@@ -134,6 +134,11 @@ def test_file_open(self): with self.assertRaisesRegexp(IOError, "Permission denied:"): file_open('../../foo') + def test_file_open_suffix(self): + "Test file_open from same root name but with a suffix" + with self.assertRaisesRegexp(IOError, "Permission denied:"): + file_open('../trytond_suffix', subdir=None) + def suite(): func = unittest.TestLoader().loadTestsFromTestCase
trytond/tools/misc.py+1 −1 modified@@ -32,7 +32,7 @@ def secure_join(root, *paths): "Join paths and ensure it still below root" path = os.path.join(root, *paths) path = os.path.normpath(path) - if not path.startswith(root): + if not path.startswith(os.path.join(root, '')): raise IOError("Permission denied: %s" % name) return path
a67a7f03c302Sanitize path in file_open against suffix
3 files changed · +8 −1
CHANGELOG+2 −0 modified@@ -1,3 +1,5 @@ +* Sanitize path in file_open against suffix (CVE-2017-0360) + Version 4.2.2 - 2017-03-10 * Bug fixes (see mercurial logs for details)
trytond/tests/test_tools.py+5 −0 modified@@ -128,6 +128,11 @@ def test_file_open(self): with self.assertRaisesRegexp(IOError, "Permission denied:"): file_open('../../foo') + def test_file_open_suffix(self): + "Test file_open from same root name but with a suffix" + with self.assertRaisesRegexp(IOError, "Permission denied:"): + file_open('../trytond_suffix', subdir=None) + def suite(): func = unittest.TestLoader().loadTestsFromTestCase
trytond/tools/misc.py+1 −1 modified@@ -32,7 +32,7 @@ def secure_join(root, *paths): "Join paths and ensure it still below root" path = os.path.join(root, *paths) path = os.path.normpath(path) - if not path.startswith(root): + if not path.startswith(os.path.join(root, '')): raise IOError("Permission denied: %s" % name) return path
Vulnerability mechanics
Generated by null/stub on May 9, 2026. Inputs: CWE entries + fix-commit diffs from this CVE's patches. Citations validated against bundle.
References
10- www.securityfocus.com/bid/97489nvdThird Party AdvisoryVDB Entry
- github.com/advisories/GHSA-7cwg-2575-3546ghsaADVISORY
- lists.debian.org/debian-security-announce/2017/msg00084.htmlnvdThird Party AdvisoryWEB
- nvd.nist.gov/vuln/detail/CVE-2017-0360ghsaADVISORY
- hg.tryton.org/trytondghsaWEB
- www.debian.org/security/2017/dsa-3826nvdWEB
- github.com/pypa/advisory-database/tree/main/vulns/trytond/PYSEC-2017-97.yamlghsaWEB
- github.com/tryton/trytond/commit/30e978593733385db3144f8c583eeb4679575cf0ghsaWEB
- github.com/tryton/trytond/commit/a67a7f03c30277515f530cad5950056171ed5bd1ghsaWEB
- hg.tryton.org/trytondnvd
News mentions
0No linked articles in our index yet.