Get Cracking

I found an interesting puzzle posted by the FBI recently. It is a challenge to decipher some code. The code is a bunch of symbols. Heopfully each symbol is just a reference to a certain letter or character. The FBI was nice enough to show us where the spaces are in the words.

My interest is to see if I could maybe write a program to do the cracking for me. The symbols look like they each have nine positions. Those positions are sometimes occupied by a circle. When the circle is present, it is filled in with one of a few different colors.

Well I could scan in the picture with my software. Divide up the words by the spaces between them. Then identify where the circles are and what colors they contain. I could definitely represent this as something better that symbology with circles. In fact, assuming this is a simple substitution cipher, I would just want to represent each distinct symbol with a number.

Then I could perhaps do some sort of brute force deciphering. The software should know which letters occur most frequently in normal text. Then it could choose a mapping based on how often the letters show up in the encoded message. Then it could take each word using the current mapping, and see whether the words are in a dictionary.

The software, if fast enough, could iterate through all possible combinations of mappings. Then it could generate a score for each mapping based on how many words are spelled correctly accoring to a dictionary. The software would then present the translation for the highest scoring mappings to the user, who could make the final determination as to what makes sense.

Screen Scraping to the Rescue

I play this online game these days. It is a casual turn based game. Nothing heavy. It is a bit addicting. Occasionally I look to compare my progress against other players. There is a ratings board on the web site. But here is the problem. Every so often, I get a message stating that I visited the ratings board too often. Then I cannot see my rank. WTF?

This is a free game. So it is not like I am losing money. But this should not be that hard. There are around 1000 total players. At any given time, only 10 of them are online. How hard can it be to support a rankings page? Yeah they are probably querying a database, and sorting my character level and experience.

What? Are they running an Excel database LOL? I bet it is MySQL. And hello? Can you cache the data please? Performance problem solved. No charge. Time to take matters into my own hands. I hear the source code for the site is available. No need for me to whine. I should just implement the cache idea and demonstrate an elegant solution.

My first step was to get a snapshot of all the ratings screens. Next I am going to code up a parser to grab the raw data out of the HTML. Then I think I will import this stuff into my own database. Might not even need to do the caching if I tune the SQL correctly. For now I may just use a free Oracle database. I could just as easily use MySQL. I think I already have an instance running on my machine right now.

This is going fun. In the end, might even need to host the game on my own site. Pwned.

Errors Give me the Log

I was trying to read an article or a blog entry. Took a while for me to get to that tab in my browser. When I did, saw the following stack trace in the browser:

Traceback (most recent call last):
  File "/base/python_runtime/python_lib/versions/1/google/appengine/ext/webapp/_webapp25.py", line 714, in __call__
    handler.get(*groups)
  File "/base/data/home/apps/s~combemmu-hrd/1.366712374553545399/main.py", line 432, in get
    if self.blog(self.request.path[1:]):
  File "/base/data/home/apps/s~combemmu-hrd/1.366712374553545399/main.py", line 230, in blog
    posts = [BlogPost.get_by_key_name('p' + slug)]
  File "/base/python_runtime/python_lib/versions/1/google/appengine/ext/db/__init__.py", line 1275, in get_by_key_name
    return get(keys[0], **kwargs)
  File "/base/python_runtime/python_lib/versions/1/google/appengine/ext/db/__init__.py", line 1533, in get
    return get_async(keys, **kwargs).get_result()
  File "/base/python_runtime/python_lib/versions/1/google/appengine/api/apiproxy_stub_map.py", line 604, in get_result
    return self.__get_result_hook(self)
  File "/base/python_runtime/python_lib/versions/1/google/appengine/datastore/datastore_rpc.py", line 1450, in __get_hook
    self.check_rpc_success(rpc)
  File "/base/python_runtime/python_lib/versions/1/google/appengine/datastore/datastore_rpc.py", line 1222, in check_rpc_success
    rpc.check_success()
  File "/base/python_runtime/python_lib/versions/1/google/appengine/api/apiproxy_stub_map.py", line 570, in check_success
    self.__rpc.CheckSuccess()
  File "/base/python_runtime/python_lib/versions/1/google/appengine/api/apiproxy_rpc.py", line 133, in CheckSuccess
    raise self.exception
