1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

Can XMLHTTP be blocked?

Discussion in 'C#' started by Sean@WMS, Oct 28, 2008.

  1. #1
    I've a client for whom we have an XMLHTTP routine that "pings" a manufacturer website to make sure it's responding before pulling it into a frameset -- if it's not responding, we displace a message. We're using the GET method as the URL's we're pinging use a query string.

    All day yesterday a certain manufacturer's web site was down, so the message was doing it's job. Then they finally came back online this morning and all was well.

    Now, however, this afternoon, the .send method is returning a 500.100 error: "A connection with the server could not be established", while the pages in question are resolving just fine in a browser.

    I'm wondering if there is a way that they are somehow blocking these hits. I mean, what's the difference between hitting the site with XMLHTTP and hitting it in a browser?
    SEMrush
     
    Sean@WMS, Oct 28, 2008 IP
    SEMrush
  2. SearchBliss

    SearchBliss Well-Known Member

    Messages:
    1,899
    Likes Received:
    70
    Best Answers:
    2
    Trophy Points:
    195
    Digital Goods:
    1
    #2
    The servers IP can be blocked (like any computer) from opening a page using the GET method. Do you use Server.CreateObject ("Microsoft.XMLHTTP")? If so you can try Server.CreateObject("MSXML2.ServerXMLHTTP") to see if it was a change on their end. If it doesn't work, the IP may be blocked.
     
    SearchBliss, Oct 28, 2008 IP
  3. Sean@WMS

    Sean@WMS Peon

    Messages:
    134
    Likes Received:
    6
    Best Answers:
    0
    Trophy Points:
    0
    #3
    Thanks, SearchBliss.

    Yes, using MSXML2.ServerXMLHTTP

    Good point about blocking IP, though the manufacturer completely condones the use of their site this way as our client is one of their biggest sellers.

    Unfortunately, their server is down again, so I can't test, but when they come back up, I'll test that and report back.
     
    Sean@WMS, Oct 28, 2008 IP
  4. SearchBliss

    SearchBliss Well-Known Member

    Messages:
    1,899
    Likes Received:
    70
    Best Answers:
    2
    Trophy Points:
    195
    Digital Goods:
    1
    #4
    How often is the server down? This could also be the problem.
     
    SearchBliss, Oct 29, 2008 IP
  5. kadesmith

    kadesmith Peon

    Messages:
    479
    Likes Received:
    6
    Best Answers:
    0
    Trophy Points:
    0
    #5
    It could also be a firewall issue. I've had that happen before where I was able to go out, but the request coming back was being stopped at the firewall level.
     
    kadesmith, Oct 29, 2008 IP
  6. Sean@WMS

    Sean@WMS Peon

    Messages:
    134
    Likes Received:
    6
    Best Answers:
    0
    Trophy Points:
    0
    #6
    Turns out they were indeed blocking the IP address.

    Nice little bit of irony here:

    As I mentioned earlier, we use the XMLHTTP to test a manufacturer site to make sure it's up, else display a message asking folks to give a call to order.

    Well, somehow an error snuck into our process and the query string we were hitting the manufacturer link with was getting clipped to the first name/value pair . . . . which apparently caused their site to dump a sort of "Show EVERYTHING" response, and that was crashing their site.

    We got it all ironed out this morning with them.

    Thanks for your input :)
     
    Sean@WMS, Oct 29, 2008 IP
  7. fireworking

    fireworking Peon

    Messages:
    460
    Likes Received:
    10
    Best Answers:
    0
    Trophy Points:
    0
    #7
    Ok thats good. Because errors are very very VERY VERY ANNOYING. When making my own programming scripts, I always run into errors. So, did someone hack your script or something?
     
    fireworking, Oct 29, 2008 IP
  8. SearchBliss

    SearchBliss Well-Known Member

    Messages:
    1,899
    Likes Received:
    70
    Best Answers:
    2
    Trophy Points:
    195
    Digital Goods:
    1
    #8
    No problem.
     
    SearchBliss, Oct 30, 2008 IP
  9. Sean@WMS

    Sean@WMS Peon

    Messages:
    134
    Likes Received:
    6
    Best Answers:
    0
    Trophy Points:
    0
    #9
    Yeah, me, LOL!

    I've finally pieced it all together to a minor update I did on 20 of these sites last week, and didn't anticipate the little "boy and the dike" issue I introduced on one of them.

    On this particular site the URL's for the manufacture's site all have query strings. The procedure involve a link to a category which then opens to a frameset where first a message is dispalyed that "we are not such and such manufacturer, but a preferred vendor, yadda yadda", and then that page of the frameset redirects to the manufacturer's category page.

    Well, the update to this site had the effect of puting a query string URL inside of another query string as things were being passed back and forth. That is the manufacturer's URL (with its own query string) was being passed within one of our query strings . . . . so, ultimately, that had the affect of clipping off everything but the manufacturer's first name/value pair (leaving out things like the category & subcategory IDs) . . . and THAT, as luck would have it, had the effect of querying their site to dump EVERY SINGLE PRODUCT DETAIL about EVERY SINGLE PRODUCT in a single search result. That weakness on their end exacerbated by the traffic we were directing crushed their server every few minutes (blush).

    "Boy and the dike" issues are really hard to anticipate (especially accross 20 sites, not realizing that ONE of them would end up with a different behavior), though I've still dope slapped myself. However, IMHO, the real problem here is that the manufacturer has so poorly handled their own search query handling.

    Could I claim to have been an acidental beneficent hacker -- pointing out inadvertantly a serious weakness in their application?

    Oh! And what made it even more fun was that they transferred DNS to another server while all of this was going on.

    And I just can't resist sharing this tid bit either: Just as I went to post this the first time, DP crashed too! I was like, "Sheit, dood! Are you the crasher of servers now?!" LOL!
     
    Sean@WMS, Oct 30, 2008 IP