https://github.com/jesperpedersen/libfaults
Fault injection for system calls
https://github.com/jesperpedersen/libfaults
c fault fault-injection injection shared-library system-call
Last synced: about 1 year ago
JSON representation
Fault injection for system calls
- Host: GitHub
- URL: https://github.com/jesperpedersen/libfaults
- Owner: jesperpedersen
- License: bsd-3-clause
- Created: 2020-01-08T17:31:18.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2020-04-06T11:43:38.000Z (about 6 years ago)
- Last Synced: 2025-02-02T19:46:14.995Z (over 1 year ago)
- Topics: c, fault, fault-injection, injection, shared-library, system-call
- Language: C
- Size: 41 KB
- Stars: 2
- Watchers: 2
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
- Authors: AUTHORS
Awesome Lists containing this project
README
# libfaults
`libfaults` is library that can generate a fault injection for system calls.
See [Getting Started](./doc/GETTING_STARTED.md) on how to get started with `libfaults`.
See [Configuration](./doc/CONFIGURATION.md) on how to configure `libfaults`.
Alternative, take a look at [libfiu](https://blitiri.com.ar/p/libfiu/).
## Tested platforms
* [Fedora](https://getfedora.org/) 28+
* [RHEL](https://www.redhat.com/en/technologies/linux-platforms/enterprise-linux) 7.x/8.x
## Compiling the source
`libfaults` requires
* [gcc](https://gcc.gnu.org)
* [cmake](https://cmake.org)
* [make](https://www.gnu.org/software/make/)
```sh
dnf install gcc cmake make
```
Alternative [clang](https://clang.llvm.org/) can be used.
### Release build
The following commands will install `libfaults` in the `/usr/local` hierarchy
and run the default configuration.
```sh
git clone https://github.com/jesperpedersen/libfaults.git
cd libfaults
mkdir build
cd build
cmake -DCMAKE_INSTALL_PREFIX=/usr/local ..
make
sudo make install
LD_PRELOAD=/usr/local/lib/libfaults.so
```
### Debug build
The following commands will create a `DEBUG` version of `libfaults`.
```sh
git clone https://github.com/jesperpedersen/libfaults.git
cd libfaults
mkdir build
cd build
cmake -DCMAKE_BUILD_TYPE=Debug ..
make
cd src
LD_PRELOAD=libfaults.so
```
Remember to set the `log_level` configuration option to `debug5`.
## Contributing
Contributions to `libfaults` are managed on [GitHub.com](https://github.com/jesperpedersen/libfaults/)
* [Ask a question](https://github.com/jesperpedersen/libfaults/issues)
* [Raise an issue](https://github.com/jesperpedersen/libfaults/issues)
* [Feature request](https://github.com/jesperpedersen/libfaults/issues)
* [Code submission](https://github.com/jesperpedersen/libfaults/pulls)
Contributions are most welcome !
## License
[BSD-3-Clause](https://opensource.org/licenses/BSD-3-Clause)