Problems replication task ssh

Hi there,

I ran into a problem with the replication task on 24.04. I tunnel via wireguard in another network and execute a replication task. SSH connection works, I can see the datasets and pools on the remote drive. The remote user is admin (builtin_administrator, root groups set), has a writable home directory (for whatever that is needed) and can execute sudo commands. I have further set the " Use Sudo For ZFS Commands" option.

I get the error:

  File "/usr/lib/python3/dist-packages/middlewared/plugins/zettarepl.py", line 401, in run_replication_task
    self._run_replication_task_job(f"task_{id_}", job)
  File "/usr/lib/python3/dist-packages/middlewared/plugins/zettarepl.py", line 461, in _run_replication_task_job
    raise CallError(make_sentence(message.error))
middlewared.service_exception.CallError: [EFAULT] sudo: a terminal is required to read the password; either use the -S option to read from standard input or configure an askpass helper
sudo: a password is required.

Is anyone having a smart idea on how to fix this?