如何使用 curl 欺骗发件人 IP 地址? [英] How can I spoof the sender IP address using curl?

查看:30
本文介绍了如何使用 curl 欺骗发件人 IP 地址?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

为了测试目的,我需要使用欺骗性 IP 地址发出请求.最简单的方法是什么?

I need to make a request with a spoofed IP address for testing purposes. What's the easiest way to do this?

推荐答案

就我个人而言,通过以下方式更改 HTTP 标头就足够了:

For my own purposes, changing the HTTP header was enough, via the following:

curl --header "X-Forwarded-For: 1.2.3.4" "http://www.foobar.com"

这篇关于如何使用 curl 欺骗发件人 IP 地址?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