blob: b58a4526f6cf9c30f5e07d7ffe79b0b39308d715 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
|
% ----------------------------
\subsubsection{Process Isolation}
% ----------------------------
\begin{frame}[fragile]
\frametitle{Why isolating tasks?}
\begin{figure}[h]
\centering
\includegraphics[width=5cm]{images/multithread_norm.png}
\end{figure}
\end{frame}
% ----------------------------
\begin{frame}[fragile]
\frametitle{Multithreaded Application under attack}
\begin{figure}[h]
\centering
\includegraphics[width=5cm]{images/multithread_attack.png}
\end{figure}
\end{frame}
% ----------------------------
\begin{frame}[fragile]
\frametitle{Multi-process vs. Multi-thread}
\begin{figure}[h]
\centering
\includegraphics[width=8cm]{images/multiproc_norm.png}
\end{figure}
\end{frame}
% ----------------------------
\begin{frame}[fragile]
\frametitle{Multi-process under attack}
\begin{figure}[h]
\centering
\includegraphics[width=8cm]{images/multiproc_attack.png}
\end{figure}
\end{frame}
% ----------------------------
\subsubsection{Memory Management}
% ----------------------------
\begin{frame}[fragile]
\frametitle{Memory Manangement}
\begin{itemize}
\item create process context
\item overload VMA
\end{itemize}
\begin{figure}[h]
\centering
\includegraphics[width=8cm]{images/proc_isol.png}
\end{figure}
\end{frame}
% ----------------------------
\subsubsection{Multiprocess Programming}
% ----------------------------
\begin{frame}[fragile]
\frametitle{Multiprocess Programming}
\begin{columns}[onlytextwidth]
\begin{column}{0.45\textwidth}
\begin{beamerboxesrounded}[shadow=true]{Program:}
\begin{tiny}
\begin{verbatim}
[...]
pid = fork();
switch (pid) {
case -1:
/* error handling */
case 0:
/* child processing */
execve(argv[0], &argv[0], envp);
break;
default:
/* parent processing */
[...]
pid = wait(&status);
}
[...]
\end{verbatim}
\end{tiny}
\end{beamerboxesrounded}
\end{column}
\begin{column}{0.45\textwidth}
\begin{beamerboxesrounded}[shadow=true]{Arguments:}
\begin{tiny}
\begin{verbatim}
char *argv[] = {
"/bin/myappl",
"--config",
"/etc/myconfig",
NULL,
};
\end{verbatim}
\end{tiny}
\end{beamerboxesrounded}
\begin{beamerboxesrounded}[shadow=true]{Environment:}
\begin{tiny}
\begin{verbatim}
char *envp[] = {
"HOME=/myhome",
"PATH=/bin:/usr/bin",
"TZ=UTC0",
NULL,
};
\end{verbatim}
\end{tiny}
\end{beamerboxesrounded}
\end{column}
\end{columns}
\end{frame}
|