Skip to content

Commit 07fa762

Browse files
authored
Merge pull request #127 from kevinbackhouse/SANE_exploit
SANE Backends exploit (CVE-2020-12861)
2 parents 3a7b4f9 + 38b182e commit 07fa762

18 files changed

Lines changed: 4074 additions & 0 deletions
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
fakescanner
2+
sane_backends_exploit
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
all: fakescanner sane_backends_exploit
2+
3+
fakescanner: fakescanner.cpp utils.hpp utils.cpp
4+
g++ -Wall -Wextra -O2 fakescanner.cpp utils.cpp -o fakescanner
5+
6+
sane_backends_exploit: sane_backends_exploit.cpp utils.hpp utils.cpp
7+
g++ -Wall -Wextra -O2 sane_backends_exploit.cpp utils.cpp -o sane_backends_exploit
8+
9+
clean:
10+
rm -f fakescanner sane_backends_exploit
Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
# Vulnerabilities in SANE Backends
2+
3+
This directory contains two proof-of-concept exploits for several vulnerabilities in
4+
[SANE Backends](https://gitlab.com/sane-project/backends).
5+
6+
The first PoC, [fakescanner.cpp](fakescanner.cpp),
7+
is an enumeration of the different vulnerabilities listed in the
8+
[bug report](https://gitlab.com/sane-project/backends/-/issues/279).
9+
Run it like this:
10+
11+
```bash
12+
make
13+
./fakescanner epson 0
14+
```
15+
16+
(There are different command-line options for triggering different bugs.)
17+
On a different computer, start
18+
[Simple Scan](https://packages.ubuntu.com/bionic/simple-scan).
19+
20+
The second PoC, [sane_backends_exploit.cpp](sane_backends_exploit.cpp),
21+
is a more elaborate exploit which uses a subset of the vulnerabilities
22+
to pop a calculator.
23+
It is designed to target
24+
[Simple Scan](https://packages.ubuntu.com/bionic/simple-scan)
25+
on
26+
[Ubuntu 18.04 LTS](https://releases.ubuntu.com/bionic/).
27+
It will not work on more recent Ubuntu versions due to the glibc version
28+
being different.
29+
Run it like this:
30+
31+
```bash
32+
make
33+
./sane_backends_exploit
34+
```
35+
36+
On a different computer, start
37+
[Simple Scan](https://packages.ubuntu.com/bionic/simple-scan).

0 commit comments

Comments
 (0)