1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Curl and visitor IP addresses problem

Discussion in 'Black Hat SEO' started by binkage, Mar 13, 2011.

  1. binkage

    binkage Newbie

    Joined:
    Jan 26, 2010
    Messages:
    6
    Likes Received:
    0
    Greetings,

    I am using Curl to spoof the referrer but ran into a problem. It seems that my visitor IP addresses do not pass through curl and they just get replaced with my server's IP address.

    I heard something about "sockets" or some other options to allow limited "tunneling" through Curl and provide some communication between the target destination and the client browser in order for the visitor IP to be seen by the target and data to transfer back to the client browser.

    Can anyone help me out with this or provide some advice?

    Thanks
    Kind regards
     
  2. f0rked

    f0rked Registered Member

    Joined:
    Jan 25, 2009
    Messages:
    71
    Likes Received:
    64
    Curl obviously will not pass the users IP along as it's making the call to the pages via your server. PHP sockets would work in a similar way. If you're wanting to spoof your referrer look into something like CPA Redirector. There is a standalone version as well as a wordpress plugin.

    Standalone version:
    Code:
    http://www.contentgeneration.org/cpa-redirector-standalone-version/
    I too wish that curl could pass along the users IP, but that's just not something that is possible.
     
  3. binkage

    binkage Newbie

    Joined:
    Jan 26, 2010
    Messages:
    6
    Likes Received:
    0
    Thanks for the link f0rked,

    Do you know of anything like this that works purely in PHP or something that behaves similarly (no html, javascript or meta redirects)?
     
  4. darkAsPitch

    darkAsPitch Registered Member

    Joined:
    Aug 25, 2009
    Messages:
    91
    Likes Received:
    480
    Location:
    In the shadows.
    Spoofing a REFERRER in curl is quite simple. You just say basically "referrer = this_webpage" in pseudocode.

    Spoofing the IP address is a whole nother story. And is quite impossible to do if you actually want to read/interact-with the page you are accessing.
     
  5. binkage

    binkage Newbie

    Joined:
    Jan 26, 2010
    Messages:
    6
    Likes Received:
    0
    Is there some way to pass the original and legitimate IP without spoofing or touching it at all?

    I was hoping there might be a way to work with just passing IP as long as it wasn't touched, changed or spoofed, but have the ability to spoof only the referrer using some PHP functions or libraries.
     
  6. nambooooo

    nambooooo Regular Member

    Joined:
    May 21, 2009
    Messages:
    219
    Likes Received:
    71
    Location:
    GreenMTN
    It's really impossible by architecture. PHP is server-side, therefore all requests carry server's IP address (or proxy's). The response from the third-party page is send to your server (PHP) it cannot be sent to the client, or if it does, it's useless since the client didn't request the third-party page (PHP on the server did) and the client will ignore it.
    You need something client-side (JS)