Skip to content


Some must-have Firefox hidden settings

How to hide the “download finished” bubble

This is controlled by the browser.download.manager.showAlertOnComplete setting (edit it via about:config): set it to false to disable the highly annoying “download finished” popup which sloooooowwwwly appears and then diiiiiiiiisappeeeaaaars every time a file has finished downloading (this thing is particularly slow when your GPU is busy doing something else).

How to skip antivirus scanning of incoming files + don’t tag downloaded exe’s as coming from Internet

This is controlled by the browser.download.manager.scanWhenDone setting: set it to false to disable the bloody time-wasting virus scan at the end of every file download. This never caught a single virus for me anyway… Also, it makes the downloaded files bypass Windows security policy checks (the former preference browser.download.manager.skipWinSecurityPolicyChecks was merged into this one), ie when you launch a downloaded executable Windows won’t bother you with the warning popup “this program was downloaded from Internet, are you sure you want to run it?”.

How to delete words from the personal dictionary

For some reason, I find it extremely easy to accidentally add misspelled words to the personal dictionary – I guess that menu item is somewhat misplaced. On the other hand, deleting them is then a pain in the ***, notably the GUI provides no way to do this. You’ll have to manually edit the dictionary file…
It’s located in your profile folder (on Windows NT/2k/XP/Vista/Se7en, it looks like %appdata%\Mozilla\Firefox\Profiles\xxxxxxxx.default – just browse to %appdata%\Mozilla\Firefox\Profiles\ then it will be obvious -, for other OSes, check out Profile folder on MozillaZine, or even simpler go to about:support and click on “Profile Directory – Open containing folder”) and is named persdict.dat. You can edit it with any plain text editor supporting Unix line breaks (for instance Notepad++ is good, the standard Windows notepad isn’t). Make sure that Firefox isn’t running, as it will overwrite the file when you close it. Source

How to configure several profiles

Close Firefox (make sure there’s really no more firefox.exe running in the background), then relaunch it with the -profilemanager argument. On Windows, the easiest way to do is is probably to hit [Windows key]+R (for “Run”), and then type firefox.exe -profilemanager. After that, you should get the profile manager window, which should be self-explanatory enough. If you need more details, this post should be helpful.

How to prevent Firefox from trimming link URLs

That stupid feature was added when they replaced the status bar with that retarded add-on bar. Before that, when you hovered a link it’s target would show up in the status bar. As far as I remember, they then moved that preview to the address bar (with big fat huge trimming, as this is a limited and already well-filled space), and due to enough people getting upset with it, they moved it back to the bottom of the window (to the bottom-left, or when the find bar is opened (bug?), to the bottom-right), but this time above the add-on bar. BUT they didn’t remove the trimming: that URL preview is by default limited to 50% of the window’s width. Why the heck not 100%?? Anyway, to change that, go to your chrome folder (you might need to create it manually), which is located in %appdata%\Mozilla\Firefox\Profiles\xxxxxxxx.default\chrome (see the section about dictionary entries for more details and alternative OSes), then edit or create (with a plain text editor) the file userChrome.css. In this file, add the following section:
statuspanel {max-width: 100% !important;}
And voilà, when you restart Firefox link URL previews will be able to use the whole width of the window, so they shouldn’t get trimmed often, then…

How to decrease the minimum tab width

As in the previous tip, you need to create/edit userChrome.css. Add the following code (edit sizes as you wish):
.tabbrowser-tab[fadein]:not([pinned]) {
min-width: 15px !important;
max-width: 250px !important;}

How to force Firefox to display the full URL in the address bar

By this I mean, the real full URL, including the bloody http:// part. Well, I long thought this was impossible, but eventually a setting was created for this! In about:config, just set browser.urlbar.trimURLs to false. The change will be immediately visible! :)

Well, that’s all for today… Those are pretty much all the dirty hacks I need to perform when dealing with a new Fx install, apart from the ever changing extensions.checkCompatibility mess. Keeping them on a single page should make my life easier the next time I need them…

