DiSTANTunes technical OverviewDT consists of two parts: a server part that runs on users machine and aclients part that runs in browser.The server part consists of small http web server written in C# from scratchand GUI to manage its settings. The server scans the selected directory formp3 files and creates in-memory list of them. A hash key is generated foreach file during the scanning. This key is later used by the client torequest a particular file (instead of using a full file system path). Theserver has some built-in security measures and doesnt serve anything besidesmp3 files and client application files (which are stored in internal serversresources).Server supports: a. HTTP 1.0 (supports keep-alive connections and gzip compression) b. Cookies-based authentication c. Generating playlist by extracting ID3 tags from mp3 files. d. Simple client-server protocol for requesting playlists and mp3 files. e. Flood protection (if a clients sends a lot of requests in a short time, it will be blocked by IP for 1 minute) f. Password brute force cracking protection (a client is blocked for 1 minute after several incorrect password attempts) g. Logging of all requests (using log4net library) h. Caching of parsed mp3 tags in memory i. Automatic checking for updates and installing them • All update files must be signed with developers private key, otherwise the server will reject the update (additional security against programs home page hacking). j. Auto starting on reboot k. 3 UI languages: English (full support), Japanese(70% translated so far) and Russian(70% translated so far) • The languages can be switched on the fly without restarting the server. • When you run the program for the first time it tries to detect you UI language and sets its UI language accordingly. l. Integrated internet connection tester that can tell whether you will be able to access the files from the Internet. m. iTunes integration (iTunes music folder is automatically detected) n. Simple and advanced UI (with more settings)Server supports all Windows versions starting from Windows XP SP2 to Windows7. To run DT on Windows XP you will need .NET Framework 2.0, other versionshave it built-in.DT server’s executable file is obfuscated using Babel .NET obfuscator to make reverse engineering harder. Server has a bug reporting function. If the program crashes, it asks user whether to send a bug report to the developers (needs Internet connection). This data is collected on DT’s website and developers are notified. Client part is written in Flex using Mate Framework (all components are loosely coupled). The client requires Flash Player version 10 or later. It can play mp3 files, request playlists and share the information about the currently playing song using Twitter. Client’s UI allow you can search for songs by
song name, artist, album and genre. You can shuffle your playlist and make songs loop forever. There is a flat list mode when all files from the child directories are displayed as one big list. Playlist can be sorted by any column. Client’s design is not finished yet. DT has an installer written using Windows Installer XML (WiX) toolset. Installer automatically checks if .NET Framework is not installed and installs it when needed. We developed a very simple protocol for client‐server communication based on JSON.