Skip to content

Applied hash functions commitments #55

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 4 commits into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions applied-hash/commitments/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
ltxobj/
notes.pdf
slides.pdf
bibsp.sty
crypto.bib

37 changes: 37 additions & 0 deletions applied-hash/commitments/Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
.PHONY: all
all: notes.pdf slides.pdf

LATEXFLAGS+= -shell-escape

SRC+= preamble.tex
SRC+= abstract.tex contents.tex

DEPENDS+= bibsp.sty
DEPENDS+= crypto.bib

FIGS+=

notes.pdf: notes.tex
notes.pdf: ${SRC} ${DEPENDS} $(addprefix fig/,${FIGS})

slides.pdf: slides.tex
slides.pdf: ${SRC} ${DEPENDS} $(addprefix fig/,${FIGS})


$(addprefix fig/, ${FIGS}):
${MAKE} -C $(dir $@) $(notdir $@)


.PHONY: clean
clean:
${RM} notes.pdf slides.pdf

.PHONY: distclean
distclean:
${MAKE} -C fig clean


INCLUDE_MAKEFILES=../../makefiles
include ${INCLUDE_MAKEFILES}/tex.mk
INCLUDE_BIBSP=../../bibsp
include ${INCLUDE_BIBSP}/bibsp.mk
22 changes: 22 additions & 0 deletions applied-hash/commitments/abstract.tex
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
% What's the problem?
% Why is it a problem? Research gap left by other approaches?
% Why is it important? Why care?
% What's the approach? How to solve the problem?
% What's the findings? How was it evaluated, what are the results, limitations,
% what remains to be done?

% XXX Summary
\emph{Summary:}
\dots

% XXX Motivation and intended learning outcomes
\emph{Intended learning outcomes:}
\dots

% XXX Prerequisites
\emph{Prerequisites:}
\dots

% XXX Reading material
\emph{Reading:}
\dots
49 changes: 49 additions & 0 deletions applied-hash/commitments/contents.tex
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
\mode*

\section[Hash functions]{What was a hash function now again?}

\begin{frame}
\begin{definition}[One-way function\footfullcite{GoldreichFOC-1}]
\begin{itemize}
\item Let \(h\colon \{0,1\}^*\to \{0,1\}^*\).
\item \(h\) is \emph{one-way} if
\begin{enumerate}
\item there exists an efficient algorithm \(A\) such that \(A(x)
= h(x)\);
\item for every efficient algorithm \(A^\prime\), every positive
polynomial \(p(\cdot)\) and all sufficiently large \(n\)'s
\[\Prob{A^\prime(h(x), 1^n) \in h^{-1}(h(x))} < \frac{1}{p(n)}\]
\end{enumerate}
\end{itemize}
\end{definition}
\end{frame}

\begin{frame}
\begin{definition}[Preimage resistance (one way)]
\begin{description}
\item[Input] hash function~\(H\), value~\(y\).
\item[Output] Any \(x\) such that \(H(x) = y\).
\end{description}
\end{definition}

\begin{definition}[Second preimage resistance (weak collision resistance)]
\begin{description}
\item[Input] hash function~\(H\), value \(x\).
\item[Output] Any value \(x'\) such that \(H(x) = H(x')\).
\end{description}
\end{definition}

\begin{definition}[Collision resistance (strong collision resistance)]
\begin{description}
\item[Input] hash function~\(H\).
\item[Output] Any two \(x, x'\) such that \(H(x) = H(x')\).
\end{description}
\end{definition}
\end{frame}


\section{Commitments}


\section{Keyed hash functions}

11 changes: 11 additions & 0 deletions applied-hash/commitments/fig/Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
.PHONY: all
all:


.PHONY: clean
clean:
true


INCLUDE_MAKEFILES=../../../makefiles
include ${INCLUDE_MAKEFILES}/doc.mk
45 changes: 45 additions & 0 deletions applied-hash/commitments/notes.tex
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
\documentclass{article}

\usepackage[hyphens]{url}
\usepackage[hidelinks]{hyperref}

\input{preamble.tex}

\usepackage[noamsthm,notheorems]{beamerarticle}
\setjobnamebeamerversion{slides}

%\usepackage{authblk}
%\let\institute\affil

\declaretheorem[numbered=unless unique,style=theorem]{theorem}
\declaretheorem[numbered=unless unique,style=definition]{definition}
\declaretheorem[numbered=unless unique,style=definition]{assumption}
\declaretheorem[numbered=unless unique,style=definition]{protocol}
\declaretheorem[numbered=unless unique,style=example]{example}
%\declaretheorem[style=definition,numbered=unless unique,
% name=Example,refname={example,examples}]{example}
\declaretheorem[numbered=unless unique,style=remark]{remark}
\declaretheorem[numbered=unless unique,style=remark]{idea}
\declaretheorem[numbered=unless unique,style=exercise]{exercise}
\declaretheorem[numbered=unless unique,style=exercise]{question}
\declaretheorem[numbered=unless unique,style=solution]{solution}