Posted in Firefox.


Looking for calligraphic letters in LaTeX?

Well, the hardest part for me was to figure out how to write “calligraphic” with my somehow unactivated spellchecker. That’s not “callygraphic”, not “calygraphic”, for instance. Anyway, as mentioned in this big guide at page 76, math alphabets such as \mathcal{yourLetter} will probably make you happy. Some funkier styles are available, such as the old gothic \textgoth{yourLetter}. Note that most of them (not mathcal, though) require some packages, as usual…

That was a short one…

Posted in LaTeX.


Oops, the FBI stole my files!

In case you’re not a regular here, over the years I’ve offered a variety of more or less large files on this site: a portable version of OpenOffice 3.2.1, a portable version of R (about version 2.11, I think), high resolution episodes of Pioneer One (that’s a free series primarily distributed over BitTorrent), Doctor Who trailers, portable versions of Flash, some other free portable or non-portable applications (7-Zip, GnuPG with unlocked key size – binary and source -, etc), my OWN application VisualGPG, Catalyst drivers, some other drivers (like, all the drivers of my computers), and other things I’m probably forgetting. That was all legal files, in total about 200 files for about 10 GiB.

Well, they’ve just all been stolen – during my sleep like a proper robbery – by the FBI, who effectively took them away when they decided to shut down MegaUpload. Although I did have a backup of my most important files, I didn’t have a backup of most of the files, which were rather there for storage or archiving. They claim they did that to fight copyright infringement, well at least copying isn’t stealing. But taking away the files is. The FBI robbed my files, should I call the police? … or maybe I should call al-Qaeda?

Anyway, for you visitors, it means that at the moment, all the files I link to on Megaupload are sadly unavailable. For a few of them, a FileSonic mirror is available. I’ll try to upload some of the others there, too. But I don’t really have the time to browse all the site looking for every missing file, so in case you need specific files, drop a comment and I’ll give them priority for the re-up, if I have a backup of them.

Update (2012-01-23)

Well, this seemed to have scared the hell out of other hosts. FileSonic, the alternate mirror where I put some of the files, also SILENTLY (as usual when they do a crappy move) disabled file-sharing (since they delete uploaded files after 30 days with no downloads I really wonder what kind of a business model they can have now…). Good thing I hadn’t moved more files to them…
Since it seems that most file hosts are (or will be) chickening out too (which I guess is understandable since they get treated worse than terrorists), I’m left with the only option to host the files on this very server. This means that there won’t be big files anymore (bye bye Pioneer One…), and also probably I won’t keep an archive of old versions apart from a few exceptions.

Update (2012-01-28)

Looks like legal action is indeed on its way, see Joint complaint of those affected by the closure of Megaupload service. Of course, Megaupload’s Terms of Service said something along the line “we reserve the right to delete your hosted files at any time”, but it didn’t reserve the right for a third party such as the FBI to do so.

Posted in digital rights and DRMs, site news, Totally pointless, web filtering.


Réponse au jeu concours PC INpact / Asus Eee Pad Transformer Prime

Exceptionally again, this post is written in French because it targets pretty much exclusively a French audience.

Encore un concours chez PC Inpact… Plus cours que les autrse celui-ci: il ne contient qu’une seule question. Cette fois il s’agit de gagner un Eee Pad Transformer Prime d’Asus.

No problem should ever have to be solved twice.

Suite à la perte de notre AAA, le moindre boost de productivité est plus que jamais bienvenu, voici donc sans plus tarder la réponse, sous réserve que je ne me sois pas trompé comme d’habitude:

  • Question 1: l’autonomie maximale de l’Eee Pad Transformer Prime (TF201), selon Asus, en lecture 720p et avec l’Eee Station (j’imagine qu’il s’agit du “dock”) est de 18 heures. Source (notez la note de bas de page “L’autonomie a été mesurée en mode économie d’énergie, avec la lecture d’une vidéo 720p, luminosité réglée à 60 nits et volume des écouteurs par défaut”). Source #2: un article de PCINpact d’il y a quelques mois déjà.

