An even simpler solution might be to make sure that any files in squashfs that are not owned by root are owned by tc.
Are there rare instances where files/directories in an extension are meant to be owned by a user other than root or tc (e.g., virtual users such as lp)? If so, then this naive approach won't work.
Yes! This is also the solution I applied to my personal TCZs: user=tc, group=staff.
Basically we mount in /tmp/tcloop, but the links are in /usr/bin , owner by root:root.
we could patch on the fly tc_UID and staff_GID in /etc/ (passwd, groups); because the cpio/ tar /gz use only ids but not real names. (seen from win10 with 7zip).
EDIT: even better, if you want to be sure that ONLY tc-UID use the appl, then you create a fake group GID, and all files in squash are owner by: tc:fake. Why you want to allow other not invited "users" to use your app in your system?