Slashdot Mirror


Why Do Web Developers Keep Making The Same Mistakes? (hpe.com)

An anonymous reader quotes HPE Insights: Software developers and testers must be sick of hearing security nuts rant, "Beware SQL injection! Monitor for cross-site scripting! Watch for hijacked session credentials!" I suspect the developers tune us out... The industry has generated newer tools, better testing suites, Agile methodologies, and other advances in writing and testing software. Despite all that, coders keep making the same dumb mistakes, peer reviews keep missing those mistakes, test tools fail to catch those mistakes, and hackers keep finding ways to exploit those mistakes. One way to see the repeat offenders is to look at the Open Web Application Security Project Top 10, a sometimes controversial ranking of the 10 primary vulnerabilities, published every three or four years by the Open Web Application Security Project... It boggles the mind that a majority of top 10 issues appear across the 2007, 2010, 2013, and draft 2017 OWASP lists...

It's sad that eight out of 10 of the issues from 2013 are still top security issues in 2017. In fact, if you consider that the draft 2017 list combined two of the 2013 items, it's actually nine out of 10. Ouch... What can you do? Train everyone better, for starters. Look at coding and test tools that can help detect or prevent security vulnerabilities, but don't consider them silver bullets. Do dynamic application security testing, including penetration testing and fuzz testing. Ensure admins do their part to protect applications. And finally, make sure you establish a culture of security-aware programming and deployment.

