Skip to content

Commit

Permalink
Initial commit
Browse files Browse the repository at this point in the history
  • Loading branch information
Molokai committed Jan 30, 2019
1 parent f88dcce commit 162fa21
Show file tree
Hide file tree
Showing 6 changed files with 52 additions and 0 deletions.
23 changes: 23 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
FROM ubuntu:latest
MAINTAINER [email protected]

RUN apt-get update && apt-get upgrade -y
RUN apt-get install -y lighttpd perl git golang libjson-perl libdatetime-perl libwww-mechanize-perl cron
RUN mkdir /root/sslscan && mkdir /var/www/html/json && mkdir ~/git && cd ~/git && git clone https://github.com/ssllabs/ssllabs-scan && git clone https://github.com/nfcring/sslscan && ls sslscan
ADD index.html /var/www/html/.
ADD start.sh /root/.
RUN chmod 644 /var/www/html/*
RUN cd ~/git/ssllabs-scan && go build ssllabs-scan-v3.go
RUN cp ~/git/sslscan/sslscan.css /var/www/html/.
RUN chmod +x /root/start.sh
RUN touch /var/log/cron.log
RUN apt-get install -y rsyslog
ADD sslscan_cron /etc/cron.d/.
ADD hosts.txt /root/git/sslscan/hosts.txt
RUN chmod 644 /etc/cron.d/sslscan_cron
ADD runscan.sh /root/.
RUN chmod +x /root/runscan.sh
CMD /root/start.sh



1 change: 1 addition & 0 deletions hosts.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
github.com
10 changes: 10 additions & 0 deletions index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="refresh" content="60">
<title>SSL security scan</title>
</head>
<body>
<p>First scan has not completed yet. come back in a few minutes.</p>
</body>
</html>
6 changes: 6 additions & 0 deletions runscan.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
#!/bin/bash
cd ~/git/sslscan
perl scanssl-beta.pl
cp sslscan.html /var/www/html/index.html
cp -R /root/git/sslscan/json/ /var/www/html/.
chown -R www-data:www-data /var/www/html
5 changes: 5 additions & 0 deletions sslscan_cron
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# m h dom mon dow user command
#run scan at 01:00 every night
0 01 * * * root perl /root/runscan.sh

# empty line
7 changes: 7 additions & 0 deletions start.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
#!/bin/sh
# start syslog
rsyslogd
# start web server
/usr/sbin/lighttpd -f /etc/lighttpd/lighttpd.conf
# run cron - which runs scan from /etc/cron.d/sslscan_cron
cron && tail -f /var/log/syslog

0 comments on commit 162fa21

Please sign in to comment.