Blog Archive


TeleHash: an encrypted p2p network for your apps

Date: 12 Nov 2013
Tags: [ dht ]  [ encryption ]  [ json ]  [ kademlia ]  [ p2p ]  [ telehash

In the current day and age, using a plain HTTPS connection might not be the most secure way to communicate anymore. Sure, for your purposes and goals we can assume that this communication is safe enough, but cracks are appearing in the security, and we might need to move to better, more secure ways in maybe a shorter period than anyone expected. But how do we do this? We are not crypto-experts, and you probably have no idea how HTTPS works to begin with. Should we find ourselves a secure way to encrypt our data? Should we “invent” new methods that look safe, just because it’s too complex to explain what’s going on?


Yearly mail routine

Date: 22 Oct 2013
Tags:

**January 1, **

This year will be different. I will sort all my mail directly into different mailboxes. I will make sure my inbox will be 0 at all times. Yes! This is going to be an awesome worry-free mail year!


FullSpectrumLaser aka: why you should think twice on buying from them

Date: 21 Jul 2013
Tags: [ full spectrum laser ]  [ lasercutter ]  [ no service

After buying a secondhand generic Rabbit laser cutter, I immediately fell in love with laser cutting and engraving. It really rocks, you can make really neat things and we even use it for promotion for my company. Awesome stuff, but our laser cutter wasn’t good enough: it’s a pretty cheap chinese manufacturing, with buggy software that only can communicate through a LPT port (remember those, me neither). So we decided to take a look around to see if we could find a better cutter, and we came out at Full Spectrum Laser. We decided to buy a laser cutter from them:  - worst - decision - ever..


PHP's Resources and garbage collection

Date: 10 Jul 2013
Tags: [ deamon ]  [ garbage collection ]  [ PHP ]  [ strace

Today, I’ve found a nice bug/feature/whatsmathing in PHP. I was playing around with writing a daemon and if you have any experience writing daemons (in any language), there are a few rules you have to live by. For instance, setting your effective uid and gid to a non-privileged user (in case you needed to do some privileged initialization, like opening a socket on a tcp port < 1024), setting the process as a group leader with posix_setsid(), and redirecting stdio file descriptions. And here something went wrong which took a while to find and fix..


Twitter Customer Support: the best thing that happened for customers and companies

Date: 07 Jul 2013
Tags: [ social media ]  [ twitter

I’m not a social media 2.0 hipster kinda guy. I use Twitter a lot on personal account, I do not have Facebook. But i do some LinkedIn. There’s lots of power in (ab)using social media, I understand this, and I understand I do not use their full potential (nor I want to do so). However, there is one case I like to use social media with Twitter in particular: complaining to companies. Why? It works.. and almost at a 100% satisfaction rate.


Saffire update may 2013: coalesce

Date: 22 Apr 2013
Tags:

One of the things that happens over and over again is that you need to check a value, and if it’s not set, it should set a default value. Normally, these variables could be initially set by properties, but sometimes you don’t have any control on initialization. For instance, when these values come from users.


Scrum issues: being agile isn't easy..

Date: 01 Apr 2013
Tags: [ scrum

I do a lot of consulting work and because of this I see lots of different development processes at many companies. Some of them are good, but most of them are not. And this problem isn’t caused by lack of trying, but of lack of expertise. Most - if not all - software development departments I visit try to be “agile” by implementing scrum. But unlike what many people think, implementing scrum in an efficient way isn’t that easy. It takes time and effort on ALL levels of a company. If your clients, or IT department aren’t ready to do scrum, then you won’t succeed either. You could of course, implement some of the facets of scrum, but scrum - it is not.


How Saffire doesn't do things different

Date: 21 Feb 2013
Tags: [ saffire

The question I get asked a lot, is what makes Saffire different? The most honest answer: nothing. There is absolutely nothing that makes Saffire different from other language, because Saffire doesn’t do things different. And there is a good reason for this: after many decades  of developing languages by many and much smarter people than yours truly, I do not pretend to have found the correct way on how to do things different - and better.


PHP5.5: Try/Catch/Finally

Date: 12 Feb 2013
Tags: [ catch ]  [ exception ]  [ finally ]  [ PHP ]  [ try

Exception handling is available in PHP since version 5.  It allows you to have a more fine-grained control over code when things go wrong ie, when exceptions occur. But since PHP 5.5, exception handling has finally evolved into what it should have been from the beginning: the finally part has been implemented.


Custom symfony2 config loader

Date: 30 Jan 2013
Tags: [ custom ]  [ loader ]  [ PHP ]  [ symfony2

It happens more and more: large projects where your symfony2 site is just a small part in the big picture. Lots of additional components might even play a bigger part, especially when you are dealing with asynchronous components  which are connected through message queues for instance. So the question is: we want to make sure that all your components are using the same settings, be it your symfony2 project, your bash-scripts, 3rd python application and whatnot. How do we keep this all in sync?


Saffire january 2013 update

Date: 26 Jan 2013
Tags: [ saffire ]  [ varags

Most development languages will have some kind of printf() functionality. It takes a string, and can have optional arguments, depending on the placeholders you have set inside your string.


Saffire - Programming the web since 2013

Date: 20 Dec 2012
Tags:

So, Saffire started as a way to “learn” a bit about flex/bison. I’ve dealt with these systems before a long time ago (pre-2K), and i forgot lots about them. So it was about time for a refreshal. Unfortunally, looking on the internet for tutorials, almost all of them are about how to write a calculator (bison’s version of “hello world”, most probably). Very soon, I decided to try and parse my own language, with some idea’s I collected over time on how *my* favorite language should look like. Two hours later: Saffire was born.


Debugging remote CLI with phpstorm

Date: 20 Dec 2012
Tags:

Even in these days, with full-featured PHP IDEs around,  I still see PHP developers using var_dump() and die() to debug their code. Not only is this a very bad way of “debugging”, it has other dangers as well, like side-effects on calling (non-idempotent) methods multiple times, not removing debug statements and possible even committing this to the VCS repository, which gets send onto your production environment. We’ve probably all been there,.. But we don’t have to. Debugging your code properly through an IDE is quite easy, but one of the major problems is debugging CLI code. Since many frameworks like Zend, Symfony and micro-frameworks like Cilex can be used to create command-line apps, cronjobs and even daemons, so how do we easily debug this kind of code?


Introducing the REST cookbook

Date: 12 Dec 2012
Tags:

One of the many things I do, on pretty much a weekly basis, is answering questions about REST and HTTP. Is this status code correct for X, should I use POST or PUT, is this hateoas enough, how do i handle logins in a RESTful API etc, etc…  This is why I decided to setup a simple website, that pretty much tries to answer any question about REST.  It’s not completed yet.. Actually, it hasn’t got many posts to begin with :), but a start has been made and we will fill it with questions and answers about REST and HTTP issues.


Saffire: december 2012 update

Date: 10 Dec 2012
Tags:

A few months ago I started with a new programming language called Saffire, and it’s time for an update. Since then, we have merged over 100 pull requests, and the number of contributors is steadily increasing. This post is explains of the functionality we already implemented (or want to implement).


Installing composer: russian roulette.

Date: 15 Oct 2012
Tags:

I love working with composer. I think it’s a really neat way of dealing with dependencies in (PHP) projects and it’s not for nothing that big frameworks like symfony2 are using composer as their primary way of handling bundles and other components. But this blogpost is not about problems with composer (well, not really anyway). It’s about installing composer. It is fundamentally wrong, and it sets a very, very bad precedent for both experienced and inexperienced (php) developers.


Writing a language

Date: 17 Aug 2012
Tags: [ ast ]  [ bison ]  [ flex ]  [ grammar ]  [ lex ]  [ saffire ]  [ yacc

In the last blogpost I was talking about a new language in the making. Unfortunately, writing a complete new language - from scratch - isn’t as easy and takes a fair bit of time. During this development process, I will try and blog a bit on the things we are developing, the problems we are facing and the solutions we are implementing. The current Saffire status: we are able to generate AST tree’s from   Saffire source programs. If you have no clue what I’m talking about, no worries: this blogpost will try and explain it all.


Saffire: A dive into a new language

Date: 04 Aug 2012
Tags: [ bison ]  [ flex ]  [ saffire

Confused by Perl? Bored by Python? Ruby too 2011? What’s the alternative? PHP? Come on!  Well, seek no further since here is the next language for at least the coming decade: Saffire!


MultiParamConverter for Symfony2

Date: 04 Aug 2012
Tags: [ annotation ]  [ bundle ]  [ multiparamconverter ]  [ symfony ]  [ symfony2

If you know Symfony2, you probably are using (or at least, have heard of) the @paramConverter annotation from the SensioFrameworkExtraBundle. This is a really simple way to convert slugs into entities. But lots of times I find myself having multiple slugs inside my routes, and this is something the @paramConverter annotation cannot do. So that’s why I’ve created the multiParamConverter.


Using varnish to offload (and cache) your OAuth requests

Date: 06 Jul 2012
Tags: [ oauth ]  [ offloading ]  [ varnish

For a current project both me and a colleague are working on a big API system that authenticates through an OAuth system. Normally, such an API does all the necessary OAuth checking, handling of tokens etc, but we wanted to have a system that actually offloads our authentication just the same way one could offload HTTPS traffic for keeping the API simple, extendible and even performant.