Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 4 of 4
  1. #1
    Regular Coder
    Join Date
    Jun 2008
    Posts
    104
    Thanks
    71
    Thanked 0 Times in 0 Posts

    Arrow Need to block this ASAP

    In my log files, I've been receiving thousands of requests that look like the following:

    Code:
    "POST / HTTP/1.0" 200 18890 "-" The Incutio XML-RPC PHP Library -- WordPress/3.0.1"
    It's so bad that the shared server that I'm on crashed.

    Can someone help me block these types of requests?

    Thanks!

  • #2
    God Emperor Fou-Lu's Avatar
    Join Date
    Sep 2002
    Location
    Saskatoon, Saskatchewan
    Posts
    16,994
    Thanks
    4
    Thanked 2,662 Times in 2,631 Posts
    Quote Originally Posted by four0four View Post
    In my log files, I've been receiving thousands of requests that look like the following:

    Code:
    "POST / HTTP/1.0" 200 18890 "-" The Incutio XML-RPC PHP Library -- WordPress/3.0.1"
    It's so bad that the shared server that I'm on crashed.

    Can someone help me block these types of requests?

    Thanks!
    Not sure this is actually a problem; according to this some XML-RPC request from a wordpress has accessed the site and was provided with a valid result.
    If you want, you can block the referrer if its not specified or in this case is just a "-". See this link for information on that: http://www.javascriptkit.com/howto/htaccess14.shtml
    PHP Code:
    header('HTTP/1.1 420 Enhance Your Calm'); 
    Been gone for a few months, and haven't programmed in that long of a time. Meh, I'll wing it ;)

  • #3
    Regular Coder
    Join Date
    Jun 2008
    Posts
    104
    Thanks
    71
    Thanked 0 Times in 0 Posts
    It crashed the shared server I was on, due to the thousands of POST requests.

    So I need to block this, to prevent anything like that from happening again.

    Instead of blocking the user agent, I came up with the following to block all POST requests to my website, yet allow all POST requests from within my website.

    Code:
    RewriteEngine on
    RewriteCond %{REQUEST_METHOD} POST
    RewriteCond %{HTTP_HOST} !.*mydomain.com.*
    RewriteRule ^.* - [F,L]
    but it doesn't seem to work correctly. Any ideas?

  • #4
    God Emperor Fou-Lu's Avatar
    Join Date
    Sep 2002
    Location
    Saskatoon, Saskatchewan
    Posts
    16,994
    Thanks
    4
    Thanked 2,662 Times in 2,631 Posts
    That looks right to me, not exactly sure why it won't work. Unless of course the accessing client is pretending its host is matching that domain.
    Still don't think this will solve your problems; it will stop a page from being served, but it won't stop the connection itself. If this is getting to be a problem for your shared host, they should look at blocking the originating source addresses themselves.
    I don't know what you are using, but if you are on a wordpress I would assume that this is your wordpress talking with someone else. If this is the case, then just don't use wordpress.
    PHP Code:
    header('HTTP/1.1 420 Enhance Your Calm'); 
    Been gone for a few months, and haven't programmed in that long of a time. Meh, I'll wing it ;)


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •