fix TOCTOU Issue by fixing access to path check 61/256461/2
authordyamy-lee <dyamy.lee@samsung.com>
Sun, 28 Mar 2021 23:58:21 +0000 (08:58 +0900)
committerdyamy-lee <dyamy.lee@samsung.com>
Fri, 11 Jun 2021 01:18:53 +0000 (10:18 +0900)
commitf25242e5bf907a5b54338834a2c7d7001817598c
treed55a2a6f15ff1d09402d99926d7e2af6421aeb5c
parente3664d8e0d799b7d127cf8f54bb9ac370e3e7dc9
fix TOCTOU Issue by fixing access to path check

Calling function 'fopen' after check function like 'access' which perform
check on path can cause a time-of-check, time-of-use race condition.
For resolving this, remove 'access' and
just print error message of fopen() fail with errno.

Change-Id: I46b4639815b52fef1548209d703cf40d9ee6920b
base/base_gui_direct.h
fota_gui_common/fota_gr_direct_ro_common.c
fota_gui_wearable/fota_gr_direct_ro_wearable.c
recovery_gui_common/recovery_gr_direct_common.c
rw-update-ani-common/fota_gr_direct_rw_common.c
rw-update-ani-wearable/rw-update_new_fb_cairo.c