bump conpot to latest master, cleanup

This commit is contained in:
t3chn0m4g3 2022-03-09 15:19:51 +00:00
parent d2f3be9477
commit 99c719eed4
4 changed files with 16 additions and 1142 deletions

View file

@ -19,18 +19,14 @@ RUN apk --no-cache -U add \
pkgconfig \
python3 \
python3-dev \
py3-cffi \
py3-cryptography \
py3-gevent \
py3-pip \
tcpdump \
wget && \
#
# Setup ConPot
git clone https://github.com/mushorg/conpot /opt/conpot && \
cd /opt/conpot/ && \
# git checkout 804fd65aa3b7ffa31c07fd4e863d4a5500414cf3 && \
git checkout 1c2382ea290b611fdc6a0a5f9572c7504bcb616e && \
git checkout b3740505fd26d82473c0d7be405b372fa0f82575 && \
#git checkout 1c2382ea290b611fdc6a0a5f9572c7504bcb616e && \
# Change template default ports if <1024
sed -i 's/port="2121"/port="21"/' /opt/conpot/conpot/templates/default/ftp/ftp.xml && \
sed -i 's/port="8800"/port="80"/' /opt/conpot/conpot/templates/default/http/http.xml && \
@ -41,9 +37,11 @@ RUN apk --no-cache -U add \
sed -i 's/port="6969"/port="69"/' /opt/conpot/conpot/templates/default/tftp/tftp.xml && \
sed -i 's/port="16100"/port="161"/' /opt/conpot/conpot/templates/IEC104/snmp/snmp.xml && \
sed -i 's/port="6230"/port="623"/' /opt/conpot/conpot/templates/ipmi/ipmi/ipmi.xml && \
pip3 install --no-cache-dir -U setuptools && \
pip3 install --no-cache-dir --upgrade pip && \
pip3 install --no-cache-dir -U cffi \
setuptools \
wheel && \
pip3 install --no-cache-dir . && \
pip3 install --no-cache-dir pysnmp-mibs && \
cd / && \
rm -rf /opt/conpot /tmp/* /var/tmp/* && \
setcap cap_net_bind_service=+ep /usr/bin/python3.9 && \
@ -68,7 +66,6 @@ RUN apk --no-cache -U add \
mariadb-dev \
pkgconfig \
python3-dev \
py-cffi \
wget && \
rm -rf /root/* && \
rm -rf /tmp/* && \

File diff suppressed because it is too large Load diff

View file

@ -91,19 +91,19 @@
<value type="value">1</value>
</key>
<key name="ifInOctets">
<value type="value">1618895</value>
<value type="function">conpot.emulators.misc.sysinfo.BytesRecv</value>
</key>
<key name="ifInUcastPkts">
<value type="value">7018</value>
<value type="function">conpot.emulators.misc.sysinfo.PacketsRecv</value>
</key>
<key name="ifInNUcastPkts">
<value type="value">291</value>
</key>
<key name="ifOutOctets">
<value type="value">455107</value>
<value type="function">conpot.emulators.misc.sysinfo.BytesSent</value>
</key>
<key name="ifOutUcastPkts">
<value type="value">872264</value>
<value type="function">conpot.emulators.misc.sysinfo.PacketsSent</value>
</key>
<key name="ifOutUNcastPkts">
<value type="value">143</value>
@ -168,7 +168,7 @@
<value type="value">0</value>
</key>
<key name="ipAdEntAddr">
<value type="value">"217.172.190.137"</value>
<value type="function">conpot.emulators.misc.sysinfo.LocalIP</value>
</key>
<key name="ipAdEntIfIndex">
<value type="value">1</value>
@ -290,7 +290,7 @@
<value type="value">45</value>
</key>
<key name="tcpCurrEstab">
<value type="value">0</value>
<value type="function">conpot.emulators.misc.sysinfo.TcpCurrEstab</value>
</key>
<key name="tcpInSegs">
<value type="value">30321</value>
@ -305,7 +305,7 @@
<value type="value">2</value>
</key>
<key name="tcpConnLocalAddress">
<value type="value">"217.172.190.137"</value>
<value type="function">conpot.emulators.misc.sysinfo.LocalIP</value>
</key>
<key name="tcpConnLocalPort">
<value type="value">2404</value>
@ -336,7 +336,7 @@
<value type="value">47</value>
</key>
<key name="udpLocalAddress">
<value type="value">"217.172.190.137"</value>
<value type="value">"163.172.189.137"</value>
</key>
<key name="udpLocalPort">
<value type="value">161</value>

View file

@ -11,7 +11,7 @@
<!-- Core value that can be retrieved from the databus by key -->
<key_value_mappings>
<key name="power_simulator">
<value type="function">conpot.protocols.kamstrup.usage_simulator.UsageSimulator</value>
<value type="function">conpot.emulators.kamstrup.usage_simulator.UsageSimulator</value>
</key>
<key name="register_1024">
<value type="value">0</value>