Resurrecting iChat Audio and Video Conferencing


Published on: by Chris Jones

Updated on: • 7 min learn

Add this to your /and many others/hosts file in your outdated Mac operating Leopard or Show Leopard (has not been examined on Tiger or Panther), and iChat ought to be capable of make audio and video calls once more. This assumes your router does port-preserving NAT (most do).

157.230.2.213 configuration.apple.com

Do notice that in case you are on a BSD primarily based router like pfSense or OPNsense, you will want to allow supply port preservation in your outbound NAT settings.

I was probably the most annoying form of Apple zealot. In the early 2000s, I believed all the pieces Apple had was higher than anything on the market whether or not it was true or not. There was one place that it was true, nevertheless, and that was within the realm of video and audio conferencing within the early 2000s.

The massive gamers for client stage video conferencing on the time have been Microsoft with MSN Messenger, Yahoo! with Yahoo! Messenger, and AOL with AOL Instant Messenger (AIM). Then at Apple’s World Wide Developer Conference (WWDC) in June of 2003, together with the G5 processor and OS X 10.3 panther, Apple introduced “iChat AV”.

They additionally introduced this attractive over-engineered webcam to go together with it referred to as the “iSight”.

Original iSight Webcam

I truly had a G4 laptop computer and an iSight. It felt like dwelling sooner or later and I liked it. This submit is about how I obtained iChat’s video conferencing on early OS X working over the Internet once more to relive a few of that enjoyable.

In early 2023, my good friend (shall be known as “Methodius”) and I made a decision to simply attempt it and see what would occur. We tried to check a easy iChat audio name on OS X Leopard. That model of iChat works with XMPP (Jabber) servers, so we every set it up with an account on jabb.im, and pressed the inexperienced name button. It rang for the opposite occasion, it mentioned it was attempting to attach, after which…failed to attach.

It’s by no means that straightforward.

Time to do some site visitors inspection with tcpdump. Thankfully, that comes pre-installed on OS X from again then so I did not have to put in something further. Along with the packet inspection, I additionally ran iChat in debug mode by launching it within the terminal like this:

/Applications/iChat.app/contents/MacOS/iChat -errorLogLevel 7

iChat’s debug mode was very useful and barely documented anyplace, so now it lives right here if I ever have to look it up once more.

  1. iChat makes an http request to http://configuration.apple.com/configurations/macosx/ichat/1/snatmap.txt to get the deal with of an SNATMAP server.
  2. iChat makes a UDP request to that SNATMAP server to get its personal public IP deal with.
  3. iChat on each ends then exchanges their public IPs and ports through their textual content communication channel (XMPP in our case).
  4. iChat on each ends then makes an attempt to arrange a peer-to-peer RTP connection by blasting packets to every over over the general public IPs and ports beforehand found through the SNATMAP server. Since NAT connections are stateful, and outbound NAT connections open an inbound connection to the machine making the request, iChat behind NAT routers are capable of join with one another with out the necessity to arrange NAT port forwarding forward of time.
  1. iChat tried to make an http request to http://configuration.apple.com/configurations/macosx/ichat/1/snatmap.txt however obtained redirected to https which it couldn’t connect with as a result of OS X’s TLS suite is just too outdated.
  2. iChat failed to finish that request, so as a substitute of exchanging our public IPs, they exchanged non-public LAN IPs as a substitute, which clearly failed to attach over NAT.

The https URL continues to be up on the time of scripting this, nevertheless, and truly comprises one thing!

snatmap://snatmap.apple.com:5678

OK, NP. I arrange my very own easy net server, hosted that file myself, replace OS X’s /and many others/hosts file to level configuration.apple.com to an IP of my selecting. Ran it and…nonetheless nothing.

Apple’s SNATMAP server would not reply anymore. At this level, we have been at a lifeless finish as a result of we had no concept how this SNATMAP server labored or how iChat expects to speak with it. We realized lots however resulted in failure.

Methodius and I determine to attempt once more in summer season 2026, however this time with just a little LLM help. With our prior community captures, we have been in a position to make use of an LLM to reverse engineer iChat’s video conferencing framework and work out what the request to the SNATMAP server appears like and what iChat expects as a response. From that, we have been capable of generate a specification file of the SNATMAP protocol.

Even although I did not have the know tips on how to decompile iChat, learn the meeting code, and them make sense of it, I can a minimum of discover ways to write a easy UDP server from the spec file the LLM generated.

I’m a programs engineer and admin by commerce. I set up and configure servers, however I’ve by no means written a server of my very own earlier than. Turns out, this SNATMAP server made for an excellent first server to observe with.

The protocol:

  1. Communicates over UDP on port 5678
  2. The request packet comprises 4 fields in 16 bytes.
    1. Type (“1” for request)
    2. Nonce (random quantity used to match a request with a response)
    3. shopper native IP (unused)
    4. shopper native port (unused)
  3. The response packet comprises 4 fields in 16 bytes
    1. Type (“2” for response)
    2. Nonce (the identical random quantity from the request)
    3. External IP from the UDP request
    4. The exterior port from the UDP request

Links for the spec file and supply code to the SNATMAP server are on the finish of this submit

Since Methodius has youngsters and, because of this, has a lot much less free time than I do, I wanted a approach to take a look at how iChat works throughout the Internet on my own. Since I haven’t got two separate ISP connections to play with, I made a decision to construct an “Internet” in a lab. This was achieved by operating two NAT routers (OpenWrt) as digital machines operating on a KVM host (Proxmox) that traversed a flat community area appearing because the “Internet”. Then I bodily hooked two Macs as much as the bodily KVM host (through USB NICs) the place the VM routers assigned them IP addresses in their very own non-public LAN behind a NAT. Then on the “Internet” community, I had the Jabber (ejabberd), net (lighttpd), and SNATMAP servers operating in a Debian Linux VM.

Here it’s diagrammed with footage of the bodily setup with the Proxmox Server (the Thinkpad laptop computer) and the 2 Macs hooked as much as it.
iChat Diagram
iChat Lab 1
iChat Lab 2
iChat Lab 3
iChat Lab 4

With this, I used to be capable of take a look at and iterate rapidly.

The spec file can be utilized to create your personal model of the server for those who so need. The supply code was hand written in Python from the spec file and is able to run on nearly any OS that may run Python 3.

If you want to self host, make certain you might have an online server configured to reply requests to configuration.apple.com and have it serve snatmap.txt from the trail

/configurations/macosx/ichat/1/snatmap.txt

In snatmap.txt make it include

snatmap://YOUR_SERVER_IP:5678

changing YOUR_SERVER_IP with the general public IP deal with of the server the SNATMAP server is operating on.

Or you possibly can simply use my server! I protecting it operating for the 1-5 individuals left within the globe that wish to video chat utilizing the traditional software program. 😀

On your outdated mac operating OS X Leopard or Snow Leopard (would possibly work on older however not examined), simply enter this into your /and many others/hosts file.

157.230.2.213 configuration.apple.com

Then have the good friend you wish to name do the identical. After that, mash that inexperienced name button!

It’s true! You may even use a reasonably trendy Logitech webcam. I examined on OS X Leopard with a Logitech C920.

Here is a screenshot of Methodius and I chatting over the true Internet with iChat AV.
iChat AV Screenshot Real

Enjoy and joyful chatting!



Source link