A BLACK DOT!
Yes, you heard it right. The most interesting thing that I saw today was a black dot.
Since few days a message which crashes your whatsapp has been making rounds on whatsapp and has taken over the internet.
The message is simple one and looks like the one in the image below:
And it really does crash your WhatsApp.
Now, the beauty isn’t that it crashes your app but is in the way it does.
Before diving into how it does this, lets understand what is Unicode. Unicode is the international standard for representing text. For example, characters like ‘a’, ‘b’, ‘ ‘, etc are all represented by a unique code. Each character has its own unique code. Now, there are some characters that are not visible to us, as they are meant for the system or machine that you are using.
Two such invisible characters are:
RIGHT-TO-LEFT MARK ( U + 200F )
LEFT-TO-RIGHT MARK ( U + 200E )
This characters direct the system to change the way adjacent characters are placed. LRM(Left-to-Right) is used in english language which is read from left-to-right and RLM(Right-to-Left) is used for languages like Arabic where characters are read from right-to-left.
Now we are all set to see the magic that the black dot does!
In the image above, the message only contains a black dot and a text that says “touch here”.
OK! Lets decode this simple and harmless message so that we can see all the characters (even the invisible ones)
After decoding it looks like this:
If you look closely you will see a pair of unicode characters repeated number of times.
Ahh! This is nothing but LRM and RLM characters repeated in pair number of times.
Now when WhatsApp processes this message, repeated change in direction of text takes up too much processing power, eventually crashing your app.
The thing that amazed me the most is there is no complex algorithm to crash your app, just two invisible characters repeated over a number of times. Its that SIMPLE!
The creators of this message really believed in “ There is beauty in Simplicity.”