%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\documentstyle[12pt,twoside,alltt]{article}
\textwidth=6in
\oddsidemargin=0.25in
\evensidemargin=0.25in
\topmargin=-0.1in
\footskip=0.8in
\parindent=0.0cm
\parskip=0.3cm
\textheight=8.00in
\setcounter{tocdepth} {3}
\setcounter{secnumdepth} {2}
\sloppy

\newenvironment{proof}{\noindent{\bf Proof:}}{\qed\bigskip}
\newenvironment{proof_sketch}{\noindent{\bf Sketch of 
Proof}\hspace*{1em}}{\qed\bigskip}

\newtheorem{theorem}{Theorem}
\newtheorem{corollary}{Corollary}
\newtheorem{lemma}{Lemma}
\newtheorem{claim}{Claim}
\newtheorem{fact}{Fact}
\newtheorem{definition}{Definition}
\newtheorem{assumption}{Assumption}
\newtheorem{observation}{Observation}
\newtheorem{example}{Example}
\newcommand{\qed}{\rule{7pt}{7pt}}

\newcommand{\lecture}[4]{
\pagestyle{headings}
\thispagestyle{plain}
\newpage
\noindent
\begin{center}
\framebox{
\vbox{
\hbox to 5.75in { {\bf 6.857 Computer and Network Security
\hfill Fall Term, 1997}  }
\vspace{4mm}
\hbox to 5.75in { {\Large \hfill Lecture #1 : #2 \hfill} }
\vspace{2mm}
\hbox to 5.75in { {\it Lecturer: #3 \hfill Scribe: #4} }
}
}
\end{center}
\markboth{Lecture #1 : #2}{Lecture #1 : #2}
\vspace*{4mm}
}

\begin{document}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Lecture command takes 4 arguments:
%		ordinal number of the lecure
%		date of the lecure
%		lecturer
%		scribe---that is you
%
\lecture{19}{November 4, 1997}{Ron Rivest}{Thor Sewell} 
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%


%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%
% For theorems, lemmas, definitions, remarks, etc. use commands
% \begin{theorem} .... \end{theorem} 
% \begin{definition} ... \end{definition} 
% \begin{proof} ... \end{proof}
% and so on ...
%
% If you want to insert figures in your notes do the following: 
% 1) Prepare your figures using your favourite graphic editor
% 	for example idraw or xfig
% 2) Save your pictures in PostScript form using the following convention
% 	notes-nn-fig-mm.ps where nn is the number of the lecture you 
% 	are scribing and mm is the sequential number of the picture in the 
% 	notes
% 3) Insert the following block in your LaTeX code in the place you 
% 	want to insert the figure BUT LEAVE IT AS A COMMENT (with the %
% 	at the beginning of the line) since it will not work on athena: 
%
% \begin{figure}[h]
% \begin{center}
% \mbox{\psfig{figure=notes-nn-fig-mm.ps}}
% \caption{A very nice picture.}
% \label{fig:mm}
% \end{center}
% \end{figure}
%
% 	of course the picture will not show up when you compile and 
% 	print your notes, but don't worry the TA will take care of it. 
% 4) When you mail the TA the LaTeX code mail him/her the PostScript
%	files for the figures as well 
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Your notes start here!
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\section{Topics Covered}
\begin{itemize}
\item Java Security (continued)
\item TCP/IP
\item Syn Flooding
\item Firewalls - Packet Level
\end{itemize}


\section {Review: Java Security}

Malicious Applets:

a) Barking Dog Applet - sets up thread which is immortal; redefines its own "step" method to do nothing

b) Business assassin applet - kills competitors

c) D.O.S. - soaks up all CPU cycles

d) Continious Window Opening

e) Forging e-mail - telnet to port 25

\paragraph {Digitally Signed Applets}
Browser has approved list of applets signed by Y; Y is approved by X

\section {TCP-IP}
Internet sessions are TCP-IP session.  In a TCP conversation packets flow in both directions. Acknowledgment packets and control packets flow to both directions regardless if data is flowing one way. The following illustrates a TCP-IP conversation:

\begin{center}
Client-----------------------------Server

---------------Syn(1000)------------$>$

$<$---------Syn(2000), Ack (1001)-----

---------------Ack(2001)------------$>$

$<$--------------Data, Acks-----------$>$

----------Ack(2300), Fin(1500)------$>$

$<$---------Ack(1501), Fin(2400)------

---------------Ack(2401)------------$>$
\end{center}
\section {Syn Flooding}
\begin{itemize}
\item send many Syn's to server, but never follow up
\item source address can be bogus
\item approaches: 
\begin{enumerate}
\item trace source of packets
\item short time-out
\item sign cookies - offload memory requirement to client
\item table capable of holding large number of entries
\end{enumerate}
\end{itemize}

Internet$<$------Side B-------$>$Firewall$<$------Side A-------$>$Corporate Network

Firewall should be secure, meaning that all packets going from the corporate network to the outside must go through the firewall. The firewall should allow communication according to policy.

\section {Firewalls - Packet Level}

Packet Filters are an inexpensive and feasible level of gateway security because primarily they are imbedded in the router software.  Packet filters will descriminate between packets based on the source, destination, and port. Packet filters are configured by (1) determining a security policy, (2) specifying the allowable packets formally, and (3) expressions rewritten to a vendor supported syntax.  Therefore, the firewall looks at each packet and decides, based only on that packet, what to do. As illustrated in the following table, what is not expressly permitted is prohibited.

FROM....ACTION..SOURCE..PORT...DESTINATION...PORT.......FLAGS

A................allow......Inside........*.................*.....................25
	
B................allow........*............25.................*......................*...............Ack

A................allow.......Inside........*................*....................25................Ack

* - matches anything
\paragraph {FTP difficult}
\begin{center}
Client.................................Server

$<$---------Establish connection----------$>$

--------------User name-------------------$>$

$<$------------Password?--------------------

----------------Password------------------$>$

----------------Port X (1906)-------------$>$

Server opens a connection to port

-----------------Get foo------------------$>$

$<$---------Connection established---------

$<$-----------------File foo--------------------

$<$------------Transfer done---------------
\end{center}
\paragraph {Tunneling}
The goal of firewalls is to control and watch what is happening. However, tunneling is a method to by-pass firewalls by encapsulating a message from one protocol in another protocol. After reaching the destination point the second protocol is removed and the original message is available in the network.  

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Your notes end here!
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\end{document}



