Sandbox Firefox – First step to security

2014-03-19 2 min read Fedora Firefox

First we will setup cgroup to limit cpu and memory usage, so here we go:

Add the configuration in /etc/cgconfig.conf

#------start cgconfig----------------
#new group
group firefox {
    perm {
        task {
#user your login id and group here, so that you can control this group
        uid = amitag;
        gid = amitag;
        }
        admin {
# same as above, set to your login id and group.
           uid = amitag;
           gid = amitag;
        }
    }
# set the limits for cpu.. by default there are 1024 shares of cpu with no other groups,
# so share of 102 would be around 10% .
    cpu{
        cpu.shares="102";
    }
# limit the cpus to be used to only 0-1
    cpuset{
        cpuset.cpus=0-1;
        cpuset.mems=0;
    }
# limit the maximum memory to 700Mb.
    memory {
        memory.limit_in_bytes="700M";
        memory.max_usage_in_bytes="0";
    }
}
#------end cgconfig----------------

 

Continue reading

cgroups – use to control your cpu and memory

2014-01-06 2 min read Fedora Firefox Learning

cgroups is a kernel feature and with userspace utilities, we can use the feature to control the cpu and memory for per process. So, lets first install the required tools.

sudo yum install libcgroup-tools

Now, we need to enable the service.

sudo systemctl enable cgconfig.service
sudo systemctl enable cgred.service

cgconfig.service is to enable configuration for cgroups and
cgred.service is to enable configuration for cgroups for processes depending on the name.

Continue reading

quick notepad in firefox.

2013-05-20 1 min read Firefox

If you quickly need to note something and you do not want to leave your browser then just add a bookmark to :

data:text/html, <html contenteditable>

and whenever you need to get the notepad, just open this bookmark. Sorry, I do not remember, where I got this from, but this is something that I did not discover but since I do not remember where I got this from, I am not able to credit the authour.

Continue reading

Firefox troubleshooting

2013-03-11 1 min read Firefox

Here are few quick tips on getting to see what could be wrong with firefox.

Config entries – about:config

Support Information – about:support

Details on config entries – http://kb.mozillazine.org/About:config_entries

Reset firefox profile – https://support.mozilla.org/en-US/kb/reset-firefox-easily-fix-most-problems

Firefox profiles – https://support.mozilla.org/en-US/kb/profiles-where-firefox-stores-user-data

 

Continue reading

Taking screenshot in firefox.

2013-02-03 1 min read Firefox

Couple of days back, I was trying to take screenshot with Firefox. As usual I started out with searching for plugins which could take a screen shot for the whole page and not just the visible portion of the page. Installed couple of them, some did not work. Finally I found something called Development Bar.

So, here is a simple way to take a screenshot. Press “Shift+F12”. This will bring up a bar in the bottom of the firefox window. To take a screenshot, type:

Continue reading

pdfjs – html5+javascript based pdf viewer for Firefox.

2012-09-05 1 min read Firefox

Firefox 15 has arrived and there is lot to brag about. Since there are already many blogs on this, so just  giving you a link to one of those. But what is most interesting is the integration of PDF.js. It is a new html5 + javascript based pdf viewer.

GHacks Link

And to enable this viewer all you need to do is go to “about:config“. Search for pdfjs and set pdfjs.disabled to “FALSE” and your browser is all set to use the inline pdf viewer.

Continue reading
Older posts