Bon, c’était court et plutôt très facile à trouver, étant donné que PCI fournissait un lien quasi direct vers la source…

Posted in Uncategorized.


Another, simpler method to bypass the Wikipedia blackout

If you’re reading this, you most likely know that Wikipedia is blacked-out to protest SOPA. Now that you’re aware of the SOPA issue, maybe you want to get back to work and access the encyclopedia. Luckily for you there seems to be quite a few methods available to bypass the blackout. And here is another one, much simpler IMO: just disable JavaScript. If on Firefox, you can simply use the NoScript extension. Although I couldn’t name them for sure, similar extensions are available for other browsers.

Edit: alright, I do the search for you:
- Noscript for Google Chrome / Iron (NB: the page fails to load for me for some reason, but that’s the URL I’m pointed to when searching for it both on Google and on the Chrome web store)
- NoScripts for Opera

Edit 2: Meh, Wikipedia itself is actually giving possible solutions. Oops.

Posted in digital rights and DRMs, Internet.


PhotoBucket edits the pictures you upload… poorly

About a week ago, this very server had some severe connectivity issues. As usual, not a problem on the server itself but bloody network mayhem: FTP and SSH were, long story short, unusable for data transfers. But I had just finished this post about OpenStreetMap and I wasn’t in the mood to delay it too much, so I though about an alternative method to “upload” the pictures it contained: upload the picture to PhotoBucket, then download it from the server (SSH was working fine enough to be able to use wget and move files around).

As usual, I thought a bit about the best way to pack the pictures, decided that the moderate JPG gain wasn’t worth the quality loss over PNG, then squished the PNGs as much as I possibly could, using OptiPNG and PNGOUT.

The second picture, as can now be seen here, was about 472 KiB in size, substantially down from about a whole MiB (slightly less actually) as originally created with Paint or GIMP (not really sure which one I used this time). But when I grabbed it from PhotoBucket… it had inflated back to 920 KiB, a whopping 95% increase! I don’t mind PhotoBucket trying to recompress my uploaded pictures, but if they fail to improve the compression (particularly when they fail that much) maybe they should keep the original…

Posted in Internet, Totally pointless.


Comparing 2 lists in R

Just a simple R script that reads a CSV file made up of 2 columns, and outputs which elements are only in the first column, which elements are only in the second column, and which elements are in both (note that it won’t count elements but will remove duplicates). Pretty simple actually (except that I tried to vectorize it a bit, so it should be a bit optimized), I’m only posting it as a backup.

Here’s the script:

myData=read.csv("MyListComparisonData.csv");
g1=as.character(unique(myData[,1])); # we'll name the first list (first column) g1. For some reason it can be interpreted as a factor (maybe because we had some repetitions, thus the need for "unique" to improve speed), so we specify "as.character"
g2=as.character(unique(myData[,2])); # second list: g2
gcommon=c(); # initialize vector for storing common elements
gonlyG1=c(); # initialize vector for storing elements specific to g1
gonlyG2=c(); # initialize vector for storing elements specific to g2

# we'll loop over g1 and see if the current element can be found in g2
repeat{
  if(length(which(g2==g1[1]))>0){ # vectorized way to check if one or more elements of g2 match the current one
    gcommon[length(gcommon)+1]=g1[1]; # if yes, we add it to the "common" list
    g2=g2[-which(g2==g1[1])]; # then we remove it from g2

  }
  else{gonlyG1[length(gonlyG1)+1]=g1[1];} # otherwise, we add it to the "g1 only" list
  g1=g1[-1]; # then in any case we remove it from g1
  if(length(g1)==0) break; # we're done emptying g1, so move on
}
gonlyG2=g2; # because we removed from g2 all common elements with g1, anything left if specific to g2

