Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. The Lounge
  3. The SQL Injection Attack is alive and well.

The SQL Injection Attack is alive and well.

Scheduled Pinned Locked Moved The Lounge
databasequestionannouncement
38 Posts 15 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • H Henry Minute

    Yup. In the sense that I was head of the dept that employed them and conducted the interviews. LAN only stuff back then though. From the comments it would seem that things have changed more than a little since then.

    Henry Minute Do not read medical books! You could die of a misprint. - Mark Twain Girl: (staring) "Why do you need an icy cucumber?" “I want to report a fraud. The government is lying to us all.” I wouldn't let CG touch my Abacus! When you're wrestling a gorilla, you don't stop when you're tired, you stop when the gorilla is.

    A Offline
    A Offline
    Andy Brummer
    wrote on last edited by
    #25

    That makes more sense. Typically the SA's I've worked with are deployment monkeys that just keep the OS running.

    Curvature of the Mind now with 3D

    1 Reply Last reply
    0
    • C Chris Meech

      AspDotNetDev wrote:

      but the main step is to not use code that allows for SQL injection.

      A proper use of security would help as well. It's one thing to allow a user to type or inject "delete ...", it's quite another to actually authorise a user to do that. :)

      Chris Meech I am Canadian. [heard in a local bar] In theory there is no difference between theory and practice. In practice there is. [Yogi Berra] posting about Crystal Reports here is like discussing gay marriage on a catholic church’s website.[Nishant Sivakumar]

      A Offline
      A Offline
      AspDotNetDev
      wrote on last edited by
      #26

      Indeed, it would help, but still doesn't prevent all forms of mischief. If you have an SP that deletes records of a particular type, then that may allow a user to cause some damage. The main form of defense is the code (parameterized queries).

      [WikiLeaks Cablegate Cables]

      1 Reply Last reply
      0
      • H Henry Minute

        According to this report[^]. It is difficult to believe that Systems Administrators are unaware of this exploit and yet numerous sites are still vulnerable.

        Henry Minute Do not read medical books! You could die of a misprint. - Mark Twain Girl: (staring) "Why do you need an icy cucumber?" “I want to report a fraud. The government is lying to us all.” I wouldn't let CG touch my Abacus! When you're wrestling a gorilla, you don't stop when you're tired, you stop when the gorilla is.

        M Offline
        M Offline
        Mycroft Holmes
        wrote on last edited by
        #27

        from the article:

        Generally, the sites being hit are small businesses, community groups, sports teams and many other mid-tier organisations.

        A lot of these would be single devs, possibly juniors getting experience. If I saw this from a senior dev, whoosh out the door. SQL Injection is sooo easy to stop it is ridiculous that it is still a threat.

        Never underestimate the power of human stupidity RAH

        H C 2 Replies Last reply
        0
        • OriginalGriffO OriginalGriff

          Henry Minute wrote:

          It is difficult to believe that Systems Administrators are unaware of this exploit

          You don't spend enough time in Q&A: nobody seems to be taught about it, even in passing... :sigh:

          Real men don't use instructions. They are only the manufacturers opinion on how to put the thing together. Manfred R. Bihy: "Looks as if OP is learning resistant."

          G Offline
          G Offline
          gavindon
          wrote on last edited by
          #28

          I will say, the one SQL class I took to get my recent associates degree, never mentioned anything remotely close to this. It was all about how to build a table, keys etc.. without ever ONCE mentioning anything about "maybe this is not good practice" or the fact that if something is poorly constructed, it is simple to "hack" with injections. Neither did anything in ANY of my programming classes. I've learned more about security on CP than was ever even mentioned in my school.

          Programming is a race between programmers trying to build bigger and better idiot proof programs, and the universe trying to build bigger and better idiots, so far... the universe is winning.

          OriginalGriffO 1 Reply Last reply
          0
          • M Mycroft Holmes

            from the article:

            Generally, the sites being hit are small businesses, community groups, sports teams and many other mid-tier organisations.

            A lot of these would be single devs, possibly juniors getting experience. If I saw this from a senior dev, whoosh out the door. SQL Injection is sooo easy to stop it is ridiculous that it is still a threat.

            Never underestimate the power of human stupidity RAH

            H Offline
            H Offline
            Henry Minute
            wrote on last edited by
            #29

            Mycroft Holmes wrote:

            A lot of these would be single devs, possibly juniors getting experience.

            Good point.

            Mycroft Holmes wrote:

            SQL Injection is sooo easy to stop it is ridiculous that it is still a threat.

            Quite agree.

            Henry Minute Do not read medical books! You could die of a misprint. - Mark Twain Girl: (staring) "Why do you need an icy cucumber?" “I want to report a fraud. The government is lying to us all.” I wouldn't let CG touch my Abacus! When you're wrestling a gorilla, you don't stop when you're tired, you stop when the gorilla is.

            1 Reply Last reply
            0
            • A AspDotNetDev

              OriginalGriff wrote:

              It was in with your Certificate

              Speaking of, did you get yours yet?

              [WikiLeaks Cablegate Cables]

              OriginalGriffO Offline
              OriginalGriffO Offline
              OriginalGriff
              wrote on last edited by
              #30

              No, but I assume that the Hamsters are swimming across the Atlantic with it gripped in their teeth - that's got to take a while...

              Real men don't use instructions. They are only the manufacturers opinion on how to put the thing together. Manfred R. Bihy: "Looks as if OP is learning resistant."

              "I have no idea what I did, but I'm taking full credit for it." - ThisOldTony
              "Common sense is so rare these days, it should be classified as a super power" - Random T-shirt

              1 Reply Last reply
              0
              • G gavindon

                I will say, the one SQL class I took to get my recent associates degree, never mentioned anything remotely close to this. It was all about how to build a table, keys etc.. without ever ONCE mentioning anything about "maybe this is not good practice" or the fact that if something is poorly constructed, it is simple to "hack" with injections. Neither did anything in ANY of my programming classes. I've learned more about security on CP than was ever even mentioned in my school.

                Programming is a race between programmers trying to build bigger and better idiot proof programs, and the universe trying to build bigger and better idiots, so far... the universe is winning.

                OriginalGriffO Offline
                OriginalGriffO Offline
                OriginalGriff
                wrote on last edited by
                #31

                Damn. I hate it when I am right! :-D

                Real men don't use instructions. They are only the manufacturers opinion on how to put the thing together. Manfred R. Bihy: "Looks as if OP is learning resistant."

                "I have no idea what I did, but I'm taking full credit for it." - ThisOldTony
                "Common sense is so rare these days, it should be classified as a super power" - Random T-shirt

                1 Reply Last reply
                0
                • A AspDotNetDev

                  Isn't that more the responsibility of a programmer than a systems administrator? I suppose a properly secured database helps (i.e., you can disallow arbitrary SQL code and only allow stored procedures to execute), but the main step is to not use code that allows for SQL injection.

                  [WikiLeaks Cablegate Cables]

                  T Offline
                  T Offline
                  Timothy Carroll
                  wrote on last edited by
                  #32

                  I agree. Anecdotally, most SysAdmins I know are well aware of this attack vector, but many developers I know still do string sanitation instead of parameterization. This is squarely in developer and QA's corners. DBAs are only involved if they are part of the code auditing process (MANY times, they are not). SysAdmins would rarely ever be involved except when they set up IPS rules because their developer colleagues can't write secure code.

                  1 Reply Last reply
                  0
                  • H Henry Minute

                    According to this report[^]. It is difficult to believe that Systems Administrators are unaware of this exploit and yet numerous sites are still vulnerable.

                    Henry Minute Do not read medical books! You could die of a misprint. - Mark Twain Girl: (staring) "Why do you need an icy cucumber?" “I want to report a fraud. The government is lying to us all.” I wouldn't let CG touch my Abacus! When you're wrestling a gorilla, you don't stop when you're tired, you stop when the gorilla is.

                    M Offline
                    M Offline
                    MadMyche
                    wrote on last edited by
                    #33

                    I got to do so seek & destroy on Friday to look for this 'new' exploit, and while going through files and DBs I read more and more on this attack. First of all, there was nothing new about this attack. Second, this isn't a new attack. Forensic packet analysis has shown this has been going on since October. Third, Websense reporting that it affects Sql Server 2000, 2003, & 2005. A- I must have missed MS releasing Sql Server 2003 B- IMHO this method could affect any DB, as the root of the problem was the application C- IMHO the reason they hadn't seen 2008 affected is due to the fact of better coding standards now in place C1- Less ASP sites on the web C2- More validation in the applications to detect & eliminate rogue data C3- The various frameworks applications used to talk to DB (LINQ, Entity Framework) I will not relieve the DBA of responsibility, as I also believe that Stored Procedures should be the norm for I/O operations.

                    1 Reply Last reply
                    0
                    • H Henry Minute

                      According to this report[^]. It is difficult to believe that Systems Administrators are unaware of this exploit and yet numerous sites are still vulnerable.

                      Henry Minute Do not read medical books! You could die of a misprint. - Mark Twain Girl: (staring) "Why do you need an icy cucumber?" “I want to report a fraud. The government is lying to us all.” I wouldn't let CG touch my Abacus! When you're wrestling a gorilla, you don't stop when you're tired, you stop when the gorilla is.

                      P Offline
                      P Offline
                      Peter Mulholland
                      wrote on last edited by
                      #34

                      Was that a genuine report or an April fools?

                      Pete

                      H 1 Reply Last reply
                      0
                      • P Peter Mulholland

                        Was that a genuine report or an April fools?

                        Pete

                        H Offline
                        H Offline
                        Henry Minute
                        wrote on last edited by
                        #35

                        I took it as genuine.

                        Henry Minute Do not read medical books! You could die of a misprint. - Mark Twain Girl: (staring) "Why do you need an icy cucumber?" “I want to report a fraud. The government is lying to us all.” I wouldn't let CG touch my Abacus! When you're wrestling a gorilla, you don't stop when you're tired, you stop when the gorilla is.

                        1 Reply Last reply
                        0
                        • W wizardzz

                          IMO it's the job of the DBA to allow only SP's and the developer to sanitize any input parameters. So, it's everyone's fault. Given the description of the hacked sites, I'm guessing this is the exploitation of a an open source or cheap product they all used in common, assuming that SQL injection would have been accounted for. It could even be an inside job from the developers of the common software.

                          "Life should not be a journey to the grave with the intention of arriving safely in a pretty and well preserved body, but rather to skid in broadside in a cloud of smoke, thoroughly used up, totally worn out, and loudly proclaiming "Wow! What a Ride!" — Hunter S. Thompson

                          S Offline
                          S Offline
                          Spectre_001
                          wrote on last edited by
                          #36

                          Current best practice is to use parameterized queries. This is what most ORMs do under the hood. If you only allow SPs, you have to hand constructed SQL to your ORM, which negates the reason for using an ORM in the first place. If you are not using an ORM, then I would agree that the safest thing to do is to only allow SPs at the DB level, but it is not the only solution. If you have decent developers, parameterized queries is still the way to go. Limiting DB access to SPs is not necessarily best practice, but does help protect you from developers that don't know what they are doing (best thing is probably not to hire those guys in the first place).

                          Kevin Rucker, Application Programmer QSS Group, Inc. United States Coast Guard OSC Kevin.D.Rucker@uscg.mil "Programming is an art form that fights back." -- Chad Hower

                          1 Reply Last reply
                          0
                          • M Mycroft Holmes

                            from the article:

                            Generally, the sites being hit are small businesses, community groups, sports teams and many other mid-tier organisations.

                            A lot of these would be single devs, possibly juniors getting experience. If I saw this from a senior dev, whoosh out the door. SQL Injection is sooo easy to stop it is ridiculous that it is still a threat.

                            Never underestimate the power of human stupidity RAH

                            C Offline
                            C Offline
                            CurtainDog
                            wrote on last edited by
                            #37

                            This ignores the fact that the exploit most likely comes from third-party code, so it's not at all easy to stop. The irony is that if you roll your own web framework your site might be much more secure even if your code much less secure by the virtue of the fact that no one will bother to try to hack you. I still wouldn't recommend it though.

                            M 1 Reply Last reply
                            0
                            • C CurtainDog

                              This ignores the fact that the exploit most likely comes from third-party code, so it's not at all easy to stop. The irony is that if you roll your own web framework your site might be much more secure even if your code much less secure by the virtue of the fact that no one will bother to try to hack you. I still wouldn't recommend it though.

                              M Offline
                              M Offline
                              Mycroft Holmes
                              wrote on last edited by
                              #38

                              CurtainDog wrote:

                              This ignores the fact that the exploit most likely comes from third-party code

                              This is still a decision someone makes and that person needs to be responsible for that decision. Mind you I know nothing about said frameworks, I am a roll yer own type.

                              Never underestimate the power of human stupidity RAH

                              1 Reply Last reply
                              0
                              Reply
                              • Reply as topic
                              Log in to reply
                              • Oldest to Newest
                              • Newest to Oldest
                              • Most Votes


                              • Login

                              • Don't have an account? Register

                              • Login or register to search.
                              • First post
                                Last post
                              0
                              • Categories
                              • Recent
                              • Tags
                              • Popular
                              • World
                              • Users
                              • Groups