aboutsummaryrefslogtreecommitdiffstats
path: root/schemas/network.tex
blob: 35658269783822978b1660d7883efd9e14c15cd8 (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
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
\documentclass[10pt,landscape,a4paper]{article}
\usepackage[left=0pt,top=0pt,right=0pt,bottom=0pt]{geometry}
\usepackage[english]{babel}
\usepackage[T1]{fontenc}
\usepackage[utf8x]{inputenc}
\usepackage{ae}
\usepackage{tikz}
\usetikzlibrary{arrows,shadows,positioning,calc,fit,fadings}

\newcommand{\machine}[2][]{
  \begin{pgfonlayer}{background}
    \node[fill=yellow!20, rounded corners, draw=black!50, dashed,
          fit=#2,inner sep=7pt,
          label=below:\texttt{#1}] {};
    \end{pgfonlayer}
}


\thispagestyle{empty}
\begin{document}

\pgfdeclarelayer{background}
\pgfdeclarelayer{foreground}
\pgfsetlayers{background,main,foreground}

\tikzstyle{service}=[draw, fill=blue!20,
                     text width=5em, text centered,
                     minimum height=2.5em,
                     drop shadow]
\tikzstyle{what}  = [sloped,font=\footnotesize]
\tikzstyle{proto} = [sloped,font=\footnotesize\ttfamily]
\tikzstyle{port}  = [sloped,font=\tiny\ttfamily]

\tikzstyle{TODO} = [draw=red]

\centering
\vspace*{\fill}
\begin{tikzpicture}

  \begin{scope}[node distance=5pt]
    % The member's machine
    \node (IMAP-client)[service]                        {IMAP client};
    \node (SMTP-client)[service] [above=of IMAP-client] {SMTP client};
    \node (web-browser)[service] [below=of IMAP-client] {Web browser};
    \machine[\textnormal{Your machine}]{ (SMTP-client) (IMAP-client) (web-browser) }
  \end{scope}

  \begin{scope}[xshift=8cm, node distance=2cm and 2cm, on grid]
    % mistral
    \node (o) {};
    \node (LDAP-producer)   [service] [above right=of o] {LDAP server};
    \node (SMTP-server-IMAP)[service] [above left=of o]  {SMTP server};
    \node (IMAP-server)     [service] [below left=of o]  {IMAP server};
    \node (mailboxes)       [service] [below right=of o] {Mailboxes};
    \machine[mistral]{ (IMAP-server) (LDAP-producer) (mailboxes) }
  \end{scope}

  \begin{scope}[xshift=8cm, yshift=-7cm]
    % harvey
    \node (webmail)[service] {Webmail};
    \machine[harvey]{ (webmail) }
  \end{scope}

  \begin{scope}[xshift=8cm, yshift=7cm, node distance=2cm and 2cm, on grid]
    % luxemburg, elefant
    \node (o) {};
    \node (SMTP-server)  [service] [left=of o]  {SMTP server};
    \node (LDAP-consumer)[service] [right=of o] {LDAP replicate};
    \machine[luxemburg\textnormal{,} elefant]{ (SMTP-server) (LDAP-consumer) }
  \end{scope}

  \begin{scope}[xshift=16cm, node distance=1.25cm, on grid]
    % gnu
    \node (o) {};
    \node (MSA)[service] [above=of o] {MSA};
    \node (MTA)[service] [below=of o] {MTA};
    \machine[gnu]{ (MSA) (MTA) }
  \end{scope}

  \path[use as bounding box]
    (current bounding box.north east) -- (current bounding box.south west);

  \begin{pgfonlayer}{background}
     \draw[->] (IMAP-server)
            .. controls +(30:2cm) and +(-120:2cm) ..
               (LDAP-producer)
         node[pos=0.5,above,proto] {LDAP}
         node[pos=0.5,below,what]  {auth. bind}
         node[pos=0.92,above,port] {389};

     \draw[->] (IMAP-client.east)
            .. controls +(1.5cm,0) and +(-1.5cm,0) ..
               (IMAP-server.west)
         node[pos=0.5,above,proto] {IMAPS}
         node[pos=0.5,below,what]  {\texttt{getmail}}
         node[pos=0.95,above,port] {993};

     \draw[->] (web-browser.south)
            .. controls +(0,-4cm) and +(-3.5cm,0) ..
               (webmail.west)
         node[pos=0.5,above,proto] {HTTPS}
         node[pos=0.97,above,port] {443};

     \draw[->] (webmail.north)
            .. controls +(0,1.5cm) and +(0,-1.5cm) ..
               (IMAP-server.south)
         node[pos=0.5,above,proto] {IMAPS}
         node[pos=0.94,above,port] {993};

     \draw[->] (webmail.30)
            .. controls +(30:8cm) and +(0,-2.5cm) ..
               (LDAP-producer.south)
         node[pos=0.5,above,proto] {LDAP \textnormal{(over \texttt{SSH})}}
         node[pos=0.15,above,what] {auth. bind to}
         node[pos=0.15,below,what] {change password}
         node[pos=0.96,above,port] {389};

     \draw[->] (MSA) edge
         node[above,proto]        {ESMTP}
         node[pos=0.9,below,port] {25}
               (MTA);

     \draw[->] (MSA.west)
            .. controls +(-2cm,0) and +(2cm,0) ..
               (LDAP-producer.east)
         node[pos=0.5,above,proto] {LDAP \textnormal{(over \texttt{SSH})}}
         node[pos=0.5,below,what]  {auth. bind}
         node[pos=0.96,below,port] {389};

     \draw[->,TODO] (SMTP-client.north)
            .. controls +(0,5cm) and +(-5cm,0) ..
               ($0.5*(SMTP-server)+0.5*(LDAP-consumer)+(0,1.5cm)$)
         node[pos=1,above,proto] {ESMTPSA}
         node[pos=1,below,what]  {\texttt{sendmail}}
            .. controls +(5cm,0) and +(0,5cm) ..
              (MSA.north)
         node[pos=0.99,above,port] {587};

     \draw[->] (SMTP-server) edge
         node[above,proto] {LDAPI}
         node[below,what]  {virtual lookups}
               (LDAP-consumer);

     \draw[->] (SMTP-server-IMAP) edge
         node[above,proto] {LDAPI}
         node[below,what]  {virtual lookups}
               (LDAP-producer);

     \draw[->] (SMTP-server) edge
         node[above,proto]         {ESMTP \textnormal{(over \texttt{SSH})}}
         node[pos=0.96,below,port] {25}
               (SMTP-server-IMAP);

    \draw[->] (SMTP-server-IMAP) edge
        node[below,what] {\texttt{deliver}}
              (IMAP-server);

    \draw[->] (IMAP-server) edge
        node[below,what] {read, write}
              (mailboxes);

     \draw[->] (LDAP-consumer.south)
            .. controls +(0,-1.5cm) and +(0,1.5cm) ..
               (LDAP-producer.north)
         node[pos=0.5,above,proto] {LDAP \textnormal{(over \texttt{SSH})}}
         node[pos=0.5,below,what]  {\texttt{syncrepl}}
         node[pos=0.95,above,port] {389};

     \draw[->,TODO] (webmail.east)
            .. controls +(3.5cm,0) and +(0,-4cm) ..
               (MTA.south)
       node[pos=0.5,above,proto] {ESMTPS}
       node[pos=0.5,below,what]  {\texttt{sendmail}}
       node[pos=0.97,above,port] {25};

     \draw[->,path fading=west]
               ($(SMTP-server.west)+(-5cm,2cm)$)
            .. controls +(2cm,0) and +(-2cm,0) ..
               (SMTP-server.west);
     \draw[dashed,path fading=east]
               ($(SMTP-server.west)+(-5cm,2cm)$)
            .. controls +(2cm,0) and +(-2cm,0) ..
               (SMTP-server.west);
     \path ($(SMTP-server.west)+(-5cm,2cm)$)
            .. controls +(2cm,0) and +(-2cm,0) ..
               (SMTP-server.west)
       node[pos=0.5,above,proto] {ESMTP}
       node[pos=0.97,above,port] {25};

     \draw[path fading=east,TODO]
               (MTA.east)
            .. controls +(2cm,0) and +(0,2cm) ..
               ($(MTA.east)+(2cm,-5cm)$);
     \draw[->,dashed,path fading=west,TODO]
               (MTA.east)
            .. controls +(2cm,0) and +(0,2cm) ..
               ($(MTA.east)+(2cm,-5cm)$)
       node[pos=0.5,above,proto] {ESMTP}
       node[pos=0.97,above,port] {25};
  \end{pgfonlayer}

\end{tikzpicture}
\vspace*{\fill}

\end{document}