How do I spoof the IP that my computer sends a server without using something like a VPN or proxy?

Solution 1:

Spoofing your IP address in the manner you are describing is like writing the wrong return address on an envelope and expecting a reply letter to your real address. It isn't going to happen because the only reply information they have is the wrong return address.

There are many Linux tools that will let you create spoofed IP datagrams, and with iptables you can tell a Linux system, acting as a router, to do all sorts of things to traffic, including modifying your source IP to something totally different. Likely your ISP, if it is a residential ISP, is going to automatically filter any traffic coming from your cable or DSL modem where the source IP doesn't match what the ISP gave you via DHCP, or at least within its public subnet. This may prompt your ISP to cut off your service thinking you are infected with malware.

The only way you can "hide" your IP is have another system in front of you that takes your traffic and forwards it on your behalf, i.e., a proxy.

Solution 2:

This (as far as I'm aware - I'm happy to be proven wrong) isn't possible - at least not in a standard home network with an ISP-provided router and not with the constraints that you've given (no VPN/proxy/router changes).

You can definitely spoof an IP on your home subnet, but this wouldn't affect the SNAT (source NAT) that your router performs - all requests originating from your router will appear to be from its WAN interface.

If you control two static IP addresses, you could set your router to SNAT to that IP (assuming it's approved by your ISP). Something like this in iptables-speak:

iptables -t nat -I POSTROUTING 1 -p all -s 192.168.x.y -j SNAT --to-source 1.2.3.4