Design Article
Deciphering phone and embedded security - Part 2: What really happens during an unlock operation
Mohit Arora, Sr. Systems Engineer & Security Architect, Freescale Semiconductor
7/9/2012 8:30 AM EDT
[Part one covers the general Android architecture, including a look at the basic Android platform and the associated framework, as well as commonly used terminology like "rooting" and "flashing."]
Now that we have learned the basics and common terms of the Android world, let's link it all together to see what really happens during Rooting.
Smartphone Hardware - Typical ComponentsFigure 1 shows the typical components for smart phone hardware.

- Baseband Processor (BP): BP manages all radio functions of the smart phone and runs the GSM protocol stack.
- Application Processor (AP): General purpose processor to manage user-interfaces and applications.
The first hardware generation of smart phones did nothing but integrated the feature phone and a PDA into one case. The keypad and display of the baseband processor is removed. What remains of the feature phone is a GSM modem controlled by AT commands sent from the AP with each processor including its own memory (RAM and Flash).
With the latest and greatest smartphones, the industry has produced highly integrated products, uniting the AP and BP in one physical package. To further complicate and reduce cost, there is no need to have independent RAM and Flash chips for AP and BP. Rather, a single RAM and Flash chip is divided by assigning portions of the RAM and Flash to each of the two processors.
BP and AP are not expected to converge as there are good reasons for keeping them separate (even though they are on same package). Another important point to note is that due to good real-time radio performance, BP runs a real time OS (RTOS) like Nucleus or ThreadX while the OS on application processor may vary (Linux, Android, iOS, Symbion, Windows 8, etc.).
- Flash: This includes the main non-volatile memory that includes the operating system along with applications. Often a smart phone would include NOR Flash which is byte addressable and much faster for boot as well as kind of cache for applications. NAND Flash on the other hand is much slower and less reliable; however it is cheaper to manufacturer in bulk and is often used as main storage in the phone (media etc). Main interest is on NOR Flash as we are not really concerned about Data Flash, it being not associated with the Flashing procedure.
It is important to note that besides the usual OS and other standard stuff, Flash includes the main software components,
- MCU (Mobile Control Unit) - main program/software that runs on the phone.
- PPM (Post Programmable Memory) - determines languages available in the phone. This is also called as "language pack"
- CNT (Content) - default pictures and sounds in the phone's gallery. This could be part of the Main Flash or a separate chip.
- EEPROM: contains various settings specific to your phone, including calibration for various devices present in your phone, like the battery, camera, light sensor, RF part, etc.
Unlike in old generation phones, many of the latest phones now emulate EEPROM as part of Flash memory so there is no physical EEPROM, however this is dependent on phone manufacturer.
- OTP (One Time Programmable) Memory: These are arrays of one time programmable fuses that are part of the application processor and within the device package. These are burnt at the factory and the user does not have access to them, and they cannot be modified.


Jeske
7/10/2012 7:05 AM EDT
It sounds weird to me an freescale specialist, giving away hints about ways to unlock smartphones...If I was a smatphone manufacturer, I'm not sure if I would be happy reading such articles.. for sure not the ones coming from the guins wo will be probably supporting new devs...
Sign in to Reply
Steve_B
7/10/2012 9:25 AM EDT
Look at the titles of Part III and IV. It's clear that if you use the lousy "security" approaches he's describing, your products are easily cracked. Want to bet me that future parts will describe something better? Something made by Freescale? ;-)
I used to work in this area. Cellphone security is complicated, and many chip and phone manufacturers are still on the steep part of the learning curve of how to do it. Phone hackers are extremely clever, and any half-hearted "security" system is going to be hacked - count on it.
Sign in to Reply
Steve_B
7/10/2012 9:31 AM EDT
Let me clarify. By "if you use the lousy "security" approaches he's describing", I meant in part 2. Part 3 looks like he's going to describe a trusted boot sequence. Pay close attention, it's table-stakes if you want to play this game ;-).
Sign in to Reply
Mohit.arora
7/17/2012 6:31 AM EDT
Thanks Steve, you are correct. Part 3 is going to cover all sort of secure bootloader options while Part 4 is going to extend it further covering ideal security platform that leverages the concepts from mobile world and apply on embedded/Industrial devices that need best in class security.
Sign in to Reply
Mohit.arora
7/17/2012 6:29 AM EDT
The whole idea was to take Smarphone as this as example so people could relate it better to the applications they know and then apply the concepts to embedded world.
Part 3 will include more details on secure bootloaders while Part 4 will extend it to cover idea security platform inherits capabilities from the mobile world and can be incorporated in future embedded devices.
Would be happy to receive any further feedback.
Sign in to Reply
gayatrikumar_1
7/10/2012 9:12 AM EDT
Ok, now, People know the secret.
Smart Phone Manufacturers will become smarter :)
Sign in to Reply
JustinTALA
7/10/2012 10:25 AM EDT
excellent article guyz.
@author
can you propose further reading please ?
I'm super interested.
Sign in to Reply
Mohit.arora
7/17/2012 6:32 AM EDT
Justin, Thanks. Next part should be up in next 2 weeks (I hope) or earlier :-)
Sign in to Reply
jzwatches
10/18/2012 12:29 AM EDT
Well, as a smartphone user, I'm not quite sure whether this article is supposed to benefit me as a consumer or is targetting phone manufacturers. I have a friend who used to own an iPhone. He found an article online that provided a method to "unlock" it and he was able to customize his iPhone with personalized tones and wallpapers. Thus, from his point of view as a consumer, such articles have benefited him in a way that he is able to use his phone the way he wants the phone to work, and not be restricted to only the default phone features. However, if this article is about ensuring that your phone is safe enough from hackers who wish to invade your privacy, then I'm definitely looking forward to the upcoming subsequent articles to tell me how to be on my guards.
- http://www.jzandf.com
Sign in to Reply