agent: use standard socket when available