IP Spoofing with UDP Request sampler

311 views
Skip to first unread message

darc...@gmail.com

unread,
Apr 29, 2016, 10:39:49 AM4/29/16
to jmeter-plugins
Hello,

I'm trying to simulate multiple concurrent UDP requests from different IP Addresses. Is there a way to spoof IP addresses using UDP Request sampler?
Also, can I specify the source port that UDP Request sampler uses to send the datagrams?

Andrey Pokhilko

unread,
May 3, 2016, 2:58:59 PM5/3/16
to jmeter-plugins, darc...@gmail.com
Hello,

IP spoofind is currently not available in UDP sampler. It's not as easy to implement since it would require completely different internal implementation (see http://stackoverflow.com/questions/10626262/spoof-source-ip-port-with-datagrampacket). 

If I'd implement such sampler, I'd not modify current UDP sampler. It should be different sampler, because UDP sampler highly relies on SocketChannel, which is irrelevant for Raw Sockets.

Second part about source address is also not implemented, but it can be done by just improving UDP sampler. Feel free to bring pull request that implements it.

--
Andrey

пятница, 29 апреля 2016 г., 17:39:49 UTC+3 пользователь darc...@gmail.com написал:

aram.o...@gmail.com

unread,
Jul 20, 2016, 1:48:15 PM7/20/16
to jmeter-plugins, darc...@gmail.com
Plus-1 for being able to specify the source port for that the UDP request comes from.

I am guessing that neither of you have had the opportunity to add this feature into the UDP Sampler?

--Aram S. Openden

Andrey Pokhilko

unread,
Aug 22, 2016, 4:35:36 PM8/22/16
to jmeter-...@googlegroups.com

Hi,

In couple of hours, there will be UDP plugin version 0.2 released, shipping bind address/port settings. Check it out.

Andrey Pokhilko

--
You received this message because you are subscribed to the Google Groups "jmeter-plugins" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jmeter-plugin...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

kli...@janklimes.cz

unread,
Nov 30, 2016, 5:24:06 PM11/30/16
to jmeter-plugins
Hello Andrey,
I tryed UDP plugin version 0.2 on JMeter 3.0 under CentOS 7.2 but spoofing source ip address or source UDP port not working.
Also, i download last version 0.5.7 from github to eclipse project with JMeter source code, build JAR file of UDP Request plugin, import to \lib\ext but spoofing source IP or port not working too.
I use kg.apc.jmeter.samplers.DNSJavaDecoder and Wireshark show correct generate packet to port UDP 53 of DNS server, but source IP of this packed is always had same as currently assigned to interface and source UDP port is different that entered in Bind Local Port, maybe different as well.
Entered IP as Bind Local Address is realy addded to interface as second IP addresses.
Just not running for me, what I doing wrong? :)
Are you testing and working this features, Andrey?
Sccreenshot in attachment are from ver 0.2 release.
Jan
pluginconfig.PNG
debugerror.PNG

Andrey Pokhilko

unread,
Dec 6, 2016, 6:08:03 AM12/6/16
to jmeter-...@googlegroups.com

Hi,

UDP sampler allows _choice_ of originating IP address. It's not same thing as IP spoofing. With UDP sampler the IP you choose as source address _must_ exist on your machine.

Andrey Pokhilko

Reply all
Reply to author
Forward
0 new messages