Popen in sandboxed app



I’m willing to make a system call from my legato application using popen().

What I don’t understand is that as soon as I put sandboxed to true, my popen() call doesn’t return anything. If I put it to false, I will either have the correct return of my command or a sh: /bin/notACommand: No such file or directory if I put a command which doesn’t exist.

I understand that in order to use echo for instance in a sandbox I’d need to declare the files in my adef file like the following (note that it didn’t work in sandbox either though):

		/bin/echo							/usr/local/bin/

But I would expect at least to have an error if the command cannot be found. Did I miss something here?

Thanks for your help,


Hi Ben,
Please try add below in the requires: file: section to run as sandbox:

/bin/sh /bin/sh



Hi lotam, thanks for your answer.

I had to move out from this solution anyway but it really looks like the problem comes from not having sh indeed, I’ll give it a go when I have a chance.

Thanks again,
Best regards,