3 ms·
IMO, the plethora of poorly written articles and tutorials is the ultimate culprit here. You'll find few go into detail regarding file extensions vs. mime types
by jqueryin 15y ago
IMO, the plethora of poorly written articles and tutorials is the ultimate culprit here. You'll find few go into detail regarding file extensions vs. mime types, file permissions, file ownership, or anything under the hood. When a beginner is left to their own devices with some sample code that doesn't mention the implications of not taking security seriously, we're left with swiss cheese implementations.
This may inherently be due to PHP's age. As an early dynamic language, it could be expected that the earliest shared source code and tutorials would likely contain bugs.
- kijin 15y ago> it could be expected that the earliest shared source code and tutorials would likely contain bugs. Unfortunately, a lot of recent PHP tutorials published in seemingly up-to-date websites also contain WTF code. Case in point: this tutorial [1] showed up on reddit a couple of days ago. [1] http://www.anil2u.info/2011/06/object-oriented-programming-in-php/ http://www.anil2u.info/2011/06/object-oriented-programming-i... Nowadays, I view any PHP code outside of Stack Overflow and Github with the utmost suspicion.
- infinity 15y agoA couple of days ago a tutorial "PHP MD5 Secure login script" showed up on Hacker News: http://news.ycombinator.com/item?id=3084834 http://news.ycombinator.com/item?id=3084834 The article has later been removed from the site.