# fill with void the columns which are too small
nRows=max(length(gcommon),length(gonlyG1),length(gonlyG2))+1;
gcommon[nRows]="";gonlyG1[nRows]="";gonlyG2[nRows]="";
# now that all vectors have same length, we can put them into a dataframe
output=data.frame(gcommon,gonlyG1,gonlyG2);
# and write to disk
write.csv(output,"comparaison_result.csv",quote=TRUE,sep=",",row.names=FALSE,col.names=TRUE);

And here’s a sample CSV input file:

"elementA","elementB"
"elementA","elementB"
"elementB","elementC"

The result for this input should be: elementA is only in first column, elementC is only in second column, elementB is in both columns.

Posted in R (R-project).


A bad idea in R: using variables named like existing functions

R has an amazing robustness to programming weirdness. To give you a first idea: you can call a function with missing arguments, with named or unnamed (or truncated-named!) arguments, with badly-ordered arguments (as long as you name them), or with truncated parameter values as long as they are unambiguous. For instance, all these work and give the very same result:

curve(expr=dexp(x, rate = 1, log = TRUE),from=0,to=5);
curve(expr=dexp(x, rat = 1, lo = T),fro=0,to=5);
curve(dexp(x, rate = 1, log = T),0,5);
curve(from=0,to=5,expr=dexp(x,log = T, rate = 1));

And it is even possible to create a variable which has the same name as an existing standard function (you can’t do that with user-defined functions, though). For instance, check out this sequence:

> max=5;
> max(8,7);
[1] 8
> max;
[1] 5

We define a variable called “max”, set it to 5, then use the max() function normally, then call our “max” variable.

Falling to this kind of lazy standards, though, isn’t a good idea, because problems can arise. For instance if you name a variable like a standard function, you won’t be able to use apply() on it any more:

> A=matrix(c(1,5,2,4),2,2);
> max=5;
> apply(A,2,max);
Error in get(as.character(FUN), mode = "function", envir = envir) :
object 'FUN' of mode 'function' was not found

Posted in programming, R (R-project).


Did you know OpenStreetMap?

OpenStreetMap is a free (as in free software) alternative to Google Maps. I’d say the 2 most important differences with Google Maps are 1) the license and 2) the possibility to contribute. OpenStreetMap relies on its users to add a lot of extra data, such as shops, accommodations, transportation, banks, etc. Additionally, I don’t know if it’s the same in every other countries, but for France the building data are particularly accurate because OSM was allowed to import official cadastral data. So you get to see a very detailed view of buildings. This seems to be the case also for Vienna and London. For New York building data seem a lot sparser.

Rather than a long discussion, let’s give you an illustrative picture: here are 2 maps of Centre Hospitalo-Universitaire (CHU) Pitié-Salpêtrière, one of Europe’s largest teaching hospitals. First, the Google Map version. Then the OpenStreetMap version. Notice how the first one shows no building and very few street names (not the most noticeable ones, too!), while the second not only shows buildings but also provides the names of some of them, and also show village greens.

CHU Pitié-Salpêtrière - Google Maps
CHU Pitié-Salpêtrière - OpenStreetMap

Posted in open source.


Installing Freenet on Ubuntu server (command line)

After the Tor command line installation guide, it’s only logical to carry on with Freenet ;) It’s a bit sad how both those projects lack of crystal clear command line instructions, as, once again, they would likely benefit the most from users running them on dedicated servers, i.e. most often on GUI-less machines. This guide was made for Ubuntu, but should be remarkably similar on other Linux distributions, apart from the package manager (yum vs apt-get, I guess).

Installing Java

The main turn off with Freenet for me is that it’s written in Java. Once you’ve installed it you’ll see for yourself how CPU-intensive it actually is – much more than Tor (which on the opposite isn’t too demanding). Anyway, installing Java is now a bit trickier than before, because Oracle got their reference implementation removed from official distribution repositories, but OpenJDK works just as well so that’s what we’ll pick.
apt-get install openjdk-6-jdk
(that will be about 170 MiB of stuff to install)

