2

In UC, consider the protocol ρ^φ, which uses the protocol φ 'as a subroutine'. If I understand correctly, ρ would call φ with arguments, which would then perform computations, perhaps even calling its own sub-sub-protocols, and would finally return the result to ρ, which continues execution.

As far as I can understand, it is not possible for φ to 'callback' ρ when it is executing. On the other hand, in typical programming languages, this is possible. A simple example that I'm thinking about would be something like a C function with signature void (char* result), where result is an array that the 'called' function would populate.

I was wondering if UC has a way to deal with this? Or is it out of scope?

Suraaj K S
  • 232
  • 1
  • 7

1 Answers1

0

I think UC does not allow the callback function, or not yet.

If we want to define this kind of callback function in a protocol/functionality (for your example, $\rho^\varphi$, $\rho$ is the caller, and $\varphi$ returns the callback), we can define the corresponding functionality in $\rho$ and reject any data that does not conform to the format since we usually do not want our cryptographic protocol to behave arbitrarily, especially when the env is adversarial. Just like @poncho's comment, a callback function is also not necessary. In addition, how does $\rho$ assert if a callback is proper or not? I think a function is too expressive to be considered in a callback way.

Anyway, because the caller needs to run the ``callback'', we'd better define the functionality in the caller directly, not via a roundabout.

Haotian Yin
  • 174
  • 8