blob: f3e39b0f627cb9c1e02fbb6da89e09c6b5198e24 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
|
custodian-enqueue
-----------------
We open named files from the user to parse tests.
We don't run shell commands.
custodian-dequeue
-----------------
Two tests pass arguments from the configuration file to
the shell:
ping
http/https
The hostname used to ping, and the url, are both passed
directly to the shell with no encoding or sanitizing.
This means a test such as the following is a risk:
$(touch /tmp/blah) must run ping.
HOWEVER the hostname will pass the following regexp:
^([^\s]+)\s+
So in real terms the only risk is commands without
spaces:
$(/tmp/exploit.sh) must run ping
TODO: Fix this
general
-------
We decode arbitrary JSON from the queue. We should sign
it, or validate it. This will prevent trojan malformed
JSON from being added.
TODO
----
Anything else? DoS attacks?
Steve
--
|