Installing Freenet

Even though the headless server instructions there are a bit scary, I found them quite sufficient. It’s not that complicated to install after all (also, maybe after getting warmed up by Tor’s installation I’m a little biased, too ;) ), so I’ll just list the commands you need to type (obviously, edit the pathes), and they should be pretty self-explanatory:
cd /where/you/want/to/install/it
mkdir someFolder
cd someFolder
wget https://downloads.freenetproject.org/alpha/installer/freenet07.tar.gz --no-check-certificate
tar xzf freenet07.tar.gz

Now we need to create a user for Freenet, give it a password and assign them the freenet folder:
useradd someUserName
passwd someUserName
[enter the password twice]
chown someUserName freenet -R

First Freenet launch, configuration

Connect to the machine where you just installed Freenet as this someUserName, go to the freenet folder and run run.sh:
cd /where/you/want/to/install/it/someFolder/freenet
./run.sh

FYI (actually, more for my personal archives ^^), here’s the output:

Enabling the auto-update feature
Detecting tcp-ports availability...
Downloading update.sh
Downloading wrapper_Linux.zip
Downloading freenet-stable-latest.jar
Downloading freenet-ext.jar
Downloading the JSTUN plugin
Downloading the UPnP plugin
Downloading seednodes.fref
Installing cron job to start Freenet on reboot...
Installed cron job.
Starting Freenet 0.7...
Please visit http://127.0.0.1:8888/ to configure your node
Finished

Now, you need to connect to http://127.0.0.1:8888 to configure Freenet. If, as is likely since you’re reading this tutorial on console-based installation, it’s not on the same computer as where you are now, you have 2 options:
- follow this to allow external IPs (preferably, just a specific one: yours ;) ) to connect to your Freenet node
- create an SSH tunnel to your machine (see the second half of this old post), and then when your browser is configured to use it (NB: don’t forget to remove “127.0.0.1″ from the exclusion list, in Firefox called “no proxy for”), going to http://127.0.0.1:8888 will actually go to your server.

Well, that’s pretty much it, now just configure it from the GUI as you wish. Here are a few hints, though:

  • You should increase the RAM available to Freenet. By default it’s 128, it would be a good idea to at least double it. Actually 512 MiB would be even nicer. Note that you’ll have to restart Freenet in order for the change to be applied. The RAM can also be configured manually in wrapper.conf:
    wrapper.java.initmemory=60
    wrapper.java.maxmemory=512
  • You’ll probably want to review input and output bandwidth settings (although you already had the opportunity to do so during the first launch wizard)
  • You’ll want to increase the datastore size (this helps the network) and the client cache (this helps you ;) ), because during the first launch wizard you aren’t really given much choice for some reason… Respectively 50GiB and 25GiB could be fine for instance, although of course you can increase that much more. Note however that whenever you change those settings Freenet will rebuild it’s database, which means it will be somewhat slower for a while.
  • Finally, it’s probably a good idea to install some social plugins such as WebOfTrust and Freetalk (both are official plugins), which will give you access to discussion boards. Other plugins of interest: Sone (kind of a social network), Library (search engine), Freenet Search (search engine too).

Bonus: solving the “There isn’t enough entropy available on your system… Freenet won’t start until it can gather enough.” error

Freenet seems to have massive needs for entropy, and if you happen to run out of it, it might take some time to spontaneously replenish. A quick way to boost this is to generate lots of disk access. I saw the suggestion of running find / >/dev/null, but it didn’t help a lot for me, maybe because my HD isn’t that filled. What worked great was to either copy a big directory, or even simpler, to download some large file, like: wget ftp://ftp.free.fr/mirrors/ftp.ubuntu.com/dvd/current/precise-dvd-amd64.iso

Bonus 2: restarting/stopping the node without using the web GUI

The ./run.sh script can be run with arguments, such as ./run.sh restart or ./run.sh stop

Posted in cryptography, privacy, servers.