mirror of https://github.com/zcash/zips.git
Generalize Pedersen hash spec to make chunks per segment variable.
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
This commit is contained in:
parent
0325aa2fd6
commit
99ad9689e9
|
@ -3657,19 +3657,22 @@ Let $\ExtractJ$ be as defined in \crossref{concreteextractorjubjub}.
|
||||||
|
|
||||||
Let $\FindGroupJHash$ be as defined in \crossref{concretegrouphashjubjub}.
|
Let $\FindGroupJHash$ be as defined in \crossref{concretegrouphashjubjub}.
|
||||||
|
|
||||||
|
Let $c = 63$.
|
||||||
|
|
||||||
\newsavebox{\gencountbox}
|
\newsavebox{\gencountbox}
|
||||||
\begin{lrbox}{\gencountbox}
|
\begin{lrbox}{\gencountbox}
|
||||||
\begin{bytefield}[bitwidth=0.28em]{32}
|
\begin{bytefield}[bitwidth=0.28em]{32}
|
||||||
\bitbox{32}{$32$-bit $\floor{\frac{i-1}{61}}$}
|
\bitbox{32}{$32$-bit $\floor{\frac{i-1}{c}}$}
|
||||||
\end{bytefield}
|
\end{bytefield}
|
||||||
\end{lrbox}
|
\end{lrbox}
|
||||||
|
|
||||||
\introlist
|
\introlist
|
||||||
|
\vspace{2ex}
|
||||||
Define $\PedersenBaseAlg, \PedersenGenAlg \typecolon \byteseq{8} \times \Nat \rightarrow \GroupJ$ by:
|
Define $\PedersenBaseAlg, \PedersenGenAlg \typecolon \byteseq{8} \times \Nat \rightarrow \GroupJ$ by:
|
||||||
|
|
||||||
\begin{tabular}{@{\hskip 2em}r@{\;}l}
|
\begin{tabular}{@{\hskip 2em}r@{\;}l}
|
||||||
$\PedersenBase{D}{i}$ &$:= \FindGroupJHash\left(D, \Justthebox{\gencountbox}\right)$ \\
|
$\PedersenBase{D}{i}$ &$:= \FindGroupJHash\left(D, \Justthebox{\gencountbox}\right)$ \\
|
||||||
$\PedersenGen{D}{i}$ &$:= \scalarmult{4 \smult ((i\!-\!1) \bmod 61)}{\PedersenBase{D}{i}}$
|
$\PedersenGen{D}{i}$ &$:= \scalarmult{4 \smult ((i\!-\!1) \bmod c)}{\PedersenBase{D}{i}}$
|
||||||
\end{tabular}
|
\end{tabular}
|
||||||
|
|
||||||
\newcommand{\si}[1]{s^{\kern 0.02em i}_{#1}}
|
\newcommand{\si}[1]{s^{\kern 0.02em i}_{#1}}
|
||||||
|
|
Loading…
Reference in New Issue