What's New!

Chat with

How to Defend
Your Computer 

The Guides
to (mostly) 
Harmless Hacking

Happy Hacker 
Digests (old stuff) 

Hacker Links 


Meet the 
Happy Hacksters 

Help for 



It Sucks 
to Be Me!

How to Commit
Computer Crime (not)! 

What Is a 
Hacker, Anyhow? 

Have a 
Great Life! 

News from the 
Hacker War Front

More Fun with Firefox

How to Modify Firefox Even if You Don't Know How to Program

After awhile it gets boring just making Firefox perform tricks that are already written into it. It's more fun to make Firefox do entirely new things. The easiest trick is to change the images it displays. Click My Computer and run a search on the files inside your Firefox program, which usually is located at C:\Program Files\Mozilla Firefox\. If you search for all files ending with ".gif" you'll get a bunch of tiny pictures. What would happen if you made them bigger and/or different?

Below is a screen shot I made when I first set Firefox to deny access to images on a server different from the site in the URI bar and to block all ads. This caused a lot of broken image icons to appear on the New York Times website. Then I changed the broken image icon a teensy bit:

Broken image icons beomce smiley faces

You can also find images that end with .png. However, the biggest images are hidden from your IE search function but a good hacker can find them. I'll show you how later in this guide.

You can learn many other ways to alter a compiled program to make it hilariously hacker-like using nothing more than a hex editor at http://happyhacker.org/harmless/hex.shtml . That Guide shows how to do it to the Windows operating system, but the same techniques work on almost any other software under almost any operating system.

How to Modify Firefox if You Can Program or Even Just Want to Learn How

Hex editing programs is fun enough, but the tricks you can play with this are limited. If you can program, and if you can get the source code to the program you want to alter, you can do just about anything to it. The Mozilla Foundation website lets you download the source code to all its programming projects, so this is a great place to start.

An easy way to begin if you have never written a program before is to find cascading style sheets within Firefox. These control how certain web pages look in Firefox. They all end with the extension ".css" and they are easy to change even if you have never coded a single line of a web page in your life. You can find the names of these files by viewing Firefox.exe in a hex editor.

This works with finding any of the cool displays you get in Firefox from putting unusual commands in the URI window. For example, put about: mozilla into the URI window and then click View --> Page Source. This tells you the source code for that web page on display is hidden in C:/Program%20Files/Mozilla%20Firefox/chrome/toolkit.jar.

We can also view the location of the page that embeds the brand image when you type about:mozilla by inputting chrome://global/content/about.xhtml into your URI window:

Any file ending in .jar is a Java archive file. This usually would tell us that Java is one of the languages used by Firefox, and that you need to learn how to program Java if you want to alter these.

However, Robin Sheat has kindly pointed out that "In the case of Firefox, it's not Java. Firefox doesn't use Java (with the exception of Java applets which are quite different). It just happens to use the .jar format (which is actually just .zip, although it has a standardised layout of the things inside) as a convenient way to bundle many files together. If you're a Linux user, install the terminal file manager 'mc'. It will let you easily see inside the .jar files. Often, you can double-click
them and they'll open in an archive viewer if that's your thing."

More Fun with Firefox --->>

Back to the Guides to (mostly) Harmless Hacking --->>  
Carolyn's most
popular book,
in 4th edition now!
For advanced
hacker studies,
read Carolyn's
Google Groups
Subscribe to Happy Hacker
Visit this group

© 2013 Happy Hacker All rights reserved.