Narrowing permission of extracted file 74/200074/2 accepted/tizen_5.0_unified accepted/tizen/5.0/unified/20190226.075154 accepted/tizen/unified/20190219.154045 submit/tizen/20190219.014414 submit/tizen_5.0/20190219.014427
authorSunmin Lee <sunm.lee@samsung.com>
Mon, 18 Feb 2019 01:52:49 +0000 (10:52 +0900)
committerSunmin Lee <sunm.lee@samsung.com>
Tue, 19 Feb 2019 01:35:09 +0000 (10:35 +0900)
Change-Id: I45fc34c8aa3c3582e4f75aaa590cf6036a1e75a9
Signed-off-by: Sunmin Lee <sunm.lee@samsung.com>
packaging/libtota.spec
ss_engine/fota_tar.c

index 7699ea2e58b4cf0203d4322d86d068f1307a7c2e..9e8abcd5a591bd27afc973934ac6191fe098a425 100755 (executable)
@@ -1,6 +1,6 @@
 Name:          libtota
 Summary:       fota update library
-Version:       1.2.5
+Version:       1.2.6
 Release:       0
 Group:         System
 License:       Apache-2.0 and BSD-2-Clause and BSD-3-Clause and PD
index 3d073d2eecbcb7a19e5ecaa7ca6b4f68f896b7a0..d5a7a996656ea66ed85532704d03a745127785e2 100755 (executable)
@@ -1027,7 +1027,7 @@ int fast_tar_extract_file(char *tar, char *item, char *pathname, int size, int o
                close(fd);
                return -1;
        }
-       fd2 = open(pathname, O_CREAT | O_WRONLY, 0777);  // Directory where file is required should be created already.
+       fd2 = open(pathname, O_CREAT | O_WRONLY, S_IRWXU);       // Directory where file is required should be created already.
        if (fd2 < 0) {
                LOG("can't open file(%s).\n", pathname);
                SS_Free(buf);
@@ -1095,7 +1095,7 @@ int tar_extract_file(char *tar, char *item, char *pathname)
                close(fd);
                return -1;
        }
-       fd2 = open(pathname, O_CREAT | O_WRONLY, 0777);  // Directory where file is required should be created already.
+       fd2 = open(pathname, O_CREAT | O_WRONLY, S_IRWXU);       // Directory where file is required should be created already.
        if (fd2 < 0) {
                LOG("can't open file(%s).\n", pathname);
                SS_Free(buf);