Code Monkey home page Code Monkey logo

lossybridge's Introduction

  • DEPRECATED -

Update : I learnt a new way! using TC and a linux module is not needed

brctl addbr br0 brctl addif br0 ethX <---- first ethernet interface brctl addif br0 ethY <----- Second Ethernet interface ifconfig br0 up

tc qdisc add dev ethX root netem delay 200ms 400ms 25% loss 15.3% 25% duplicate 1% corrupt 0.1% reorder 5% 50%

Look at the netem module documentation as a WAN emulator is standard with the linux kernel

BridgeMangle

A simple Netfilter-Bridge utility that drops packets based on a random values that are traversing the linux bridge subsystem. This emulates a bad network link between devices.

This only works with Linux Bridges as it intercepts the FORWARD

Building - just run MAKE

sudo insmod bridgebreak_out.ko

Setup : You need atleast 2 ethernet devices in a bridge
sudo brctl addbr br0
sudo brctl addif br0 eth1
sudo brctl addif br0 eth2
sudo ifconfig br0 up

Show Status : cat /proc/loss
SET Random probability : echo 5000 > /proc/loss (5000 is an example)
A value from 0 to 65535 is valid

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.