# Not able to read/write anything in appsWriteable

**URL:** <https://forum.legato.io/t/not-able-to-read-write-anything-in-appswriteable/6993>\
**Category:** Uncategorized\
**Created:** [January 27, 2026, 10:30am UTC](https://forum.legato.io/t/not-able-to-read-write-anything-in-appswriteable/6993 "2026-01-27T10:30:59Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![fsdabharati](https://avatars.discourse-cdn.com/v4/letter/f/e0b2c6/32.png) [@fsdabharati](https://forum.legato.io/u/fsdabharati)\
**Post date:** [January 27, 2026, 10:30am UTC](https://forum.legato.io/t/not-able-to-read-write-anything-in-appswriteable/6993/1 "2026-01-27T10:30:59Z")

</div>

Has anyone read/written any file in apps sandbox? I need help. I am not able to write anything in appswriteable under my app. it is showing me path is not correct. What should I do?

---

<div class="post-metadata">

**Author:** ![jyijyi](https://sea1.discourse-cdn.com/flex019/user_avatar/forum.legato.io/jyijyi/32/822_2.png) [@jyijyi](https://forum.legato.io/u/jyijyi)\
**Post date:** [January 27, 2026, 11:46am UTC](https://forum.legato.io/t/not-able-to-read-write-anything-in-appswriteable/6993/2 "2026-01-27T11:46:30Z")

</div>

Have you tried to compile by using fopen() and fwrite() to create a file inside sandboxed application?

---

<div class="post-metadata">

**Author:** ![fsdabharati](https://avatars.discourse-cdn.com/v4/letter/f/e0b2c6/32.png) [@fsdabharati](https://forum.legato.io/u/fsdabharati)\
**Post date:** [January 27, 2026, 12:19pm UTC](https://forum.legato.io/t/not-able-to-read-write-anything-in-appswriteable/6993/3 "2026-01-27T12:19:55Z")

</div>

my app name is RR

#include “legato.h”

COMPONENT\_INIT

{

LE\_INFO(“\*\* File write and read test \*\*”);

FILE \* fd;

char buf[] = “Hello Sierra…\n”;

fd = fopen (“test.txt”, “w”);

fwrite (buf, sizeof(char), sizeof(buf), fd);

fclose (fd);

fd = fopen (“test.txt”, “r”);

fread(buf, sizeof(char), sizeof(buf), fd);

LE\_INFO(“Data read from the file is ==\> %s”,buf);

fclose (fd);

}

Above code is working for me and it is creating and reading a text.txt file which is inside /legato/systems/current/appsWriteable/RR

But i want to paste my 4 private key files in app sandbox and later on encrypt them by accessing them through the app so i am not sure where exactly should I keep these files so that these are accesible through my app?

---

<div class="post-metadata">

**Author:** ![jyijyi](https://sea1.discourse-cdn.com/flex019/user_avatar/forum.legato.io/jyijyi/32/822_2.png) [@jyijyi](https://forum.legato.io/u/jyijyi)\
**Post date:** [January 27, 2026, 12:33pm UTC](https://forum.legato.io/t/not-able-to-read-write-anything-in-appswriteable/6993/4 "2026-01-27T12:33:19Z")

</div>

You can use bundle in adef file

> **[bundles - Application Definition .adef - Legato Docs](https://docs.legato.io/latest/defFilesAdef.html#defFilesAdef_bundles)**
>
> Lists additional files or directories to be copied from the build host into the app so they’re available to the app at runtime (e.g., audio files, web pages, executable scripts or programs built using some external build system). | legato™ is an open...

Here is an example to bundle audio file

> <https://github.com/legatoproject/legato-af/blob/master/apps/test/audio/audioPlaybackRec/audioPlaybackRec.adef>

After that you can use fread() to read the content

---

<div class="post-metadata">

**Author:** ![fsdabharati](https://avatars.discourse-cdn.com/v4/letter/f/e0b2c6/32.png) [@fsdabharati](https://forum.legato.io/u/fsdabharati)\
**Post date:** [January 27, 2026, 3:45pm UTC](https://forum.legato.io/t/not-able-to-read-write-anything-in-appswriteable/6993/5 "2026-01-27T15:45:11Z")

</div>

Bundle is working fine for me. but is it possible to create the folder ‘USER’ with ssh root in my app (SecStore) directory after app is flashed in mangOH yellow

like below, USER folder added after app is flashed in mangOH yellow

/legato/systems/current/appsWriteable/SecStore/\*\*USER  
\*\*

because when I create USER manually after flashing the app then my source code does not recognize this path and USER folder.

Question : when I manually create a folder in **/legato/systems/current/appsWriteable/SecStore/**  
then is it going outside sandbox and hence my app code does not find this path?

---

<div class="post-metadata">

**Author:** ![jyijyi](https://sea1.discourse-cdn.com/flex019/user_avatar/forum.legato.io/jyijyi/32/822_2.png) [@jyijyi](https://forum.legato.io/u/jyijyi)\
**Post date:** [January 27, 2026, 4:11pm UTC](https://forum.legato.io/t/not-able-to-read-write-anything-in-appswriteable/6993/6 "2026-01-27T16:11:17Z")

</div>

no, i don’t think so

for sandboxed application, probably you need to create the required folder during adef in bundle section
