Random knowledge shared...
SOLID - the O is for Open Closed Principle
In the second installment of this series we will be looking at the Open Closed Principle (OCP), responsible for the O in SOLID. This principle is extremely important if you accept the premise that all software systems change during their lifetime. If you want to design systems that need to last beyond their very first versions adhering to the Open Closed Principle is paramount.
Read more about "SOLID - the O is for Open Closed Principle"
SOLID - The S is for Single responsibility
SOLID is an acronym that stands for five different principles that have to do with clean object oriented code. Lately the term SOLID seems to get more widespread in the community of PHP developers. Talks are given, blogs are written and information is shared. What I'm missing in all these is a thorough explanation of why these principles matter. I see a lot of explanations of the principles, but the why is lacking. I will try to create a series showing the why of each of the five SOLID principles, starting with the S of Single responsibility.
Read more about "SOLID - The S is for Single responsibility"
Book Review - Growing Object-oriented software guided by tests
Recently I've been reading Growing Object-oriented software, guided by tests (Freeman & Pryce) and I thoroughly enjoyed it. I've been getting into unit testing and test driven development (TDD) lately and as such I am convinced TDD works and unit tests are vital to your application.
The only problem is, there is a lot of text on writing unit tests and there usefulness, but I haven't seen much fully worked out examples of a TDD cycle. This book provided exactly that!
Read more about "Book Review - Growing Object-oriented software guided by tests"
Currently on PHP's internals - Property Accessors
My last article discussing the current status of PHP's internals was quite well read so it is time for another update. Today I will be discussing a feature that at this moment is called "Property Accessor". It is a method of defining getters and setters. Originally an RFC was defined as early as september 2009, but recently new discussion took place and an actual patch was created. There is no certainty this feature will ever make a PHP version but discussion seems to target implementation details and not the feature itself, so things are looking bright for this feature.
Read more about "Currently on PHP's internals - Property Accessors"
The real problem of the hash table dos attack
Yesterday I read a tweet about something being fixed in the PHP core. Curious to what exactly was fixed I started reading. It appears that Julian Wälde (zeri) and Alexander Klink (alech) have presented a way to use the way hash tables solve collisions on different entries as a method of attacking web platforms.
Since the attack is well covered I will explain it only briefly and mostly refer to good explanations. But more important than the attack itself is the way it was handled by various communities. To give a hint, it wasn't handled very well. At all.
Read more about "The real problem of the hash table dos attack"
I am a developer at