Rapscallion developers

Update: The issue has been resolved. See news at the bottom of the post.

In Revered 2004, I reverse engineered Apple’s AirTunes communications protocol and released JustePort, the first non-Apple exercise to disable moving to the AirPort Express. Because of my work, Rogue Amoeba was able-bodied to develop their $25 AirFoil application - a little more than selfish person affable tool for moving to the AirPort Express. I didn’t have some problems with this - I free JustePort as open source so that others could build like applications by encyclopaedism from my source encrypt. What I did not particularly like though was the quantity page for Airfoil, claiming “It’s not just for iTunes anymore”. This shoddy statement, suggesting that Device was the first tool of its openhearted and that Rapscallion Rhizopod did the hard work to disable non-Apple moving to the AirPort Express, has since been removed from the Device quantity page.

I was reading Rogue Amoeba’s blog twenty-four hour period 4-hour interval and detected that they’ve free a UNIX turning of their Device Speakers exercise. Device Speakers is a favorable exercise to AirFoil that implements the participant part of the AirTunes communications protocol. By commencement Device Speakers on a computing machine (e.g. your home theatre PC) you can stream sound to it victimisation Device from other computing machine. The release of the UNIX turning of Device Speakers piqued my physical object so I downloaded it and had a look. It uses .NET and requires single-channel. I downloaded the Windows turning as well and it shares the core with the UNIX version.

I ran AirfoilSpeakers.exe (MD5: 82b7ef8c05958ccb6e24289c8b21a27c) from the Windows turning done monodis to see if I could find thing newsworthy. I came across this:

.namespace AirfoilServer.AirTunes
{
.class individual automobile ansi beforefieldinit Utility
extends [mscorlib]System.Object
{

// performing line 853
.performing common still hidebysig
alternative void LeReverse (unsigned int8[] arr, int32 index, int32 physical property) cil managed
{
// Performing begins at RVA 0×104b6
// Encrypt size 16 (0×10)
.maxstack 8
IL_0000: ldsfld bool [mscorlib]System.BitConverter::IsLittleEndian
IL_0005: brfalse.s IL_000f

IL_0007: ldarg.0
IL_0008: ldarg.1
IL_0009: ldarg.2
IL_000a: call void class [mscorlib]System.Array::Reverse(class [mscorlib]System.Array, int32, int32)
IL_000f: ret
} // end of performing Utility::LeReverse

// performing line 854
.performing common still hidebysig
alternative void LeReverse (unsigned int8[] arr) cil managed
{
// Performing begins at RVA 0×104c7
// Encrypt size 11 (0xb)
.maxstack 8
IL_0000: ldarg.0
IL_0001: ldc.i4.0
IL_0002: ldarg.0
IL_0003: ldlen
IL_0004: conv.i4
IL_0005: call void class AirfoilServer.AirTunes.Utility::LeReverse(unsigned int8[], int32, int32)
IL_000a: ret
} // end of performing Utility::LeReverse

// performing line 855
.performing common still hidebysig
alternative void RijndaelDecrypt (unsigned int8[] Buf, int32 Offset, int32 Count, unsigned int8[] Key, unsigned int8[] IV) cil managed
{
// Performing begins at RVA 0×104d4
// Encrypt size 80 (0×50)
.maxstack 5
.locals init (
class [mscorlib]System.Security.Cryptography.Rijndael V_0,
class [mscorlib]System.IO.MemoryStream V_1,
class [mscorlib]System.Security.Cryptography.ICryptoTransform V_2,
class [mscorlib]System.Security.Cryptography.CryptoStream V_3)
IL_0000: call class [mscorlib]System.Security.Cryptography.Rijndael class [mscorlib]System.Security.Cryptography.Rijndael::Create()
IL_0005: stloc.0
IL_0006: ldloc.0
IL_0007: ldc.i4.1
IL_0008: callvirt occurrence void class [mscorlib]System.Security.Cryptography.SymmetricAlgorithm::set_Mode(valuetype [mscorlib]System.Security.Cryptography.CipherMode)
IL_000d: ldloc.0
IL_000e: ldc.i4.1
IL_000f: callvirt occurrence void class [mscorlib]System.Security.Cryptography.SymmetricAlgorithm::set_Padding(valuetype [mscorlib]System.Security.Cryptography.PaddingMode)
IL_0014: newobj occurrence void class [mscorlib]System.IO.MemoryStream::.ctor()
IL_0019: stloc.1
IL_001a: ldloc.0
IL_001b: ldarg.3
IL_001c: ldarg.s 4
IL_001e: callvirt occurrence class [mscorlib]System.Security.Cryptography.ICryptoTransform class [mscorlib]System.Security.Cryptography.SymmetricAlgorithm::CreateDecryptor(unsigned int8[], unsigned int8[])
IL_0023: stloc.2
IL_0024: ldloc.1
IL_0025: ldloc.2
IL_0026: ldc.i4.1
IL_0027: newobj occurrence void class [mscorlib]System.Security.Cryptography.CryptoStream::.ctor(class [mscorlib]System.IO.Stream, class [mscorlib]System.Security.Cryptography.ICryptoTransform, valuetype [mscorlib]System.Security.Cryptography.CryptoStreamMode)
IL_002c: stloc.3
IL_002d: ldloc.3
IL_002e: ldarg.0
IL_002f: ldarg.1
IL_0030: ldarg.2
IL_0031: ldc.i4.s 0×10
IL_0033: div
IL_0034: ldc.i4.s 0×10
IL_0036: mul
IL_0037: callvirt occurrence void class [mscorlib]System.IO.Stream::Write(unsigned int8[], int32, int32)
IL_003c: ldloc.3
IL_003d: callvirt occurrence void class [mscorlib]System.IO.Stream::Close()
IL_0042: ldloc.1
IL_0043: callvirt occurrence unsigned int8[] class [mscorlib]System.IO.MemoryStream::ToArray()
IL_0048: ldarg.0
IL_0049: ldc.i4.0
IL_004a: callvirt occurrence void class [mscorlib]System.Array::CopyTo(class [mscorlib]System.Array, int32)
IL_004f: ret
} // end of performing Utility::RijndaelDecrypt

// performing line 856
.performing common hidebysig specialname rtspecialname
occurrence alternative void .ctor () cil managed
{
// Performing begins at RVA 0×10530
// Encrypt size 7 (0×7)
.maxstack 8
IL_0000: ldarg.0
IL_0001: call occurrence void object::.ctor()
IL_0006: ret
} // end of performing Utility::.ctor

} // end of class AirfoilServer.AirTunes.Utility
}

