Skip to content

Commit dbf3f70

Browse files
authored
Merge pull request #32 from dreadnode/ads/eng-1003-robopages-create-robopages-for-eyewitness
feat: eyewitness robopage
2 parents 982ce52 + f02da9a commit dbf3f70

File tree

2 files changed

+178
-0
lines changed

2 files changed

+178
-0
lines changed
Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
FROM debian:bookworm
2+
3+
# Install dependencies
4+
RUN apt-get update && apt-get install -y \
5+
git \
6+
wget \
7+
cmake \
8+
python3 \
9+
xvfb \
10+
python3-pip \
11+
python3-netaddr \
12+
python3-dev \
13+
firefox-esr \
14+
python3-venv \
15+
&& rm -rf /var/lib/apt/lists/*
16+
17+
# Clone EyeWitness
18+
RUN git clone --depth 1 https://github.com/RedSiege/EyeWitness.git /EyeWitness
19+
WORKDIR /EyeWitness
20+
21+
# Setup Python virtual environment and dependencies
22+
RUN python3 -m venv venv && \
23+
. venv/bin/activate && \
24+
python3 -m pip install \
25+
fuzzywuzzy \
26+
selenium==4.9.1 \
27+
python-Levenshtein \
28+
pyvirtualdisplay \
29+
netaddr && \
30+
cd Python/setup && \
31+
./setup.sh
32+
33+
# Set environment variables
34+
ENV TERM=xterm \
35+
SCREENSHOT_DIR=/eyewitness/screens \
36+
LOGDIR=/eyewitness/logs
37+
38+
# Create directories and selenium log path
39+
RUN mkdir -p /eyewitness/screens /eyewitness/logs
40+
41+
# Create wrapper script to handle venv activation and Xvfb
42+
RUN echo '#!/bin/bash\n\
43+
source /EyeWitness/venv/bin/activate\n\
44+
mkdir -p "$SCREENSHOT_DIR"\n\
45+
xvfb-run --server-args="-screen 0, 1024x768x24" \\\n\
46+
python3 /EyeWitness/Python/EyeWitness.py \\\n\
47+
--selenium-log-path "$LOGDIR" "$@"' > /usr/local/bin/run-eyewitness && \
48+
chmod +x /usr/local/bin/run-eyewitness
49+
50+
VOLUME ["/eyewitness"]
51+
WORKDIR /eyewitness
52+
53+
ENTRYPOINT ["/usr/local/bin/run-eyewitness"]
Lines changed: 125 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,125 @@
1+
description: >
2+
EyeWitness is designed to take screenshots of websites, provide some server header info, and identify default credentials if possible.
3+
4+
functions:
5+
eyewitness_single:
6+
description: Capture screenshot and information from a single URL
7+
parameters:
8+
target:
9+
type: string
10+
description: The URL to capture
11+
examples:
12+
- https://example.com
13+
14+
container:
15+
platform: linux/amd64
16+
build:
17+
path: ${cwd}/eyewitness.Dockerfile
18+
name: eyewitness_local
19+
volumes:
20+
- ${cwd}/eyewitness:/eyewitness
21+
22+
cmdline:
23+
- --headless
24+
- --web
25+
- --single
26+
- ${target}
27+
- --no-prompt
28+
- -d
29+
- /eyewitness/screens/report
30+
31+
eyewitness_file:
32+
description: Capture screenshots and information from a file containing URLs
33+
parameters:
34+
target_file:
35+
type: string
36+
description: File containing URLs to scan (one per line)
37+
examples:
38+
- urls.txt
39+
40+
container:
41+
platform: linux/amd64
42+
build:
43+
path: ${cwd}/eyewitness.Dockerfile
44+
name: eyewitness_local
45+
volumes:
46+
- ${cwd}/eyewitness:/eyewitness
47+
- ${cwd}/${target_file}:/eyewitness/targets.txt
48+
49+
cmdline:
50+
- --headless
51+
- --web
52+
- -f
53+
- ${target_file}
54+
- --no-prompt
55+
- -d
56+
- /eyewitness/screens/report
57+
58+
eyewitness_nmap_xml:
59+
description: Capture screenshots from a Nmap XML output file
60+
parameters:
61+
xml_file:
62+
type: string
63+
description: Path to Nmap XML output file
64+
examples:
65+
- nmap_output.xml
66+
67+
container:
68+
platform: linux/amd64
69+
build:
70+
path: ${cwd}/eyewitness.Dockerfile
71+
name: eyewitness_local
72+
volumes:
73+
- ${cwd}/eyewitness:/eyewitness
74+
- ${cwd}/${nmap_xml_file}:/eyewitness/scan.xml
75+
76+
cmdline:
77+
- --headless
78+
- --web
79+
- -x
80+
- /eyewitness/${nmap_xml_file}
81+
- --no-prompt
82+
- -d
83+
- /eyewitness/screens/report
84+
85+
eyewitness_custom_ports:
86+
description: Scan specific URLs with custom HTTP/HTTPS ports
87+
parameters:
88+
target:
89+
type: string
90+
description: The URL to capture
91+
examples:
92+
- https://example.com
93+
http_ports:
94+
type: string
95+
description: Additional HTTP ports (comma-separated)
96+
examples:
97+
- "8080,8081"
98+
default: ""
99+
https_ports:
100+
type: string
101+
description: Additional HTTPS ports (comma-separated)
102+
examples:
103+
- "8443,9443"
104+
default: ""
105+
106+
container:
107+
platform: linux/amd64
108+
build:
109+
path: ${cwd}/eyewitness.Dockerfile
110+
name: eyewitness_local
111+
volumes:
112+
- ${cwd}/eyewitness:/eyewitness
113+
114+
cmdline:
115+
- --headless
116+
- --web
117+
- --single
118+
- ${target}
119+
- --no-prompt
120+
- --add-http-ports
121+
- ${http_ports}
122+
- --add-https-ports
123+
- ${https_ports}
124+
- -d
125+
- /eyewitness/screens/report

0 commit comments

Comments
 (0)