Skip to content

LD_PRELOAD program that forces specified calls to fail

License

Notifications You must be signed in to change notification settings

sloweax/dlblock

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Usage

usage: dlblock [-b block-list] command [args]

Example

# the program you want to run must be dynamically linked

dlblock -b connect curl google.com # makes every `connect(2)` calls fail
# curl: (7) Failed to connect to google.com port 80 after 22 ms: Couldn't connect to server

dlblock -b open,openat touch file # both `open(2)` and `openat(2)` will fail
# touch: cannot touch 'file': Cannot allocate memory

Build

Make sure to have make and gcc installed

git clone https://github.com/sloweax/dlblock
cd dlblock
make install

About

LD_PRELOAD program that forces specified calls to fail

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published