OverQuotaError: The API call datastore_v3.Get() required more quota than is available.


Yum. What is all this good stuff? Guess maybe too many people were viewing the blog entry? I got a good view of some of their directory structure. Obviously they are using Python, and also Google App Engine. I wonder if they meant for me to see all this?

More importantly, is there anything I can do with all this information? Maybe I just got some insight that could come in handy. Just tried to refresh the page again. Still spitting out the stack trace. Something is hosed.

Hiding the Payload

Just read this interesting post on sneaking an Easter Egg into the Cucumbertown application. The source code was being watched by peer reviewers. So they had to get tricky. They wanted a song to play when they pressed the secret key combo. They hid the data for the song within an image. The tactic is nothing new. But I like the ideas behind using this to get past the watchguards.

Still not sure I understand how they hid the code that actually played the music. Maybe you can follow. Check out the original post on this early hack. Be warned. These peeps code in C#. Ouch.

Veti-Gel Stops Bleeding Immediately

New York University student Joe Landolina has come out with an amazing product. It is called Veti-Gel. It stops bleeding immediately when applied. We are talking about 10 seconds or less here. You apply it to the wound. It holds its own pressure. You don't need to press down on it.

The gel uses plant polymers to get the job done. Joe calls this platform technology. It also helps to start the healing process. It allegedly can stop the bleeding from punctured organs. Orignally this was called Medi-Gel. That name matches the one from the Mass Effect video game.

This obviously has military applications. Joe is trying to get a grant from the Department of Defense. The Army already has a similar product calls QuickClot that it uses. Hospitals use another product that is similar.

Right now Joe is trying to get approval from the Food and Drug Administration. They will start doing tests on animals next. Joe has filed a patent for this breakthrough tech. Obviously this need to go through a lot of trials. Others call this in the early stages. But damn. This is exciting stuff if it is for real.

Software License


I needed some software for a class I am taking. Thought I could just download the free version. Nope. The company took that version off the market. Okay. Let's price the commercial version. It costs $1000. WTF? That does not even include documentation or install media. They do have a lite version for $500. Also a fail. That's about how much my whole college course for the semester costs. What's a starving student to do?

My initial instinct was to head to the Windows registry. I had signed up for a free 30 day trial. Maybe I could hack that somehow. It was not obvious how to do that. Then I searched around for some license codes on the net. They were easy to find, and surprisingly, they worked. If that had failed, I would maybe have to resort to running a keygen. I always fear it would also leave some malware on my system though.

I told my instructor about the fail. He said that as an instructor, he might be able to get 1 copy of the software for free. But he was going to keep that for himself. He did share some ideas on how to extend the trial. He thought we could just keep resetting the system clock on our PCs. Our he thought the key might be stored in a browser cookie. That seemed weird since this is not a web app.

There was one piece of good news to go the legit route. My instructor said the company does provide a 30% discount to students. So the lite version costing $500, with a 30% discount, would be $350. That is still way too much money for the piece of software I needed. Sure it was good software. But it did not do that much. As a last ditch legit effort, I could talk my company into buying me a copy of the software. They have big bucks in their budget. And I am learning this stuff for work.

Pwn2Own Happening Now

I just heard about the Pwn2Own competition going on in Vancouver right now. It is taking place at the CanSecWest conference. The conference specializes in digital security. Hewlett Packard and Google are backing the contest with some sweet prizes. Prizes for pwning the latest version of browsers top out at $100k. Bamm.

This is not a new competition. It has been held in previous years. But Pwn2Own had previously focused on browser vulnerabilities. Now the goal has been broadened to include browser plugins. You got to break the latest version of the browsers running on the latest operating systems. And they got all the current patches installed.

You cannot work for HP or Google to enter. And yeah you got to be 18 years old at a minimum. You must be registered for the CanSecWest conference to qualify. Bad news is that it costs $2200++ USD to get into the conference at this late date. I guess this only makes sense if you were already planning to attend the conf. Then again, the high cost of entry might minimize the competition.

One cool thing about the compeition is that you get drawn at random to attack the machine and browser. Then you go to work to hack an exploit. You got 30 minutes to break in. Then you got to hand over all your details to collect your prize. Of course HP will pass the info on so the holes can be plugged. This is a legit opportunity.