• Stars
    star
    2,972
  • Rank 14,598 (Top 0.3 %)
  • Language
    Rust
  • License
    Other
  • Created 3 months ago
  • Updated 2 months ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Blazingly ๐Ÿ”ฅ fast ๐Ÿš€ memory vulnerabilities, written in 100% safe Rust. ๐Ÿฆ€

Blazingly ๐Ÿ”ฅ fast ๐Ÿš€ memory vulnerabilities, written in 100% safe Rust. ๐Ÿฆ€

cve-rs allows you to introduce common memory vulnerabilities (such as buffer overflows and segfaults) into your Rust program in a memory safe manner.

Why choose cve-rs?

  • ๐Ÿฉธ Bleeding edge technology
  • ๐Ÿ•น๏ธ Paradigm-changing (no more unsafe code!)
  • ๐Ÿ”ฅ Blazingly fast
  • ๐Ÿ’ก Easy to use
  • ๐Ÿ† Featuring way ๐Ÿ‘‹ too 2๏ธโƒฃ many ๐Ÿคฏ emojis in the ๐Ÿ“– readme ๐Ÿ”ฅ ๐Ÿฆ€ ๐Ÿ’จ
  • ๐Ÿฆ€ Built in 100% memory-safe Rust

Example

// With cve-rs, you can crash prod in a ๐Ÿ”ฅ blazingly fast manner!
pub fn segfault() {
	let null: &mut u8 = cve_rs::null_mut::<u8>();
	*null = 42;
}

Segfault demo

Rust is an amazing language. You can program a lot of useful things while ensuring that your program will stay safe. Unfortunately, safe Rust is quite limiting. For example, you cannot introduce code that could corrupt the program's memory. Now, with cve-rs, you can corrupt your program's memory without corrupting your program's memory.

We are very committed to making sure cve-rs is memory-safe. We know that unsafe code can have unintended consequences, such as memory unsafety that causes bugs like segmentation faults, use-after-frees, and buffer overflows.

That is why cve-rs uses #![deny(unsafe_code)] in the entire codebase. There is not a single block of unsafe code (except for some tests) in this project.

cve-rs implements the following bugs in safe Rust:

  • Use after free
  • Buffer overflow
  • Segmentation fault

cve-rs also contains safe reimplementations of:

  • std::mem::transmute
  • std::ptr::null()/null_mut() but for references

Installation

cve-rs can be used directly with Cargo.

To use it as a library:

cargo add cve-rs

Or to run our example binary:

cargo install cve-rs
cve-rs

WASM support

cve-rs supports WASM through the WASI API, and also to Webassembly that you can run in a browser.

You can compile it and run it using Wasmer with the following commands:

cargo build --target wasm32-wasi
wasmer run target/wasm32-wasi/debug/cve-rs.wasm

Contributors

Special thanks to @Bright-Shard and @Creative0708, and everyone else who contributed to cve-rs.

Can I use cve-rs in production?

This project is licensed under the GLWTSPL.

Wait, how safe is cve-rs?!?

This project is licensed under the GLWTSPL.

License

This project is licensed under the GLWTSPL.

Good Luck

...and godspeed.

More Repositories

1

SeeShark

Simple C# camera library.
C#
136
star
2

OwOverlay

A very simple configurable key overlay written in Rust.
Rust
7
star
3

oSUS

Some osu! utilities written in Rust.
Rust
4
star
4

read-last-lines-ts

Efficiently reads the last lines of a file, written in TypeScript for intellisense
TypeScript
4
star
5

clipbox

A (eventually) cross-platform clipboard library.
Rust
4
star
6

NativeFileDialogs.NET

Full .NET wrapper for NativeFileDialogs (Extended).
C#
3
star
7

loki

God of Chaotic Chat Apps.
2
star
8

sorbot

Le Bot Discord de vรฉrification pour le serveur Sorbonne Jussieu ! (GitHub mirror from GitLab)
CoffeeScript
2
star
9

ye

yes, but faster, and written in Rust.
Rust
2
star
10

strnth

strnth^strnth^strnth
Haskell
2
star
11

zapf

ZAP file format.
Rust
2
star
12

TicTacToe

A TicTacToe in C# that is designed to be extensible.
C#
1
star
13

yt-music

Download songs from YouTube in mp3 format, thumbnail included
Python
1
star
14

parsers-ts

Making simple parsers in typescript.
TypeScript
1
star
15

arcsquared

Rewrite of Arcthird in Typescript, which is a rewrite of Arcsecond in Coffeescript.
TypeScript
1
star
16

single-rotation-gpu

Program that lets you observe the evolution of a grid state in a cellular automaton called Single Rotation.
C++
1
star
17

single-rotation-cpu

Program that lets you observe the evolution of a grid state in a cellular automaton called Single Rotation.
C++
1
star
18

arcthird

The arcsecond library from LLJS only works for strings and array types. I am trying to make it more abstract by rewriting it to work on any abstract custom stream, using Coffeescript! (GitHub mirror from GitLab)
CoffeeScript
1
star
19

arch-chan

An archival fork of RavioliMavioli's Arch-chan Live2D and Inochi2D models
1
star
20

simple-tga-reader

Simple TGA image reader
Rust
1
star
21

V4l2.AutoGen

Auto-generated C# bindings for V4l2 (Video4Linux2).
C#
1
star