Much of the analysis provided so far has honed in on one or more of the many modules donned by Flame, which provides it with functionality to persist, propagate, and gather data from target systems. Flame is currently known to contain 20 unique modules whose purposes in life range from hijacking the Windows update process (named Gadget and Munch), to an Autorun infector, which is now known to provide a direct link to Stuxnet via resource 207 (from Stuxnet.A). It will likely take much of the rest of this year for Flame to be more exhaustively understood, but I wanted to take a moment to reflect on what we do know and what we can infer with regard to those responsible for its creation and operation.
Be prepared. Flame was prepared, unlike any malware framework that we have seen in the public domain before. While few of Flame's components were truly unique from a functionality standpoint, their integration in a single framework is pretty impressive. This clear, modular design is indicative of a mature development operation that likely assigned a number of teams to the development of each of Flame's modules. Development of code in this manner also supports a compartmentalized approach to Flame's development -- meaning that no single module developer need be necessarily familiar, or have any knowledge of other modules being developed in parallel to theirs -- or, indeed, be aware of the overall complexity and mission of Flame.
I do find it slightly curious that the authors of Flame decided to incorporate most of its features into a single assembly. When penetrating an environment, different systems are going to have differing values to you as an attacker. As such, you’re going to typically load tools onto compromised systems based on what you plan on leveraging that system for. Flame chose to load all of its modules onto infected systems ahead of time -- which has the advantage of everything being there should you need it -- but has the distinct disadvantage that should you be detected, the entire framework and any add-on modules are now in the hands of your targets. This isn’t really something that I’ve ever considered before, given that nothing we’ve seen before is this complex, but it does make me wonder whether Flame's authors intentionally made this design decision based on its original targets residing on closed networks where its operators would be unable to load and unload modules in a more on-demand manner.
While somewhat interesting, most of Flame's modules all relate to functionality that we have seen elsewhere before. These include audio recording, screen capture, Bluetooth device-snooping, and so forth. One feature sticks out above the rest: Flame leveraged malicious software, signed by a seemingly authentic Microsoft certificate, in order to subvert the Windows update process.
In order to achieve this, Flame exploited a previously unknown “chosen-prefix” collision in the MD5 hashing algorithm. Although practical collision attacks in MD5 have been demonstrated in the past, this particular method was previously unknown -- and clearly the work of crypto mathematicians, of the sorts you are most likely to find at academic institutions and, yes -- working for governments.
Marc Stevens, one of the original researchers responsible for previously documented attacks against MD5, noted on his blog:
"Using our forensic tool, we have indeed verified that a chosen-prefix collision attack against MD5 has been used for Flame. More interestingly, the results have shown that not our published chosen-prefix collision attack was used, but an entirely new and unknown variant. This has led to our conclusion that the design of Flame is partly based on world-class cryptanalysis."
In many regards, this feature alone gave Flame the potential to spread more effectively and silently than any buffer overflow, logic bug, or privilege escalation flaw could have ever provided. Research breakthroughs like this are far less common than others in the security arena, making this feature more valuable than any conventional 0day that you might stumble across in your typical crime ware.
This is not the type of offensive technology that any entity is going to let go of without good cause, and so its presence in Flame provides us some valuable insights into how critical Flame’s higher level purpose was in the eyes of its possible state sponsor. My guess would be that whoever was responsible may well see the use of cyber in this context, as one of a number of last resorts prior to an armed conflict with the target. And in that event, it could well have been part of an ongoing contingency plan preparing both the cyber and physical battlefields.
Tom Parker is the CTO of FusionX