Skip to content

Commit fa6ba9f

Browse files
committed
see 05/07 log
1 parent f643559 commit fa6ba9f

File tree

8 files changed

+19
-8
lines changed

8 files changed

+19
-8
lines changed

README-CN.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@
4141

4242
[logo]: https://raw.githubusercontent.com/Blankj/AndroidUtilCode/master/art/logo.png
4343

44-
[aucsvg]: https://img.shields.io/badge/AndroidUtilCode-v1.14.3-brightgreen.svg
44+
[aucsvg]: https://img.shields.io/badge/AndroidUtilCode-v1.14.4-brightgreen.svg
4545
[auc]: https://github.com/Blankj/AndroidUtilCode
4646

4747
[apisvg]: https://img.shields.io/badge/API-14+-brightgreen.svg

README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ If this project helps you a lot and you want to support the project's developmen
4141

4242
[logo]: https://raw.githubusercontent.com/Blankj/AndroidUtilCode/master/art/logo.png
4343

44-
[aucsvg]: https://img.shields.io/badge/AndroidUtilCode-v1.14.3-brightgreen.svg
44+
[aucsvg]: https://img.shields.io/badge/AndroidUtilCode-v1.14.4-brightgreen.svg
4545
[auc]: https://github.com/Blankj/AndroidUtilCode
4646

4747
[apisvg]: https://img.shields.io/badge/API-14+-brightgreen.svg

app/build.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ dependencies {
5656
// LeakCanary
5757
debugImplementation "com.squareup.leakcanary:leakcanary-android:$leakcanary_version"
5858
releaseImplementation "com.squareup.leakcanary:leakcanary-android-no-op:$leakcanary_version"
59-
// implementation 'com.blankj:utilcode:1.14.3'
59+
// implementation 'com.blankj:utilcode:1.14.4'
6060
}
6161

6262

build.gradle

+3-3
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ buildscript {
77
dependencies {
88
classpath 'com.android.tools.build:gradle:3.1.2'
99
classpath 'com.github.dcendents:android-maven-gradle-plugin:1.5'
10-
classpath 'com.jfrog.bintray.gradle:gradle-bintray-plugin:1.7.3'
10+
classpath 'com.jfrog.bintray.gradle:gradle-bintray-plugin:1.8.0'
1111

1212
classpath "tech.harmonysoft:traute-gradle:1.1.8"
1313
// NOTE: Do not place your application dependencies here; they belong
@@ -44,8 +44,8 @@ ext {
4444
min_sdk_version = 14
4545
target_sdk_version = 27
4646

47-
version_code = 1_014_003
48-
version_name = '1.14.3'// E.g 1.9.72 => 1,009,072
47+
version_code = 1_014_004
48+
version_name = '1.14.4'// E.g 1.9.72 => 1,009,072
4949

5050
// App dependencies
5151
support_version = '27.1.0'

update_log.md

+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
* 18/05/07 修复 ZipUtils 漏洞,发布 1.14.4 版本
12
* 18/05/03 修复 ToastUtils 默认字体大小问题,发布 1.14.3 版本
23
* 18/05/02 修复 PermissionUtils 空异常,发布 1.14.2 版本
34
* 18/04/28 新增 FlashlightUtils,发布 1.14.1 版本

utilcode/README-CN.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
Gradle:
44
```groovy
5-
implementation 'com.blankj:utilcode:1.14.3'
5+
implementation 'com.blankj:utilcode:1.14.4'
66
```
77

88

utilcode/README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
Gradle:
44
```groovy
5-
implementation 'com.blankj:utilcode:1.14.3'
5+
implementation 'com.blankj:utilcode:1.14.4'
66
```
77

88

utilcode/src/main/java/com/blankj/utilcode/util/ZipUtils.java

+10
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
package com.blankj.utilcode.util;
22

3+
import android.util.Log;
4+
35
import java.io.BufferedInputStream;
46
import java.io.BufferedOutputStream;
57
import java.io.File;
@@ -291,12 +293,20 @@ public static List<File> unzipFileByKeyword(final File zipFile,
291293
while (entries.hasMoreElements()) {
292294
ZipEntry entry = ((ZipEntry) entries.nextElement());
293295
String entryName = entry.getName();
296+
if (entryName.startsWith("../")) {
297+
Log.e("ZipUtils", "it's dangerous!");
298+
return files;
299+
}
294300
if (!unzipChildFile(destDir, files, zf, entry, entryName)) return files;
295301
}
296302
} else {
297303
while (entries.hasMoreElements()) {
298304
ZipEntry entry = ((ZipEntry) entries.nextElement());
299305
String entryName = entry.getName();
306+
if (entryName.startsWith("../")) {
307+
Log.e("ZipUtils", "it's dangerous!");
308+
return files;
309+
}
300310
if (entryName.contains(keyword)) {
301311
if (!unzipChildFile(destDir, files, zf, entry, entryName)) return files;
302312
}

0 commit comments

Comments
 (0)