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

查看:131
本文介绍了如何使用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头就足够了: / p>

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天全站免登陆