Hoe Cnspec te gebruiken om verouderde firmware en misconfiguraties te detecteren op PLCnext Control
Als voorbeeld nemen we de PLCnext Control AXC F 2125 van Phoenix Contact, die gebaseerd is op de ARM Cortex-A9-processor en een IEC 61131-runtimesysteem heeft. Cnspec is een open-source-tool die verschillende opties biedt voor het scannen van de Linux-gebaseerde PLCnext Control om oude firmware en misconfiguraties te detecteren. Deze handleiding biedt stapsgewijze instructies om een PLCnext Control te scannen via de cnspec SSH-provider.
-
Installeer cnspec op je laptop (Installatiegids)
-
Test de verbinding en vestig een cnspec-shell naar de PLCnext Control door het volgende commando uit te voeren:
cnspec shell ssh admin@192.168.1.10 --ask-pass -
Voer het volgende MQL-commando uit binnen de cnspec-shell:
file("/etc/plcnext/arpversion").content
Zoals we zien, konden we via SSH verbinden met de PLCnext Control en het eerste MQL-commando uitvoeren.
→ loaded configuration from /home/user/.config/mondoo/mondoo.yml using source default Enter password: → discover related assets for 1 asset(s) → resolved assets resolved-assets=1 ___ _ __ ___ _ __ ___ ___ / __| '_ \/ __| '_ \ / _ \/ __| | (__| | | \__ \ |_) | __/ (__ \___|_| |_|___/ .__/ \___|\___| mondoo™ |_| cnspec> file("/etc/plcnext/arpversion").content file.content: "Arpversion: 23.0.0.65 GIT Commit Hash: d755854b5b21ecb8dca26b0a560e6842a0c638d7 Build Job: \"jenkins-PLCnext-Yocto_Targets-Yocto_AXCF2152-release%2F23.0.x-65\" "
-
Download het PLCnext Technology-beleid uit de publieke cnspec-policies-repository om een basische beveiligingsscan uit te voeren door het volgende commando uit te voeren:
git clone https://github.com/mondoohq/cnspec-policies Cloning into 'cnspec-policies'... remote: Enumerating objects: 1075, done. remote: Counting objects: 100% (149/149), done. remote: Compressing objects: 100% (84/84), done. remote: Total 1075 (delta 75), reused 115 (delta 61), pack-reused 926 Receiving objects: 100% (1075/1075), 699.81 KiB | 402.00 KiB/s, done. Resolving deltas: 100% (690/690), done. -
Voer het volgende commando uit om een complete beveiligingsscan op de PLCnext Control via SSH uit te voeren:
cnspec scan ssh admin@192.168.1.10 -f cnspec-policies/community/mondoo-phoenix-plcnext-security.mql.yaml --ask-pass
De volledige output ziet er zo uit:
cnspec scan ssh admin@192.168.1.10 -f cnspec-policies/community/mondo-phoenix-plcnext-security.mql.yaml --ask-pass → loaded configuration from /home/user/.config/mondoo/mondoo.yml using source default Enter password: → using service account credentials → discover related assets for 1 asset(s) → resolved assets resolved-assets=1 axcf2152 ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 100% score: F Asset: axcf2152 --------------- Controls: ✕ Fail: Ensure SSH MaxAuthTries is set to 4 or less ✓ Pass: Ensure secure permissions on SSH public host key files are set ✓ Pass: Ensure only strong MAC algorithms are used ✓ Pass: Ensure only strong ciphers are used ✓ Pass: Ensure SSH IgnoreRhosts is enabled ✓ Pass: Ensure SSH Idle Timeout Interval is configured ✕ Fail: Ensure SSH password authentication is disabled ✓ Pass: Ensure current system time is synchronized ✓ Pass: Ensure only strong Key Exchange algorithms are used ✓ Pass: Ensure SSH LoginGraceTime is set to one minute or less ✓ Pass: Ensure SSH Protocol is set to 2 ✓ Pass: Ensure SSH root login is disabled or set to prohibit-password ✓ Pass: Ensure SSH LogLevel is appropriate ✓ Pass: Ensure SSH PermitUserEnvironment is disabled ✓ Pass: Ensure SSH HostbasedAuthentication is disabled ✓ Pass: Ensure SSH access is limited ✓ Pass: Ensure secure permissions on SSH private host key files are set ✓ Pass: Ensure SSH warning banner is configured ✕ Fail: Ensure Firewall is active ✓ Pass: Ensure SSH PermitEmptyPasswords is disabled ✓ Pass: Ensure SSH X11 forwarding is disabled ✓ Pass: Ensure latest PLCnext Firmware is installed Scanned 1 assets For detailed output, run this scan with "-o full".
De open-source cnspec-beveiligingsoplossing biedt een uitgebreide aanpak voor het identificeren van kwetsbaarheden en misconfiguraties in zowel IT- als OT-systemen. Door je systemen regelmatig te scannen, kun je proactief potentiële beveiligingsproblemen identificeren en oplossen voordat ze een probleem worden.
Let op:
De Makers Blog toont toepassingen en gebruikersverhalen van community-leden die niet getest of beoordeeld zijn door Phoenix Contact. Gebruik ze op eigen risico.
Industriële technologie
- Wie Draagt IP-verantwoordelijkheid in de Supply Chain? Rechten en Risico's Verduidelijken
- Na De Grote Ontslaggolf: De Opkomst Van Grote Erkenning In De Werkvorming
- 3D-printen van tandwielen meesteren: expert tips en complete gids
- 11 Bewezen Strategieën voor Betaalbare PCB-assemblage Zonder Inboete op Kwaliteit
- Honenproces Ontrafeld: Definitie, Constructie, Principes, Voordelen en Industriële Toepassingen
- Supply Chain Automatisering: De Toekomst van Logistieke Efficiëntie Sturen
- Top 10 Essentiële Toepassingen van Aluminiumoxidepoeder in de Industrie
- Passingen in de Werktuigbouwkunde: Lichtkruip, Pers en Overgangspassingen
- AI-gestuurde turbine-schijfproductie verlaagt kosten, risico's en leveranciersonzekerheid in 2026
- Een Metaalfabricagepartner Kiezen: Voordelen, Nadelen En Hoe Waarde Te Maximaliseren
- De ultieme gids voor PCB conformal coating: uw printplaten beschermen