Optional safety
A TouchDesigner project runs Python, and a partner's edits run on your machine. Among people who trust each other that is fine. For a workshop, a public jam or a first session with someone new, the host can switch on two rules: one keeps components out, the other holds code back until the host has looked at it. Both are off by default, both are on the Host page of the TDXCollab COMP, and they count for everyone in the session. Partners see which are on in the Status line and the People heading of the TDXCollab window, and the status bar tells them when they join and whenever the host switches one.
Vanilla: only TouchDesigner's own COMPs
- What passes: a COMP as the OP Create dialog makes it (an empty Base or Container, a Geometry COMP with its torus), a copy of a COMP built in the zone (copy and paste, cut and paste, undo), and annotations.
- What is taken out: palette components,
.toxfiles dropped in, locked components, and any other COMP that arrives with contents or custom parameters. It is removed again on the side that placed it, before anything is sent, and the status bar says why. There is no review for these: a COMP only one side has would split the zone. - COMPs already in the zone when Vanilla goes on stay, and copies of them pass.
No Scripts: Python stays with whoever wrote it
No Scripts holds back two kinds of Python.
- Operators with Python of their own stay on the machine that made them, tagged
TDXCollab:script: Execute DATs of every kind (Execute, CHOP, DAT, OP, Parameter and Panel Execute), Evaluate DATs, COMPs with an extension, and locked components.- An Evaluate DAT's code is not in its own text: it is its Expression parameter and the cells of the DATs it reads (its input, its Input Data DAT and its Expressions DAT). Review shows each of them, and an approval covers them all: change the Expression, point it at another DAT or edit a cell it reads, and it is held again until the host approves it.
- Code inside an operator that syncs stays home while the operator syncs:
- the callbacks DAT of a Timer CHOP, Text COMP, Script operator, Web Server DAT and the like (partners get TouchDesigner's template);
- an expression or bind that runs code:
run(),mod.,exec,eval,import,getattrand the like. Plain expressions such asabsTime.frame * 0.1sync as before.
Each side also cleans what arrives before any of it can run: a COMP or a whole zone from a partner
is opened in TouchDesigner's /sys/quiet, where nothing cooks, and what does not pass is taken out.
- TouchDesigner's own internals pass (an annotation's, a Button's) while they are exactly as TouchDesigner makes them. Change any of it and that COMP is held too.
- Switched on, what the zone already holds counts as approved and keeps syncing. Only what is new or changes afterwards is held.
- Text and Table DATs still sync. They run nothing by themselves, and whatever could run them is held.
Review: the host decides
Whatever No Scripts holds back goes to the host.
- A pop-up names who wants to add what. Its Review button opens the Review window, and so does Review… on any row of Review in the TDXCollab window (the left click on the menu bar chip).
- The Review window lists everything waiting on the left: what it is, who sent it, and a
mark for the worst flag found in it (see below). On the right is the one you pick, read-only
and highlighted as Python, GLSL or whatever language it is in:
- a script, a callbacks text or an expression as it is;
- a COMP as an Overview of its operators and every parameter that holds code, and each of its DATs on its own: pick one with Part or step through them with the arrows.
- Approve lets it go to everyone exactly as it is. If it changes later, it comes back for review.
- Reject keeps it on its maker's side. Their own Review list says the host kept it out.
- Later closes the window; everything stays waiting.
- Partners see what they hold and whether it is waiting or kept out.
Flags: what the code reaches
Before you read a line, the host's TDXCollab scans everything under review for code that reaches outside TouchDesigner or hides what it does. Each flag names the line, what was found and why it matters.
| Level | What it means | For example |
|---|---|---|
| Danger | It can change your machine, your files or your project, or it hides code | os.system, subprocess, deleting or writing files, project.save (the prank that saved a copy of a partner's project under another name), quitting, creating or destroying operators, run(), exec or eval with code in it, imports by name, decoded code, changing a module for everyone (sys.modules, SomeModule.x = ...), naming TDXCollab, naming a private place (.ssh, .env, AppData, ~/.tdxcollab), uploading a file |
| Caution | Worth a look before approving | importing os, socket or requests, network calls, file dialogs, saving an operator to a file, names built at run time, Python's internals, reading a file, reaching outside the zone (op('/...'), op('../...'), root, a global OP Shortcut, parent() climbing two networks or more), your clipboard, environment, preferences or undo history, time.sleep, input(), while True with no break, making an operator that sends data off the machine or writes files, pointing one at an address |
| Info | Usually harmless | listing a folder, decoding data, a parent shortcut or iop found by searching up, another component's extension, moving your network editors |
The scan follows the usual disguises: another name for the same thing (p = project,
from os import system as s), getattr with the name written out, and decoded or pieced-together
text fed to exec. A parameter's own .eval(), which every TouchDesigner script uses to read a
value, is not flagged. It reads names, it does not run anything, and it cannot prove code
harmless: no flag means nothing it knows was found, not that the code is safe. A partner cannot
send flags of their own: only your scan counts.
Approvals are saved with the zone. Only the host's count: a partner's copy of the Keep Local table and a partner's zone the host takes bring none. Deleting an approval by hand (Open Table) holds that item again on every side until it is approved again.
What these do not catch
- They are not a sandbox. The No Scripts expression check reads text:
op('/').destroy()orproject.save()in an expression passes it (the review's flags would name both, but only for what is under review), and a determined person can disguise a call well enough to get past the flags too. - A Full Edit partner can still change your network in every other way. Who you let in, and with what role, stays the first protection: see Sessions and roles.
- Scripts already in the zone keep running on the machines that had them before the switch.
- A partner on an older TDXCollab holds nothing back on their side. Yours still cleans what they send.
- A locked component is approved by its saved bytes. If they change with every save, it cannot be approved.
The switches themselves are listed with the rest on the Parameters page.