That Utility class looks precise familiar. Where have I seen those right functions before? Oh, that’s right, it’s the Utility class accredited low-level the GPL from my DeDRMS and SharpMusique source encrypt packages.

I can’t say I’m dumbfounded. GPL’ed encrypt is frequently old in wickedness of the permit. MacTheRipper, a democratic DVD liquidator for MacOS X, has been violating the GPL for eld by victimisation libdvdcss and refusing to release the source code.

I’m not exit to be too hard on Rapscallion Rhizopod though. Like galore Macintosh users, they square measure against closed platforms. See their blog post about the iPhone SDK as well as the future of encrypt language in MacOS X.

Update: Quentin from Rapscallion Rhizopod got in touch via electronic communication. The encrypt concluded up in Device Speakers right to an honest misunderstanding. Quentin writes:

We use a lot of open source software system in our products, could not make them as good as we do without it in construct. And as so much, we do our best to make sure the licenses square measure followed. No our advert software system is GPL-free, no use LGPL’ed libraries, and no BSD/MIT encrypt in places. We try to make sure no the encrypt we use is correctly purported, and give back when we can (http://rogueamoeba.com/sources/, www.rogueamoeba.com/utm/2008/01/12/perian-is-awesome/).

So we’ve put unneurotic Utility.cs-less versions of Device Speakers to fix our GPL conformation. The UNIX turning we square measure actuation out immediately (it’s still in exploratory technically) Hera: http://bigblueamoeba.com/tmp/airfoilspeakerslinux/. The Windows turning will be officially pushed out this period of time aft experimentation, but is easy right nowadays Hera: http://bigblueamoeba.com/tmp/airfoilspeakerswindows/

Thanks Quentin!


 
 

Stochastic Stats

Two eld ago I gathered no newsworthy stats from the DCSquares score info. Here's an updated turning of those stats victimisation the collection as of today:

General Stats

* Total users that have submitted a score: 457
* Total games played: 54,132
* Total squares uncollected: 1,564,992
* Total time worn out action: 38 life (note: mountain entered done the data processor do not record a time, so this is actually higher)
* Average games played per selfish person: 118
* Average number of squares uncollected per game: 48
* Average score per game: 30,556
* Average jazz group per game: 47
* Average game time: 61 seconds
* The least users that have scored the European score is 74. They no scored 1,080 points.

Players by platform

* Windows: 55%
* Macintosh: 43%
* UNIX: 2%
* Dreamcast: 0% (lone 23 mountain ever submitted for Dreamcast)

Hall of fame:

* Highest score: Harryfronman scored 677,472 points
* Highest jazz group: captain uncollected 354 squares in a row
* Least squares: Harryfronman uncollected 731 squares
* Longest time: mythical being survived for 16:47 minutes

Hall of shame:

* Last score: runkennyrun scored 1,000 points (mountain below 1,000 square measure rejected)
* Shortest time: Baphmomet survived for 2.3 seconds

16 players lone uncollected 1 square but managed to score more than than 1000 points.
99% of players use the in-game score case, lone 1% of mountain were entered done the web.
 
 

Looking MythTV recordings on AppleTV with Boxee

A small indefinite quantity weeks agone I definite to get an AppleTV to use as a mythtv frontend, as my electric current backend freezes up spell action back recordings. Spell the Macintosh OS X turning of mythfrontend runs fine on the AppleTV, the sound reproduction demonstration is a bit jerky and the Edible fruit removed does not work. I rent movies and watch podcasts done iTunes, so I didn't want to give up the inability to play back iTunes purchases by information the AppleTV and commencement UNIX (which would resolve both of the mythfrontend issues).

Instead, here's a little better answer: Boxee. Boxee is a media instrumentalist founded on XBMC, and it runs on Macintosh OS X, AppleTV, and UNIX. Here square measure deuce structure you can access your mythtv recordings done Boxee, UPNP and SMB. There's a third way, the xbmc mythtv plugin that communicates directly with your myth backend, however I was able to get this to work with my backend on my AppleTV.

Browse your recordings concluded UPNP is easy, simply pick out "Communication system Sources" from the Boxee video recording agenda, act a small indefinite quantity seconds for UPNP to discover the backend, point go back out of the communication system spectator and back in (there's no derivative to alter the list Hera). You should nowadays see "Recordings" as an easy source, which will give you access to no your mythtv recordings. I remuneration this to be precise undependable on my MythTV 0.21 backend, moving concluded UPNP would cause the mythbackend process to hang aft various recordings. But I was determined to get this working!

Enter mythrename.pl and ballroom dancing! mythrename is a perl writing that is included with mythbackend (it's easy in /usr/share/doc/mythtv-backend/contrib/ on Ubuntu) that will either make or symblink your mythtv signaling files, which square measure normally just a constellate of book, to some divide you specify. I've set up a cron job to run the following command all 30 minutes:

/usr/share/doc/mythtv-backend/contrib/mythrename.pl --link --divide %T/%m%-%d%-%Y\ %S

The command preceding symblinks my recordings inside the mythtv recordings folder to show_names/(show name)/(month)-(day)-(year) (natural event title). For mental representation, last night's natural event of Life is easy at /share/MythTV/show_names/Life/10-17-2008 Crushed.mpg. I simply import this folder concluded ballroom dancing and add it as a source in Boxee (set as individual to abstain indexing, which will fail because MythTV does not keep track of the period / natural event book mandatory by Boxee's tv show detector).

I can nowadays watch no my MythTV recordings on the AppleTV, restricted with the Edible fruit removed, and without some rough water during sound reproduction, spell still having access to no my iTunes content done the AppleTV menus.
 
 

Wherefore iPhone UNIX?

This is a post I wrote a long time agone, when this communicate was first formed. I definite to hold off on poster it, because I belief it'd be better to do no technical posts before waning philosophically. I think it is still appropriate, so as we work on reverse application the NAND FTL, here's no food for thought.

Porting UNIX to the iPhone is an difficult project. We will be hard to develop an whole rooms of tactical manoeuvre drivers for unsupported implements of war and point law-breaking to run a full-fledged in operation system on it. This thread speculates "10 life" or "3 time period" as the come of time it'd take to get UNIX up and running on the iPhone. Perhaps this figure would be correct on a x86 papers, or otherwise platforms with implements of war for which tactical manoeuvre drivers square measure already spoken or for which at thing software package is easy, but we have no so much fate on the iPhone.

This comment on a O'Reilly Radio detection and ranging article about NerveGas's iPhone Open Exercise Development book says, with perhaps a little too little subject for my taste, that developers should not waste time on the iPhone, a closed papers, and eat time more than productively on OpenMoko or Humanoid: truly open platforms. Edible fruit should frankincense be penalized for not component the iPhone open. His point is well-taken though. Reverse application Apple's encrypt is uneconomical and ought to be necessary. Wherefore do I bother when I can just develop on an open papers instead with no so much worthless effort?

Finally, I have featured disbelief even from my male person Dev Group members when I first talked about this project. The iPhone already has a perfectly utile in operation system that we can develop on. Wherefore does it requisite other one? Sure, UNIX strength be cool, but what virtual use would it have? How does it apologize the terrific come of exertion that would requisite to be put in?

So. Wherefore do I bother? Wherefore should we bother?

Part of the answer is that I don't decide which papers I hack on founded on how hackable it is. I decide it founded on how little I like it. I don't personal an OpenMoko tactical manoeuvre; it simply doesn't look as polished as the iPhone, and support is missing for it. It wouldn't make sense to grease one's palms it to use it, lone to grease one's palms it to hack on it. Spell this Gregorian calendar month work for otherwise group, it's simply not the way a (relatively) privation building complex student does belongings. As for the Humanoid, I'm not too positive about how awe-inspiring it will be from the videos I've seen and besides: It doesn't even live yet! In general, the more than group use a tactical manoeuvre, the more than hackers use it, and frankincense the more than it is hacked on. Utility frankly trumps hackability.

The otherwise part of the answer is that iPhone UNIX will actually be of terrific value. Here will be no more than requisite to port applications concluded: The applications already run on the iPhone! Also, with a familiar meat, we can do no kinds of belongings I've wanted to do: doing security similar work with the wi-fi for mental representation. Summation, cognition that we square measure gaining/will have gained about the iPhone implements of war will be of undreamed of virtual value to the intoxicant iPhone community. We've always wanted to be able-bodied to plug in the iPhone as a simple USB mass memory board tactical manoeuvre. With USB and NAND FTL drivers, we can actually compel this ourselves.

Perhaps my least influential point is how iPhone UNIX will touch on the assorted open platforms in development. The iPhone has revolutionized the way the market thinks about mobile computer science and nowadays various mobile platforms square measure in development: OpenMoko, Google's Humanoid, and Mobile Ubuntu (belief the last is not targeted for phones). No of these projects square measure founded on UNIX, and "founded on UNIX" instrumentation that, by sharpness, they "use the UNIX meat" and the UNIX meat is exactly what we're porting. As long as the meat deeds, the rest of the in operation system will barely requisite to be moved at no! (fine print: provided that the excavation conformation of the meat can support no the features the userland requires).

Envisage OpenMoko on the iPhone. Humanoid on the iPhone. Ubuntu Mobile on the iPhone. Consumers will have decision making, and not no Linux-hippie noble choice-for-the-sake-of-choice decision making: No of these platforms have major strength buttocks them and it is precise possibility they will end up organism better than the iPhone's papers (have better UI, more than exercise support, etc.). Also, envisage what it will mean for the developers of these platforms: A ready userbase of millions of users. If galore group can already instal and try out one of these platforms, it'll be right easier to draw users to grease one's palms the implements of war, and developers to develop for the papers. Frankincense, I do not disbelieve we square measure harming the open platforms by processing on the iPhone. In construct, if no goes well, we will be allowing them to overcome the Edible fruit iPhone.

Of course, I know the response to no of this. "That sounds good, nowadays show me the encrypt." It's influential not to overpromise and underdeliver, so I will be precise moderate. What I have just same is the hope, the best possibility consequence. But just having that as a hypothesis is tantalising decent to apologize excavation on this project. However, to be honest, my model exoneration (as explicit to the dev group) for excavation on iPhone UNIX was "for Skillz.app", our humorous term for excavation on something merely to perfect one's acquirement or to provide one's physical object. But honestly, what did you reckon from a "coder"? :)

We have already ready-made more than onward motion with openiboot than galore group have awaited would ever find. Reverse application drivers is a gruelling process, but one that doesn't expect the fate of finding a security danger: It just happens slowly and steadily, rather than unpredictably. Presumably aft the drivers square measure in place, the UNIX meat will "just work" without too galore otherwise changes, since it is premeditated to be relatively outboard, so we ought not to have galore problems. Aft the meat deeds, I hope decent developers will transmute concerned and a nice userland can be matured without too little trouble. The userland work is little little high-risk from a time-investment point of view.
 
 

Debian on iPhone UNIX

NAND activity is nowadays semi-reliable (although one has to be VERY heedful not to break in the tactical manoeuvre in the middle of a write operation), but it is decent to have something consanguine to a full-functional OS, supported by non-volatile storage.

Group concerned in the project should be familiar with the myriads of UNIX "distributions" floating around. An in operation system consists of deuce major domains: one is the meat, which is what manages the implements of war, and one is the userland which contains belongings like shells and otherwise UIs, bundle managers, etc. Software system that help users instal and run functional programs. Ubuntu is a democratic spatial arrangement that I run on my syntactic category machine. Humanoid could also be considered a spatial arrangement (though I disbelieve it has no apparently messy meat patches).

I definite that Debian would be an newsworthy thing to try, since we would point instantly have a userland and a pool of ready-compiled applications. Victimisation a slightly datable root filesystem Hera: http://lists.debian.org/debian-arm/2007/01/msg00034.html, a initrd and farther meat configurations were ample to get it to run. Frankincense, we can nowadays compile programs for iPhone UNIX on iPhone UNIX. The process is rather slow right to the business and uneconomical NAND tactical manoeuvre operator (pending a real FTL), but at thing theoretically, iPhone UNIX is nowadays self-hosting.

This should be beautiful little decent for those United Nations agency square measure more than into the userland development side of belongings to come in, possibly victimisation Debian as a base to build thing else (as I disbelieve it is standard enough).

I will be offer manual on how to get this no to work soon. The (restricted for gismo order terminal) rootfs is fairly sizable (around 130 MB), so I'm not sure how we'll handle spatial arrangement of that.