Stop connection with IP after X packets

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP











up vote
0
down vote

favorite












There is a communication between my machine and a server (10 packets), and i'm trying to control it packet by packet.
How can I stop all communication after x packets ? (1-9 in my case)



I tried to use tshark -c 2 host xxx.xxx.xxx.xxx and then cut the communication but it is too slow and let some packets through.



Additionally, is it possible to slow down this communication drastically, let's say to 1 packet per second ?







share|improve this question















  • 2




    You need to provide more information of what you are trying to do. tshark does not stop communication it is recording it. Which communication would you like to stop?
    – Winnie Tigger
    Jun 15 at 5:38










  • You can surely do something tinkering with the connbytes match. For the 2nd part, same advice as Winnie Tigger. tc might be used to add latency, but latency and speed isn't the same depending on how the communication is done.
    – A.B
    Jun 18 at 23:46















up vote
0
down vote

favorite












There is a communication between my machine and a server (10 packets), and i'm trying to control it packet by packet.
How can I stop all communication after x packets ? (1-9 in my case)



I tried to use tshark -c 2 host xxx.xxx.xxx.xxx and then cut the communication but it is too slow and let some packets through.



Additionally, is it possible to slow down this communication drastically, let's say to 1 packet per second ?







share|improve this question















  • 2




    You need to provide more information of what you are trying to do. tshark does not stop communication it is recording it. Which communication would you like to stop?
    – Winnie Tigger
    Jun 15 at 5:38










  • You can surely do something tinkering with the connbytes match. For the 2nd part, same advice as Winnie Tigger. tc might be used to add latency, but latency and speed isn't the same depending on how the communication is done.
    – A.B
    Jun 18 at 23:46













up vote
0
down vote

favorite









up vote
0
down vote

favorite











There is a communication between my machine and a server (10 packets), and i'm trying to control it packet by packet.
How can I stop all communication after x packets ? (1-9 in my case)



I tried to use tshark -c 2 host xxx.xxx.xxx.xxx and then cut the communication but it is too slow and let some packets through.



Additionally, is it possible to slow down this communication drastically, let's say to 1 packet per second ?







share|improve this question











There is a communication between my machine and a server (10 packets), and i'm trying to control it packet by packet.
How can I stop all communication after x packets ? (1-9 in my case)



I tried to use tshark -c 2 host xxx.xxx.xxx.xxx and then cut the communication but it is too slow and let some packets through.



Additionally, is it possible to slow down this communication drastically, let's say to 1 packet per second ?









share|improve this question










share|improve this question




share|improve this question









asked Jun 15 at 4:32









bob dylan

117119




117119







  • 2




    You need to provide more information of what you are trying to do. tshark does not stop communication it is recording it. Which communication would you like to stop?
    – Winnie Tigger
    Jun 15 at 5:38










  • You can surely do something tinkering with the connbytes match. For the 2nd part, same advice as Winnie Tigger. tc might be used to add latency, but latency and speed isn't the same depending on how the communication is done.
    – A.B
    Jun 18 at 23:46













  • 2




    You need to provide more information of what you are trying to do. tshark does not stop communication it is recording it. Which communication would you like to stop?
    – Winnie Tigger
    Jun 15 at 5:38










  • You can surely do something tinkering with the connbytes match. For the 2nd part, same advice as Winnie Tigger. tc might be used to add latency, but latency and speed isn't the same depending on how the communication is done.
    – A.B
    Jun 18 at 23:46








2




2




You need to provide more information of what you are trying to do. tshark does not stop communication it is recording it. Which communication would you like to stop?
– Winnie Tigger
Jun 15 at 5:38




You need to provide more information of what you are trying to do. tshark does not stop communication it is recording it. Which communication would you like to stop?
– Winnie Tigger
Jun 15 at 5:38












You can surely do something tinkering with the connbytes match. For the 2nd part, same advice as Winnie Tigger. tc might be used to add latency, but latency and speed isn't the same depending on how the communication is done.
– A.B
Jun 18 at 23:46





You can surely do something tinkering with the connbytes match. For the 2nd part, same advice as Winnie Tigger. tc might be used to add latency, but latency and speed isn't the same depending on how the communication is done.
– A.B
Jun 18 at 23:46
















active

oldest

votes











Your Answer







StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "106"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);

else
createEditor();

);

function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
convertImagesToLinks: false,
noModals: false,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);



);








 

draft saved


draft discarded


















StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f449935%2fstop-connection-with-ip-after-x-packets%23new-answer', 'question_page');

);

Post as a guest



































active

oldest

votes













active

oldest

votes









active

oldest

votes






active

oldest

votes










 

draft saved


draft discarded


























 


draft saved


draft discarded














StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f449935%2fstop-connection-with-ip-after-x-packets%23new-answer', 'question_page');

);

Post as a guest













































































Popular posts from this blog

Peggy Mitchell

Palaiologos

The Forum (Inglewood, California)