Sunday, 13 January 2013

How to write a binary file format

Recently I wrote a small tool (mediaextract) that can extract several file formats from arbitrary binary files. While writing this I had to look at many file format specifications. It quickly came apparent to me what are the dos and what the don'ts when it comes to binary file formats and their documentations, so I thought I summarize them here.

Thursday, 1 November 2012

Social Share Privacy

More and more websites use like-buttons from Facebook, Google+ and Twitter. However, these buttons send information to these social networks even if the user do not click them, but only if they are present on a webpage. This way these networks are able to track which websites users are visiting and are able to build fairly complete browser histories of their users. Because this is neither what a user might expect nor what many website operators that embed like-buttons want, heise online developed a jQuery plugin that provides an alternative way of using these social services.

Thursday, 31 May 2012

Cross site HTTP Auth via JavaScript

The best way to authenticate against another website is of course OAuth. But sometimes such an mechanism is not provided. E.g. Magnatune.com currently only supports HTTP Auth. Now that is something completely different, you might say (no communication between the two web servers possible). Well, once authenticated via HTTP Auth with Magnatune.com any site can embed a HTML5 audio element to play the member streams instead of just the free versions. So to enable a member feature in my Magnatune Player Greattune Player I came up with a hack to authenticate against Magnatune via JavaScript. Actually it's several hacks for different browsers and browser versions.

Saturday, 26 May 2012

Add Browser Ponies to your Blog

Because I was asked how to add Browser Ponies (a Desktop Ponies implementation in JavaScript I wrote a while ago) to your blogger blog I thought I write a howto here.

For adding Browser Ponies to your tumblr see here. And here is a video showing how to make a Browser Ponies bookmarklet.

Monday, 7 May 2012

Save/download data generated in JavaScript

Because I was bored I wrote a HTML5 player for Magnatune: Magnatune Player Greattune Player [repo]. Besides learning jQuery, HTML5 audio and HTML Drag and Drop I also developed a method to save playlists to files.

Everything except the search is implemented in JavaScript, so the server never knows the playlist. Because I didn't want to send the playlist to the server just so the user can download it I investigated what methods there are to save data generated in JavaScript. I came up with the solution presented here. It does not use Flash or a echo server and is therefore supported in every recent browser except Internet Explorer before the version 10.