fbarresi / SoftPlc

Software plc with docker support
MIT License
120 stars 30 forks source link

Possibility of config changes? #1

Closed adityasriv22 closed 4 years ago

adityasriv22 commented 4 years ago

I tried to enumerate the plc through nmap s7-enumerate and I got this output

Starting Nmap 7.60 ( https://nmap.org ) at 2020-05-01 21:15 IST Nmap scan report for 172.17.0.2 Host is up (0.000092s latency).

PORT STATE SERVICE 102/tcp open iso-tsap | s7-enumerate: | Module: 6ES7 315-2EH14-0AB0 | Basic Hardware: 6ES7 315-2EH14-0AB0 | Version: 3.2.6 | System Name: SNAP7-SERVER | Module Type: CPU 315-2 PN/DP | Serial Number: S C-C2UR28922012 |_ Copyright: Original Siemens Equipment MAC Address: 02:42:AC:11:00:02 (Unknown) Service Info: Device: specialized

Nmap done: 1 IP address (1 host up) scanned in 1.03 seconds

Is there a way to change attributes like serial no , module type , system name and also add plant identification?

fbarresi commented 4 years ago

Hi! These parameters are hard coded into snap7. I found in the code, that they was just recorded from a real Siemens hardware. I can also see where this bytes are stored, src/core/s7_firmware.h, but I have no way to create an additional function in my code in order to change them.