goprotos7 is a standalone server that implements a protocol compatible with S7 communication, commonly used by industrial automation systems and PLCs. It is intended for testing, education, and development of SCADA/HMI tools and industrial simulators.
⚠️ This software is not affiliated with Siemens AG or any proprietary implementation.
It is an independent, reverse-engineered protocol implementation for compatibility and research purposes only.
- Implements ISO-on-TCP (RFC 1006) with COTP session negotiation
- Supports request connection
- Supports response request connection
- Supports PDU (Protocol Data Unit) request
- Implements S7 communication protocol
- readvar request and response
- writevar request and response
- Simulates access to Data Blocks (DB)
- Goals:
- ReadVar
- WriteVar
- Goals:
- Simulate wrong request package response error
Build:
go build -o goprotos7 ./cmd/goprotos7Run:
| Env | Default Value | Description |
|---|---|---|
--bin-folder or -b |
Target BINs files folder. | |
--port or -p |
102 |
The port to listen on. If empty, the default port 102 will be used. |
./goprotos7 --qlite-path ./db.sqlite --db-bin-path ./dbThe service will start listening on port 102 by default, which is the standard port for S7 communication.
Used to create and maintain the database blocks used by goprotos7. Will create the bin file using the "db_variables" table from the SQLite database.
| Env | Default Value | Description |
|---|---|---|
--qlite-path or -s |
`` | Store the default path for the SQLite database file. If empty, the pwd will be used. |
--db-bin-path or -b |
`` | Store the database BIN files path |
--flags.enable-webadmin |
false |
If true will enable the dbtools "frontend" |
--log-level.sqlite |
SILENCE |
Define the SQLite log level |
