File tree Expand file tree Collapse file tree 2 files changed +9
-1
lines changed
app/src/main/kotlin/org/fossify/filemanager/activities Expand file tree Collapse file tree 2 files changed +9
-1
lines changed Original file line number Diff line number Diff line change @@ -7,6 +7,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
77
88## [ Unreleased]
99
10+ ### Fixed
11+
12+ - Preserve modified date when unzip files ([ #176 ] )
13+
1014## [ 1.1.0] - 2025-05-21
1115
1216### Added
@@ -66,3 +70,4 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
6670[ #120 ] : https://github.com/FossifyOrg/File-Manager/issues/120
6771[ #149 ] : https://github.com/FossifyOrg/File-Manager/issues/149
6872[ #150 ] : https://github.com/FossifyOrg/File-Manager/issues/150
73+ [ #176 ] : https://github.com/FossifyOrg/File-Manager/issues/176
Original file line number Diff line number Diff line change @@ -171,7 +171,9 @@ class DecompressActivity : SimpleActivity() {
171171 continue
172172 }
173173
174- val isVulnerableForZipPathTraversal = ! File (newPath).canonicalPath.startsWith(parent)
174+ val outputFile = File (newPath)
175+
176+ val isVulnerableForZipPathTraversal = ! outputFile.canonicalPath.startsWith(parent)
175177 if (isVulnerableForZipPathTraversal) {
176178 continue
177179 }
@@ -187,6 +189,7 @@ class DecompressActivity : SimpleActivity() {
187189 fos!! .write(buffer, 0 , count)
188190 }
189191 fos!! .close()
192+ outputFile.setLastModified(entry.lastModifiedTimeEpoch)
190193 }
191194
192195 toast(R .string.decompression_successful)
You can’t perform that action at this time.
0 commit comments