![如何在乳胶中制定协议?](https://linux22.com/image/368140/%E5%A6%82%E4%BD%95%E5%9C%A8%E4%B9%B3%E8%83%B6%E4%B8%AD%E5%88%B6%E5%AE%9A%E5%8D%8F%E8%AE%AE%EF%BC%9F.png)
答案1
这是一个起点 - 在tabularx
,包裹在protocol
环境中:
\documentclass{article}
\usepackage{tabularx}
\newcounter{protocol}
\newenvironment{protocol}[1]
{\par\addvspace{\topsep}
\noindent
\tabularx{\linewidth}{@{} X @{}}
\hline
\refstepcounter{protocol}\textbf{Protocol \theprotocol} #1 \\
\hline}
{ \\
\hline
\endtabularx
\par\addvspace{\topsep}}
\newcommand{\sbline}{\\[.5\normalbaselineskip]}% small blank line
\begin{document}
\begin{protocol}{Secure Multi-Party Shuffling Scheme}
\textit{Inputs.} For all $i \in [n]$, party~$P_i$ holds an input~$x_i$.
Let~$C$ denote the probabilistic sorting network of~[LP90] and~$d$ denote its depth.
\sbline
\textit{Goal.} Parties jointly compute a random shuffle of their inputs.
\sbline
\textit{The protocol:}
\begin{enumerate}
\item \textbf{Setup.}
\begin{enumerate}
\item
Parties run \textsf{Build-Quorums} to agree on $n$ quorums $Q_1, \ldots, Q_n$.
\item
Parties in $Q_1$ run \textsf{Gen-Rand} and \textsf{VSS-Reconst} repeatedly to generate
a sequence~$R$ of $\Theta(\log^2 n)$ random bits.
\item
Parties in $Q_1$ send $R$ to all other quorums in the following way. For all $i \in \{2, \ldots, n\}$, parties
in~$Q_i$ receive~$R$ from $Q_{\lfloor i/2 \rfloor}$, and then send it to all parties in~$Q_{2i}$ and $Q_{2i+1}$.
\item
For all $i \in [n]$ and $j \in [m]$, parties assign~$Q_i$ to~$P_i$ and $Q_{(j \textrm{mod} n)}$
to the $j$-th gate of~$C$, and connect the gates based on the random butterfly tournament described in~[LP90] and the
random sequence~$R$.
\end{enumerate}
\end{enumerate}
\end{protocol}
\end{document}
来源:安全多方混洗