Binary file handouts/ho01.pdf has changed
--- a/handouts/ho01.tex Fri Sep 26 12:14:41 2014 +0100
+++ b/handouts/ho01.tex Mon Sep 29 17:43:35 2014 +0100
@@ -491,30 +491,33 @@
\pcode{5baa61e4c9b93f3f0682250b6cf8331b7ee68fd8}
\end{center}
-\noindent then just a lookup in the dictionary will reveal
-that the plain-text password was \pcode{password}. What is
-good about this attack is that the dictionary can be
-precompiled in the ``comfort of the hacker's home'' before an
-actual attack is launched. It just needs sufficient storage
-space, which nowadays is pretty cheap. A hacker might in this
-way not be able to crack all passwords in our database, but
-even being able to crack 50\% can be serious damage for a
-large company (because then you have to think about how to
-make users to change their old passwords---a major hassle).
-And hackers are very industrious in compiling these
-dictionaries: for example they definitely include variations
-like \pcode{passw0rd} and also include rules that cover cases
-like \pcode{passwordpassword} or \pcode{drowssap} (password
-reversed). Historically, compiling a list for a dictionary
-attack is not as simple as it might seem. At the beginning
-only ``real'' dictionaries were available (like the Oxford
-English Dictionary), but such dictionaries are not
-``optimised'' for the purpose of passwords. The first real
-hard data about actually used passwords was obtained when a
-company called RockYou ``lost'' 32 Million plain-text
-passwords. With this data of real-life passwords, dictionary
-attacks took off. Compiling such dictionaries is nowadays very
-easy with the help of off-the-shelf tools.
+\noindent then just a lookup in the dictionary will reveal that the
+plain-text password was \pcode{password}. What is good about this
+attack is that the dictionary can be precompiled in the ``comfort of
+the hacker's home'' before an actual attack is launched. It just needs
+sufficient storage space, which nowadays is pretty cheap. A hacker
+might in this way not be able to crack all passwords in our database,
+but even being able to crack 50\% can be serious damage for a large
+company (because then you have to think about how to make users to
+change their old passwords---a major hassle). And hackers are very
+industrious in compiling these dictionaries: for example they
+definitely include variations like \pcode{passw0rd} and also include
+rules that cover cases like \pcode{passwordpassword} or
+\pcode{drowssap} (password reversed).\footnote{Some entertaining rules
+ for creating effective dictionaries are described in the book
+ ``Applied Cryptography'' by Bruce Schneier (in case you can find it
+ in the library), and also in the original research literature which
+ can be accessed for free from
+ \url{http://www.klein.com/dvk/publications/passwd.pdf}.}
+Historically, compiling a list for a dictionary attack is not as
+simple as it might seem. At the beginning only ``real'' dictionaries
+were available (like the Oxford English Dictionary), but such
+dictionaries are not ``optimised'' for the purpose of passwords. The
+first real hard data about actually used passwords was obtained when a
+company called RockYou ``lost'' 32 Million plain-text passwords. With
+this data of real-life passwords, dictionary attacks took
+off. Compiling such dictionaries is nowadays very easy with the help
+of off-the-shelf tools.
These dictionary attacks can be prevented by using salts.
Remember a hacker needs to use the most likely candidates
@@ -558,15 +561,29 @@
will be associated with a different hash-value. This will
make the life harder for an attacker.
-Note another interesting point. The web-application from the
-previous section was only secure when the salt was secret. In
-the password case, this is not needed. The salt can be public
-as shown above in the Unix password file where is actually
-stored as part of the password entry. Knowing the salt does
-not give the attacker any advantage, but prevents that
-dictionaries can be precompiled. The moral is that you should
-never store passwords in plain text. Never ever.
+Note another interesting point. The web-application from the previous
+section was only secure when the salt was secret. In the password
+case, this is not needed. The salt can be public as shown above in the
+Unix password file where is actually stored as part of the password
+entry. Knowing the salt does not give the attacker any advantage, but
+prevents that dictionaries can be precompiled. While salts do not
+solve every problem, they help with protecting against dictionary
+attacks on password files. It protects people who have the same
+passwords on multiple machines. But it does not protect against a
+focused attack against a single password and also does not make poorly
+chosen passwords any better. Still the moral is that you should never
+store passwords in plain text. Never ever.\medskip
+\noindent
+If you want to know more about passwords I recommend viewing some
+youtube videos from the PasswordCon(ference) which takes place each
+year. The book by Bruce Schneier about Applied Cryptography is also
+recommendable, though quite expensive. Clearly, passwords are a
+technology that comes to the end of its usefulness, because brute
+force attacks become more and more powerful and it is unlikely that
+humans get any better in remembering (securely) longer and longer
+passwords. The big question is which technology can replace
+passwords\ldots
\end{document}
%%% Local Variables:
Binary file handouts/ho02.pdf has changed
--- a/handouts/ho02.tex Fri Sep 26 12:14:41 2014 +0100
+++ b/handouts/ho02.tex Mon Sep 29 17:43:35 2014 +0100
@@ -6,74 +6,67 @@
\section*{Handout 2 (E-Voting)}
-In security there are many counter-intuitive phenomena: for
-example I am happy (more or less) to use online banking every
-day, where if something goes wrong, I can potentially loose a
-lot of money, but I am staunchly against using electronic
-voting (lets call it e-voting for short). E-voting is an idea
-that is nowadays often promoted in order to counter low
-turnouts in elections\footnote{In my last local election where
-I was eligible to vote only 48\% of the population have cast
-their ballot. I was, I shamefully admit, one of the
-non-voters.} and generally sounds like a good idea. Right?
-Voting from the comfort of your own home, or on your mobile on
-the go, what could possibly go wrong? Even the UK's head of
-the Electoral Commission, Jenny Watson, argued in 2014 in a
-Guardian article that the UK should have e-voting. Her
-plausible argument is that 76\% of pensioners in the UK vote
-(in a general election?), but only 44\% of the under-25s. For
-which constituency politicians might therefore make more
-favourable (short-term) decisions is clear. So being not yet
+In security engineering, there are many counter-intuitive phenomena:
+for example I am happy (more or less) to use online banking every day,
+where if something goes wrong, I can potentially lose a lot of money,
+but I am staunchly against using electronic voting (lets call it
+e-voting for short). E-voting is an idea that is nowadays often
+promoted in order to counter low turnouts in elections\footnote{In my
+ last local election where I was eligible to vote only 48\% of the
+ population have cast their ballot. I was, I shamefully admit, one of
+ the non-voters.} and generally sounds like a good idea. Right?
+Voting from the comfort of your own home, or on your mobile on the go,
+what could possibly go wrong? Even the UK's head of the Electoral
+Commission, Jenny Watson, argued in 2014 in a Guardian article that
+the UK should have e-voting. Her plausible argument is that 76\% of
+pensioners in the UK vote (in a general election?), but only 44\% of
+the under-25s. For which constituency politicians might therefore make
+more favourable (short-term) decisions is clear. So being not yet
pensioner, I should be in favour of e-voting, no?
-Well, it turns out there are many things that can go wrong
-with e-voting, as I like to argue in this handout. E-voting in
-a ``secure way'' seems to be one of the things in computer
-science that are still very much unsolved. It is not on the
-scale of Turing's halting problem, which is proved that it can
-never be solved in general, but it is unsolved with current
-technology. This is not just my opinion, but
-from shared by Alex Halderman, who is the world-expert on this
-subject and from whose course on Securing Digital Democracy
-I have most of my information and inspiration. It is also
-a controversial topic in many countries:
+Well, it turns out there are many things that can go wrong with
+e-voting, as I like to argue in this handout. E-voting in a ``secure
+way'' seems to be one of the things in computer science that are still
+very much unsolved. It is not on the scale of Turing's halting
+problem, which is proved that it can never be solved in general, but
+more in the category of being unsolvable with current technology. This
+is not just my opinion, but also shared by many security researchers
+amogst them Alex Halderman, who is the world-expert on this subject
+and from whose course on Securing Digital Democracy I have most of my
+information and inspiration. It is also a controversial topic in many
+countries:
\begin{itemize}
\item The Netherlands between 1997--2006 had electronic voting
- machines, but ``hacktivists'' had found they can be
- hacked and also emitted radio signals revealing how you
- voted.
+ machines, but ``hacktivists'' had found they can be hacked to change
+ votes and also emitted radio signals revealing how you voted.
-\item Germany had used them in pilot studies, but in 2007 a
- law suit has reached the highest court and it rejected
- electronic voting on the grounds of not being
- understandable by the general public.
+\item Germany conducted pilot studies with e-voting, but in 2007 a law
+ suit has reached the highest court and it rejected e-voting on the
+ grounds of not being understandable by the general public.
-\item UK used optical scan voting systems in a few trail
- polls, but to my knowledge does not use any e-voting in
- elections.
+\item UK used optical scan voting systems in a few trail polls, but to
+ my knowledge does not use any e-voting in elections.
-\item The US used mechanical machines since the 1930s, later
- punch cards, now DREs and optical scan voting machines.
+\item The US used mechanical machines since the 1930s, later punch
+ cards, now DREs and optical scan voting machines.
\item Estonia used since 2007 the Internet for national
- elections. There were earlier pilot studies for voting
- via Internet in other countries.
+ elections. There were earlier pilot studies for voting via Internet
+ in other countries.
-\item India uses e-voting devices since at least 2003. They
- used ``keep-it-simple'' machines produced by a
- government owned company.
+\item India uses e-voting devices since at least 2003. They used
+ ``keep-it-simple'' machines produced by a government owned company.
\item South Africa used software for its tallying in the 1993
- elections (when Nelson Mandela was elected)
- and found that the tallying software was
- rigged, but they were able to tally manually.
+ elections (when Nelson Mandela was elected) and found that the
+ tallying software was rigged, but they were able to tally manually.
\end{itemize}
-The reason that e-voting is such a hard problem is that we
-have requirements about the voting process that conflict with
-each other. The five main requirements are:
+The reason that e-voting is such a hard problem is that we have
+requirements about the voting process that conflict with each
+other. The five main requirements for voting in general are:
\begin{itemize}
\item {\bf Integrity}
@@ -85,11 +78,15 @@
\item {\bf Ballot Secrecy}
\begin{itemize}
\item Nobody can find out how you voted.
- \item (Stronger) Even if you try, you cannot prove how you voted.
+ \item (Stronger) Even if you try, you cannot prove how you
+ voted. The reason is that you want to avoid vote selling as has
+ been tried, for example, by a few jokers in the recent
+ Scottish referendum.
\end{itemize}
\item {\bf Voter Authentication}
\begin{itemize}
- \item Only authorised voters can vote up to the permitted number of votes.
+ \item Only authorised voters can vote up to the permitted number of votes
+ (in order to avoid the ``vote early, vote often'').
\end{itemize}
\item {\bf Enfranchisement}
\begin{itemize}
Binary file hws/hw02.pdf has changed
--- a/hws/hw02.tex Fri Sep 26 12:14:41 2014 +0100
+++ b/hws/hw02.tex Mon Sep 29 17:43:35 2014 +0100
@@ -10,15 +10,15 @@
\begin{enumerate}
\item Voice voting is the method of casting a vote in the `open air' for everyone
present to hear. Which of the following security requirements do paper ballots
-satisfy better than voice voting? Check all that apply and give a brief explanation
+satisfy \textbf{better} than voice voting? Check all that apply and give a brief explanation
for your decision.
\begin{itemize}
-\item[$\Box$] Integrity\bigskip\bigskip
-\item[$\Box$] Enfranchisement\bigskip\bigskip
-\item[$\Box$] Ballot secrecy\bigskip\bigskip
-\item[$\Box$] Voter authentication\bigskip\bigskip
-\item[$\Box$] Availability\bigskip\bigskip
+\item[$\Box$] Integrity
+\item[$\Box$] Enfranchisement
+\item[$\Box$] Ballot secrecy
+\item[$\Box$] Voter authentication
+\item[$\Box$] Availability
\end{itemize}
@@ -29,7 +29,8 @@
that apply. Give a brief reason for each defence that mitigates chain voting attacks.
\begin{itemize}
-\item[$\Box$] Using a glass ballot box to make it clear there are no ballots in the box before the start of the election.
+\item[$\Box$] Using a glass ballot box to make it clear there are no
+ ballots in the box before the start of the election.
\item[$\Box$] Distributing ballots publicly before the election.
\item[$\Box$] Checking that a voter's ID (drivers license, passport) matches the voter.
\item[$\Box$] Each ballot has a unique ID. When a voter is given a ballot, the ID is recorded. When the voter submits his or her ballot, this ID is checked against the record.
Binary file slides/slides02.pdf has changed
--- a/slides/slides02.tex Fri Sep 26 12:14:41 2014 +0100
+++ b/slides/slides02.tex Mon Sep 29 17:43:35 2014 +0100
@@ -1,76 +1,15 @@
\documentclass[dvipsnames,14pt,t]{beamer}
-\usepackage{beamerthemeplaincu}
-\usepackage[latin1]{inputenc}
-\usepackage{mathpartir}
-\usepackage[absolute,overlay]{textpos}
-\usepackage{ifthen}
-\usepackage{tikz}
-\usepackage{pgf}
-\usepackage{calc}
-\usepackage{ulem}
-\usepackage{courier}
-\usepackage{listings}
-\renewcommand{\uline}[1]{#1}
-\usetikzlibrary{arrows}
-\usetikzlibrary{automata}
-\usetikzlibrary{shapes}
-\usetikzlibrary{shadows}Net
-\usetikzlibrary{positioning}
-\usetikzlibrary{calc}
-\usepackage{graphicx}
-
-\definecolor{javared}{rgb}{0.6,0,0} % for strings
-\definecolor{javagreen}{rgb}{0.25,0.5,0.35} % comments
-\definecolor{javapurple}{rgb}{0.5,0,0.35} % keywords
-\definecolor{javadocblue}{rgb}{0.25,0.35,0.75} % javadoc
+\usepackage{../slides}
+\usepackage{../graphics}
+\usepackage{../langs}
-\lstset{language=Java,
- basicstyle=\ttfamily,
- keywordstyle=\color{javapurple}\bfseries,
- stringstyle=\color{javagreen},
- commentstyle=\color{javagreen},
- morecomment=[s][\color{javadocblue}]{/**}{*/},
- numbers=left,
- numberstyle=\tiny\color{black},
- stepnumber=1,
- numbersep=10pt,
- tabsize=2,
- showspaces=false,
- showstringspaces=false}
+\setmonofont[Scale=.88]{Consolas}
+\newfontfamily{\consolas}{Consolas}
-\lstdefinelanguage{scala}{
- morekeywords={abstract,case,catch,class,def,%
- do,else,extends,false,final,finally,%
- for,if,implicit,import,match,mixin,%
- new,null,object,override,package,%
- private,protected,requires,return,sealed,%
- super,this,throw,trait,true,try,%
- type,val,var,while,with,yield},
- otherkeywords={=>,<-,<\%,<:,>:,\#,@},
- sensitive=true,
- morecomment=[l]{//},
- morecomment=[n]{/*}{*/},
- morestring=[b]",
- morestring=[b]',
- morestring=[b]"""
-}
-
-\lstset{language=Scala,
- basicstyle=\ttfamily,
- keywordstyle=\color{javapurple}\bfseries,
- stringstyle=\color{javagreen},
- commentstyle=\color{javagreen},
- morecomment=[s][\color{javadocblue}]{/**}{*/},
- numbers=left,
- numberstyle=\tiny\color{black},
- stepnumber=1,
- numbersep=10pt,
- tabsize=2,
- showspaces=false,
- showstringspaces=false}
+\hfuzz=220pt
% beamer stuff
-\renewcommand{\slidecaption}{APP 02, King's College London, 1 October 2013}
+\renewcommand{\slidecaption}{APP 02, King's College London}
%Bank vs Voting
%http://www.parliament.vic.gov.au/images/stories/committees/emc/2010_Election/submissions/13_VTeague_EMC_Inquiry_No.6.pdf
@@ -81,8 +20,7 @@
\begin{document}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-\mode<presentation>{
-\begin{frame}<1>[t]
+\begin{frame}[t]
\frametitle{%
\begin{tabular}{@ {}c@ {}}
\\
@@ -99,32 +37,27 @@
\end{tabular}
\end{center}
-
-\end{frame}}
+\end{frame}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-\mode<presentation>{
\begin{frame}[c]
\frametitle{\begin{tabular}{c}This Course is about\\[-2mm] ``Satan's Computer''\end{tabular}}
Ross Anderson and Roger Needham wrote:\bigskip
-\begin{tikzpicture}
-\draw (0,0) node[inner sep=2mm,fill=cream, ultra thick, draw=red, rounded corners=2mm]
-{\normalsize\color{darkgray}
-\begin{minipage}{10cm}\raggedright\small
+\begin{bubble}[10cm]
+\small
``In effect, our task is to program a computer which gives
answers which are subtly and maliciously wrong at the most
inconvenient possible moment\ldots{} we hope that the lessons
learned from programming Satan's computer may be helpful
in tackling the more common problem of programming Murphy's.''
-\end{minipage}};
-\end{tikzpicture}\\[30mm]
+\end{bubble}\\[30mm]
\only<2>{
-\begin{textblock}{11}(2,12)
+\begin{textblock}{11}(3,12)
\begin{tabular}{c}
\includegraphics[scale=0.12]{pics/ariane.jpg}\\[-2mm]
\footnotesize Murphy's computer
@@ -136,99 +69,11 @@
\end{tabular}
\end{textblock}}
-\end{frame}}
+\end{frame}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-\mode<presentation>{
-\begin{frame}[c]
-\frametitle{\Large\begin{tabular}{c}User-Tracking Without Cookies\end{tabular}}
-
-Can you track a user {\bf without}:
-
-\begin{itemize}
-\item Cookies
-\item Javascript
-\item LocalStorage/SessionStorage/GlobalStorage
-\item Flash, Java or other plugins
-\item Your IP address or user agent string
-\item Any methods employed by Panopticlick\\
-\mbox{}\hfill $\rightarrow$ \textcolor{blue}{\url{https://panopticlick.eff.org/}}
-\end{itemize}
-
-Even when you disabled cookies entirely, have Javascript turned off and use a VPN service.\\\pause
-And numerous sites already use it (Google).
-
-\end{frame}}
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-
-
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-\mode<presentation>{
-\begin{frame}[c]
-\frametitle{\begin{tabular}{c}Web-Protocol\end{tabular}}
-
-\only<1->{
-\begin{textblock}{1}(2,2)
- \begin{tikzpicture}[scale=1.3]
- \draw[white] (0,0) node (X) {\includegraphics[scale=0.12]{pics/firefox.jpg}};
- \end{tikzpicture}
-\end{textblock}}
-
-\only<1->{
-\begin{textblock}{1}(11,2)
- \begin{tikzpicture}[scale=1.3]
- \draw[white] (0,0) node (X) {\includegraphics[scale=0.15]{pics/servers.png}};
- \end{tikzpicture}
-\end{textblock}}
-
-\only<1->{
-\begin{textblock}{1}(5,2.5)
- \begin{tikzpicture}[scale=1.3]
- \draw[white] (0,0) node (X) {};
- \draw[white] (3,0) node (Y) {};
- \draw[red, ->, line width = 2mm] (X) -- (Y);
- \node [inner sep=5pt,label=above:\textcolor{black}{\small GET static.jpg}] at ($ (X)!.5!(Y) $) {};
- \end{tikzpicture}
-\end{textblock}}
-
-\only<2->{
-\begin{textblock}{1}(5,6)
- \begin{tikzpicture}[scale=1.3]
- \draw[white] (0,0) node (X) {};
- \draw[white] (3,0) node (Y) {};
- \draw[red, <-, line width = 2mm] (X) -- (Y);
- \node [inner sep=5pt,label=below:\textcolor{black}{\small ETag: 7b33de1}] at ($ (X)!.5!(Y) $) {};
- \node [inner sep=5pt,label=above:{\includegraphics[scale=0.15]{pics/tvtestscreen.jpg}}] at ($ (X)!.5!(Y) $) {};
- \end{tikzpicture}
-\end{textblock}}
-
-\only<3->{
-\begin{textblock}{1}(4.2,11)
- \begin{tikzpicture}[scale=1.3]
- \draw[white] (0,0) node (X) {};
- \draw[white] (3,0) node (Y) {};
- \draw[red, ->, line width = 2mm] (X) -- (Y);
- \node [inner sep=5pt,label=above:\textcolor{black}{\small GET static.jpg ETag: 7b33de1}] at ($ (X)!.5!(Y) $) {};
- \end{tikzpicture}
-\end{textblock}}
-
-\only<4->{
-\begin{textblock}{1}(4.2,13.9)
- \begin{tikzpicture}[scale=1.3]
- \draw[white] (0,0) node (X) {};
- \draw[white] (3,0) node (Y) {};
- \draw[red, <-, line width = 2mm] (X) -- (Y);
- \node [inner sep=5pt,label=below:\textcolor{black}{\small HTTP/1.1 304 (Not Modified)}] at ($ (X)!.5!(Y) $) {};
- \end{tikzpicture}
-\end{textblock}}
-
-\end{frame}}
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-\mode<presentation>{
\begin{frame}[c]
\frametitle{Today's Lecture}
\begin{center}
@@ -238,8 +83,7 @@
\end{tabular}
\end{center}
-
-\end{frame}}
+\end{frame}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%