pub fn write(data_dir: &Path, agent_id: &str, local_url: &str, block_id: &str)Expand description
Write (create or update) an agent entry in the shared registry.
The entry includes the writing instance’s auth_key (from
LOCAL_AUTH_KEY) so a peer performing an HTTP forward of a missed
inject can authenticate. On Unix the file is created with mode 0600
at open time (not write-then-chmod, which would briefly expose
the file at the default umask — same security boundary as the
existing authkey.dev file). On Windows, default ACLs inherit
user-only on user-owned directories.