mirror of https://github.com/cowrie/cowrie.git
Small config changes (#845)
* Adding /etc/cowrie/cowrie.cfg to possible configurations We want also to look for /etc/cowrie/cowrie.cfg as a possible configuration. * Write ssh host keys into /var/lib/cowrie Dynamical data should be written into /var/lib/cowrie. I know that OpenSSH is doing this but we are not OpenSSH and we should have only stuff written below /var. So /var/log/cowrie and /var/lib/cowrie. * Moving log and dl below var/, cleanup old folders This helps keeping the writes of the daemon in one place and makes it easier later when building a cowrie package. Old paths have been removed from the repository to keep it clean. * Fixing wrong log path Path should be var/log/cowrie not var/log * Fixing json output The json output was not configured to use the default log path. This has been fixed now. * Change order of config reads According to @micheloosterhof there is an order of precedence here.
This commit is contained in:
parent
6c7417393a
commit
be3a7235a5
|
@ -3,8 +3,8 @@ MAINTAINER Florian Pelgrim <florian.pelgrim@craneworks.de>
|
|||
RUN apk add --no-cache libffi && \
|
||||
addgroup -S cowrie && \
|
||||
adduser -S -s /bin/bash -G cowrie -D -H -h /cowrie cowrie && \
|
||||
mkdir -p /cowrie/dl && \
|
||||
mkdir -p /cowrie/log/tty && \
|
||||
mkdir -p /cowrie/var/lib/cowrie/downloads && \
|
||||
mkdir -p /cowrie/var/log/cowrie/tty && \
|
||||
chown -R cowrie:cowrie /cowrie && \
|
||||
chmod -R 775 /cowrie
|
||||
COPY requirements.txt .
|
||||
|
|
|
@ -1,2 +0,0 @@
|
|||
*
|
||||
!.gitignore
|
|
@ -32,13 +32,13 @@ hostname = svr04
|
|||
# Directory where to save log files in.
|
||||
#
|
||||
# (default: log)
|
||||
log_path = log
|
||||
log_path = var/log/cowrie
|
||||
|
||||
|
||||
# Directory where to save downloaded artifacts in.
|
||||
#
|
||||
# (default: dl)
|
||||
download_path = dl
|
||||
# (default: downloads)
|
||||
download_path = ${honeypot:state_path}/downloads
|
||||
|
||||
|
||||
# Directory for miscellaneous data files, such as the password database.
|
||||
|
|
|
@ -1,2 +0,0 @@
|
|||
*
|
||||
!.gitignore
|
|
@ -41,4 +41,4 @@ def readConfigFile(cfgfile):
|
|||
return parser
|
||||
|
||||
|
||||
CONFIG = readConfigFile(("etc/cowrie.cfg.dist", "etc/cowrie.cfg", "cowrie.cfg"))
|
||||
CONFIG = readConfigFile(("etc/cowrie.cfg.dist", "/etc/cowrie/cowrie.cfg", "etc/cowrie.cfg", "cowrie.cfg"))
|
||||
|
|
|
@ -1 +0,0 @@
|
|||
cowrie*
|
Loading…
Reference in New Issue