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
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
  1. Home
  2. Web Development
  3. ASP page crashed if form field has ' and REPLACE word

ASP page crashed if form field has ' and REPLACE word

Scheduled Pinned Locked Moved Web Development
sysadminhelp
10 Posts 2 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.
  • S Offline
    S Offline
    SABhatti
    wrote on last edited by
    #1

    I have an asp page wich submit two fields, title and contents. Now if user type single code ('), or semi-colon (;) and replace (the word REPLACE) then on submitting the form, page crashes. Any help please.. Note: it is working fine on development server (win 2003) but crashing on production server (win 2000) -----

    G 1 Reply Last reply
    0
    • S SABhatti

      I have an asp page wich submit two fields, title and contents. Now if user type single code ('), or semi-colon (;) and replace (the word REPLACE) then on submitting the form, page crashes. Any help please.. Note: it is working fine on development server (win 2003) but crashing on production server (win 2000) -----

      G Offline
      G Offline
      Guffa
      wrote on last edited by
      #2

      Could you specify "crashes"? Does the page look different? Do you get an error message? Does the web server crash?

      --- "Anything that is in the world when you're born is normal and ordinary and is just a natural part of the way the world works. Anything that's invented between when you're fifteen and thirty-five is new and exciting and revolutionary and you can probably get a career in it. Anything invented after you're thirty-five is against the natural order of things." -- Douglas Adams

      S 1 Reply Last reply
      0
      • G Guffa

        Could you specify "crashes"? Does the page look different? Do you get an error message? Does the web server crash?

        --- "Anything that is in the world when you're born is normal and ordinary and is just a natural part of the way the world works. Anything that's invented between when you're fifteen and thirty-five is new and exciting and revolutionary and you can probably get a career in it. Anything invented after you're thirty-five is against the natural order of things." -- Douglas Adams

        S Offline
        S Offline
        SABhatti
        wrote on last edited by
        #3

        well, here is the sample text in text area .... 1) you'll send your blood glucose level up higher than you expected; 2) you'll fill up but without the nutrients that come with vegetables and grains; and 3) you'll gain weight. So, don't pass up a slice of birthday cake. Instead, eat a little less bread or potato, and replace it with the cake. Taking a brisk walk to burn some calories is also always helpful. ... when I post back, it displays page cannot be found (generic error) this is an classic ASP. It does not even go to Request.Form section.. If I remove the single quotes and semi-colons then it works.. OR if remove REPLACE word then also it works..

        -----

        G 1 Reply Last reply
        0
        • S SABhatti

          well, here is the sample text in text area .... 1) you'll send your blood glucose level up higher than you expected; 2) you'll fill up but without the nutrients that come with vegetables and grains; and 3) you'll gain weight. So, don't pass up a slice of birthday cake. Instead, eat a little less bread or potato, and replace it with the cake. Taking a brisk walk to burn some calories is also always helpful. ... when I post back, it displays page cannot be found (generic error) this is an classic ASP. It does not even go to Request.Form section.. If I remove the single quotes and semi-colons then it works.. OR if remove REPLACE word then also it works..

          -----

          G Offline
          G Offline
          Guffa
          wrote on last edited by
          #4

          SABhatti wrote:

          when I post back, it displays page cannot be found (generic error) this is an classic ASP.

          Do you really get an http 404 error? That seems very unlikey, as the existance of the page doesn't change with what you send to it. Could you quote some of the actual error message? Have you disabled "friendly http errors" in the browser so that you see the actual error message?

          --- "Anything that is in the world when you're born is normal and ordinary and is just a natural part of the way the world works. Anything that's invented between when you're fifteen and thirty-five is new and exciting and revolutionary and you can probably get a career in it. Anything invented after you're thirty-five is against the natural order of things." -- Douglas Adams

          S 1 Reply Last reply
          0
          • G Guffa

            SABhatti wrote:

            when I post back, it displays page cannot be found (generic error) this is an classic ASP.

            Do you really get an http 404 error? That seems very unlikey, as the existance of the page doesn't change with what you send to it. Could you quote some of the actual error message? Have you disabled "friendly http errors" in the browser so that you see the actual error message?

            --- "Anything that is in the world when you're born is normal and ordinary and is just a natural part of the way the world works. Anything that's invented between when you're fifteen and thirty-five is new and exciting and revolutionary and you can probably get a career in it. Anything invented after you're thirty-five is against the natural order of things." -- Douglas Adams

            S Offline
            S Offline
            SABhatti
            wrote on last edited by
            #5

            sorry it says PAGE CANNOT BE DISPLAYED.. click on refresh butoon, check you lan settings etc.. Well one thing that I did is to remote into the web server and browse it locally. Locally it works fine. But when I am trying to browse it from outside, it crashes. -- modified at 15:09 Friday 19th October, 2007

            -----

            G 1 Reply Last reply
            0
            • S SABhatti

              sorry it says PAGE CANNOT BE DISPLAYED.. click on refresh butoon, check you lan settings etc.. Well one thing that I did is to remote into the web server and browse it locally. Locally it works fine. But when I am trying to browse it from outside, it crashes. -- modified at 15:09 Friday 19th October, 2007

              -----

              G Offline
              G Offline
              Guffa
              wrote on last edited by
              #6

              I guess it's no on the question about "friendly http errors", then. Fix that, so that you see the actual error message. Without a proper error message, it's just guesswork.

              --- "Anything that is in the world when you're born is normal and ordinary and is just a natural part of the way the world works. Anything that's invented between when you're fifteen and thirty-five is new and exciting and revolutionary and you can probably get a career in it. Anything invented after you're thirty-five is against the natural order of things." -- Douglas Adams

              S 1 Reply Last reply
              0
              • G Guffa

                I guess it's no on the question about "friendly http errors", then. Fix that, so that you see the actual error message. Without a proper error message, it's just guesswork.

                --- "Anything that is in the world when you're born is normal and ordinary and is just a natural part of the way the world works. Anything that's invented between when you're fifteen and thirty-five is new and exciting and revolutionary and you can probably get a career in it. Anything invented after you're thirty-five is against the natural order of things." -- Douglas Adams

                S Offline
                S Offline
                SABhatti
                wrote on last edited by
                #7

                I have checked the configuration on IIS, and option to send detailed script error is selected. As I mentioned before that it is working fine if I browse it from the actual web server using its IP. But it crashes if I access it from outside. I am also going to check with our firewall administrators. Thanks for your help. -- the weird thing is that it is not giving any error, and this is really an old page in classic ASP, and I don't really know how to catch this exception in classic ASP...

                -----

                G 1 Reply Last reply
                0
                • S SABhatti

                  I have checked the configuration on IIS, and option to send detailed script error is selected. As I mentioned before that it is working fine if I browse it from the actual web server using its IP. But it crashes if I access it from outside. I am also going to check with our firewall administrators. Thanks for your help. -- the weird thing is that it is not giving any error, and this is really an old page in classic ASP, and I don't really know how to catch this exception in classic ASP...

                  -----

                  G Offline
                  G Offline
                  Guffa
                  wrote on last edited by
                  #8

                  Have you disabled "friendly http errors" in the browser so that you see the actual error message?

                  --- "Anything that is in the world when you're born is normal and ordinary and is just a natural part of the way the world works. Anything that's invented between when you're fifteen and thirty-five is new and exciting and revolutionary and you can probably get a career in it. Anything invented after you're thirty-five is against the natural order of things." -- Douglas Adams

                  S 1 Reply Last reply
                  0
                  • G Guffa

                    Have you disabled "friendly http errors" in the browser so that you see the actual error message?

                    --- "Anything that is in the world when you're born is normal and ordinary and is just a natural part of the way the world works. Anything that's invented between when you're fifteen and thirty-five is new and exciting and revolutionary and you can probably get a career in it. Anything invented after you're thirty-five is against the natural order of things." -- Douglas Adams

                    S Offline
                    S Offline
                    SABhatti
                    wrote on last edited by
                    #9

                    Well, we figured that it is the firewall. When ever user types REPALCE, FIND, or any word that is also a command in firewall, along with any special character like single quote, semi-colon, or double quote. The firwall take it as command injection and block it. It looks weired. Our firewall guys do not want to disable command injection. They said that we might have to use the SSL on the server. I don't know how correct is that. But on SSL enabled server it works fine. Its definitely not how the browser displays the error. It is the firewall because the firewall does not let me catch any error.

                    -----

                    G 1 Reply Last reply
                    0
                    • S SABhatti

                      Well, we figured that it is the firewall. When ever user types REPALCE, FIND, or any word that is also a command in firewall, along with any special character like single quote, semi-colon, or double quote. The firwall take it as command injection and block it. It looks weired. Our firewall guys do not want to disable command injection. They said that we might have to use the SSL on the server. I don't know how correct is that. But on SSL enabled server it works fine. Its definitely not how the browser displays the error. It is the firewall because the firewall does not let me catch any error.

                      -----

                      G Offline
                      G Offline
                      Guffa
                      wrote on last edited by
                      #10

                      What kind of firewall is that? What is the purpose of blocking traffic like that? The firewall can't be access directly with an unauthorised request, can it? Is the protection (?) something that the "firewall guys" have come up with themselves?

                      --- "Anything that is in the world when you're born is normal and ordinary and is just a natural part of the way the world works. Anything that's invented between when you're fifteen and thirty-five is new and exciting and revolutionary and you can probably get a career in it. Anything invented after you're thirty-five is against the natural order of things." -- Douglas Adams

                      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