#include "storage-external.h"
#define BLOCK_CONF_FILE "/etc/storaged/block.conf"
+#define USER_UID_START 5000
+
const char *dir_path[STORAGE_DIRECTORY_MAX];
const int tz_id[STORAGE_DIRECTORY_MAX] = {
return STORAGE_ERROR_INVALID_PARAMETER;
}
+ if (storage_id == STORAGE_TYPE_INTERNAL && getuid() < USER_UID_START) {
+ _E("Only Tizen applications and user session daemons can use \
+ storage_get_root_directory(STORAGE_TYPE_INTERNAL, ...)");
+ return STORAGE_ERROR_INVALID_PARAMETER;
+ }
+
/* internal storage */
DD_LIST_FOREACH(st_int_head, elem, st) {
if (st->storage_id != storage_id)