mirror of
https://github.com/scratchfoundation/scratchjr.git
synced 2025-07-02 16:10:25 -04:00
android: continue to SecurityException
This commit is contained in:
parent
7dadc706d0
commit
56cc06bded
1 changed files with 1 additions and 1 deletions
|
@ -195,7 +195,7 @@ public class ScratchJrUtil {
|
||||||
// we need to confirm it will only extract to the expected folder.
|
// we need to confirm it will only extract to the expected folder.
|
||||||
// For more details see https://support.google.com/faqs/answer/9294009
|
// For more details see https://support.google.com/faqs/answer/9294009
|
||||||
if (!unzipFile.getCanonicalPath().startsWith(toPath)) {
|
if (!unzipFile.getCanonicalPath().startsWith(toPath)) {
|
||||||
continue;
|
throw new SecurityException("Unsafe file path found and unzipping will not be allowed for security purposes.");
|
||||||
}
|
}
|
||||||
if (ze.isDirectory()) {
|
if (ze.isDirectory()) {
|
||||||
if(!unzipFile.isDirectory()) {
|
if(!unzipFile.isDirectory()) {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue