and added files
[bcm963xx.git] / userapps / opensource / reaim / html / dcc.html
1 <html>
2 <head>
3   <title>Introduction to AIM Direct Connections and Address Translation Firewalls</title>
4   <link rel="stylesheet" href="doc-ns4.css" type="text/css" />
5   <style type="text/css">
6     @import url("doc.css");
7   </style>
8   <meta name="Author" content="Mark P. Cooke" />
9   <meta name="Version" content="$Id: dcc.html,v 1.7 2002/12/09 23:30:21 mark-c Exp $" />
10 </head>
11 <body>
12 <div class="page">
13 <a href="index.html"><img src="back.gif" width="20" height="20" class="back" /></a><h1>AIM Messaging Overview</h1>
14
15 <h2>Basic Outline</h2>
16
17 <p>The AIM client supports two methods to send text messages to other AIM
18 users.  The first is used unless a direct connection has been established,
19 and in this mode, all messages pass through an AIM server.</p>
20
21 <ol>
22 <li>Alice on Machine 1 establishes a connection to an AIM server</li>
23 <ul><li>This works through most firewalls.  It's just a single connection</li></ul>
24 <li>Bob on Machine 2 establishes a connection to an AIM server</li>
25 <ul><li>This works through most firewalls.  It's just a single connection</li>
26     <li>It is not necessarily the same AIM server as Alice, but this doesn't matter</li></ul>
27 <li>Alice wants to send a text message to Bob</li>
28 <ul><li>Alice's machine sends a message to the AIM server it is connected to</li>
29     <li>The AIM servers check which machine Bob's connected to, and hands off the message to that AIM server</li>
30     <li>Bob receives Alice's message from the AIM server he's connected to</li></ul>
31 </ol>
32
33 <p>In the above process, Alice and Bob have no idea about each other's
34 internet address - it just isn't required.  However, all the messages are
35 going through the AIM servers they are connected to.  This costs AOL money,
36 and also permits them to see all the messages Alice and Bob are exchanging.</p>
37
38 <p>Because of the cost, transferring files requires Alice and Bob to establish
39 a direct connection between each other.  Once this is done, as the name implies,
40 data flows directly between Alice and Bob, without the AIM servers being
41 involved - so it doesn't cost AOL any money.</p>
42
43 <ol>
44 <li>Alice on Machine 1 establishes a connection to an AIM server</li>
45 <ul><li>This works through most firewalls.  It's just a single connection</li></ul>
46 <li>Bob on Machine 2 establishes a connection to an AIM server</li>
47 <ul><li>This works through most firewalls.  It's just a single connection</li></ul>
48 <li>Alice sends a direct connection establishment message to Bob</li>
49 <ul><li>Alice's machine send a message to the AIM server it is connected to.  This message contains the internet address of Alice's machine</li>
50     <li>The AIM servers check which machine Bob's connected to, and hands off the message to that AIM server</li>
51     <li>Bob receives Alice's message from the AIM server he's connected to, and once this is received, Bob can try to make a direct connection to the address Alice just sent</li></ul>
52 </ol>
53
54 <p>If Bob establishes a connection to Alice, then everything is fine, and
55 they have a direct connection established.  If Bob's machine can't contact
56 Alice's, the direct connection establishment then proceeds as follows:</p>
57
58 <ol>
59 <li>Bob's machine times out trying to connect to Alice</li>
60 <li>Bob's machine sends a message to Alice via the AIM server, containing his internet address, and waits for Alice to connect to him</li>
61 <li>Alice receives the message from Bob via the AIM server she is connected to, and attempts to connect to Bob</li>
62 </ol>
63
64 <p class="last">At this point, Alice either successfully connects to Bob, or another timeout
65 happens.  If the timeout happens, both Bob and Alice's AIM clients will tell
66 them that the connection couldn't be established.</p>
67
68 <h2>The Issue Of Address Translation</h2>
69
70 <p>One reason for Alice and Bob being unable to connect to each other is if
71 there is an Address-Translating firewall between their machine and the AIM
72 server they connect to.  In essence, this usually means that their machine
73 cannot be directly reached from anywhere else on the internet.  Consider
74 the diagram below:</p>
75
76 <pre>
77        Local LAN                  Internet
78   [alice]---+-----[firewall]---------------+--[AIM Server Cluster]
79  10.0.0.5   | 10.0.0.1   A.B.C.D           |
80             |                              |
81   [others]--+                              +--[Bob]
82                                              W.X.Y.Z
83
84 </pre>
85
86 <p class="last">A.B.C.D is the only address that the rest of the internet can contact
87 directly.  Unfortunately, in the direct connection setup, Alice's machine
88 doesn't know this, and so uses 10.0.0.5 in her message to Bob.</p>
89
90 <h2>A Solution: The ReAIM Proxy</h2>
91
92 <p>The ReAIM proxy is a small program designed to run on (or behind) the
93 firewall shown in the diagram above.  It intercepts the messages going
94 from Alice to the AIM servers, and if the message is a direct connection
95 request, it changes the address Alice put in the packet from 10.0.0.5
96 to A.B.C.D, and keeps track that Alice has a direct connection pending.</p>
97
98 <p class="last">When Bob gets the modified message, he connects to A.B.C.D, and the proxy
99 answers.  With a little bit of jiggery pokery, the proxy matches up Bob's
100 request with Alice's pending request, and sets up a connection so that
101 Alice and Bob can communicate (almost) directly.</p>
102
103 <br>
104 <center><A href="http://sourceforge.net"><IMG src="http://sourceforge.net/sflogo.php?group_id=40800" width="88" height="31" border="0" alt="SourceForge Logo"></A></center>
105
106 </div>
107 </body>
108 </html>