\begin{document}
\title{%
Applied Hash Functions: Commitments
}
\author{Daniel Bosk}
\institute{%
KTH EECS
}

\maketitle

\begin{abstract}
\input{abstract.tex}
\end{abstract}

\input{contents.tex}

\printbibliography
\end{document}
39 changes: 39 additions & 0 deletions applied-hash/commitments/preamble.tex
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage[british]{babel}
\usepackage{booktabs}

\usepackage[all]{foreign}
\renewcommand{\foreignfullfont}{}
\renewcommand{\foreignabbrfont}{}

\usepackage{newclude}
\usepackage{import}

\usepackage[strict]{csquotes}
\usepackage[single]{acro}

\usepackage[natbib,style=alphabetic,maxbibnames=99]{biblatex}
\addbibresource{crypto.bib}

\usepackage{subcaption}

\usepackage[noend]{algpseudocode}
\usepackage{xparse}

\let\email\texttt

\usepackage[outputdir=ltxobj]{minted}
\setminted{autogobble,fontsize=\footnotesize}

\usepackage{amsmath}
\usepackage{amssymb}
\usepackage{mathtools}
\usepackage{amsthm}
\usepackage{thmtools}
\usepackage[unq]{unique}
\DeclareMathOperator{\powerset}{\mathcal{P}}

\usepackage[binary-units]{siunitx}

\usepackage{bibsp}
118 changes: 118 additions & 0 deletions applied-hash/commitments/slides.tex
Original file line number Diff line number Diff line change
@@ -0,0 +1,118 @@
\documentclass[ignoreframetext]{beamer}
\input{preamble.tex}

\usetheme{Berlin}
\setbeamertemplate{footline}%{miniframes theme}
{%
\begin{beamercolorbox}[colsep=1.5pt]{upper separation line foot}
\end{beamercolorbox}
\begin{beamercolorbox}[ht=2.5ex,dp=1.125ex,%
leftskip=.3cm,rightskip=.3cm plus1fil]{author in head/foot}%
\leavevmode{\usebeamerfont{author in head/foot}\insertshortauthor}%
\hfill%
{\usebeamerfont{institute in head/foot}\usebeamercolor[fg]{institute in head/foot}\insertshortinstitute}%
\end{beamercolorbox}%
\begin{beamercolorbox}[ht=2.5ex,dp=1.125ex,%
leftskip=.3cm,rightskip=.3cm plus1fil]{title in head/foot}%
{\usebeamerfont{title in head/foot}\insertshorttitle} \hfill \insertframenumber%
\end{beamercolorbox}%
\begin{beamercolorbox}[colsep=1.5pt]{lower separation line foot}
\end{beamercolorbox}
}
\setbeamercovered{transparent}
\setbeamertemplate{bibliography item}[text]

\AtBeginSection[]{%
\begin{frame}<beamer>
\tableofcontents[currentsection]
\end{frame}
}

\ProvideDocumentEnvironment{assumption}{o}{%
\IfValueTF{#1}{%
\begin{block}{Assumption: #1}
}{%
\begin{block}{Assumption}
}
}{%
\end{block}
}

\ProvideDocumentEnvironment{protocol}{o}{%
\IfValueTF{#1}{%
\begin{block}{Protocol: #1}
}{%
\begin{block}{Protocol}
}
}{%
\end{block}
}

\ProvideDocumentEnvironment{remark}{o}{%
\IfValueTF{#1}{%
\begin{alertblock}{Note: #1}
}{%
\begin{alertblock}{Note}
}
}{%
\end{alertblock}
}

\ProvideDocumentEnvironment{idea}{o}{%
\IfValueTF{#1}{%
\begin{block}{Idea: #1}
}{%
\begin{block}{Idea}
}
}{%
\end{block}
}

\ProvideDocumentEnvironment{question}{o}{%
\setbeamercolor{block body}{bg=orange!15,fg=black}
\setbeamercolor{block title}{bg=orange,fg=white}
\setbeamercolor{local structure}{fg=orange}
\IfValueTF{#1}{%
\begin{block}{Question: #1}
}{%
\begin{block}{Question}
}
}{%
\end{block}
}

\ProvideDocumentEnvironment{exercise}{o}{%
\setbeamercolor{block body}{bg=yellow!10,fg=black}
\setbeamercolor{block title}{bg=yellow,fg=black}
\setbeamercolor{local structure}{fg=yellow}
\IfValueTF{#1}{%
\begin{block}{Exercise: #1}
}{%
\begin{block}{Exercise}
}
}{%
\end{block}
}


\begin{document}
\title{%
Applied Hash Functions: Commitments
}
\author{Daniel Bosk}
\institute{%
KTH EECS
}

\begin{frame}
\maketitle
\end{frame}

\mode<all>
\input{contents.tex}
\mode*

\begin{frame}[allowframebreaks]
\printbibliography
\end{frame}
\end{document}