335 comments

  1. Wrong by hcs_$reboot · · Score: 5, Insightful

    That's not the same web devs making those same mistakes. Developers with some experience do not write code that fails against easy sql-injection. But companies prefer to hire younger inexperienced devs for the reasons that have been discussed here on /. many times.

    --
    Slashdot, fix the reply notifications... You won't get away with it...
    1. Re:Wrong by ovanklot · · Score: 5, Insightful

      That's not the same web devs making those same mistakes. Developers with some experience do not write code that fails against easy sql-injection. But companies prefer to hire younger inexperienced devs for the reasons that have been discussed here on /. many times.

      I'll add to that that this isn't limited to web developers.

      --
      "Programming is life, the rest is mere details"
    2. Re:Wrong by gweihir · · Score: 4, Insightful

      Does not match my experience. Some (few, say 10%) of these people do indeed acquire insight and experience with more time in the field, but most do not seem to. They make the same basic mistakes and have the same defective and incomplete understanding of how thing work, 5 years in, 10 years in and then they move to another field because they have become unemployable in their "specialty".

      --
      Most ACs are not even worth the keystrokes to insult them. Be generically insulted by this and ignored otherwise.
    3. Re:Wrong by KiloByte · · Score: 3, Insightful

      I'll add to that that this isn't limited to web developers.

      Hell yeah this. In most fields, there's decades of prior wisdom that one should at least try to get a grasp of before making "brilliant" inventions. Like, you shouldn't write an init system before reading "Unix for Dummies".

      Things like SIGHUP/nohup are basic knowledge, if you don't know this you shouldn't write your snowflake way of killing processes on logout. If you don't know ways to authenticate users and what user names are explicitly allowed by POSIX (the 0day issue), you shouldn't create a gaping security hole, and even worse, you don't WONTFIX it just because one of your distribution's clicky-clicky tools doesn't allow such names, while "$EDITOR /etc/passwd" or LDAP are "user errors".

      I'm for one a kernel newbie -- yet I know better than when faced with a problem like "shit network driver does high-order allocations while atomic, with disastrous reasons when under memory pressure" to rush into making an ad-hoc pool instead of reading how it should be done, or asking those with a clue. The former was my first reaction, yet I at least bothered to think before wasting developers' time with a bogus patch.

      --
      The creatures outside looked from Alt-Right to Antifa; but already it was impossible to say which was which.
    4. Re:Wrong by scsirob · · Score: 4, Funny

      We have a special name for those people who do not learn from their mistakes. We call them "Managers"..

      --
      To Terminate, or not to Terminate, that's the question - SCSIROB
    5. Re:Wrong by jrumney · · Score: 2

      That's not the same web devs making those same mistakes.

      True, the web developers from 2013 have all retired and taken up jobs in the fast food industry by now.

    6. Re:Wrong by swilver · · Score: 2, Insightful

      Those few are the ones you want to keep. However, you won't be able to keep them if you don't pay them well, or make their lives difficult/annoying with stupid management decisions. They'll be the first to leave as they have many options and don't have to deal with stupidity -- leaving your company with those that seem unable to learn from their mistakes, or just don't give a shit.

      I'm considered a decent developer, and if you want to keep me you better be prepared to pay me significantly more than that fresh CS graduate that just joined the team, don't give me any shit, trust what I'm doing and let me do my work unsupervised -- like how you would treat another person that you've come to respect and trust.

      Do that, and I'll pro-actively come up with ideas and solutions for problems you didn't even know existed yet and will treat your software as my own making sure that no harm comes to it, not from inside or outside the team.

      Failing that, I'll just rake in some money until something better comes along, while you only get maybe 50% of my best as the constant distractions/annoyances/stupidity just don't foster a good environment for creative work.

    7. Re:Wrong by Anonymous Coward · · Score: 0

      This is the reason!
      I have 7 years of web dev experience, nobody in my company knows JS the way I do. Yet our head of dev has decided that junior devs straight out of college should be in charge web development. None of them know the merit of frontend unit tests, decoupling components, carefully picking out dependencies instead of npm install 700 libraries, ... Senior devs have nothing to do on the frontend in a lot of people's minds. Senior means you should be doing backend work, architecture, ... Frontend we now shit out one unmaintainable mess of a portal after the other, as soon as a product becomes a tad complex we hit a million regression defects after the other and just write another shitty portal.

    8. Re: Wrong by Anonymous Coward · · Score: 0

      Gave up slaving as code monkey years ago but deadlines and lack of ownership of quality. Cant blame dev for broken leadership.

    9. Re:Wrong by tlhIngan · · Score: 2

      That's not the same web devs making those same mistakes. Developers with some experience do not write code that fails against easy sql-injection. But companies prefer to hire younger inexperienced devs for the reasons that have been discussed here on /. many times.

      Well that pretty much applies to practically every job these days. The companies pursue money above all else, to the detriment of themselves - assuming everyone (and everything) is a swappable interchangeable part.

      Nothing can be further from the truth - sure some things can be swapped around with little issues (printers, paper, pens, etc), but other things require considerable effort to swap around - things like servers and people. Servers need to be set up, software and data transferred, configured, and added to the network and then everything else needs configuration to use the new server. Sure there's redundancy and all that, but you still had to set it all up and it's a ton of effort to do so. It's why the best we have is putting them in VMs so they can migrate around which is a ton less work than configuring new machines. But even then it's no panacea, since OSes get outdated and you need to upgrade them as they fall out of support.

      People are the same. They embody knowledge, and often what you're paying for is not the actual work output, but the knowledge of how the systems work inside the company. Even if everything is documented and you fire the sysadmin and hire some junior guy in his place, there's going to be a ramp up time to acquire basic working knowledge, and then to replicate the institutional knowledge lost by firing the old sysadmin. Sure the documentation is there, but it takes time to digest.

      Plus, the documentation may cover "what", but not "why". Why are systems set up the way they are?

      The other thing is, replacing something means the team has to readjust to new team dynamics. Not a problem if they were bad and you removed the problem person, but if they were quite gelled and work well together, you risk breaking up what works well. Seems like a great way to add risk to a project - will the replacement work well within the team, or will everything fall to pieces?

    10. Re:Wrong by cardpuncher · · Score: 4, Insightful
      More to the point, why should these serious "mistakes" be possible at all.

      If these errors keep occurring, you have to stop blaming the web developers and start blaming the technology. There is no good reason that cross-site scripting or session hacking should even be possible. It's a mad idea to turn user input into a human-readable SQL command string when no human needs to read it.

      The problem is that we stared off with insecure shoddy hacks and there has been a whole slew of incremental mitigations, none of which happens by default in order not to break further the already-broken crap that's out there. That's not the fault of the application developers, that's the fault of the browser and server developers.

    11. Re:Wrong by gweihir · · Score: 1

      Yes, very much so. I see that all the time, especially with large customers.

      --
      Most ACs are not even worth the keystrokes to insult them. Be generically insulted by this and ignored otherwise.
    12. Re:Wrong by K.+S.+Kyosuke · · Score: 2

      Hell yeah this. In most fields, there's decades of prior wisdom that one should at least try to get a grasp of before making "brilliant" inventions. Like, you shouldn't write an init system before reading "Unix for Dummies".

      Obligatory reference

      --
      Ezekiel 23:20
    13. Re:Wrong by Anonymous Coward · · Score: 0

      > 5 years in, 10 years in and then they move to another field because they have become unemployable in their "specialty".

      Consequently, during a 40 years long career, they are webdev between 12.5 to 25% of the time and then no more. Seems like

      >That's not the same web devs making those same mistakes.

      is still true.

      My personal experience is that contrary to the usual opinion on /., any normally constituted person, can learn anything. The principal difference is the time to learn and the incentives to learn good coding practice (if there is no consequences on them, many (most?) people will produce what needs the minimum effort).

    14. Re:Wrong by war4peace · · Score: 1

      Well yeah, because most are web developers; very few are web developers AND security experts at the same time, and they are usually way more expensive.
      Code written by web developers must go through a security audit and insecure parts need to be rewritten to close the security holes.

      --
      ...gis sdrawkcab (usually not responding to ACs; don't bother posting as AC)
    15. Re:Wrong by ThosLives · · Score: 2

      This was my thought too - if you have a critical component in a system, you want to make it as difficult as possible to get wrong.

      Especially if there is clearly a "correct" and "incorrect" way to do something. There's a reason most sane cables either make it extremely difficult to connect in the wrong orientation or even better make it so all the likely orientations are serviceable.

      The tools and frameworks could pick up the ball and make it more difficult to get things wrong, this would be much less an issue.

      --
      "There are a dozen opinions on a matter until you know the truth. Then there is only one." - CS Lewis (paraprhase)
    16. Re:Wrong by zifn4b · · Score: 1

      That's not the same web devs making those same mistakes. Developers with some experience do not write code that fails against easy sql-injection. But companies prefer to hire younger inexperienced devs for the reasons that have been discussed here on /. many times.

      Yes, companies tend to search the bargain bin for unicorns even though it's completely irrational. Either they go with young inexperienced recent college grads or they go with H1B's. The headline ought to read "Why do companies keep making the same mistakes hiring recent college grads and H1B Visa's resulting in poor software quality instead of hiring talented, experienced developers who can write quality code?"

      The answer to this question is simple: Companies have champagne taste and a beer budget.

      Nothing new there...

      --
      We'll make great pets
    17. Re:Wrong by MoarSauce123 · · Score: 1

      I beg to differ. Experience level has little to do with it. As QA I worked with about a hundred developers over the years and they typically want to use the newest hipster libraries and crank out new features that dazzle top management. Security, bug fixing, sound architecture, and reliable frameworks are tedious work that do not demo well, which is why devs tend no to bother with it. I run tools checking for injections and XSS on every page that has a form, I report the results in great detail....and for the longest time none of this was fixed based on the argument that users will never enter a query or js code into a text field. Cue the company mandated security audit that the app blatantly failed and now out of a sudden this is top priority and front and center. So far nobody dared to ask why QA did not test for this and reported on these issues....
      Let me put it bluntly: DEVELOPERS GO AND FIX THE BUGS THAT QA REPORTED!!!!!!!

    18. Re:Wrong by MoarSauce123 · · Score: 1

      Agreed, BUT the correct way typically is a bit more difficult, takes a bit more time, and thus costs more. Fast and cheap is preferred by most managers, good not so much.

    19. Re:Wrong by wisnoskij · · Score: 1

      I wouldn't be too sure. A few dozen programmers that program that way, and possibly even teach how to program that way, could fill the web with thousands upon thousands of these common mistakes.

      --
      Troll is not a replacement for I disagree.
    20. Re: Wrong by Anonymous Coward · · Score: 0

      Agile nor Warerfall methods improve quality. Just how fast it hits the streets.

      The laugh moment was. "We are a Agile shop. We will get to that change by the end of 2018 ". Can you say they do not know what AGILE MEANS?

    21. Re:Wrong by Anonymous Coward · · Score: 0

      It's a fundamental problem with computer technology based on the initial protocols of computer communication. The first computers were part of proprietary systems, like the phone system. AT&T always counted on owning the whole system and what security they had was of the security by obscurity type. That someone might hack into their system was an afterthought typically addressed legally rather than technologically.
      When ARPANET started thinking about connecting networks security was the last thing on their minds. After all they (the government) owned all the networks. Who was there to break into them?
      Originally the PC was a stand alone device. The infection of PC via viruses carried by floppy disk holding malware was a surprise. The weaponization of inter-computer communication was really a shock when it happened.
      You want to fix the problems you've got to go back to the fundamentals of the system architecture and protocols and redo them with security as a foundation principle. That will never happen.

    22. Re: Wrong by Anonymous Coward · · Score: 0

      The newer devs I've seen don't even know how to code: they just plug a few details into whatever IDE they like and push out something that looks like it works

      Never mind that it breaks plenty of other functionality: that's for more senior people to clean up after. Sure, the senior folks could have built it without breaking things in the first place, and taken less time doing so - but then what would the new kids work on? And there's enough work backlogged that more devs are needed.

      So the senior dev's have their work lives made miserable, and aren't getting a raise because they haven't produced new features.

      Any wonder software is crap?

    23. Re:Wrong by eneville · · Score: 1

      Code written by web developers must go through a security audit and insecure parts need to be rewritten to close the security holes.

      I think *all* code should go through at least peer review by a senior team member. It is the flamboyant prima donna who thinks they are above the rest of the team make the biggest blunders.

    24. Re: Wrong by Gr8Apes · · Score: 1

      The laugh moment was. "We are a Agile shop. We will get to that change by the end of 2018 ". Can you say they do not know what AGILE MEANS?

      "Agile" shop is just another way of saying "failure waiting to happen" shop.

      --
      The cesspool just got a check and balance.
    25. Re:Wrong by gweihir · · Score: 1

      Tell me about it. I am a security expert and sometimes do coding for customers. For one large customer, I do cost about 2.5 times per hour than their regular coders. On the other hand, I think that their regular coders are directly more expensive and the time they need to do things (than then suck afterwards) is really impressive. I have seen quotes like $500k just for changing the path in a web-application and placing a proxy in front of it. Incredible.

      --
      Most ACs are not even worth the keystrokes to insult them. Be generically insulted by this and ignored otherwise.
    26. Re:Wrong by gweihir · · Score: 1

      Well, yes. But what if you do not have senior member that can do it, because the only senior team member is already the only one that can do the more complicated things? That seems to be the standard set-up these days.

      --
      Most ACs are not even worth the keystrokes to insult them. Be generically insulted by this and ignored otherwise.
    27. Re:Wrong by Anonymous Coward · · Score: 0

      If these errors keep occurring, you have to stop blaming the web developers and start blaming the technology.

      But people like yourself do not WANT secure technology. You have voted with your wallet, and have voted that secure tech must die, and insecure "easy" tech must be rewarded.

      At a company I worked for, where the goal was to provide secure software, time and time again customers complained about using certificate authentication between their software and ours in their testing and development setups, going many times over as far as publicly claiming our software was "broken" for not allowing blank passwords to function.

      Instead they would flock to vendors like Microsoft and even Oracle, at far higher prices both up front and in the long run, which allowed them to bypass and even remove all forms of security to make the devs job easier.

      Our company is no longer in business as it eventually became crystal clear no one wants security built into the components they purchase if it inconveniences them, even when it is the cheaper option.

      You don't get to now go blaming the companies that only sell the insecure by design products because those are the only options you will even entertain purchasing.

    28. Re:Wrong by Anonymous Coward · · Score: 0

      Nah, not really. All developers in major corporations produce the same garbage code. Whether it is bounding problems leading to sql injections, memory leaks, or just plain stupidity.
      The goals of software development are simple, get as many features out as you can in as little time as possible.

      Here we are asking to look for, and test against security vulnerabilities, heck, I'd be happy if test plans included more than just "does it work?"

      Problems rarely have to do with 'does it work', what about 'does it break?'

    29. Re:Wrong by KiloByte · · Score: 1

      Your link is broken -- it redirects to a country-specific YouTube site that dims the page and presents an empty white rectangle. If I recall correctly, if I dropped enough privacy-related extensions, it'd show me a form to sign away most of my rights, then keep doing so unless it's allowed setting a 3rd-party cookie. Just no.

      Redirecting someone to youtube.pl when following a link to youtube.com is inexcusable, as content of these two is different (even if a good part of videos can be watched on both). They used to have an opt-out but AFAIK it's gone with no replacement.

      I also have no 1h7m to waste to watch a talk I could read in 5mins or skim over in much less.

      --
      The creatures outside looked from Alt-Right to Antifa; but already it was impossible to say which was which.
    30. Re:Wrong by postbigbang · · Score: 1

      But that would be the right thing to do.

      If there was QA.

      If the list from QA wasn't many screens long, some with red flashing thingies attached to them.

      If the in-house coffee machine wasn't calling my name.

      If you didn't give me gruesome deadlines to begin with, and impossible specs.....

      If.....

      --
      ---- Teach Peace. It's Cheaper Than War.
    31. Re:Wrong by K.+S.+Kyosuke · · Score: 1

      I'm not redirecting anyone to youtube.pl; the link came from YouTube's very own "Copy video URL at current time", which I assumed to be doing The Right Thing, so I have no idea what it's doing wrong for you, and you also shouldn't have to watch for an hour when the timestamp for the relevant portion is clearly included in it.

      --
      Ezekiel 23:20
    32. Re: Wrong by Anonymous Coward · · Score: 0

      The link worked fine for Me. It's an Alan Kay talk.

    33. Re:Wrong by KiloByte · · Score: 1

      Yeah, the breakage is not your fault. That timestamp you included might still be encoded somewhere inside the massive URL that sign-away-your-firstborn page redirects to, getting past it is currently beyond my threshold of putting up with crap.

      Google somehow insists that everyone with an IP in country X prefers language X, even when accessing a country-Y-specific URL, with browser sending English as the preferred language. Searches in non-English are mostly useless except for some local stuff -- but I for one never shop/etc using Google. For plain searches there's DuckDuckGo, but there's far more to Google than that.

      For a more extreme horror show, try Google over Tor. Their captchas are broken most over time.

      --
      The creatures outside looked from Alt-Right to Antifa; but already it was impossible to say which was which.
    34. Re:Wrong by Anonymous Coward · · Score: 0

      It's because the people who go for web development jobs fancy themselves as software developers when they aren't. They don't have the knowledge, experience or education to deal with anything that isn't purely superficial. That's why most web sites are shit.

    35. Re:Wrong by Anonymous Coward · · Score: 0

      No, you can't make a sharp cooking knife that can't also slit a throat. In order to be useful, the knife must be sharp. Whatever guards you put on it that will make it hard to slit a throat, will make it hard (or impossible) to do useful work as well.

      What you want is a sharp knife. What you get is a sharp knife. The responsibility for handling it properly is on you.

      *Waaaaaaaah* My job is hard! I want someone *else* to do the hard parts for me!

    36. Re:Wrong by Trailer+Trash · · Score: 1

      That's not the same web devs making those same mistakes. Developers with some experience do not write code that fails against easy sql-injection.

      Oh, I could introduce you to a few. I spent many, many years cleaning up other people's messes, and it's amazing how prolific bad developers can be with their coding.

    37. Re: Wrong by dgatwood · · Score: 1

      The laugh moment was. "We are a Agile shop. We will get to that change by the end of 2018 ". Can you say they do not know what AGILE MEANS?

      Not at all. Agile means they *can* turn on a dime and work on that feature quickly. The long timeframe means that your priorities are not their priorities.

      --

      Check out my sci-fi/humor trilogy at PatriotsBooks.

    38. Re:Wrong by Anonymous Coward · · Score: 0

      Makes you wonder. These issues are likely incorporated as part of the basic curriculum and what about the "test tools [that] fail to catch those mistakes"?

    39. Re:Wrong by Anonymous Coward · · Score: 0
    40. Re:Wrong by Anonymous Coward · · Score: 0

      Sometimes people are just careless. But I think it has more to do with the fact that people go to shit universities like Kennesaw State and then think they understand computers when they really don't. As long as they get a paycheck, that's all they care about. They don't really know what they're doing and don't care to learn, as long as money comes in.

    41. Re:Wrong by Anonymous Coward · · Score: 0

      Worked for me. Perhaps your so dumb it thinks your a polack?

    42. Re:Wrong by MrKaos · · Score: 1

      Developers with some experience do not write code that fails against easy sql-injection.

      I wrote my own persistence layer that filters the inputs and generates the SQL based on what is valid for the application, it's amazing what can be achieved with the strategy design pattern. That wasn't the prime motivation for writing a persistence layer, however it was a great by product.

      --
      My ism, it's full of beliefs.
    43. Re:Wrong by Anonymous Coward · · Score: 0

      Sir i think you have misunderstood something fundamental about the way expression works.

      You can't have a language that is safe and also useful in any context other than the ones in which it is proscribed. This isn't something you can work around.

      Add to this that data structures aren't self evident... the problem we're seeing is understandable and the mitigations you propose will frustrate the hell out of you in a year or two.

    44. Re:Wrong by datavirtue · · Score: 1

      Yeah...but then everyone gets really annoyed at the security team or security engineer for holding up the release if they are allowed to at all. If the devs try to code a fix it does not solve the problem and the security engineer is again stuck being the bad guy asking for it to be re-coded over and over again while business stakeholders start pressuring the CTO/CIO, and the project managers start complaining a lot, and the pressure builds til we just release whatever it is. Or a security hole is discovered that has existed for years and no one wants to deal with it because of the above scenario that always plays out and because "it hasn't caused any problems yet." Being a security engineer is a thankless position filled with a lot of CYA emails and politics that all revolve around not enforcing security. An atmosphere of compliance-over-security forms and they pick their battles just to make it though a work week without upsetting too many people that don't care about security because it doesn't fall within their measurement of success. Show me a company that *really* values and pursues security in a serious way and I will never forget their name.

      --
      I object to power without constructive purpose. --Spock
    45. Re:Wrong by datavirtue · · Score: 1

      A lot of this has been done. You have to know the tools and use the correctly. Something you can't get around is that they are using languages that let you write your own shit from scratch cause you may or may not know that a fully tested and secure method already exists in the framework.

      --
      I object to power without constructive purpose. --Spock
    46. Re:Wrong by datavirtue · · Score: 1

      That is awesome. Our QA team couldn't test their way out of a wet paper bag. Completely useless, and wouldn't even begin to know how to test for a security vulnerability.

      --
      I object to power without constructive purpose. --Spock
    47. Re:Wrong by war4peace · · Score: 1

      Well, at least they all _pretend_ they value security :)

      --
      ...gis sdrawkcab (usually not responding to ACs; don't bother posting as AC)
    48. Re:Wrong by houghi · · Score: 1

      10% is a few? Compare that if a few engineers that build bridges or some doctors did make mistakes.

      The real issue is, as almost always, accountability. If you hire a cheapo IT person with no clue and the credit score of a whole country gets stolen and nobody goes to jail, the fault is not so much with the IT person or with the company. It is with the accountability and the law.

      Compare that with "Oh well, we designed a car and the breaks did not work and some people got dead. We knew and we did not bother with a recall. Shit happens."
      I guess that would not go well.

      --
      Don't fight for your country, if your country does not fight for you.
    49. Re:Wrong by Anonymous Coward · · Score: 0

      > It's a mad idea to turn user input into a human-readable SQL command string when no human needs to read it.

      Sure it is, but think how it came about. Initially databases only had a pure-SQL interface. Which was fine, and it's good that this interface is there.

      New applications came along, people began writing kludges to get their inputs into the pure-SQL interface. Maybe they should've asked the SQL server developers to make a second interface that doesn't suffer from injection problems.

      But the old interface isn't going to go away, so if some application programmer needs to interface to SQL and doesn't find a library for his programming language or framework or whatever, he's going to do the adaptation himself, injection and security be damned. Is this the fault of the server developers?

    50. Re:Wrong by david_thornley · · Score: 2

      The mistakes are possible because they aren't always mistakes.

      How do you prevent SQL injection? Putting user input into other strings is a reasonable thing to do. Passing a string to the database is a reasonable thing to do. It would be a pain to use parameterized SQL for everything, and I don't know of a database that does.

      There's ways to sanitize a user-entered string so it can't be used for cross-site scripting. Make that mandatory for using user-entered strings and you'll break some other stuff.

      Most of the common errors have solutions that require a certain amount of judgment.

      --
      "When you have eliminated the unacceptable, whatever is left, however improbable, must be the truthiness" - Holmes
    51. Re: Wrong by Anonymous Coward · · Score: 0

      *You're

    52. Re:Wrong by thejeffwhite · · Score: 1

      This should have been obvious from the start, the article feels like clickbait. This is like asking why do cashiers still give the wrong change?

    53. Re:Wrong by ichimunki · · Score: 1

      As a flamboyant prima donna I take offense to this. I've worked with plenty of "senior" developers who couldn't code a light switch correctly, let alone make useful comments on my work.

      All code should go through an automated scanner, though. On both the source side and the web client side.

      Then, once it doesn't have any obvious flaws, it goes to QA, which-- unlike development-- should be staffed with hardcore types with lots of experience and no fear of pissing off developers, PMs, or management. I've seen a lot where QA is left to relatively junior, non-technical people who end up mostly smoke testing, rather than being capable of really hammering an application the ways users and attackers will.

      --
      I do not have a signature
    54. Re:Wrong by ThosLives · · Score: 1

      But a knife doesn't just slit your throat while you're holding the handle and trying to cut a piece of meat.

      A knife might be dangerous, but it's not "easy to get wrong."

      --
      "There are a dozen opinions on a matter until you know the truth. Then there is only one." - CS Lewis (paraprhase)
    55. Re:Wrong by Anonymous Coward · · Score: 0

      > A knife might be dangerous, but it's not "easy to get wrong."

      Says someone who has never dropped a knife on their foot...

  2. Security is always last by Anonymous Coward · · Score: 5, Insightful

    Security is always last when implementing a new piece of software. Until management gets that security is vital to their well being, this will continue to happen. But since they have cybersecurity insurance and since everyone has the memory of a goldfish, the company will be fine, and therefore they don't need to spend the money on it. After all it would just be an added expense and possibly delay the introduction of the software in the first place which could ultimately be worse than having a buggy program.

    1. Re: Security is always last by Anonymous Coward · · Score: 0

      Most managers are in fact too lazy to even try understand the issues.

      Not enough burn yet.

    2. Re:Security is always last by lrichardson · · Score: 1

      The traditional life-cycle of a company has it being taken over by accountants just before it dies. Because accountants have real problems putting numbers to intangibles - like security. The developer hours required to implement security? *That* they can put a number to ... in the expense column. So, basically, as an expense with no immediate benefit, security gets the short end of the stick ... if it even gets that much. The situation gets worse when 'security' becomes another department. Then the group doing the development has zero incentive to do anything to make their work more secure - that falls on the 'security group' responsibility.

      Worse, most security groups have taken the same approach, and use third-party software for nearly all their needs. Without modification. Since, if/when something goes wrong, they can point their fingers at the third party, and claim that the third-party is responsible. This covers everything from McAfee on PCs (generally installed by people with close to zero technical ability), to the people running ZAP/Vega/AppScan who can barely spell SQL, let alone read it.

    3. Re:Security is always last by MoarSauce123 · · Score: 1

      That is because security is a subset of quality and software companies rather hire more support staff than have devs fix bugs. If you love self-punishment and quixote-ian endeavors then enter QA. Every day I see the taps on the back of devs, but never in my 20 years of QA did anyone come by my desk and tell me I did a good job testing and making the company tons of money by keeping customer retention high. And yes, I still report the same errors made years ago and often it is the same dev making the same mistakes over and over again. Sadly, those guys get paid twice as much as I do.

    4. Re:Security is always last by houghi · · Score: 1

      Now the money question: Why is it last? Why should it be first? "Because security" is not a good answer. That is the answer to Nice-To-Have not Must-Have.
      Why would they put security first? The real moment they will do it is money. And that can be achieved by accountability.
      If you got hacked and it is clear that you did not follow standard security procedures, you pay X amount. And no excuses, you pay.

      That would solve the problem over night. OK, give it a week because they would not believe it as till now there is no accountability whatsoever.
      1) Companies should give feedback about EVERY hack
      2) Companies should give feedback on whet they did to prevent hacks
      3) If they get hacked and they clearly did not do their job, they pay.
      4) If they fail to do 1 or 2, they pay even more.
      5) License to do business can be (temporarily) revoked as payment on top of financial ones.

      --
      Don't fight for your country, if your country does not fight for you.
    5. Re:Security is always last by michael_wojcik · · Score: 1

      Security is always last when implementing a new piece of software.

      Not always. There are organizations that implement an SDLC correctly, with secure-development practices applied throughout the development process. And guess what? That leads to much lower security defect rates in new code, and gradually whittles away at security technical debt in old code.

      Of course, the fact that your post (which, let's face it, is a cliche) was voted up to 5 Insightful shows that most places are still not implementing an SDLC, or they're doing it wrong.

  3. Because you keep replacing them with kids. by Narcocide · · Score: 2

    Next question.

  4. Simple: Cheaper than possible personnel by gweihir · · Score: 4, Informative

    Web application developers are the lowest-skilled, least educated and least talented people in the IT space. I recently had to explain to some people with supposedly 5 years experience in that space what an HTTP header looks like, because they had no clue. Same for basically every other aspect, like cookie naming, how to make you application able to work behind a proxy (in an enterprise-environment, no less), etc. It is staggering how clueless these people are. All they seem to see is a framework, which they barely understand and then put an application on top that makes all the basic mistakes you can think of. Of course, they eventually remove the mistakes that break the application in the specific target environment for a specific browser, but that is it. Forget about any understanding of the mechanisms they are using or of IT security. Some do not even know what an IP address is or how an URL is composed from components.

    So in essence: Developers that are grossly incompetent and management that is grossly incompetent for hiring these people. As we have a lot of "bean-copunter" types in management these days (MBAs and even less competent ones), things will not change anytime soon.

    --
    Most ACs are not even worth the keystrokes to insult them. Be generically insulted by this and ignored otherwise.
    1. Re:Simple: Cheaper than possible personnel by Anonymous Coward · · Score: 0

      summary:

      being managed and hired by mokeys

    2. Re:Simple: Cheaper than possible personnel by gtall · · Score: 1

      Yes, there is plenty of blame to go around. Part of that blame is on CS depts. I was once associated with a CS dept. of a major midwest uni. They said they had an "honors" group of students. I got saddled with three of them for a project in Java. When I asked if they could whack together something that did X, they grumbled, moaned, whined, and produced nothing. They didn't know how to get started. Yet they all went on to "promising" careers in industry...and they were seniors.

    3. Re:Simple: Cheaper than possible personnel by Anonymous Coward · · Score: 0

      Web application developers are the lowest-skilled, least educated and least talented people in the IT space. I recently had to explain to some people with supposedly 5 years experience in that space what an HTTP header looks like, because they had no clue.

      Being a web developer, I take offense to this.

      But, as someone who regularly has to show other people that they can actually look at server responses to see that errors happened when that magic white screen shows up that blows their minds, you're not wrong.

    4. Re:Simple: Cheaper than possible personnel by Anonymous Coward · · Score: 0

      Web application developers are the lowest-skilled, least educated and least talented people in the IT space.

      Your anecdotal reasoning collided with your massive irrational overgeneralization, creating a pretty little flash of pure incandescent stupid.

    5. Re:Simple: Cheaper than possible personnel by Anonymous Coward · · Score: 0

      They probably assumed that it was a group project. Nobody does work in university group projects.

    6. Re:Simple: Cheaper than possible personnel by gweihir · · Score: 1

      I would like to add that not all web-application developers are incompetent. I have run into the occasional (rare) really competent one, like the one guy I solved a tricky access control problem with last year by just us two locking ourselves into a conference room for an hour and then we had it figured out. I knew the access infrastructure and he really understood his application and the technology used. But for other applications (different teams) in the same application landscape, 6 months or longer even for simple things seems to be normal.

      I like the "magic white screen shows up that blows their minds". Nicely describes it.

      --
      Most ACs are not even worth the keystrokes to insult them. Be generically insulted by this and ignored otherwise.
    7. Re:Simple: Cheaper than possible personnel by gweihir · · Score: 1

      I wish this was only anecdotal. It is not. But as a consultant, I have to protect my customers, regardless of how stupid.

      --
      Most ACs are not even worth the keystrokes to insult them. Be generically insulted by this and ignored otherwise.
    8. Re:Simple: Cheaper than possible personnel by gweihir · · Score: 1

      The classical response of the blind to the one-eyed....

      --
      Most ACs are not even worth the keystrokes to insult them. Be generically insulted by this and ignored otherwise.
    9. Re:Simple: Cheaper than possible personnel by Chrondeath · · Score: 1

      I'm not typically working on the web side, so maybe this comparison isn't accurate, but expecting the web developers to know about HTTP headers seems...similar to expecting backend developers to know about assembly. It's a lower level of abstraction that your higher level of abstraction is supposed to prevent you from having to know about. If your higher level hasn't broken down on you before (in a way traceable to the lower level), you don't have a reason to have gone into it. When it DOES break down, I would expect a good developer to know enough about the existence of the lower level to start researching it, but if you haven't run into that class of errors before I wouldn't blame you for being unfamiliar with it.

    10. Re:Simple: Cheaper than possible personnel by gweihir · · Score: 1

      Actually, when their applications leaks data to the client it is not supposed to via the HTTP header, it very much is not "like assembler". It becomes I critical part of the knowledge needed to code this right or at least to understand what an external reviewer is explaining to them after a security review. Knowing about the possible data-paths is critical in order to be competent. Or the other time were I had trouble getting a team to understand how cookie names work (two applications using the same name were accessed over the same proxy and did overwrite each others cookies), because these people had no clue how cookies work and how they are transferred. The list goes on.

      No, this is not like asking them to know assembler.

      --
      Most ACs are not even worth the keystrokes to insult them. Be generically insulted by this and ignored otherwise.
    11. Re:Simple: Cheaper than possible personnel by Known+Nutter · · Score: 1

      I usually ignore AC's.

      You're doing a piss-poor job ignoring ACs. Just sayin'...

      --
      Beware of the Leopard.
    12. Re:Simple: Cheaper than possible personnel by HornWumpus · · Score: 1

      All devs should learn C and assembly as part of their education. It _is_ that simple. Get them close to the metal while young, even if they will never do it again.

      --
      John McAfee 'It was like that time I hired that Bangkok prostitute; to do my taxes, while I fucked my accountant'
    13. Re:Simple: Cheaper than possible personnel by Anonymous Coward · · Score: 0

      The problem was that you wanted them to do extra work that they did not have to do, in a shitty language no less, and that they were seniors ready to get paid to do those tasks.

      If someone came to you with extra work that you did not have to do in a medium that you did not like, were going to be judged based on your output but are not going to be paid, would you do it?

    14. Re:Simple: Cheaper than possible personnel by Anonymous Coward · · Score: 0

      The point of an honors program is to get students to rise to a challenge. Get them out of their comfort zone.

      Do you think these kids would be better prepared if they're taught to only do the minimum necessary, and only if they're comfortable with it and being paid? The real world will not coddle you.

    15. Re:Simple: Cheaper than possible personnel by Anonymous Coward · · Score: 0

      Schools across the nation have been dumbing-down CS curricula (and Software Engineering as well) in order to respond to the social interest that tech-giant social engineering has created.

      Facebook, Google, et. al., spend loads of money to sell kids on dreams of a fun and lucrative career as software developers. But as soon as they hit college-level courses and learn the realities of what it takes, most of them balk and bail.

      Colleges, of course, want that money, so they don't want students to bail, so they just dumb everything down to cash in on the trend.

      Then you have a bunch of kids graduating with lifelong debt and neither the skills nor the passion to succeed in the software development industry.

      I think it would be interesting if we instituted a software development version of the legal "bar" exam. Institute an objective test that software developers must pass in order to work in the field, and ensure that their funding is not linked to college enrollment. Colleges will have to adjust their criteria to aim at getting their grads to pass that exam, and will have to show stats on the pass rate.

      Of course, it would flop. The grim reality that it would reveal would just be too unpopular with everyone involved, and I can't see any way to fund it that would keep it immune from the incentive to dumb its criteria down in order to get more people graduating.

    16. Re:Simple: Cheaper than possible personnel by Anonymous Coward · · Score: 0

      Bullshit. My God... do you *really* think web developers don't have to know about HTTP headers?

      Is this a joke?

    17. Re:Simple: Cheaper than possible personnel by dgatwood · · Score: 1

      I'm not typically working on the web side, so maybe this comparison isn't accurate, but expecting the web developers to know about HTTP headers seems...similar to expecting backend developers to know about assembly.

      Not at all. Expecting front-end developers to know about HTTP headers is more like expecting back-end developers to know about... well, HTTP headers. HTTP headers are a fundamental part of the way that front-end JS code communicates with back-end code in whatever language. Admittedly, back-end devs have to use headers more frequently than front-end devs, who usually only need to use it when creating an API client from scratch, when figuring out why what they're sending to the back end isn't generating the right results (oh, the content type is wrong) or when doing OAuth. That said, if a web developer hasn't at least set the Content-Type header once or twice, I would almost wonder if that person really is a web developer at all.

      --

      Check out my sci-fi/humor trilogy at PatriotsBooks.

    18. Re:Simple: Cheaper than possible personnel by Luthair · · Score: 1

      CompSci isn't for training developers, its for training computer scientists. Theory is taught with the understanding that this forms the basis for development with mentoring and job experience. It sounds like you were meant to help provide the mentoring and experience, so you failed?

    19. Re:Simple: Cheaper than possible personnel by gweihir · · Score: 1

      Sometimes, I feel like trolling back....

      Yes, I know that is not smart.

      --
      Most ACs are not even worth the keystrokes to insult them. Be generically insulted by this and ignored otherwise.
    20. Re:Simple: Cheaper than possible personnel by Anonymous Coward · · Score: 0

      Bingo. I'm at a shitty university myself and the other 3 people in my group can't code at all. Coding is not for everyone that manages to pass, it seems.

    21. Re:Simple: Cheaper than possible personnel by Anonymous Coward · · Score: 0

      Assembly is the language, assembler is the tool.

    22. Re:Simple: Cheaper than possible personnel by datavirtue · · Score: 1

      "had to explain to some people with supposedly 5 years experience in that space what an HTTP header looks like"

      Had that conversation a few times myself. I have also had to walk through TCP sessions and handshakes and the like to explain things....whoooosh!!

      Eventually stopped giving internet 101 lessons to senior devs.

      --
      I object to power without constructive purpose. --Spock
    23. Re:Simple: Cheaper than possible personnel by Anonymous Coward · · Score: 0

      > Assembly is the language, assembler is the tool.

      *Ahem*

      https://pictures.abebooks.com/isbn/9780805318111-us-300.jpg

    24. Re:Simple: Cheaper than possible personnel by The+Cynical+Critic · · Score: 1

      In my experience an unusually large portion of people who end up in web development end up there not because they have an academic or even hobbyist background, but because they went to one of those "bootcamp" type affairs. Bootcamps may be great for getting people started, but because of the serious limitations on how much you're going to be able to teach someone in a couple of weeks/months who at the start of the program couldn't code their way out of a paper bag these people are going to be entering the tech workforce with very limited skills.

      Where this turns from something that just annoys more competent engineers and code inspection/quality assurance is when you factor in the fact that companies don't train their employees anymore. If an employee is clueless when they start the job, they're going to be just as clueless when they move on because of being fired or quitting on their own accord.

      Other than that there's also the way webdev draws in an unusually large amount of people who used to work on completely different stuff who at worst haven't even gone trough anything like the bootcamps and can actually be even more clueless than your usual bootcamp muppets. However unlike the webdev muppets, they tend to pick up on things faster, but being (namely) more experienced they get to practice their ineptitude and writing serious security deficiencies into the codebase a lot quicker.

      --
      "Why should I want to make anything up? Life's bad enough as it is without wanting to invent any more of it."
    25. Re:Simple: Cheaper than possible personnel by Anonymous Coward · · Score: 0

      Within the last 12 months I was working with web developers who were making a "microsite" for a major pharma company's product (product ad runs all over TV in the US, $21 billion in annual revenue, etc). The site itself actually falls under a portion of FDA regulations. The web team barely grasped the concept of a HTTP header. They knew the headers existed but had little idea of what they did. They also insisted on using JSON versus XML to feed data to a web service, but they repeatedly could not construct a JSON array properly. It was like dealing with students in a 10th or 11th grade programming class, only worse.

    26. Re:Simple: Cheaper than possible personnel by Anonymous Coward · · Score: 0

      CompSci isn't for training developers, its for training computer scientists.

      The reality is, any CS program which doesn't also teach you coding in intro classes, and force you to do actual coding in the rest of your classes ... that program is ran by idiots and is producing useless people.

      Do you know how useless someone with only a theoretical knowledge of CS is? Completely and utterly useless, and completely unqualified to do anything.

      I've known a couple of people who had MSc's in CS, who more or less treated coding as a means to an end, and a theoretical discussion. They could tell you in annoying detail why something was more elegant, or more pure, or better at this or that ... but they couldn't write or maintain actual fucking code which was worth a damn.

      They can't debug their own code, they can't fix it or extend it when new requests come in, they've pained themselves into a corner with "cleverness" that in reality is shit code, they've built frameworks and abstractions which are useless, redundant, inefficient, or just plain wrong. Feature requests and things they didn't account for ruin the elegance of their badly designed code, and often they can't even decipher their own code months later because it's so fucking elegant and fancy but is otherwise shitty.

      If you have seniors in a CS program who can't code, what you have is a bunch of useless wankers who have excelled at knowing lots of brilliant theory which they otherwise are incapable of actually applying. It's too late to mentor them at that point. Some unsuspecting company is going to hire them, they're going to talk a big game about the stuff they did and know, and then they're going to demonstrate they don't have the coding skills which comes along with that degree.

      A computer scientist who can't code is a completely useless idiot who claims to know things but has no actual experience in doing it. Which makes them blowhards and imbeciles who will tell you loudly how things should be done differently, when having no knowledge gained from having actually done anything.

      I've worked with a few of these people. The ones who could write enough code to finish their senior project/thesis but not much else? They were utterly pointless in the industry, because nobody has any need of a CS graduate for whom designing, coding, debugging, etc. is something they know the theory of but have no actual practice.

      Theory is taught with the understanding that this forms the basis for development with mentoring and job experience.

      If you graduate with nothing but theory, then I sincerely hope your dumb ass gets canned by your future employer when they decide they don't have the time and patience to teach you how to fucking code. And, yes, I have seen people get sacked as senior developers basically say "oh hell no I'm not here to teach you what you were supposed to have learned in school, and your theory is utterly devoid of any actual experience".

      Sorry, every single one of my CS classes pretty much required writing real live actual code ... from intro CS all the way up to telecommunications and operating systems. If you got a CS degree and can't code, you're a complete fucking fraud and a waste of a degree. If you came out of a school where none of the CS majors can code, then it's a terrible program.

      Theory is useless if you have never actually applied it. And nobody in industry has the desire to mentor you enough to learn to code, because they shouldn't have to.

    27. Re:Simple: Cheaper than possible personnel by irrational_design · · Score: 1

      Today I was in a meeting were some IT managers were discussing how they have been trying to hire React developers for 6 months unsuccessfully. Basically they've decided that they need to just hire any warm body that has React on their resume. So yeah...

    28. Re:Simple: Cheaper than possible personnel by Anonymous Coward · · Score: 0

      Which, of course, is completely the wrong approach.

      What they need is JS developers who have lots of years pf experience with several other frameworks, which of course they had to learn to use - just like they will learn React.

    29. Re:Simple: Cheaper than possible personnel by Anonymous Coward · · Score: 0

      and yet I can't get a job, because everyone insists on hiring those idiots, because they want to use the latest framework 'x'

    30. Re:Simple: Cheaper than possible personnel by Anonymous Coward · · Score: 0

      be sure to tell them that React is garbage, and that they shouldn't be mixing up native dev roles with web dev react responsibilities.
      Its a nuisance to those of us who are real developers.

    31. Re:Simple: Cheaper than possible personnel by Anonymous Coward · · Score: 0

      IKR, why not hire experienced developers who know what they are doing, and let them choose the framework?

      But managers feel the need to impose their preferences on the team, in order to feel useful.

  5. Millions of monkeys by Anonymous Coward · · Score: 0

    So what we have here is that there's always another webmonkey to make the same old mistakes.

    And still no Shakespeare.

    On another note, I have some dead hpe kit here that they've made pretty much impossible to get RMAed. Can't even simply email them, have to use a spam-causing "webform", or maybe call a number and get some incredibly rude idiot like I got last time, instead of fixing the problem calling me back to have a good little shoutfest. And where I am, it's now a 0900. If they'd like to start with themselves, they could be less head-up-arse about honoring that old time procurve promise, instead of rescinding it. Or, like here, musing about webmonkeys when their business is networking kit, not webmonkeying.

  6. Because it isn't a priority by Anonymous Coward · · Score: 1

    Companies (especially startups) are too focused on getting the next feature released before the next deadline. Security is one of their lowest priorities. Once they are acquired, it's then the acquiring company's problem to deal with.

  7. culture not technology by Anonymous Coward · · Score: 1

    is it not clear yet that this is a cultural issue in the way buisnesses are run and setup and not a technological impossibility?

    1. Re:culture not technology by gweihir · · Score: 1

      Apparently to some, it is not. These may be the people at the core of the problem, though.

      --
      Most ACs are not even worth the keystrokes to insult them. Be generically insulted by this and ignored otherwise.
    2. Re:culture not technology by dougTheRug · · Score: 1
      That's a very good point. The system designers have to have their design and implementation* correct, 100% of the time to be safe. And they generally only the the chance to design, once. (refactoring can give you multiple chances at implementation

      The attackers on the other hand, only have to be right, once.

      The model of this in the natural world is virus infections and other parasitic relationships. If the parasite kills its host or host ecosystem, the parasite also fails. So I think in the worst case, this will become the limiting factor to cybercrime.

      * - There are security design defects (unsafe password recovery) and security implementation defects (XSS).

    3. Re:culture not technology by MoarSauce123 · · Score: 1

      Security is not impossible, but it costs time, money, and effort. Any product manager will rather have devs work on new features than fix existing ones for security or other problems. Customers also do not value quality and security enough that they are fine with getting a feature a bit later that is fully tested and fixed. Just look at mobile apps, every other day there are bug fix releases to download and still the apps crash every five minutes. It is clearly a cultural issue!

  8. The real problems are... by bradley13 · · Score: 5, Insightful

    IMHO, these problems stem from the following source problems:

    - Incompetent developers. Look at the number one problem, number one for years now: injection. I teach students how to avoid this the first time they touch a database, which is typically in year two of their degree program. It doesn't matter: half of them still write injectable queries, even though using "prepared statements" isn't any more complex. The thing is: there is so much code to be written, that even these students - who evidently don't understand, don't care, and can't be bothered - even these students will find jobs, and some of them will be working on your web projects.

    - Internet speed. TFA talks about "agile methodologies" as if they were a good thing. While "iterative development" absolutely does make sense, in too many companies "agile", and "Scrum" and their brethren are an excuse for pushing half-tested code out the door, because everything has to be fast, fast, fast . I have news for the marketing department: No, your latest brainstorm does not have to be live next week. In fact, given that the brainstorm-after-next will basically reverse this one, it would really be better for everyone if you just fell off a bridge and drowned.

    - Too many frameworks. Real example: I used to use Guice, a small dependency-injection framework from Google, for a small demo-project. A few months ago I decided to update Guice to the latest version. But the latest version depends on another framework, Guava. Guava requires JavaX. JavaX requires Spring. Spring requires...good god, at this point I deleted Guice. I mean, seriously, binding in that much foreign code? First, you are now dependent on all that code, and whatever changes are made to it. Second, you are bringing in all of the vulnerabilties present in that code. And you have absolutely no idea what those may be, because you certainly aren't going to validate all of that code yourself. Thank you very much, I'll just implement that small bit of functionality I need, all by myself.

    --
    Enjoy life! This is not a dress rehearsal.
    1. Re:The real problems are... by Hognoxious · · Score: 2, Funny

      But the latest version depends on another framework, Guava. Guava requires JavaX. JavaX requires Spring. Spring requires...good god, at this point I deleted Guice.

      Look on the bright side, it didn't need systemd or gnome.

      --
      Confucius say, "Find worm in apple - bad. Find half a worm - worse."
    2. Re:The real problems are... by gweihir · · Score: 2

      I fully agree on all of these. I also teach a software security lecture, and last year one student summarized the purpose as "warn everybody to get an expert and not to do it themselves". Well, at least that one learned something.

      As to the last point: This is a real catastrophe in the making. Nobody still understand what they do and their dependencies seem to grow all the time. I now push "does not depend on frameworks" as a sign of quality to customers, wherever possible.

      --
      Most ACs are not even worth the keystrokes to insult them. Be generically insulted by this and ignored otherwise.
    3. Re:The real problems are... by swilver · · Score: 1

      Too many frameworks... that's a good one. You're worried about the vulnerabilities in some of the most stable, highly scrutinized, fully unit tested and secure frameworks Java has on offer and because of that... you roll your own.

      I guess I know what is really wrong with the industry: developers that think they can create their own framework, replacing several dozen man years of coding, debugging and testing in just a few days -- and then having the arrogance to think it will contain less vulnerabilities right from the get go then an established framework used by millions.

    4. Re:The real problems are... by jarle.aase · · Score: 1
      Sir you are wrong!

      Every tattooed d*head in my coffee shop agree that you need to include at least a million lines of javascript, backed a hew hundred gems, including a few dozens C libraries and some Rust apps to render HTML output.

      And bad-talking scrum??? What's wrong with scrum, dude? It makes the graybeards quit, and then we get to do everything our own way, without anyone /senior/ babbling around about security, response time or energy consumption. Scrum is great. Without scrum we may actually had to work hard to get something to work correctly.

    5. Re:The real problems are... by swilver · · Score: 1

      Quality? That's not quality. *OUR* software comes with its own Kernel, or are you gonna deny that Kernels aren't full of security issues? Some kernels consists of over 15 million lines of code! Did you check all those?

      Sure, customers are surprised at first when none of their other software runs anymore on machines with ours installed, but it is guaranteed secure.

    6. Re:The real problems are... by gweihir · · Score: 1

      Who let the clown in?

      --
      Most ACs are not even worth the keystrokes to insult them. Be generically insulted by this and ignored otherwise.
    7. Re:The real problems are... by Anonymous Coward · · Score: 0

      I'll add more problems to the list.

      - Over-reliance of businesses on workers' self-education, combined with introducing over-hyped technologies. Self-education for new frameworks and paradigms doesn't work if there is nobody to slap you if you make a mistake that you don't recognize as a mistake. Also, "making employees learn every new technology on the spot by themselves" is another name of "making employees grossly incompetent".

      - Too many bad tutorials. E.g. those that, for simplicity, omit input validation.

    8. Re:The real problems are... by dougTheRug · · Score: 1

      I think you have to honestly look at yourself and if you are not educating or failing these incompetents, you are a bad professor and a part of the problem. Insufficient education is, in my observation, the largest contributor to the problem.

    9. Re:The real problems are... by dougTheRug · · Score: 2
      If you were teaching civil engineering, the first day you would be showing them a film about the bridge that blew down because of its design failing to accommodate for its stress inputs. And the fact that people's lives were on the line.

      I would very much like to know what the first day in your course is like.

      I think you have to honestly look at yourself and if you are not educating developers on how and why injection flaws work, and how they must be stopped at every handoff of data between interpretation domains, then you are a bad professor and a part of the problem. Insufficient education is, in my observation, the largest contributor to the problem.

    10. Re:The real problems are... by DNS-and-BIND · · Score: 1

      You are assuming without any justification that the entire suite of functionality these frameworks provide is required. It is not. We just need one thing, but to implement that one thing, we need to massively expand our attack surface by bringing in huge amounts of foreign code. Your argument is that by reimplementing this entire framework vulnerabilities will be introduced, which is correct but it does not address the problem at hand. We aren't reimplementing the entire framework.

      --
      Shutting down free speech with violence isn't fighting fascism. It IS fascism!
    11. Re:The real problems are... by swilver · · Score: 3, Informative

      The example given was Guice, which is a DI framework. To implement DI you need to write at least a couple of thousand lines of code, using not every day concepts like annotation scanning, reflection, thread safety, etc. That's a non-trivial amount of work requiring a solid test suite to boot.

      Other than that I totally agree with you. I cringe every time I see some huge framework imported just to use one of its utility functions... Sure, a framework is great if over half the code needs it and it saves a lot of work, but adding a new huge framework to a huge existing code base without thought to save writing a dozen lines of code? I reject those commits when I'm leading the project.

    12. Re:The real problems are... by Bongo · · Score: 2

      I think there’s a side issue: only by trying to write one’s own, does one start to understand the problem. So as a learning excercise, trying to write one’s own is really useful. And then, use a proper framework. Otherwise there’s the opposite problem of people relying on frameworks which they don’t understand.

    13. Re:The real problems are... by Anonymous Coward · · Score: 0

      You real example is wrong. Guice does not depend on Spring. Also Javax is not a single thing, they are a bunch of independent extensions. The part of Javax that Guice depends on is just a few annotation classes.

    14. Re:The real problems are... by Kjella · · Score: 2

      The thing is: there is so much code to be written, that even these students - who evidently don't understand, don't care, and can't be bothered - even these students will find jobs, and some of them will be working on your web projects.

      And some of them will be working for PHBs that don't understand, don't care and can't be bothered. Far too often the only metric people are measured by is whether the code does the right thing with the right input under normal execution. Error handling? Security? It's working, ship it. That's what you get measured on. That's what your boss gets measured on. If you say it "isn't any more complex" and they do it anyway it's clearly because they don't get corrected or rejected. Those errors conditions are for QA to catch. Those injection vulnerabilities is something for InfoSec to discover and flag. Instead of being a safety net on the off chance that you should fail, they become the wall you throw shit at and see what sticks.

      All businesses want it yesterday, it's how the world works. Heck I'm equally bad when I want somebody else's code (internal or external) fixed. Somebody has to push back, but IMHO this is a management problem not a developer problem. If they don't want proper releases and testing, then it's eternal beta. Expect to be beta testers. As for frameworks, they usually try to do the right thing. It's when the frameworks aren't sufficient and they try to hack it on their own that most shit happens. But you can say that about everything, it's like asking a Java developer who isn't used to doing memory allocation or raw pointers to write C. Does it mean everyone should start off doing C or assembler? It actually doesn't, but don't go out of your depth.

      --
      Live today, because you never know what tomorrow brings
    15. Re:The real problems are... by TheRaven64 · · Score: 1

      Depend on the amount of code from the framework you actually need. If you're bringing in half a million lines of code to do something that could be done in a couple of thousand, then you're probably better off rolling your own: it's going to have far more tightly coupled logic and be more amenable to static analysis, as well as being an easier target to fuzz test.

      If, on the other hand, you end up implementing most of the logic in a dependency, then you're probably better off using the one that's widely deployed. Even then it's not so clear cut, because it depends a bit on your threat model. There will likely be more vulnerabilities in your code, but (for most deployments) there will be more attackers for the generic code because other higher-value targets will be using the same framework and someone who finds a vulnerability in it will be doing so with the aim of attacking one of them - but that doesn't help you when the script kiddie that buys their exploit decides to attack you though. You're trading increased vulnerability to generic attacks for increased vulnerability for targeted attacks.

      --
      I am TheRaven on Soylent News
    16. Re:The real problems are... by Anonymous Coward · · Score: 0

      The software engineering course I remember started with a picture of the first Ariane 5 rocket, which was destroyed due to a software / systems integration bug. Not all software is equally important, but software is no longer something that is just annoying when it fails.

    17. Re:The real problems are... by K.+S.+Kyosuke · · Score: 1

      You're worried about the vulnerabilities in some of the most stable, highly scrutinized, fully unit tested and secure frameworks Java has on offer and because of that... you roll your own.

      Because a random huge piece of code is likely to be bug-free?

      --
      Ezekiel 23:20
    18. Re:The real problems are... by K.+S.+Kyosuke · · Score: 1

      To implement DI you need to write at least a couple of thousand lines of code, using not every day concepts like annotation scanning, reflection, thread safety, etc.

      Hahahaha

      Java

      Oh, fuck. Well, here you may have your problem.

      --
      Ezekiel 23:20
    19. Re:The real problems are... by drinkypoo · · Score: 1

      Too many frameworks.

      The problem is more commonly one too few frameworks: specifically, people going above their pay grade and reinventing the CMS. Then they get the opportunity to make all those errors. If people just begin with a working CMS, they get to make a whole different class of mistake instead :)

      --
      "You're right," Fisheye says. "I should have set it on 'whip' or 'chop.'"
    20. Re:The real problems are... by Anonymous Coward · · Score: 0

      I would not necessarily equate "does not depend on frameworks" to be a sign of "quality."

      Here's the thing: If you are using a well known, well tested, well deployed framework, then many people are using that framework. That means that many people have run into bugs and security issues, which have been fixed. You do not need to reinvent the wheel yourself, wasting time and having to fix the same or similar bugs.

      That is the entire point of a framework.

      Yes - some frameworks, I'm sure, are incredibly bloated, but many are not. They operate in their domain and operate well. So, pick a framework that doesn't suck.

      I'm very surprised to see this kind of a comment here on Slashdot. The community is supposed to support open source software and the reuse of well-tested code. Many eyes find many bugs and all that.

    21. Re: The real problems are... by Anonymous Coward · · Score: 0

      Openssl and Apache struts are only two reasons why Roll Your Own is proven to to be the better option.

      Two big can of worms.

    22. Re:The real problems are... by ThosLives · · Score: 1

      You can also have fully unit tested code, and as soon as you start integrating it into another system, things fall apart.

      Integration testing is much much harder than unit testing.

      --
      "There are a dozen opinions on a matter until you know the truth. Then there is only one." - CS Lewis (paraprhase)
    23. Re: The real problems are... by Anonymous Coward · · Score: 0

      Maybe it did, but he didn't bother going all the way down the dependency tree

    24. Re:The real problems are... by MoarSauce123 · · Score: 1

      Should have picked the example of the Therac-25. The Ariane incident was expensive fireworks, but no lives lost due to a software bug.

    25. Re:The real problems are... by MoarSauce123 · · Score: 1

      I hope your are sarcastic. Scrum sucks! It adds so much overhead (that it claims to reduce!) that you need to hire a full time Scrum Master just to get the process working. If you want to do agile then hire polyvalent folks (means devs not too foo-foo to run a manual test and testers who have some idea how to code) and employ Kanban. Limit what everyone is working on and always keep the goal in mind to move tasks from backlog through design, dev, test to done as quickly as possible without shortcutting any of it. Instead of a Scrum Master hire a devops/deployment engineer who can push the bits to customers quickly. That way you can react fast if things don't pan out as expected in production.

    26. Re:The real problems are... by Anonymous Coward · · Score: 0

      That was the second example. Spectacular first, scary second.

    27. Re:The real problems are... by Anonymous Coward · · Score: 0

      You can write a simple dependency injection framework in two pages of code. It doesn't have to do everything Guice does.

      Of course, a better question is why you would use dependency injection at all if you don't use any advanced features.

    28. Re:The real problems are... by Anonymous Coward · · Score: 0

      I mean, seriously, binding in that much foreign code?

      You need to look into NodeJS. It's the new hotness. Just make sure you don't have any weapons lying around when you do.

    29. Re:The real problems are... by swilver · · Score: 1

      Oh, another one of those "the language is your problem" people.

      I suppose you also say stuff like:

      "... if we had written it in X using this 3 month old framework then we wouldn't be in this mess."

      "You don't need a compiler, just write unit tests with full coverage."

      "... in language X you can write 30% less lines of code, resulting in 30% less mistakes!"

      "My programming speed is bottlenecked by the amount of characters I need to type..."

      Anyway, thanks I'll give your valuable opinion the attention it deserves.

    30. Re: The real problems are... by Anonymous Coward · · Score: 0

      OK, no need to ask twice, I'm already excited enough!!!

    31. Re:The real problems are... by Anonymous Coward · · Score: 0

      > If you are using a well known, well tested, well deployed framework, then many people are using that framework.
      And many of those wil have lower standards.

      > That means that many people have run into bugs and security issues, which have been fixed.
      > Or they're not using that bit, or they found a workaround that is relevant for their use-case only (that might be completely insecure), or they're using a later version of the framework that relies on dependencies that you are not permitted to.

      > You do not need to reinvent the wheel yourself, wasting time and having to fix the same or similar bugs.
      Except that you often do, and are possibly also required to attest to having designed for and/or tested for the types of flaws.

      > So, pick a framework that doesn't suck.
      So, define "suck" and then provide some guidance on exactly how that is done, because mostly it's a minefield.

    32. Re:The real problems are... by swilver · · Score: 1

      For a random piece of code, I don't know.

      However, we weren't talking about a random piece of code, but some of the most used frameworks (in any language) on the planet.

      What do you think is a more likely source of security bugs?

      a) Closed source code written by your team / company, used by only your team and maybe a few others in the company, with a small end-user base (a few hundred thousand) in a maybe half a dozen apps or websites?

      b) Open source framework code, with regular releases used by millions of developers, serving 10's of millions of users in thousands of apps or websites?

      Also remember that the people writing frameworks are usually the more experienced developers who are highly likely more security minded than your team will ever be (or the framework wouldn't be such a success).

      I will place my bets on your closed source code any time -- and the more of it you write, the more attack surface you create.

      It's also a fallacy that importing a huge framework will somehow expose you to all security flaws it may have if you only use a small part. That's about as accurate as saying that the 12 million lines of code in Linux kernel drivers need to be all checked for security flaws whether the driver is loaded or not.

    33. Re:The real problems are... by swilver · · Score: 1

      I wrote a simple DI framework, it does take a bit more than that for even basic functionality. However, I'm interested so if you have some link or code. Perhaps it will offer some inspiration.

      I would have used an existing framework, but none of the ones I found supported changing dependencies at runtime (when loading a plugin or something). Both Guice and Spring are very much static

    34. Re:The real problems are... by Wrath0fb0b · · Score: 0

      There are two separate things: knowing what a framework does and knowing how it does it. In order to roll your own, you need to know both. But if things are documented right, the former is really enough.

      Let me give a overly-trivial example (Python for simplicity, hardly matters):

      from ecdsa import VerifyingKey
      vk = VeryifyingKey.from_pem( VK_KEY_DATA )
      assert vk.verify(signature, message):

      What I would absolutely expect an engineer working on this code to understand is as follows:
      (1) Elliptic Curve come in private/public pairs, the system depends on the authenticity of the public key and the confidentiality of the private key
      (2) It is guaranteed that the message could only have been signed by the entity holding the private counterpart to VK_KEY_DATA.
      (3) The verify function provides no guarantee on when this signature was produced. If you need proof of liveness, you need to compose this.
      (4) The verify function provides no guarantee that a third party did not capture a valid signature, message tuple and pass it along.

      What I would not require, by contrast, is an understanding of the mathematics of how EC curves provide these properties. That's may nice to have, but it really isn't necessary. So long as the engineer understands exactly what guarantees they get, the knowledge of how it's made is optional.

      [ Of course, this is trivial example because ECDSA is a nearly perfect abstraction and its guarantees are very easy to understand and grok in their totality. Real frameworks/libraries are usually leaky and difficult to document precisely because they aren't formally specified. ]

    35. Re: The real problems are... by reanjr · · Score: 1

      Because Word Press is so much more secure than an in house CMS.

    36. Re:The real problems are... by gweihir · · Score: 1

      Ah, yes. "Bouncing Betty" (or "Galloping Gertie"), the Tacoma Narrows Bridge. I saw a picture in my Software Engineering course. Do you have a source of the video that is not YouTube? I should indeed show that to my students as a reminder that they will be engineers and that engineering failure can kill.

      My first lecture starts stating that almost every piece of software these days is connected to the Internet in some way. Then it gives a broad overview over the things that can go wrong. I will treat them in-depth later. (Web Application Security is Part II and has its own "first" lecture.) I do buffer overflow including a demo that the students need to replicate themselves, discuss ways this can and cannot be fixed (e.g. NX bit is nice, but does not solve the issue). Next is Taint Checking as a data-path technique. Then data-leakage by behavior, e.g. when you can tell from the error-message that you had guessed a user right. Wherever possible, I add a current example. Final Slide is "human factors", including "Incompetent and unaware of it", The Peter Principle, The Yosemite "bear proof" trashcans that smart bears can still open, but dumb tourists cannot, and finally the "shoot the messenger" problem.

      In later lectures, I have all the classics on architecture, design and implementation level, including privilege separation in connection with input validation and normalization and the least privilege principle, fuzzing, password breaking, DoS defense, economic aspects, software maintenance, etc. Unfortunately, space is limited and many things I can only touch on the surface. I would like to make this a 2 semester course, but that is unlike to happen. So I have to select were to dive deep and were to stay on the surface.

      --
      Most ACs are not even worth the keystrokes to insult them. Be generically insulted by this and ignored otherwise.
    37. Re:The real problems are... by gweihir · · Score: 1

      Well, an 800M Euro firework is kind of impressive on its own.

      --
      Most ACs are not even worth the keystrokes to insult them. Be generically insulted by this and ignored otherwise.
    38. Re: The real problems are... by Anonymous Coward · · Score: 0

      Not if unit tests are done properly.
      Tip: Global variables that are writeable means you aren't doing it correctly.

    39. Re:The real problems are... by gweihir · · Score: 1

      Well, one additional problem is that selecting a framework is not easy to do and you only find out after having worked with it for some time what it is good at and were it sucks. And long-term support is always dicey. By KISS, if you can reasonably do it without a framework, then do so. Of course, if things get vastly more complicated because of all the things you need to re-invent, that is a different situation.

      --
      Most ACs are not even worth the keystrokes to insult them. Be generically insulted by this and ignored otherwise.
    40. Re:The real problems are... by K.+S.+Kyosuke · · Score: 1

      The first, second and fourth quoted sentence don't seem to make any sense whatsoever. The third is sometimes commonly extrapolated from the assumption that bug density is independent of language, but I'm not sure how much that is accepted.

      Regarding "the language is your problem", there's many decent environments out there, but some are just FUBAR. Regarding Java and the frameworks trying to fix it in particular, the old maxim that "programming languages should be designed not by piling feature on top of feature, but by removing the weaknesses and restrictions that make additional features appear necessary" seems to usually apply quite well.

      --
      Ezekiel 23:20
    41. Re:The real problems are... by K.+S.+Kyosuke · · Score: 1

      Do you have a source of the video that is not YouTube? I should indeed show that to my students as a reminder that they will be engineers and that engineering failure can kill.

      Why does it have to be not from YouTube? And if it for some reason can't be from YouTube, wouldn't it be sufficient to simply download it from YouTube first?

      The description of the course sounds interesting. I assume the materials aren't available on something like OCW?

      --
      Ezekiel 23:20
    42. Re:The real problems are... by K.+S.+Kyosuke · · Score: 1

      However, we weren't talking about a random piece of code, but some of the most used frameworks (in any language) on the planet.

      Someone mentioned OpenSSL above. You'd think that would be exactly the thing you're writing about, but still, you get people writing things like s2n instead of just using it. I'm not even sure how openness/closedness comes into it since both have source available.

      It's also a fallacy that importing a huge framework will somehow expose you to all security flaws it may have if you only use a small part.

      Interestingly, this seems to have been the very reasoning behind s2n.

      --
      Ezekiel 23:20
    43. Re:The real problems are... by tepples · · Score: 1

      Why does it have to be not from YouTube?

      The "appropriate use" filter on the classroom network forbids access to YouTube, or the national firewall forbids access to all services provided by Google.

      And if it for some reason can't be from YouTube, wouldn't it be sufficient to simply download it from YouTube first?

      Downloading the video is copyright infringement. A professor can't officially recommend this.

    44. Re:The real problems are... by K.+S.+Kyosuke · · Score: 1

      The "appropriate use" filter on the classroom network forbids access to YouTube, or the national firewall forbids access to all services provided by Google.

      Hey, you're not gweihir! ;) I assume these are possibilities, but I've only heard of such insanities from other parts of the world. Putting an access filter into a school is the last thing you'd witness around here. Especially when it comes to universities.

      Downloading the video is copyright infringement. A professor can't officially recommend this.

      That highly depends on local jurisdiction. Around here, your ass is covered by the law on both counts, when it comes to downloading it *and* when it comes to playing it to students in school settings. (After all, playing the video locally requires downloading the data anyway, so anything else would be insanity.)

      --
      Ezekiel 23:20
    45. Re:The real problems are... by Anonymous Coward · · Score: 0
      And some of them will be working for PHBs that don't understand, don't care and can't be bothered. Far too often the only metric people are measured by is whether the code does the right thing with the right input under normal execution. Error handling? Security? It's working, ship it. That's what you get measured on.

      OTOH, some of us are working for PHBs who think the only thing that matters is hours in the building and SLOC. Obviously, macro expansion and cut-and-paste are our most productive employees. Since the product is Mil-Spec, it is not actually required to be delivered, let alone work.

    46. Re:The real problems are... by mfnickster · · Score: 1

      Do you have a source of the video that is not YouTube?

      Try Archive.org

      --
      "Slow down, Cowboy! It has been 3 years, 7 months and 26 days since you last successfully posted a comment."
    47. Re:The real problems are... by angel'o'sphere · · Score: 1

      I guess you made a mistake then.
      Guava and Guice have no dependency to spring.
      Perhaps you got a pom.xml from somewhere that accidentally included it?

      --
      Cost free eBook I read (by iBook/Kobo/Amazon/ObookO/Gutenberg etc.): "The Green Odyssey" by Philip Jose Farmer.
    48. Re:The real problems are... by angel'o'sphere · · Score: 1

      It is only a copyright infringement if:
      a) the video has a copyright
      b) you redistribute it

      Teaching purpose btw. is in american copyright laws explicitly allowed! But not necessary in every country.

      --
      Cost free eBook I read (by iBook/Kobo/Amazon/ObookO/Gutenberg etc.): "The Green Odyssey" by Philip Jose Farmer.
    49. Re: The real problems are... by Anonymous Coward · · Score: 0

      Nice strawman. Nobody ever said it was. But I guarantee you it's better than anything you have written in terms of being secure and working correctly.

    50. Re:The real problems are... by angel'o'sphere · · Score: 1

      Unit tests only test what the coder tested for. This is often only very trivial stuff.
      E.g. no one writes a unit test to cause a buffer overflow and tries an exploit that way.
      However one might check buffer boundaries, when he sees the specc or the source code and knows that there are boundaries.

      --
      Cost free eBook I read (by iBook/Kobo/Amazon/ObookO/Gutenberg etc.): "The Green Odyssey" by Philip Jose Farmer.
    51. Re:The real problems are... by angel'o'sphere · · Score: 1

      Then you only met sucky ScrumMasters.
      For the team Scrum should reduce the workload that is not related to programming extremely and not add any overhead.
      A good ScrumMaster will manage about 4 teams. So no: you don't need a full time ScrumMaster!
      Besides organization/communication beyond the team, that means upper management, coordinating several teams etc. the job of a Scrum.master is: to implement/teach scrum. And then he makes himself superflouvious and all team related scrum stuff can be done by the team without need of a ScrumMaster.

      --
      Cost free eBook I read (by iBook/Kobo/Amazon/ObookO/Gutenberg etc.): "The Green Odyssey" by Philip Jose Farmer.
    52. Re:The real problems are... by Luthair · · Score: 1

      One has to question your ability to talk on development practices when you claim Guava depends on "javax" which doesn't exist (its the root package of all java extensions) which you then claim depends on Spring.

      There is an important distinction between libraries and frameworks which you seem to not understand. Further, you display a complete lack of understanding about how the classpath works and what leads to vulnerabilities.

    53. Re:The real problems are... by Luthair · · Score: 1

      Unused code in dependencies is just that - unused code.

    54. Re:The real problems are... by Anonymous Coward · · Score: 0

      Posting as AC because I already mod'ed on this article. All of the points of the GP are things I've heard language fetishists say and none of them are actually valid points. The point of the GP was exactly this. Raising the issue of the language above all else and ignoring the relative amount of effort put into various languages and their frameworks. Those more mature frameworks are likely to have fewer security issues than your favor of the month. As the newer one will likely have all the same ones the older stack had but they have yet to be discovered unlike the older stack where they likely have already been fixed some time ago. Basically, its a popular non-sequitur that just annoys everyone when you think it makes you look smart...hint it doesn't.

    55. Re:The real problems are... by sfcat · · Score: 1

      Someone mentioned OpenSSL above. You'd think that would be exactly the thing you're writing about, but still, you get people writing things like s2n instead of just using it. I'm not even sure how openness/closedness comes into it since both have source available.

      Replying as AC because I've already mod'ed on this article.

      OpenSSL is possibly the worst written of the widely used open source projects on the planet. The implementation itself is the real problem and a few years ago (whenever heartbleed was a thing), there was real momentum to replace OpenSSL with a better implementation. s2n is simply one of those efforts. This isn't an issue of rewriting something just to rewrite it, OpenSSL itself has serious design flaws in the code itself which makes finding and fixing security issues with it very difficult. Its written in an ancient dialect of C that wasn't widely used after the early 90's and uses unchecked function pointers all over the place. There are over 4000 gotos in the OpenSSL code itself.

      I agree you shouldn't rewrite working things, but there are very good reasons why OpenSSL shouldn't be everyone's workhorse security library/tool.

      --
      "Those that start by burning books, will end by burning men."
    56. Re:The real problems are... by Anonymous Coward · · Score: 0

      Were you an Equifax consultant at one point?

    57. Re:The real problems are... by gweihir · · Score: 1

      Sorry, I cannot give you the materials. They would be in German anyways...

      --
      Most ACs are not even worth the keystrokes to insult them. Be generically insulted by this and ignored otherwise.
    58. Re:The real problems are... by logicpeters · · Score: 1

      "A few months ago I decided to update Guice to the latest version. But the latest version depends on another framework, Guava. Guava requires JavaX. JavaX requires Spring. Spring requires..."

      Sorry, what? That sounds so crazy that I wanted to check it out for myself. I looked at the dependencies of Guava from the maven repository and don't see any evidence that there is a transitive dependency that brings in Spring (or JavaX -- do you mean the jsr's in the javax.inject package?). In fact, all four of Guava's dependencies are optional:

      https://mvnrepository.com/artifact/com.google.guava/guava/19.0

      Don't pass around false statements like this because developers take great care not to create these sorts of situations.

    59. Re:The real problems are... by logicpeters · · Score: 1

      His original statement that Guice brings in Spring (through transitive dependencies) is a complete falsehood. Check it out yourself in the Maven repo -- I just did, or roll up a simple project and see what it brings in. Both Guice and Guava are very lightweight libraries and don't bring in many transitive dependencies, if any. If they did, they would not be popular at all. Library developers are highly aware of the need to keep dependency trees light and minimal -- and you do a disservice by spreading around these false statements.

    60. Re:The real problems are... by Bongo · · Score: 1

      Ah, I see. Thanks, I learnt something :)

      Yeah it was just my experience, using Python for sysadmin stuff, where I was struggling with the multiprocessing module, and through some fault of my own, still causing lockups. So I went the way of learning the basics of fork, pipes, select, and message relaying, and then I started to appreciate what a multiprocessing module was really trying to solve. Likewise, after following the route of using callbacks to handle messages from other processes, with closures, I discovered the need for call chains, and so began to appreciate why async/await were invented. But my own background is not CS, it is architectural design, where every building is a prototype (every site and client and spec is different) so the mindset is that you start by trying to understand what unique problems this building design will have, which is why they taught us to simply try ideas in order to find out why they are not working, so as to better understand the problem, and I kinda take that mindset into IT, where there are established solutions, but to understand what those solutions were trying to solve, one has to try to solve it for oneself. And of course I am then delighted when I do and then search and find that of course this problem was already discovered by pros and they already created solutions...

    61. Re:The real problems are... by K.+S.+Kyosuke · · Score: 1

      The subject doesn't even have a web page with references? Well, too bad.

      --
      Ezekiel 23:20
    62. Re:The real problems are... by david_thornley · · Score: 1

      It's copyrighted, at least in all Bern signatories. Trust me.

      Digital video is sufficiently recent that none of it will have come out of copyright yet, and in order to be used it has to be in a fixed form, which means it's automatically copyrighted.

      If you don't like current copyright treaties, I certainly understand, but that's the law as it stands.

      --
      "When you have eliminated the unacceptable, whatever is left, however improbable, must be the truthiness" - Holmes
    63. Re:The real problems are... by angel'o'sphere · · Score: 1

      I don't know the video in question.

      However you are right in so far as digitizing an out of copyright old work creates a new derived work with new copyright.

      --
      Cost free eBook I read (by iBook/Kobo/Amazon/ObookO/Gutenberg etc.): "The Green Odyssey" by Philip Jose Farmer.
    64. Re:The real problems are... by Anonymous Coward · · Score: 0

      However you are right in so far as digitizing an out of copyright old work creates a new derived work with new copyright.

      Not quite. A simple reproduction or transfer to a new format is almost certainly not going to be judged a derivative work by a court, unless substantive changes were made to it. Simply digitizing it is not a creative change.

    65. Re: The real problems are... by ThosLives · · Score: 1

      There are many ways to have unwanted interaction that don't involve improperly shared global state.

      --
      "There are a dozen opinions on a matter until you know the truth. Then there is only one." - CS Lewis (paraprhase)
    66. Re:The real problems are... by Anonymous Coward · · Score: 0

      Teaching purpose btw. is in american copyright laws explicitly allowed!

      [citation needed]

  9. Dynamic typing by Anonymous Coward · · Score: 0

    OR mappers help against Sql-Injection. But set-up cost of such a mapper is too high, for no apparent reason.

  10. Because the market doesn't value security. by aussersterne · · Score: 2

    The pressure to release early and often is extreme. "MVP" rules the day, and no one in most senior roles has the granular perspective necessary to be aware of "security" as a concept. Is it checked into the testing repo and does it run? PUSH IT OUT. We'll fix any bugs as we "iterate."

    Oh wait, we won't actually iterate. Because existing features don't get us as much as releases of new ones. We'll just keep pushing out new ones as fast as we can.

    Security? Hell, often even basic functionality doesn't work. Release it broken, then declare it that part code deprecated in favor of new versions with new features in six months. Even if security is flawed, that's okay, it was only out for a few months "that way." Anyone still using it should have upgraded. If they don't it's their fault.

    There are flaws in the new version/new features as well? Well they've only been out for eight weeks. It was an MVP. We're agile. We'll fix any bugs as we "iterate..."

    etc.

    --
    STOP . AMERICA . NOW
    1. Re:Because the market doesn't value security. by MoarSauce123 · · Score: 1

      Yes, yes, yes! This is EXACTLY how stuff goes down. It takes quite some self-control not to punch those guys who claim that we will fix all of this later. Fixing it later will be much more difficult and thus cost more time and money. Worst thing is to have a team only dedicated to bug fixes. Each developer needs to fix the own code and do so as soon as an issue is identified. Those devs who screw up a lot will then not deliver much in value and are very easy to identify. Give them extra training and monitor if they heard the warning shot.

    2. Re:Because the market doesn't value security. by Anonymous Coward · · Score: 0

      This is essentially it, but it doesn't have to be tied to such a specific mania about fast releases and iteration. A more general description of the problem is that management, in practice, acts in such a way that if devs don't draw lines in the sand over security concerns then the product will be swiss cheese. And devs don't draw those lines (or hold them) because the power dynamic doesn't support it. Devs face a lot of problems and have little political capital within companies to address them. At many companies, a dev who treats security correctly is a pain in the ass and is viewed as too much trouble to employ relative to their peers. This will be true no matter how careful and silver-tongued the dev is, because worthwhile security is hard and has significant visible costs.

      The problem, in other words, is that since management won't think about (let alone pull out their wallet or take a two-day project hit for) software security, devs are the only ones that can make it happen. And devs don't make it happen because, like most managed teams, they end up adopting the role that management envisions for them. It's in the name, after all. You aren't the manager, you're the managed. This blanket of fail can only be pierced by a dev who is part entrepreneur, part Old Testament prophet, and part used-car salesman. And even they will only do it a couple times before they realize they are carrying the company's security on their shoulders for free, because they for damned sure aren't getting paid for it - they are actually endangering their job.

      My current employer actually doesn't fit this mold. Devs still have to be standard-bearers for security, but we are encouraged in that role and the company puts resources behind us when we present security concerns and plans to address them. This totally weirds me out. It is not how 90+% of companies handle software security.

  11. Frameworks and CMS's by Aethedor · · Score: 1

    I think that most frameworks and CMS's don't provide the right security that is needed to create a secure website. They offer protection against SQL injection, XSS and other common attacks, but don't provide a means for developers to make sure they used it correctly. Look at all the Wordpress plugins that keep on being vulnerable. How do you know a plugin is secure or not? In my opinion, there is a big difference between secure code and provable secure code. So, it's not only web developers making the same mistake. It's also frameworks and CMS's not providing a true secure base.

    In the framework I make, I always keep in mind that some other developer will use my code to build an actual website. How will that developer use it? How to make sure that developer uses it correctly? Whenever possible, I make sure that things are secure and restricted. If you want to do things that are potentially insecure, you have to disable certain security checks. For example, all output is escaped to prevent XSS. If you really want to output HTML, you have to disable the escaping. My framework comes with a script that performs a security audit for common errors. I really think that my framework is the most secure available and it's very hard to build something insecure with it that is hard to detect.

    --
    It doesn't have to be like this. All we need to do is make sure we keep talking.
  12. Because cosing culture is broken by Anonymous Coward · · Score: 0

    âoeDonâ(TM)t reinvent the wheelâ i was told once. Not many people check whether the wheel is in good condition, because... you know, productivity and that.

  13. Non-interactive authentication by Anonymous Coward · · Score: 0

    The problem is non-interactive authentication (or anonymous, if you like) of the web portal where privilege is required.

    Why is it anonymous?

    When you register a login on slashdot, you need (somehow) to get write access to a database.

  14. Budgets by Rob+Kaper · · Score: 1

    There is room in budgets to pay attention to some good practices or enforcement thereof by peer review. But often - especially with custom-made sites - it is simply not enough. I've seen plenty of projects where the design company was granted bigger fees for more hours than implementation, stereotypically also making everyone overly complicated. Even during scrum sessions where developer input is more present, doing it quickly is a much larger focus than doing it right. In the end, that simply leads to sloppy code. This is of course not true for every situation, but I've seen it happen far too often.

    1. Re:Budgets by gtall · · Score: 2

      "scrum sessions" There's your problem right there. Agile does not encourage good overall design. It is a micromanagering dream and causes coders to only work for the next sprint goals. As long as their little piece of the pie works, they get rewarded. The entire dirty snowball that gets produced is merely a by-product.

    2. Re:Budgets by Anonymous Coward · · Score: 0

      Agile isn't completely useless.

      When you have a customer with an inability to tell you what they want it can be useful.
      If you try to specify what they want they'll just get angry because it's all talk and nothing is happening.
      By doing agile you don't have to write the entire program they didn't want before they tell you what they actually wanted.

      Sure, the result will still be crap and it will cost a lot more than a program written from a good specification (Make sure you get payed per hour, and as soon each piece is finished when using agile.) but sometimes it is the smoothest way forward.

      And yes, maintaining the code will be costly, but that isn't really your problem now, is it?

    3. Re:Budgets by MoarSauce123 · · Score: 1

      So there is no budget for doing it right the first time, but there is budget for gluing together hot patches when stuff blows up in production? Any manager with that idea needs to be slapped with a wet noodle for days.

    4. Re:Budgets by MoarSauce123 · · Score: 1

      Agile only encourages customers not to tell you what they want. It becomes perfectly acceptable that they change their minds constantly and sell it was "agile" and "iterative approach". Agile is awesome for all those who are too inept to make a decision.

    5. Re:Budgets by HornWumpus · · Score: 1

      Agile is a manifesto full of truisms.

      Managers only read the parts you cite. Confuse Agile and Scrum.

      It's almost always what you say, but not absolutely always.

      --
      John McAfee 'It was like that time I hired that Bangkok prostitute; to do my taxes, while I fucked my accountant'
    6. Re:Budgets by david_thornley · · Score: 1

      Your description of Agile is not a description of good Agile.

      If you're using Agile correctly, you're not micromanaging and developers look at the overall project. That sounds like really bad management. perhaps you're using a variant of Scrum where the manager is the Scrum master, comes up with stories himself or herself (instead of involving the developers), and evaluates the developers on the basis of whether they do exactly what the manager wants.

      --
      "When you have eliminated the unacceptable, whatever is left, however improbable, must be the truthiness" - Holmes
  15. In a word: time. by Anonymous Coward · · Score: 1

    You're sitting at the computer. The project deadline has just been published. Those fifty feature requests that you've been telling management will take a week each to implement properly? You have two months, total, for all of them. Management is screaming at you to get it done. You don't have time to do more than basic testing. It seems to work? Great! Move on to the next thing.

    Meanwhile, figuring out all the ways in which the code will break - you haven't got time for that. Just pray that the security holes aren't too serious. Firewall? Which ports do we need? Oh, the hell with it - open everything up, go nuts, because figuring out exactly which ports are needed for what is just Too Damn Hard.

    Until there are direct, measurable, verifiable, financial costs for getting it wrong, management is going to push back on all those fancy security measures, because it doesn't add anything obvious. It's not like building a house, where if you get the foundations wrong, the whole thing will collapse - so the walls get built out of wet sand; the roof gets put on without any supporting joists; and it's a bloody miracle the whole thing doesn't fall over in the slightest breeze.

    Then, too, you have people who just don't care enough about the craft to learn what they're doing and why they're doing it. Cargo cult programming is a major thing, taking code snippets from Stack Overflow or wherever, pasting them together in something that looks like it came straight out of the Exorcist until it seems to work properly. Side effects? What are they?

    Or maybe it's just shipped off to the cheapest code monkeys they can find, not realising that they're paying peanuts, so the end result is going to be fortunate if it even vaguely resembles, in the dark, if you squint, the original requirements...

    All hardware sucks. All software sucks. But damn me if it doesn't seem like it's getting worse these days...

    1. Re: In a word: time. by Anonymous Coward · · Score: 0

      You should look into golang, seriously, a new beginning. Of course for your own benefit and joy!

    2. Re:In a word: time. by MoarSauce123 · · Score: 1

      This is why delivery dates ought to be set when things are guaranteed to exist. No matter how great of a devQA team you have, setting arbitrary release dates and expecting the feature wish list to be the definitive content will derail any project. This most likely happens when you promote developers to management positions.

    3. Re:In a word: time. by swilver · · Score: 1

      Management is screaming at you to get it done

      If you are a developer, with the current market, show some backbone and tell them they can do it themselves if they think they can do it quicker.

      But I guess it all depends on the way your job market is structured. Apparently in some countries the reason you were fired or left the previous company is somehow considered relevant, and a good recommendation from your previous boss is mandatory if you ever want to work in the industry again. Experience is less relevant, all that matters is that you conform to the system.

      In other countries however, we see those things for what they are: a way to keep you, and your wage, under control. Step out of line, and you'll never find a job again. Don't want to do overtime or work weekends? You'll get a bad recommendation.

      If you live in a country where these practices are outlawed, you will find that you can actually talk to your boss like he/she is a real person, have a beer with him/her (and only if you want to, not mandatory), and discuss things like adults as a team. Why? Because they donot have the power to ruin your life forever but only to the extend that you may have to look for another job in the presence of sufficient evidence that you are underperforming.

      In such countries you can, when you're treated like a replaceable cog, stand up for yourself and if necessary find a better company with a better culture. If you are a *really* good developer, you may even have offers lined up already. A mediocre developer may actually have to click apply somewhere and have to wait a few days to get a new job. Crappy developers may have to bluff a bit but will likely find a new spot within a few weeks...

  16. Ob by Hognoxious · · Score: 1

    27 people have already pointed out that web devs are fucktards, so I won't. Remember that they took something designed for displaying static pages and shoehorned interaction & dynamic shit onto it. The whole thing is built on sand.

    --
    Confucius say, "Find worm in apple - bad. Find half a worm - worse."
    1. Re:Ob by dougTheRug · · Score: 2

      Why are C developers still writing buffer overflows?

    2. Re:Ob by Anonymous Coward · · Score: 0

      Because they don't follow safe programming guidelines.

      It isn't even hard to code safe in C. Just allocate insanely large buffers and use the bounded functions to prevent overflow.
      It will be slower and require more memory than a program where you manages that manually, but it won't come close to being as inefficient and wasteful as "modern" languages.

    3. Re:Ob by TheRaven64 · · Score: 1

      The performance difference between C and a modern safer language is well under a factor of two. The performance difference between C and C++ using bounds-checked types and smart pointers everywhere is a few tens of percent. Unless you're targeting a system with 32KB of RAM or less, or you have very strict realtime guarantees (and so aren't even using malloc) there's rarely a good reason to use C these days.

      --
      I am TheRaven on Soylent News
    4. Re:Ob by Sigma+7 · · Score: 1

      It isn't even hard to code safe in C.

      The problem with C is that the unsafe stuff is default. Some of this was fixed over time, but it's taken so long that the unsafe practices are prevalent. Some of the functions later meant to offset this issue are sometimes not found in stock compilers (even if there's an update that later adds them.)

      Oh, and I did find a useful feature in one of the compilers. Turns out it was just specific to that one, and I had to rewrite code since it wasn't standard.

      Just allocate insanely large buffers and use the bounded functions to prevent overflow.

      A large memory footprint leads to other issues, such as the app "Dark Souls III" crashing half way through certain speedrun categories.

      Bounded functions work, but since they're not default, it takes significant effort to create and use them. If you're in a situation where you should use bonded functions, then you should instead use a modern managed language which is good enough for most usages. Only in very tight processing loops should one switch over to unbounded functions, because speed is necessary there.

    5. Re:Ob by HornWumpus · · Score: 1

      C is still a _great_ teaching language. Coders that can't get their mind around pointers should seek employment elsewhere. It's a good filter, even if 90% will never see a pointer again.

      C mixed with assembler is still common in embedded.

      --
      John McAfee 'It was like that time I hired that Bangkok prostitute; to do my taxes, while I fucked my accountant'
    6. Re:Ob by Anonymous Coward · · Score: 0

      Actually even C++ is better than C. C++ has much more convenient atomics and such. There is no circumstance when C is better than C++ unless you need existing C code.

    7. Re:Ob by TheRaven64 · · Score: 1

      C++ has much more convenient atomics and such

      C11 has the same set of atomics as C++11. Even the syntax is almost the same: std::atomic<T> vs _Atomic(T).

      The problem with C++ in embedded contexts is that the C++ committee is explicitly opposed to subsetting, yet what you actually want is a subset. You typically don't want exceptions or RTTI, and you don't want locales or a bunch of other stuff from the standard library. You end up not writing C++, but writing some arbitrary subset of C++ and hoping that your compiler / standard library will keep supporting it.

      --
      I am TheRaven on Soylent News
  17. Re:Wrong - new suckers... by Anonymous Coward · · Score: 0

    The problem is that there are new suckers born every minute.

  18. Email addresses! by Tomahawk · · Score: 1

    Learn how to properly parse an email address!!!

    It's upsetting how many web sites tell me a valid email address is invalid because the developers don't use a library that parses it correctly and don't bother looking up what is actually valid. Apostrophes and pluses are the main characters they get wrong, among others.

    1. Re:Email addresses! by KiloByte · · Score: 2

      Actually, most libraries are wrong, too. If you look at nodejs, it's astonishing how 90% of packages that ship a single line of code (plus tons of boilerplate) get even that single line wrong.

      It doesn't take a genius to look up the relevant RFC and write a regexp.

      --
      The creatures outside looked from Alt-Right to Antifa; but already it was impossible to say which was which.
    2. Re:Email addresses! by DamonHD · · Score: 1

      Getting such a regex right is MUCH harder than it looks:

      https://stackoverflow.com/ques...

      Rgds

      Damon

      --
      http://m.earth.org.uk/
    3. Re:Email addresses! by KiloByte · · Score: 1

      Depends on whether you want to support pre-Internet addresses, as that's a good part of the spec. If you drop stuff like routed addresses or comments/whitespace inside a domain, the rest is quite simple. Your MTA likely won't accept "@node.test:mary@ (this is a comment) example (whitespace around .) .net" thus it should be dropped at validation time.

      --
      The creatures outside looked from Alt-Right to Antifa; but already it was impossible to say which was which.
    4. Re: Email addresses! by Anonymous Coward · · Score: 0

      The irony of pointing to stackoverflow for solving a simple problem! Sometimes devs are their own worst enemy, along with perfectionism. The world aint perfect.

    5. Re:Email addresses! by DamonHD · · Score: 1

      I hear you. (I used to run a significant UUCP mail node, BTW!)

      But then we have to agree on a definition of 'right' for the application, which is nuanced.

      I still have a perfectly valid address rejected sometimes because it's 'too short'! (It's of the form X@YY.ZZZ)

      Rgds

      Damon

      --
      http://m.earth.org.uk/
    6. Re:Email addresses! by Anonymous Coward · · Score: 0

      A lot of people jump to regexp when it comes to parsing text.

      Regexps should come with a large warning text telling you to read up on Chomsky hierarchies before anyone is allowed to use them.

      It was formally proven that you can't parse documents like html, xml or texinfo with regexp long before any of them existed, yet people are so in love with the compact unreadable form that they try to do it over and over again and the result never handle all cases.

      Now, e-mail addresses might actually be one of the few things regexps can parse, but it takes a fool to think that anything involving regexp is trivial.

    7. Re:Email addresses! by TheRaven64 · · Score: 1

      It's perhaps worth noting that a number of 'regex' libraries aren't actually regular expressions, they are often provide some state that makes them equivalent to push-down automata, and therefore are able to parse all context-free languages. That doesn't necessarily make them the right tool for the job, of course.

      --
      I am TheRaven on Soylent News
    8. Re:Email addresses! by swilver · · Score: 1

      Email addresses either work or not (that's what the verification mail is for). Why software bothers to "parse" these at all I never quite understood -- there is nothing to parse, nothing to extract, it is a piece of text that when fed to an SMTP program may or may not result in a mail to whoever is filling in your form.

      If I want to give you a wrong email address there is nothing you can do about it anyway. If you want to be sure, you send a verification mail, no parsing needed. The mail either works or not, and therefore your account either works or not.

      It's about as stupid as asking to "retype" your email address... it is not like it is hidden like a password, I can see whether I typed it correct or not without typing it twice. Some forms even go as far as not allowing copy/paste for the 2nd time you need to type your email address...

    9. Re:Email addresses! by MoarSauce123 · · Score: 1

      The problem is that there is not one RFC that defines an email address!! There is one that covers the top level domain (if present), one that covers the domain name (if present), and one that covers the account portion. There isn't even a mandate for the @ to be present as it is not needed when sending email within one domain. What makes matters worse is that there is no official standard. RFC means "request for comment", it is not a finalized standard. What makes it act like a standard is that everyone adheres to it so practically it doesn't matter if it is stuck in RFC status for eons.

    10. Re:Email addresses! by KiloByte · · Score: 1

      The problem is that there is not one RFC that defines an email address!! There is one that covers the top level domain (if present), one that covers the domain name (if present), and one that covers the account portion.

      5322 is quite informative. The only simplification it does that I see on the first glance is that it defines "domain" as "dot-atom / domain-literal / obs-domain", dot-atom being a series of 1 or more atoms [a-z0-9!#$%&'*+/=?^_`{|}~-]+ separated by dots (ie, there might be no dots, but a dot can't be the first or last, and two dots can't come in a row). This allows using non-Internet domains, but if you know you'll use only them (a quite safe assumption), you know to refer to the DNS RFC. I'd risk saying that a policy that bans domain-literal is reasonable.

      There isn't even a mandate for the @ to be present as it is not needed when sending email within one domain.

      Yeah but a domain-less mail is useless on a contact form. It's about same as you said "exit our office, go left, the cafe is on the corner" vs "Sesame Street 42, Springfield TX, USA" -- valid only in a very limited number of contexts.

      What makes it act like a standard is that everyone adheres to it so practically it doesn't matter if it is stuck in RFC status for eons.

      e-mail RFCs are actually updated relatively often to keep being relevant, although they like to keep compat baggage.

      --
      The creatures outside looked from Alt-Right to Antifa; but already it was impossible to say which was which.
    11. Re:Email addresses! by david_thornley · · Score: 1

      In Perl, it's easy to write an expression that they call a regular expression that will do arbitrary matches. For example, it can recognize bababab, baabaabaab, baaabaaabaaab, and on to infinity. Context-free grammars can't do that. We're talking context-sensitive grammars.

      --
      "When you have eliminated the unacceptable, whatever is left, however improbable, must be the truthiness" - Holmes
  19. Absolutely not caused by newbies. by Anonymous Coward · · Score: 0

    I just inherited an application written by a group of senior developers (not young people claiming to be senior either) it was littered with string concatenations to build SQL queries, a heap of roll your own validation and zero unit tests. It was supposedly security reviewed and penitration tested but I doubt either of these were performed to a competent level as I cursory review finds all the usual issues and lazy work (catching top level exceptions 95% of the time).

    The sad thing had been to fix these issues had greatly reduced the amount of code. And simplified it dramatically. While many of the issues can be blamed on developers, management needs to shoulder some, budgets must be set to include the appropriate testing (and re testing) and not just to cover features.

    1. Re:Absolutely not caused by newbies. by CustomSolvers2 · · Score: 1

      Absolutely not caused by newbies.

      It seems quite sensible to assume that more experienced developers are way more likely to deliver better code than less experienced ones, so your general statement is certainly wrong. If you want to make generalisations (I don't like that too much though), note that most of the problems in programming and virtually everywhere else are likely to be caused by ignorance, short-sightedness and lack of experience. In programming, all these "features" are very common among newbies, non-technical staff making decisions without having a proper understanding of what they are doing and similar. I think that all this is extremely evident and is not the main reason why I am replying to you, but what is written below.

      it was littered with string concatenations to build SQL queries,

      I will never defend a-priori non-ideal approaches or code (and programmers) about which I know nothing. But I will always criticise blind trust in anything, including what seem better proceedings. SQL injection isn't more than an output of a behaviour which might be described as not having the situation controlled. It belongs to the same category that type-mismatches, boundary overflows and other errors appearing in algorithms where certain scenarios aren't properly accounted. The person writing SQL-injection-vulnerable code is extremely likely to have written many other wrong parts. These codes are created by people not understanding the underlying functionalities (how SQL databases work), not putting too much effort/care on that code or wishing things to be in certain way without confirming/dismissing that issue. Writing connect_to_db("string variable not sanitised") is pretty much the same than NumericType var = "non-numeric-type".

      A developer not understanding, applying, accepting the aforementioned ideas everywhere and just focusing on blindly repeating whatever approach might sound better for that situation is extremely likely to provoke other problems. I am fully aware about how to use parameterised SQL queries in any language (= knowing it right away or spending 5-10 seconds researching it) and the (dis)advantages of relying on many other approaches (e.g., specific vs. generic types); and I might choose one approach or the other depending upon the scenario. In fact, I tend to rely on string concatenation for SQL-query building. Nothing of that has absolutely any influence on the resulting applications (safe, reliable and efficient) or the generated code (well-structured, commented and usually scalable); because I know what I am doing, because I am experienced and sensible enough to not blindly apply and trust in generic anything, because I do have a full control over the code which I write, all its inputs/outputs and because creating a proper piece of software can be accomplished in an infinite number of different ways, many of them identically good.

      When you forget about all that (having the proper result you are looking for) and start focusing on irrelevant issues (worrying about making sure that you apply certain proceeding for no good reason), you might have to start rethinking a bit some of your ideas. There are lots of people systematically looking for impossible shortcuts; seriously thinking that there are generic, easy, always-working answers for complex problems; that top-quality knowledge, reliability, dependability might be easily and quickly achieved, even in something as wide and complex as programming. The reality is that all these people are extremely wrong and will only be provoking problems to themselves and others. The only way to have good skills in something as programming is time, dedication and certain basic background/personality. There is no alternative, no shortcut, no magical solution, no combination of words proving otherwise, no genius intuitively-understanding everything, no set of written-in-stone rules which will always work. On the other hand, there are lots of short-sighted people (some of them quite aggressive), lots of lies, people in denial, incompetence, unfair blaming, stupid decisions and some ignorance-prone trends which hopefully will gradually get extincted.

      --
      Custom Solvers 2.0 = Alvaro Carballo Garcia = varocarbas.
    2. Re:Absolutely not caused by newbies. by CustomSolvers2 · · Score: 1

      Here you have some ideas for those talking about SQL injection without knowing too well what all this is about. There are two basic requisites for this situation to ever occur:
      1. Non-sanitised string SQL query (= sending a random string to the database without checking what is in there).
      2. The potentiality of a malicious action to happen (e.g., building the SQL queries from random user inputs).

      If any of the aforementioned points is missing, the probability of a SQL injection to ever occur is exactly zero. What means that you can ignore the first point and blindly send queries to a SQL database (not precisely recommendable) if, for example, all the strings are hardcoded or no external actions will ever affect any of them. Similarly, you might rely on random inputs, as far as you make sure that the resulting SQL query is fine; focusing on this second aspect is the most usual proceeding. Again, I am not recommending or promoting to rely on non-ideal proceedings, just sharing some basic, objective, fanatic-free information which some people (some of them with lots to say in programming-related aspects! Incredible, but true!) might find helpful. Long live to the little bobby tables! LOL.

      --
      Custom Solvers 2.0 = Alvaro Carballo Garcia = varocarbas.
    3. Re:Absolutely not caused by newbies. by CustomSolvers2 · · Score: 1

      For the record and in case anyone is interested, I am not a web developer in the sense of mostly having web-based experience. I specialise in (custom & from-scratch) algorithm development, numerical/engineering/data analysis and efficiency improvement, where the exact language or framework (desktop, web or whatever) is quite irrelevant. Anecdotally, most of my experience is focused on desktop environments (Windows and Linux).

      --
      Custom Solvers 2.0 = Alvaro Carballo Garcia = varocarbas.
    4. Re:Absolutely not caused by newbies. by angel'o'sphere · · Score: 1

      That is actually the biggest mistake I see in modern development. (referring to the linked xkcd cartoon)
      Instead of having different DB users with rights to change the schema and rights to only query data, they have a single super user that nearly can do everything.

      --
      Cost free eBook I read (by iBook/Kobo/Amazon/ObookO/Gutenberg etc.): "The Green Odyssey" by Philip Jose Farmer.
    5. Re:Absolutely not caused by newbies. by CustomSolvers2 · · Score: 1

      Instead of having different DB users with rights to change the schema and rights to only query data, they have a single super user that nearly can do everything.

      Good point.

      --
      Custom Solvers 2.0 = Alvaro Carballo Garcia = varocarbas.
    6. Re:Absolutely not caused by newbies. by CustomSolvers2 · · Score: 1

      As far as you had some problems in the past to understand what a mechanical (industrial) engineer is, here you have what seems a clear enough example: Tony Stark/Ironman, in case of being real, making real things and having real knowledge would be a mechanical engineer; or, at least, would have an important mechanical engineering expertise.

      I want also to clarify that my opinion about you hasn't changed much; I still don't quite understand why you are so interested in talking to me, mainly after some past incidents. On the other hand, I am a resentment-free guy always ready to update my impressions if required; I do expect everyone to take full responsibility for past actions though, more out of fairness than resentment. In case of thinking that your comments are reasonable, I might reply you and keep changing my opinion; otherwise, I will continue ignoring you as so far, something which I only do under extreme circumstances.

      --
      Custom Solvers 2.0 = Alvaro Carballo Garcia = varocarbas.
    7. Re:Absolutely not caused by newbies. by angel'o'sphere · · Score: 1

      I read text ... and answer to text.
      Not to the name of the sender.

      No idea who Tony Stark/Ironman is ... and no idea why you switch to mechanical engineers.

      --
      Cost free eBook I read (by iBook/Kobo/Amazon/ObookO/Gutenberg etc.): "The Green Odyssey" by Philip Jose Farmer.
    8. Re:Absolutely not caused by newbies. by CustomSolvers2 · · Score: 1

      I read text ... and answer to text.

      Excellent approach! I also tend to do same, but there are exceptions. Perhaps I made a mistake and your various interactions with me obeyed to pure randomness. Kind of weird, but possible why not? I cannot avoid remember most of nicks/signatures with which I have chatted here, but perhaps this isn't the case with everyone. Anyway, sorry if there was any misunderstanding.

      No idea who Tony Stark/Ironman is ... and no idea why you switch to mechanical engineers.

      This comes from a previous chat with you (with that account; perhaps I am wrong to assume that only one person uses it) where you didn't know what a mechanical engineer was. I thought that Ironman was part of the popular culture which most of people know, mainly in a site for nerds. Again, accept my apologies for any misunderstanding.

      --
      Custom Solvers 2.0 = Alvaro Carballo Garcia = varocarbas.
    9. Re:Absolutely not caused by newbies. by angel'o'sphere · · Score: 1

      Erm, you are most certainly mixing me up.
      I am a software engineer, so obviously I know what a mechanical engineer is. I'm german, we are most famous for our mechanical engineering studies in our universities.
      But when you said Ironman, I dod not think about that movie. As I did not read the those Marvel comics when I was a kid, the movies don't really interest me. Unless I stumble over one by accident on youtube, I never watch stuff like that.

      --
      Cost free eBook I read (by iBook/Kobo/Amazon/ObookO/Gutenberg etc.): "The Green Odyssey" by Philip Jose Farmer.
    10. Re:Absolutely not caused by newbies. by CustomSolvers2 · · Score: 1

      Erm, you are most certainly mixing me up.

      I think that I am not, but It isn't too important. It was a quite aggressive argument about physics (which I am not particularly interested in searching) where misinterpreting other's position was quite easy. Anyway, sorry for going so much off-topic and again good point about databases.

      --
      Custom Solvers 2.0 = Alvaro Carballo Garcia = varocarbas.
  20. Economics and education standards by dougTheRug · · Score: 1
    I have been working in software security for twelve years, telling developers not to write SQL Injections, or designing processes to detect and fix them. I think there are some chief problems:

    Any business goes through an initial development phase of creating a minimum viable product. During this time, the company needs to decide if it is going to survive or not, and it must make this decision absolutely as soon as possible.

    The SOONER the business idea can FAIL, the faster the resources can be put into the next possibly viable idea. And most ideas do fail. So during the minimum viable product phase, it actually does not make economic sense to write good comments, have coding guidelines, or yes, eliminate security vulnerabilities.

    The sensible time for businesses to invest in security is: "as soon as you can afford it," which is when you have ramped up some customers and have some recurring revenue, maybe a B funding. By this time, there is a lot of code written and the business processes need a kick-start to introduce security. If the CTO or chief inventor is resistant, the security enhancements will unfortunately not be taken up correctly. If you wait until too late (3rd parties and customers customizing your APIs, or acquisitions) it costs 100x more to get the security work done.

    the second reason is: Lack of good security education in university. A few professors have posted here already about how their students are idiots and don't get it. The thing is you cannot bolt on basic security knowledge at the end of a course and expect it to stick. Every coding course should be a secure coding course as much as it is a (nobody would say this) CORRECT coding course. The end result is most students emit from university having heard the phrases cross-site-scripting, sql injection, buffer overflow -- but do not know what they are or how to prevent them.

    1. Re:Economics and education standards by swilver · · Score: 1

      The real mistake is that people think you can teach people how to write proper software with a couple of hundred contact hours as a small part of a 4 year university program. Many of these people didn't have enough prior interest in building software to even have tried writing some software before attending these classes.

      It is about as delusional as thinking that you can become a star athlete having done nothing but sitting on a couch for years eating chips and then doing 4 years of aerobics and spinning classes for a few days a week.

      Every decent software engineer I know is passionate about their *hobby* -- it isn't even work to them, it is like getting paid for the thing you like to do anyway. Without fail, they learned to build software on their own, self educated, often in their teens before schools even touched the subject. They have years of experience that go far beyond the experience they obtained doing "work" -- they often toy on side projects, in their spare time, and will fiddle with designs and code until it is just right, deadlines be damned.

      There are precious few of those people, and while some no doubt will be able to become decent engineers through education, they'll never be as good or as those curious people that made software their lives early on.

    2. Re:Economics and education standards by Anonymous Coward · · Score: 0

      Every decent software engineer I know is passionate about their *hobby* -- it isn't even work to them, it is like getting paid for the thing you like to do anyway.

      One of the best interview questions I've had asked of me was, "how many computers do you have at home?". If the answer is under three, you were likely not getting the job.

    3. Re:Economics and education standards by Anonymous Coward · · Score: 0

      You are absolutely right. The problem is those "hobby" coders are not numerous enough to produce all the code a modern society needs (or at least wants.) That means we need a way to make safe coders out of the all the people who treating coding like a job. Obviously the 55 credit hours required by most Computer Science degrees are insufficient. (Note I realize that undergraduates need more credits to graduate. I'm not including general studies, math, etc.)
      So what's need to change that? I note that many universities in the U.S., finding that their students could not write have required professors include writing requirements in many types of diverse courses with the goal of making their student's practice writing.
      Does it need to be a requirement that all programming and computer science courses include security as a requirement?
      Likewise there is not a university of which I am aware that gives a B.S. in architecture in less than 5 years, with most US architecture license requiring an additional three years of study. Is it time to admit that it is not possible to train someone to write safe programs that preform functions that can cost high dollar amounts and even sometimes risk lives in just 4 years?

    4. Re:Economics and education standards by angel'o'sphere · · Score: 1

      That is correct.
      You can not simply teach something.

      People have to learn by doing the stuff. And there they need feedback or a strong way of self reflection.

      The idea that one learns about any software topic by just sitting in a CS course is nonsense. It is more like martial arts. You can read and talk as much as you want about it ... the only way to 'learn' it is by practicing it. And that automatically implies: the older the better. That ageism in USA regarding software developers is a strange phenomena to me.

      --
      Cost free eBook I read (by iBook/Kobo/Amazon/ObookO/Gutenberg etc.): "The Green Odyssey" by Philip Jose Farmer.
  21. It's simple, really by Anonymous Coward · · Score: 0

    They are stupid. People who work with computers are stupid, in general. There are very few exceptions. They lack social skills, real-world problem-solving skills, they are lacking in each and every field that makes a human being whole. Their jobs can be outsourced and now even automated with no loss whatsoever, but they cannot see it because of an unjustified perception of self-importance that, when nullified by reality, causes them to go into embarassing and ineffective fits of rage. And that pretty much sums it up.

  22. Why? by nicolaiplum · · Score: 1

    "Why Do Web Developers Keep Making The Same Mistakes?"

    StackOverflow.com

    (they read the same wrong answers as other people, because every "I found this useful" or "Lots of people read this" ranking system does not detect factual errors, only opinions)

    --
    "For a successful technology, reality must take precedence over public relations, for Nature cannot be fooled"
    1. Re:Why? by Megane · · Score: 1

      Came looking for this, was not disappointed. They keep finding the same broken half-answers on a web site that is skewed by people scamming for points.

      I never signed up for SO, and now it's not worth bothering, because between so much already having been answered, and people who know less than they think they do down-voting good answers, I could never get any kind of decent reputation score, short of creating my own programming language that got popular so I'd have fresh questions to answer.

      --
      #naabhaprzrag, #sverubfr-000, #agi-fcbafberq, negvpyr[pynff*=' negvpyr-ary-'] { qvfcynl: abar !vzcbegnag; }
  23. Why does anyone do half-assed work? by jcr · · Score: 1

    It's because they themselves don't suffer the economic loss of fucking it up.

    -jcr

    --
    The only title of honor that a tyrant can grant is "Enemy of the State."
    1. Re:Why does anyone do half-assed work? by TheRaven64 · · Score: 1

      This deserves to be moderated up, perhaps with the corollary that often they will suffer economic loss as a result of taking the time to do it right.

      --
      I am TheRaven on Soylent News
  24. Software is difficult by Njovich · · Score: 1

    Even the simplests of software consists of thousands of lines of code where a simple mistake can compromise the system. People make mistakes. Online documentation gives flawed examples. It will take an infinite amount of time to write software to perfection. The poor guy in India working 80 hours per week coding the system has no way to know every system he is writing code for. Nobody has ever told the entry level developer that the secure_rng() or mysql_escape_string() library function is in fact not secure for his particular case. Code auditing or testing can never check everything. You only notice the places where things go wrong. Things that were secure once are no longer secure, but the code is still there. It's just a prototype, we'll never use it in production. It's 1985 and you haven't considered that someone will still use this code in 2017 or hook up your code to a network. Got to make the deadline that was set deliberately tight by an 'efficiency' seeking project manager. The experienced programmer was too expensive. Someone else was supposed to filter that variable.

    1. Re:Software is difficult by 110010001000 · · Score: 1

      Exactly. It will take an infinite amount of time to write software to perfection. Everyone here is bitching about it, but what is your alternative? Get a grip people, suck it up or do without software and go back to pen and paper.

  25. Every year by thsths · · Score: 1

    my students make the same mistakes. It is as if they learn nothing...

  26. quick and dirty by Begemot · · Score: 1

    can it be that often times "Beware SQL injection! ..." is followed by "and I need it yesterday"?

    1. Re:quick and dirty by Anonymous Coward · · Score: 0

      This.

  27. Agile is root.... by Anonymous Coward · · Score: 0

    In my experience, Agile methodologies have a lot to do with this issue, and not necessarilay because of the methodology per se.

    Everywhere I have been, rightly or wrongly, Agile has fostered a mentality of 'when the code works. the job is finished'. That then fosters a dev attitude of 'get it working, tidy the code up after it's working'. This almost always never happens! The reason? Because if the business abuses Agile to change their minds too often, the dev gets bored of changing their code god only knows how much, and bingo...... give up trying....

    1. Re:Agile is root.... by david_thornley · · Score: 1

      FWIW, this is not my experience with Agile, although this is admittedly only at one company. The company taking this seriously and trying to do it right might have something to do with that.

      --
      "When you have eliminated the unacceptable, whatever is left, however improbable, must be the truthiness" - Holmes
  28. Here's my take by Anonymous Coward · · Score: 0

    I am not that familiar with developing software. But it does appear to be a pattern of attack for hackers. This is popular software that is very complex, has potential for exploitation, and by its very design has access to areas of the OS and PC that can be accessed through that software. Sort of like a robber finding a open window, the robber wouldn't enter through a locked door. People who develop software generally don't spend a lot of time trying to find compromises or exploits. This is why even Google and Microsoft offer up rewards for others to do their dirty work so to speak.

  29. Wrong Message by Anonymous Coward · · Score: 0

    I wonder if the problem is that it's the wrong message.
    So much of the training and literature focuses on how an attack is performed rather than how to defend against an attack.
    Perhaps security people could consider preaching about the Monster Mitigations http://cwe.mitre.org/top25/mitigations.html instead of the OWASP top ten.

    1. Re:Wrong Message by MoarSauce123 · · Score: 1

      Yep...and there is hardly anything that details how to test for such vulnerabilities!

  30. Time is money by Anonymous Coward · · Score: 0

    You want to impress the boss? Get "working" code out the door. You want to get marked as a time-waster? Test everything properly and implement all appropriate security measures.

  31. Simple. Shiny by quonset · · Score: 1

    Web developers are more interested in showing off the latest and greatest procedures, bouncing ads and every unnecessary script they can lay their hands on than they are producing a usable web page.

    Within the last week I am suddenly unable to access the comments section on a web page I have gone to for years. Most likely because the developers changed twenty scripts and since I never run the latest and greatest browser, comments are now inaccessible.

    There is absolutely no reason not to have a link work in this day and age EXCEPT if it's generated by a script. The simplest of actions on a web page and developers can't get it right. If they can't get that right, why should we expect them to get anything else right?

  32. Many Listen, clients don't by Anonymous Coward · · Score: 0

    Many listened, and audit their code use tools available etc. Clients don't they want you to reuse vulnerable code, to cut costs etc. I stopped working on anything, where I don't have full control. It's my name on the line. I won't be rushed.

  33. Ctrl-C Ctrl-V by digitalhermit · · Score: 3, Interesting

    Many APIs have demo code in curl or Java with the express warning that it's demo code and not to be used in production. But it shows up anyway.

    I worked on a project last year where some offshore developers were tasked with writing an integration to a RESTful API for Nexpose. As far as "web programming" goes, talking to a REST API is pretty much a sine qua non for being called a "web developer". They didn't know how to do so. I understand that members of this same team have worked on other corporate sites.

    Combine CTRL-C/CTRL-V with inexperience and you have the source of your mistakes.

  34. Software "Engineering" vs Civil Engineering by uthanda · · Score: 2

    I've been thinking about this for a few years and have come to the conclusion that we will continue making the same mistakes until we can create a set of rules that everyone can follow. If you look at what civil engineers have done you will see that they have reduced much of what they do to equations and repeatable patterns (for lack of a better term). When someone sets out to build a bridge or a building, they start by designing it with an architect and then they pull out the equations and key tables to ensure that they have the load, weight, use, wind and all the other elements take into account. This is coupled with a very strong set of building codes that dictate minimum strengths, materials and designs to ensure safety. Setting aside the occasional corner cut in construction or neglect, when was the last time a building or bridge just collapsed? (Ok, we know the bridge in Minneapolis, but that wasn't design it was neglect)

    It's this level of discipline and rigor that ensures what engineers and architects design and build will work as planned. Couple this rigor with government and professional group mandated licensing of practitioners (try getting a building built without a professional engineer stamp on the design certifying the design is sound) and you can ensure that those designing and building something has a minimum level of training and understanding of the basic physics and processes to ensure sound design.

    Until software development can create those same sets of rules and patterns, we will be doomed to repeating the same errors over and over. What we're doing right now is the equivalent of showing someone geometry, basic physics and some sense of writing and then expecting them to design and build the Empire State Building, Burj Khalifa or an Airbus A380. If our physical counterparts did the same, then no one would even think of flying or sleeping in anything other than a tarp strung from trees.

    1. Re:Software "Engineering" vs Civil Engineering by Anonymous Coward · · Score: 0

      As the old saying goes "If Engineers designed buildings like Developers design software then the first woodpecker that came along would destroy all of civilization."

    2. Re:Software "Engineering" vs Civil Engineering by Anonymous Coward · · Score: 0

      Most engineers also tend to just be "lazy" and/or "cover their asses" and over specify by massive amounts - e.g. specify double the steel that is required rather than work out the exact amount needed.

      Society is okay with this when it comes to physical projects, they are used to the massive costs, I'm not sure Software Engineers would be able to get away with the same in Software everyone always wants to cut costs if you were found to be doubling the specification on something you'd probably be fired.

    3. Re:Software "Engineering" vs Civil Engineering by uthanda · · Score: 1

      That may be, but again, things they design rarely fail, especially for commonly built things (again the physical equivalent of a database-backed application). They also have some sense of civil liability if something were to go wrong (https://www.nspe.org/resources/professional-liability/liability-employed-engineers). This may drive them to be conservative, but I also believe Engineers understand something developers may not: their work can kill if done improperly. While a dev's work is unlikely to have a direct life-or-death consequence (save medical, aeronautical, automotive or other machinery), it can often have equally bad financial or other consequences (ahem ... Equifax, OPM, etc ... ahem).

      Call it CYA if you want, but it works. It may not be 100% efficient or live on the ragged edge of "good-enough", but it saves lives. And I would argue that it's only a matter of time before the costs involved in SW-based disasters (again see Equifax, et al) begin to be unbearable by society as a whole. When that happens, we will see this make it fast/cheap and to hell with the consequences attitude change.

    4. Re:Software "Engineering" vs Civil Engineering by Anonymous Coward · · Score: 0

      On the upside buildings would cost 1/10000th the price though.

    5. Re:Software "Engineering" vs Civil Engineering by Anonymous Coward · · Score: 0

      I happen to know a lot of civil engineers and it is a common attitude to specify double the structural steel just because "the client can afford it" - like it or not this attitude just wouldn't cut it in the software world right now.

      Also engineering errors happen more than people are aware of, especially on "smaller" projects (think shopping centers) - but even on larger projects, dams being a case where they have been quite a few failures for instance, it just isn't something that is talked about that much outside of engineering circles.

      Not defending the software profession but most comparisons to other Engineering disciplines are done with rose tinted glasses.

    6. Re:Software "Engineering" vs Civil Engineering by Anonymous Coward · · Score: 0

      Those rules and patterns already exist. It's just no one bothers to learn or follow them. Even you. You've been "thinking" about the issue but you've never researched it. Everyone just thinks about things nowadays and try to implement their solution without looking around to see what already exists. Would reading 40 year old SE papers be useful today? Hell no! Lets just write a manifesto which happens to cover the exact same points brought up in the very first software engineering conference, but we'll include more emotion and none of the research to back up our claims.

      Until developers get off their lazy asses and focus on quality instead of cool, the industry will never improve. Religiously praising languages almost designed to screw you over isn't helpful either. SW tools aren't involving well enough to be preventing all these types of errors. Instead people mess around with syntax and function names only to repeat the same mistakes over and over, changing only things that barely matter. It is impossible to overflow a number in some of the older languages, that feature is missing from more modern languages.

    7. Re:Software "Engineering" vs Civil Engineering by david_thornley · · Score: 1

      Doubling what specification? Use a cement pillar of twice the cross-section and you get twice the strength. (Or something like that. I'm not a civil engineer.) This is a case where you can just make up for ignorance by using more stuff.

      You can't do that in software. If you add additional code, you're adding to the attack surface. It may make the application more secure, but not necessarily.

      --
      "When you have eliminated the unacceptable, whatever is left, however improbable, must be the truthiness" - Holmes
  35. Same as Linux by Anonymous Coward · · Score: 0

    What can you do?

    The same thing that Linux has needed for a long time: Stop focusing on the Next Big Thing.

    Many Linux services are half-done; with inconsistent menus or interface controls, missing documentation, out-of-date sample files, then after 5 years, the leaders decide to use a different tool. It's why Linux has a mediocre UI and exhausting UX: Their philosophy is, usable is good enough. Linux is designed for servers, so it has more stability and security is a lot tighter than a certain sales-driven OS but, as several developers have complained, there's no effort to make it desirable or consistent.

    Businesses also suffer from the problem that they can't copy code: Part of it is copyright and IP, and part is needing custom software to fit their custom work processes. That custom bit is why software programmers exist today: Precise mathematical models aren't enough and piling black-box (framework) upon black-box destroys security, stability and consistency. It's re-inventing the wheel, every decade.

  36. Why do web devs keep reinventing the CMS? by drinkypoo · · Score: 1

    People keep thinking they can do better by themselves than whole teams of coders hammering on code and getting patches from dozens or hundreds more users, and they keep getting proven wrong. Why would anyone reinvent the CMS at this point?

    --
    "You're right," Fisheye says. "I should have set it on 'whip' or 'chop.'"
    1. Re:Why do web devs keep reinventing the CMS? by MoarSauce123 · · Score: 1

      Because all of the ones out there suck in varying degrees. Same with browsers and operating systems, they are all a crap fest.

  37. But, but, but, ... by Anonymous Coward · · Score: 0

    Do dynamic application security testing, including penetration testing and fuzz testing. Ensure admins do their part to protect applications. And finally, make sure you establish a culture of security-aware programming and deployment.

    But, but, but, that costs money!

  38. Not invented here by trawg · · Score: 1

    Lots of interesting comments but didn't see this one so though I'd throw it in: Not Invented Here Syndrome.

    I've seen this first hand a lot. Manny developers will get a project, review some options for components (e.g. CMS is the classic one) and decide that because that component only needs 99% of requirements, they should roll their own solution, because using that component and modifying it will take to long as they have to learn the extension system or whatever.

    As a result they end up writing lots of new untested code. Even with best intentions and good practices, bugs and thus exploits are inevitable. Especially when the focus is on making sure you're avoiding one specific class of problems like SQLi, meaning people tend to focus on check listing that instead of taking a broad, security in depth approach.

    Inevitably after a few months it turns out they underestimated the complexity of writing a whole new system from scratch and sacrifices are made, leading to focus on speed and getting it done over security.

    (Not really sure if this problem is about "Web developers"; it really seems to be a symptom of software development in general.)

    1. Re:Not invented here by Anonymous Coward · · Score: 0

      Hmm...modifying a large, complicated component that you don't really have the time to understand is likely to be just as risky as writing a new component. So what to do...

  39. Because other things are more important by Xordin · · Score: 1

    In the market, useful websites beat secure websites.

    So by natural selection, developers that ignore security multiply, while those that focus on security die out.

  40. Web Dev here. by sambaynham · · Score: 1

    The main answer, at least in my own career, is this: Lack of formal architecture training. I'm self taught, as many web devs are. Now, I was considered a pretty good Web Dev, by Web Dev standards, but I noticed that the projects my team was working on ran into common problems. No matter what fancy programming methodologies and delivery tools we were using, we always reached a point where the solution ossified and became difficult to develop for. This meant that in projects with complex requirements we always overran. Also, while we could make the client happy on delivery, we struggled to *keep* them happy. We tried 'Agile', we tried 'Extreme', we tried a thousand different buzzwords, but nothing worked. As a Web Dev, when you see this happening, there are two ways you can go. You can: A: Accept this as a reality of the field, and carry on as before. You can then have a breakdown at thirty and never work again. B: Refuse to accept crappy software and look for a better way. If you're thoughtful, and not too vain to learn the lessons of the sages, you discover the Gang of Four, Design Patterns, etc, and achieve enlightenment. I went for B and finally, after ten-odd years as a professional, am finally writing good software that *stays* good.

  41. I'm not surprised by nickjj · · Score: 1

    I use this one course hosting platform called Thinkific and pay them $100/month.

    I reported a bug 4 months ago that allowed people to purchase the wrong course when they had 2 check out windows open. It's still not fixed because it's not considered a priority. So a critical billing bug which results in customers buying the wrong course isn't considered important by their decision makers.

    So while developers are making these mistakes I have a feeling a lot of times they don't get fixed because someone at the management level has an even worse understanding of what needs to be addressed.

  42. Agile by geekymachoman · · Score: 3, Interesting

    What does agile have to do with it, except make company spend money on "scrum masters" and other nonsense instead of hiring a proper security team ? While it has some good ideas, i wouldn't attribute improvements in security to standup meetings, runs and scrum masters.

  43. Indeed by OneHundredAndTen · · Score: 1

    All too often it looks like websites are designed by the stupidest member of the team. For example, the password policies that many sites impose range from preposterous to downright ignorant.

  44. Regression suite & secured frameworks? by Anonymous Coward · · Score: 0

    Regression suite & secured frameworks?

  45. my theory: by buddyglass · · Score: 1

    Management doesn't care enough to fire them when they fuck up. If developers knew their job was on the line they might pay more attention to security. You can train them all you want, but if there are zero consequences when they ignore that training then they'll continue to be lazy.

    1. Re:my theory: by Anonymous Coward · · Score: 0

      This reduces it to a simplistic case of lack of consequences for inherently lazy workers. More spankings, quality will improve! All problems are management problems. Lazy or incompetent workers? Who hired them? No security audits? Whose fault is that? Prioritizing new features over fixing known security holes? Hiring cheap inexperienced workers? All management problems. The truth is that hardly anyone gives a crap about software quality. Good enough is the bar. Actually, "barely usable" to be more accurate. That along with a culture of shiny new eye candy over working software.

    2. Re:my theory: by buddyglass · · Score: 1

      This reduces it to a simplistic case of lack of consequences for inherently lazy workers.

      I honestly think it's that simple. If people understood their continued employment was contingent on writing quality code, whether with respect to security or anything else, they would be much more careful. As it is, nobody cares, so they respond rationally to the incentives that are presented. Show up, have a good attitude, meet your deadlines, and don't commit bugs so egregious they break the product in "obvious" ways. If you commit code that breaks the product in non-obvious ways then, well, nobody's perfect; we're not holding you accountable.

      The truth is that hardly anyone gives a crap about software quality.

      Yes and no. Most managers, devs and executives care, but only up to a point. That's the key. The happy path needs to work or the company's customers will leave. However, the product can be super buggy outside that happy path, perform poorly, and be porous from a security perspective and nobody cares. At least, not until that porosity is noticed and exposed publicly; then everybody cares all of a sudden.

  46. And Yet... by Anonymous Coward · · Score: 0

    Almost everyone, including developers:

    -Uses online banking
    -Files taxes onlne
    -Pays bills online
    -Receives paychecks online (To be fair, this is sometimes demanded by employers.)
    -Uses online medical records
    -Links multiple accounts to their bank account
    -Divulges personal information on social media
    -Keeps their photos in the cloud

    Then they are surprised when their identity is stolen.

  47. Provided there is a team by tepples · · Score: 1

    I think *all* code should go through at least peer review by a senior team member.

    If there are more than one programmer at a company, yes. But when (say) a small toy retailer in the Midwest has the budget to hire only one programmer to build its order fulfillment back end, who would review his code? Fortunately, this company's programmer at least takes care to escape HTML, parameterize or whitelist anything going into an SQL query, and require all POSTs to include the session's CSRF token.

  48. Complexity, abstraction and inexperience by ErichTheRed · · Score: 1

    I do systems integration work, so I work with the output of developers rather than doing coding -- our group gets their creations working in the real world outside the dev's laptop. What I see driving this is a mix of super-complex frameworks and other abstractions layered on top of what was designed to be a very simple system. Because the development they do is so abstract, there's very little understanding of what's going on 4 levels below their code...a database query (probably not even a SQL query these days) gets passed with user input from client-side JavaScript code to whatever MVC framework is popular this month, and a data set is returned for the client code to parse and display. You don't have to know anything about how SQL or whatever NoSQL data source works, how HTTP works, how the TLS session that is hopefully securing your session is set up, or how the message gets from one system to another. I'm sure lots of people are going to say "dude, that's old school graybeard stuff...the frameworks do it all for us!" But, I'm of the opinion that at least some first-principles instruction is needed and most new developers are coming in at a level way higher than this.

    A personal example from my world is that I've started working a lot with cloud computing, automating deployments and such. The cloud providers have done a very good job abstracting the insane amount of details that go into deploying a cloud resource, but the documentation is aimed squarely at web developers...it's all "insert properly formatted JSON file into our magic box and out pops what you asked for." This is good, but it gives zero insight into how things work, and new developers coming into the cloud-first mobile-first world won't get this education at all. Form my perspective, the only way I've been able to get my head around REST and all that stuff is to start from first principles and work up...not starting from the top of a framework call.

    I think that this will be even more interesting to watch as more and more apps are written by non-Netflix, non-Facebook, non-Google developers as microservices. Suddenly one app is hundreds of tiny ones, each with potential vulnerabilities. The skill level has to go way up when you start working this way, because speed of release isn't going to help solve security problems developers don't know they have.

  49. Our industry does not learn from history by Shados · · Score: 1

    As a whole, software engineers are arrogant little snowflakes who think they're better than everyone around them or those who came before them.

    So they just keep repeating mistakes over and over and over, rejecting advice straight up. So you can explain to someone doing something how you've seen it a million times before and it doesn't work...they'll still insist they know better. And when it blows up in their face, they'll say it was inevitable. (Obviously not always their fault: a lot of advices they get IS bullshit and they can't filter the good from the bad).

  50. It's our entire educational system by Anonymous Coward · · Score: 0

    It isn't just limited to web developers. Primary Care Physicians make the equivalent of "sql injection" mistakes all the time. That is, they screw up things that they would have been taught year 1 day 1 of medical school. We have to ask the question, how is it these people are still able to get degrees that say they know what they are doing, when clearly they do not?

    Also, since you just get a degree after a few years and are shoved out the door, people who make these mistakes after leaving school, go on to have 40-year long careers where they keep screwing up and making the same mistakes over and over again.

    1. Re:It's our entire educational system by ErichTheRed · · Score: 1

      That's interesting. My impression was that since medical school slots were so tightly controlled and that the selection process ensures that entrants basically have a voracious memory, the quality of graduates was pretty uniform. Are there differences in quality?

      I figured that was the reason doctors always seem to have all the answers...because the basic stuff is in a textbook they memorized during medical school and had it reinforced by seeing the same thing on the job. (I also figured the selection process selecting for super-academic types was why most doctors I've met have planet-sized egos.)

  51. University padding employment percentage by tepples · · Score: 1

    Why do companies keep making the same mistakes hiring recent college grads

    Might they have been bribed to do so by universities seeking to improve their post-graduation employment percentages?

    Companies have champagne taste and a beer budget.

    For which they think the rational solution is to seek out equally tasty, equally intoxicating sparkling wines produced outside Champagne.

  52. Operator IN causes problems for prepared stmts by tepples · · Score: 1

    It doesn't matter: half of them still write injectable queries, even though using "prepared statements" isn't any more complex.

    In the majority of cases, I agree that "using 'prepared statements' isn't any more complex." The biggest exception is operator IN, as none of the popular free database engines that I tested support an array as a parameter. Instead, they require each value in the list on the right side of operator IN to be its own parameter, and the application is responsible for building both the (variable-length) list of question mark placeholders and the array of values to be substituted into the equation. It also has to ensure that the order of the question mark placeholders, particularly those that occur before or after the use of operator IN, doesn't fall out of sync with the order of the elements in the array of values, or else the inadvertent use of values intended for operator IN for other parts of the statement or vice versa will end up itself causing a security hole. At some point, if the engine you're using doesn't support named placeholders, a well-tested routine to escape a single array of values for the right side of operator IN becomes safer than using question mark placeholders because of less risk of accidentally mismatching the order of placeholders with the order of values.

  53. It was a pleasure shooting you down 5:1... apk by Anonymous Coward · · Score: 0

    Tepples, It was a pleasure shooting you down 5:1 https://meta.slashdot.org/comments.pl?sid=11284751&cid=55453197/

    * LOL!

    (Don't EVER "try me" again or it'll be MORE of the same...)

    APK

    P.S.=> Not even a "nice try" - especially considering you ask people to SPEND "$" on Pi + DGA domain registrations & HOSTS = FREE & NATIVE - not "illogic logic" of "Bolting on 'MoAr'" but working w/ what you have already that costs nothing!

    All that empty 'talk' only to lose (see link above) on YOUR end, lol!

    Plus, YOU HAVE NEVER BUILT ANYTHING LIKE I HAVE YOURSELF either, lmao - pretty pitiful - all talk/no substance of your own... apk

  54. ...with the administration by tepples · · Score: 1

    I think you have to honestly look at yourself and if you are not educating or failing these incompetents, you are a bad professor and a part of the problem.

    If the administration gives a professor only one semester to cover what ought to be two semesters' worth of information security material, as gweihir described, is a professor who doesn't quit in protest "a bad professor and a part of the problem"?

  55. Some parts of C++ need more than 32K by tepples · · Score: 2

    Unless you're targeting a system with 32KB of RAM or less, or you have very strict realtime guarantees (and so aren't even using malloc) there's rarely a good reason to use C these days.

    I would dispute this 32 KiB figure.

    Several years ago, I wrote a program for Game Boy Advance homebrew that used a single std::ostringstream once, and even after enabling -Wl,--gc-sections, the statically linked executable was 180,032 bytes. It turned out that the constructor for a std::ostringstream in GNU libstdc++ would call the constructors for date, time, and currency formatting aspects of the locale even if I never output a date, time, or currency object. For a scale reference, the GBA's RAM is 32 KiB of fast RAM, 256 KiB of slow RAM, and 96 KiB of video RAM. Although up to 32 MiB of execute-in-place ROM in the cartridge is available for a single-player game, no cartridge is inserted into the systems of players 2, 3, and 4. Thus the program has to fit completely into the 256 KiB of slow RAM, as the fast RAM is used for the stack and BSS.

    1. Re:Some parts of C++ need more than 32K by TheRaven64 · · Score: 1

      To counter your anecdote: the SDK for ARM's mBed system is C++ and so is their newer mBed microkernel. Both run on systems with 32KB of RAM. I've written a thing to control the Christmas lights outside of my office that runs on an ARM Cortex M0 and uses C++ templates and some virtual functions to describe a stackable set of transforms that are applied to an LED strip. It uses about 1.8KB of RAM, because I didn't bother optimising it, but I could easily get it lower if I cared (the board has 32KB of RAM). For embedded programming, you probably don't want RTTI or exceptions, but that doesn't mean that you can't benefit from some memory safety.

      --
      I am TheRaven on Soylent News
    2. Re:Some parts of C++ need more than 32K by Anonymous Coward · · Score: 0

      No one cares about your Game Boy Advance hobby, shortbus tepples.

  56. Re:It was a pleasure shooting you down 5:1... apk by Anonymous Coward · · Score: 0

    You are off-topic. Your post appears as a non-sequitur. When another user engages you in discussion, please confine your replies to the posts to which you are replying, not the same user's posts to other unrelated discussions. What next, are you going to dig up his usernames on SoylentNews, Reddit, and elsewhere and reply to him there?

  57. Tepples, you take a shot @ me? by Anonymous Coward · · Score: 0

    See subject: Tepples I simply SHOOT YOU DOWN & BLOW YOU AWAY, easily 7:1 -> https://meta.slashdot.org/comments.pl?sid=11284751&cid=55453197

    * I truly do NOT recommend you ever try it again, or you'll what happened in the link above, PUBLICLY TO YOUR DISMAY (obviously, look @ your unidentifiable ac reply to attempt to "defend yourself" & failing) is a SWEDISH MASSAGE...

    APK

    P.S.=> You posting UNIDENTIFIABLY anonymously isn't fooling anyone but yourself either... apk

  58. The cause is ageism by Applehu+Akbar · · Score: 1

    when you hire only the inexperienced, you get the same newbie mistakes over and over again. And with each new Web-years generation of greenhorns, their solution to every problem is moar scripting. That's why Slashdot now has virtually the only online commenting system that still works on mobile devices.

    1. Re:The cause is ageism by Anonymous Coward · · Score: 0

      Reddit commenting works on my phone.

  59. Classroom vs. dorm; few seconds at once by tepples · · Score: 1

    Putting an access filter into a school is the last thing you'd witness around here. Especially when it comes to universities.

    Non-profit universities don't have unlimited bandwidth. Nor do they want to contribute to Internet access patterns that are more likely than not to disrupt instruction in the classroom. Toward this, many universities tend to block access to certain Internet resources from classrooms while allowing it from dormitories.

    After all, playing the video locally requires downloading the data anyway

    Both U.S. copyright law and the YouTube terms of use distinguish an ephemeral copy of a few seconds of a work at a time from a permanent copy of its entirety. And even in the case where the caching mechanism ends up keeping an ephemeral copy of (say) the entirety of a short film in order to reduce the latency of seeking, U.S. copyright law (17 USC 512(b)(2)(B)) distinguishes a copy under control of a user agent that respects Cache-Control from a copy under control of a program that does not.

    1. Re:Classroom vs. dorm; few seconds at once by K.+S.+Kyosuke · · Score: 1

      Non-profit universities don't have unlimited bandwidth.

      That's because no universities have unlimited bandwidth, which in turn is because nobody has unlimited bandwidth.

      Both U.S. copyright law and the YouTube terms of use distinguish an ephemeral copy of a few seconds of a work at a time from a permanent copy of its entirety.

      Yes, they may very well do that, which is why I was mentioning local jurisdiction. Despite the US-majority on /., the US is still only about four percent of the global population and I'm trying not to make any assumptions about who lives where.

      --
      Ezekiel 23:20
  60. NIH syndrome by hattable · · Score: 1

    Most devs are afflicated. It can be overcome.

    --
    OMG facts!
  61. Because of broken tools by hibiki_r · · Score: 1

    There are entire categories of problems that are only possible because of tooling that we just should not use. Just like buffer overflows can only happen because your library allows them, the same thing happens with SQL injection, and even cross site scripting.

    if one of the stairs in your house has a missing step, we do not tra

  62. True. We teach problems instead of solutions by raymorris · · Score: 2

    My experience is the same, most (but not all) experienced people are people who have been doing the same stupid shit for a long time. Some people put in the effort to learn something new and improve every week. Most people don't.

    For those who DO try to constantly learn and improve, the security community has made a mistake in how we try to help them. The OWASP top 10 list was mentioned. I'm a member of OWASP. The list, which we promote, is a basically list of how bad guys can exploit vulnerabilities. We say "SQL injection". What does that mean to a developer? What is the developer supposed to do or not do with that? Perhaps it would be more useful to publish a list of SOLUTIONS, best practices, things developers should do.

    Instead of saying "SQL injection" it might be more useful to list "parameterize SQL statements". That's something developers can do.

    Instead of "cross site scripting", how about putting "hrmlencode all output strings" on list. A developer can call htmlencode(). They know how to do that. They don't know how to "don't allow cross-site scripting". The proof of that is in 90% of code that TRIES to prevent cross-site scripting; it doesn't work. Most attempts at stopping cross site scripting are easily defeated. Even when they try it doesn't work, so why should they bother to try? If we tell them "use htmlencode()" that will work, and it's easy for them to do.

    1. Re:True. We teach problems instead of solutions by angel'o'sphere · · Score: 1

      Isn't cross site scripting a bug in the browser?
      How exactly do you prevent exploiting such a bug?

      --
      Cost free eBook I read (by iBook/Kobo/Amazon/ObookO/Gutenberg etc.): "The Green Odyssey" by Philip Jose Farmer.
    2. Re:True. We teach problems instead of solutions by raymorris · · Score: 1

      Cross site scripting is normally an issue in a web application.
      A browser can also have bugs in it's same-origin restrictions, but issues in web applications are far more common. Here's a very simple cross site scripting attack. Consider the following server-side code:

      echo "hello $_GET['name']"

      If you call script.lng?name=Bob the displayed page will say "hello Bob".

      Consider of the user follows this link:
      http://site.com/script.lng?nam...body.innerhtml='

      The script would then output:

      Hello body.innerhtml='

      The JavaScript runs under site.com, so it would have access to the session cookie for site.com. Which it then sends to hacker.com. Now the hacker can be logged in as the victim.

      Your basic, essential defense looks something like this:

      echo "hello " . htmlencode($_GET['name'])

      That way instead of sending JavaScript back to the browser, the server side script will encode as < so it'll just display the character, not interpret it as a script tag.

    3. Re:True. We teach problems instead of solutions by LesFerg · · Score: 2

      I must have been exceptionally lucky to work for an employer who also understood the importance of having a solid team of testers working closely with the developers.
      For a start we had to make sure that nothing a user could type into a text entry could break the web page or the database, either on the way in or when coming back out to be displayed, be it the most basic issues like apostrophes in user names or HTML tags and such.
      Then the testers had to learn all sorts of clever tricks to get around our best efforts to stop them breaking our code. This included SQL injection and other web-page breaking techniques.
      If a company has mission-critical systems being developed and deployed via HTML, then they need to take responsibility for testing and penetration-testing the solutions, not just smacking out the fastest cheapest solution.
      If you get the chance to work alongside good testers, make them your friends and make sure you challenge each other, taking into consideration both the crazy things your regular users can do and the malicious things others may attempt.

      --
      If I had a DeLorean... I would probably only drive it from time to time.
    4. Re: True. We teach problems instead of solutions by Anonymous Coward · · Score: 0

      If you don't parameterize the sql you run, you're an idiot. I'm not a security expert but sql injection is so obvious and has been around for so long, that companies that allow it, deserve what they get. Very easy to test for or review for.
      The solutions idea is a good one though.

  63. Moron. by Anonymous Coward · · Score: 0

    Of course there are good reasons why these mistakes should be possible. Seriously, do you even know what you are talking about?

    We need systems that can do things. And that can interoperate. That's where *all* the power is, and where *all* the end-user needs are.

    For example, we need to be able to search a database for data that matches criteria selected by the user. DUH! It is *impossible* to provide a set of tools with which a developer can build a system that can do that, and eliminate any possible risk of sql injection. Injection is what you are doing.

    Don't misunderstand me here: The developers absolutely CAN block SQL injection. If they build it right, there is no risk. But the moment you give them tools that don't let them build it wrong you give them worthless tools that they cannot use to meet novel business needs.

    That's my point. You can't fix it at the toolset level without breaking the toolset. It is impossible, because that which makes the toolset versatile enough to be useful is precisely that which makes it essentially vulnerable.

    Anyone with actual experience, and no-bullshit know-how, in the domain of software security, can tell you this.

  64. Really? by stonecypher · · Score: 2

    "Why do drivers keep making the same mistakes? It looks like eight of the top ten causes of death on the highway are the same as they were in 2013."

    Um because this shit is difficult, and if you don't know anything about it, it's easy to ask vapid generalized questions that seem meaningful.

    --
    StoneCypher is Full of BS
  65. For this reason by Anonymous Coward · · Score: 0

    For the same reason that you get your grammer and punctuation incorrect. Education. Or as a director of the U.S. Postal service once told wrote on the whiteboard, "Edutation".

  66. Penalty for bounces by tepples · · Score: 1

    Email addresses either work or not (that's what the verification mail is for). Why software bothers to "parse" these at all I never quite understood

    It's to reduce the fraction of verification emails that bounce. Some email smarthosts penalize senders for excessive bounces.

    it is a piece of text that when fed to an SMTP program may or may not result in a mail to whoever is filling in your form.

    It's also to ensure that the user didn't inject command-line options or other security-compromising garbage into the address that the form's action code is about to feed to the MSA.

    It's about as stupid as asking to "retype" your email address

    You'd be surprised at how many non-technical users fat-finger their email addresses, causing the chosen username to be unavailable because the verification mail was never received.

    1. Re:Penalty for bounces by swilver · · Score: 1

      It's to reduce the fraction of verification emails that bounce. Some email smarthosts penalize senders for excessive bounces.

      I doubt it will help much at all. Any significant percentage of bounces is probably coming from bots, and I'm sure they're experts at creating valid email addresses.

      It's also to ensure that the user didn't inject command-line options or other security-compromising garbage into the address that the form's action code is about to feed to the MSA.

      I hope you're trying to be funny. That's about as stupid as saying that we add verification to the "surname" field to make sure you're not entering an SQL statement. Obviously whatever is entered is escaped and quoted. It almost seems like you are suggesting this field is copy pasted on a shell command without quotes and escaping... you have bigger problems then.

      You'd be surprised at how many non-technical users fat-finger their email addresses, causing the chosen username to be unavailable because the verification mail was never received.

      I have no doubt this happens, but if THAT'S your reason, then all fields should have this redundancy.

  67. The web is a hack by Anonymous Coward · · Score: 0

    The web is a hack, and so it takes a serious effort to write code securely. It's much much more difficult than writing code in that famously insecure language, C. I used to write web apps, they were awesome. But that was last century for the most part, because after the bubble popped web dev was devalued and outsourced. So devs like me went back to C++ and C, doing things like embedded Linux, because it seemed like everyone wanted to hire fools to do Java (nothing wrong with Java, but they hired fools to code it all the time!). So not the same devs, and the good ones have moved on, leaving all the millenials to reinvent all the mistakes, because, well, the Web is a giant hack. (XSS is the best example of this, a security flaw by design that the designers didn't even realize they were creating, and now it's just there, to be dealt with constantly. Woo Hoo. The web is a hack.)

  68. Computer Fraud and Abuse Act by tepples · · Score: 1

    Even if a defense to copyright infringement is successful, downloading a permanent copy of the video from YouTube's server without permission from YouTube is still a violation of YouTube's terms of use and therefore of the Computer Fraud and Abuse Act and foreign counterparts.

    1. Re:Computer Fraud and Abuse Act by angel'o'sphere · · Score: 1

      If those terms of use are enforceable ...

      --
      Cost free eBook I read (by iBook/Kobo/Amazon/ObookO/Gutenberg etc.): "The Green Odyssey" by Philip Jose Farmer.
  69. Good book on coding secure websites? by Anonymous Coward · · Score: 0

    What's a good book on coding secure websites?

  70. The reason is simple by fireman+sam · · Score: 1

    The issue is "time to market". Management don't want a solution to a problem that takes weeks to get to market, in the agile world of software development, developers are given a day or two do determine what the problem really is (based off bad requirements), design a solution that meets the requirements, implement the solution, get it through testing, and then move onto the next feature.

    Code review is left up to another developer (who is also dealing with the above) to review the diff, and approve or decline the update - usually if it builds, the reviewer will approve for they don't have time to sit down and properly determine what the problem is, and go through the solution in a sufficient level to discover all the issues this introduces.

    Perhaps if developers were given the time to develop the solutions in a manner that is secure, and if developers "estimated" the work in a manner that would give them the time to develop secure solutions the software would be better, albeit late to market and over budget.

    And yes, juniors who are fresh out of uni are thrown into established projects and are expected to be able to do the first paragraph above with little guidance (for all the other developers are over worked with the above two paragraphs)

    --
    it is only after a long journey that you know the strength of the horse.
  71. Darn Slashdot (vulnerable to XSS) by raymorris · · Score: 1

    Slashdot's failure to have correct defense against XSS mangled my post. The point is, if the script echoes the input, and the input contains JavaScript, it'll each the JavaScript - which will then run in the context of the victim site. That allows attackers to steal session cookies or whatever.

    The general solution is to html encode the output, so if someone enters a character such as the less than sign (which starts a new tag), the script outputs & gt ; which causes the browser to DISPLAY the specified character, rather than treating it as the beginning of a script.

    1. Re:Darn Slashdot (vulnerable to XSS) by angel'o'sphere · · Score: 1

      Well,

      but this is a browser bug, or isn't it?

      I mean, the script code should not be able to access the other server. Or do I miss something?

      --
      Cost free eBook I read (by iBook/Kobo/Amazon/ObookO/Gutenberg etc.): "The Green Odyssey" by Philip Jose Farmer.
  72. #1 problem: Lack of education by dwheeler · · Score: 1

    The #1 problem is lack of education. A large number of software developers have had no formal training in software development. Almost all who HAVE had formal education don't receive any education or training in how to develop SECURE software.

    I teach a graduate course at George Mason University (GMU) on how to design and implement secure software. So there are people who are learning, but there are many more to go.

    For the most part, countering the OWASP top 10 doesn't cost more, so cost has nothing to do with it. At the high end of security requirements it definitely costs more, but stuff like parameterized statements (countering SQL injection) and using web frameworks that automatically counter XSS injection don't cost any more.

    --
    - David A. Wheeler (see my Secure Programming HOWTO)
  73. Re:It was a pleasure shooting you down 5:1... apk by Anonymous Coward · · Score: 0

    Get over yourself dickhead. And stop posting all this shit about your ego here.

  74. Web Development is a horrible hodgepodge by Anonymous Coward · · Score: 0

    It's inconsistent technologies, with inconsistent APIs thrown together like Jackson Pollack took a shit on a wall with chicken wire and bubblegum using half-assed industry standards waiting around for W3C standards to commit for 10-20 year windows.

  75. Part of the problem is our process by FrozenGeek · · Score: 2

    My experience is along the following: Noobs develop a new website. Senior devs have little time to review what the noobs have done. Website goes live. Users are happy. A year or two down the line, the former noobs move to other employers so as to obtain a real raise. Some time thereafter, serious security flaw is noted on original website. Flaw is fixed by senior devs, who may, or may not, adequately explain the problem to the noobs currently maintaining the website. The original devs involved never learn of the flaw or the fix. Simply put, we are not adequately taught security in school and we are unlikely to learn it at work. Compounding the issue, there is always a rush to production and very often security is the low priority task that gets tossed in order to meet the (artificial) deadline.

    --
    linquendum tondere
    1. Re:Part of the problem is our process by Anonymous Coward · · Score: 1

      Sounds about right to me. I'm one of those Sr. devs and reviewing code is part of my job, and I think I do a good job. But, deadlines are far too aggressive and on many occasions I later end up smacking my forehead after I realized I missed something obviously bad. I just don't have the time for a proper review, so I do the best I an within the constraints and continue to hope there's nothing problematic that snuck through when I ran out of time or was tired that day or whatever...

  76. Mindless Drones by Anonymous Coward · · Score: 0

    The reality is simple, but painful. The IT field is full of mindless copy&pasters and people who over rely on frameworks which they do no really understand.

  77. It is not a browser bug. Scripts can add elements by raymorris · · Score: 1

    That is not a browser bug. Scripts can add elements, including images and other scripts, to a page, and those elements may be sourced from another origin. See jsonp, for example.

    The bug is that the server-side script allows the attacker to add elements to the page by echoing the request variable directly, rather than HTML encoding it.

  78. Why? Management won't pay for it by Anonymous Coward · · Score: 0

    Neither the time to do testing or the money to buy tools exists in management's mind.
    Same as always.

  79. Re:It was a pleasure shooting you down 5:1... apk by Anonymous Coward · · Score: 0

    See here, APK: https://en.wikipedia.org/wiki/Grandiosity

  80. Security? Basic utility is lacking by rickb928 · · Score: 1

    My devs persist in designing pages I have to scroll down to show the 'Submit' button. Pages that, in a browser with an address and bookmarks bar, force that key element below the bottom of the maximized window. Why? The white space is available, the other elements could be spaced differently, this is unnecessary.

    When 8514/A and XGA came out, web developers jumped at the extra screen space. Most users still stuck at SVGA.

    If you want to see usability, corporate devs, look at Amazon. There is a Submit or Order button handy always. Yes, you scroll to show 50 results, but you don't have to look hard for the action button. On my app, you always, always have to scroll.

    And the pleas of the users fall on deaf ears. Moar Features. Moar whitespace. Moar corporate theming.

    Feh. Web app design is a wasteland. Injection hardening is how they deny that people have apostrophes in their names, or speak any language other than English in your globalized app world. Injection hardening and input sanitizing was the big push in 2007. What happened since then? Laziness.

    --
    deleting the extra space after periods so i can stay relevant, yeah.
  81. 2 Reasons by bravecanadian · · Score: 1

    1) New developers coming up employ the latest whiz-bang buzzword frameworks etc. and blindly repeat the mistakes of the past.

    2) Security takes a back seat to "getting it working" as always in IT.

  82. Re:It was a pleasure shooting you down 5:1... apk by Anonymous Coward · · Score: 0

    Shouldn't take shots at apk Tepples. It got you knocked out.

  83. Re:It was a pleasure shooting you down 5:1... apk by Anonymous Coward · · Score: 0

    Speak for yourself Tepples. You don't run slashdot and I don't think apk's taking your orders. He laughs at you instead.

  84. Just use Wt by Anonymous Coward · · Score: 0

    Use a 'proper' web development environment... then these things would be less of an issue:

    https://www.webtoolkit.eu/wt

  85. Just another reason to ... by Anonymous Coward · · Score: 0

    ... use MongoDB. It's web scale.

    https://www.youtube.com/watch?v=b2F-DItXtZs

  86. Why do Web Developers Keep Making the Same Mistake by Stubbyfingers · · Score: 1

    Because they're the same people.

  87. Because newer is better by ilsaloving · · Score: 1

    "Why Do Web Developers Keep Making The Same Mistakes?" is the wrong question entirely.

    The ACTUAL question is, why do new developers insist on completely ignoring the lessons of the past? This is what happens when you mindlessly encourage a culture of "young people are better than old people" and "new stuff is better than old stuff".

    It results in exactly what you see today: the same idiotic mistakes being made over and over again. Reinventing the wheel over and over again. None of the issues happening today are new. They've been solved for decades. But because the "solved" technology is "old", it's ignored.

    It's depressing how software development is the ONLY professional industry where learning lessons from the past are actually frowned upon, and people who rediscover the same thing all over again are considered visionary.

  88. Re:Why do Web Developers Keep Making the Same Mist by Anonymous Coward · · Score: 0

    I want to say that often this is true.

    Some developers actually learn and become better at their job, including the security aspects.

    However I've met plenty of devs who simply never got better. At anything. There are far too many deadweight devs who were never qualified, never had the skills, never even had the inherent attitudes and reflexes required to become any good. They don't read, they rarely watch videos, they hardly ever go on courses, not unless they are required and paid for by their employer. These people are a curse to any organization that hires them.

  89. Pit of Failure vs Pit of Success by CapOblivious2010 · · Score: 1

    The problem is that the tools we use make it easier to do the wrong thing than to do the right thing. Take SQL injection, for example:

    When I started using SQL (late 80s / early 90s), parameterized SQL was pretty much the only way to go. I did actually figure out how to execute an arbitrary string of SQL and capture the resulting columns, whose names and data types couldn't be known until runtime. But it was a royal pain, and I doubt most people would have been that persistent - if at all possible, they'd have stuck with the easy way, which involved using SQL parameters.

    Fast-forward through a few decades of "advancement" in tools, and now it's trivial to execute a string of arbitrary SQL (just begging for SQL injection), and SQL parameters are this strange thing that people may have heard of, but they're hard to use and they seem like more trouble than they're worth. So far too many people just do it the easy (i.e. INSECURE) way!

  90. Re:It is not a browser bug. Scripts can add elemen by angel'o'sphere · · Score: 1

    and those elements may be sourced from another origin.
    Hm, I always assumed that would be against the "same source policy" browsers are supposed to enforce.

    --
    Cost free eBook I read (by iBook/Kobo/Amazon/ObookO/Gutenberg etc.): "The Green Odyssey" by Philip Jose Farmer.
  91. Done is better than perfect by Anonymous Coward · · Score: 0

    I don't know that I agree with the argument here... IMHO OWASP largely exists to drive sales to security products and consultancies. It's also 2017... plenty of high-profile libraries and frameworks actively militate *against* vulns OWASP lists.

    But that aside, the insecure code I've written as an Enterprise Shitware Developer usually follows this pattern:

    "We need these features"
    "That'll take 6 to 8 months to do given current resources."
    "We need them in 4 weeks."
    "What happens if they're not done then?"
    "The project gets cut. Oh, and it needs to do Z."
    "Are you sure it needs to do Z? That's not only deprecated and bad practice, it's tremendously vulnerable."
    "Yes. And that part needs to be done next week. Also, we have 3 hours of meetings booked daily for the next month."

    Under circumstances like that, green developers just write terrible code, though honestly they probably don't know any better. Senior developers take massive shortcuts, i.e., write terrible code, and lie to themselves about how they'll fix it later. In a lot of environments, you can't push back against a timeline or constraints without it being either a career-limiting move.

    Additionally... in a lot of companies, the software might be vulnerable but the entire business process is questionable. For every SQL injection there's a dozen unencrypted files in emails full of PII and credit card information.

  92. Nope by raymorris · · Score: 1

    It does not violate the same-origin policy.

    The same-origin policy is mostly about frames/iframes and cookies. It says that scripts from one origin my not read the contents from a different origin except:
    Scripts from another origin (predates the policy)
    Websockets

    A script from a.com may not read a cookie or a reponse body from b.com

    Scripts MAY create tags which will then load resources from another origin. So a script from a.com may create an img element that loads an image from b.com. As a special case, it may NOT load an image from b.com into an HTML canvas object, because that would allow it to read the contents.

    1. Re:Nope by angel'o'sphere · · Score: 1

      Good to know.

      So far I had no need to know this ... but that might change.

      Scripts MAY create tags which will then load resources from another origin.
      Bah, does such a spec make sense or is that for historical reasons the case?

      --
      Cost free eBook I read (by iBook/Kobo/Amazon/ObookO/Gutenberg etc.): "The Green Odyssey" by Philip Jose Farmer.
  93. Tools by NewYork · · Score: 1

    Use Code Analyzers

  94. Save money and hire the cheapest developers by original+bit+basher · · Score: 1

    For decades I have been aware that companies keep hiring new developers fresh out of college that work hard, are productive in the lines of code they write, maybe meet deadlines, and keep making mistakes experienced workers gave up on decades ago. This year's budget doesn't care about expenses several years from now.

  95. Partly each by raymorris · · Score: 1

    It's partly because that's good design and partly because of historical reasons. Specifically, the script tag existed prior to the same-origin policy, and it was common to load scripts for other sources. This probably wouldn't be allowed if same-origin were designed in from the beginning. It allows jsonp, which contravenes the spirit of same-origin.