Skip to content
Back to skills

Esp32 Modbus Security And Mapping

ASecurity

Use when implementing Modbus RTU/TCP register maps, scaling, access control, exception handling or multi-vendor interoperability.

  • 16 stars
  • 0 votes
  • 0 copies
  • 1 view
  • Added November 7, 2026
ai-agentsrustapisecurity

Works with

  • cli
  • api

Security analysis

A100/100

Pro scans all 2 files and shows the line behind each finding

Scanned November 7, 2026

npx -y skills add Esmail-sarhadi/esp32-agent-skills --skill esp32-modbus-security-and-mapping --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Esp32 Modbus Security And Mapping?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Esp32 Modbus Security And Mapping
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/esmail-sarhadi-esp32-modbus-security-and-mapping/badge)](https://www.skillsdirectory.com/skills/esmail-sarhadi-esp32-modbus-security-and-mapping)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: esp32-modbus-security-and-mapping
description: Use when implementing Modbus RTU/TCP register maps, scaling, access control, exception handling or multi-vendor interoperability.
license: MIT
---

# Modbus Security And Mapping

A Modbus register map is an application contract, not a universal schema. Address notation, data representation, permissions and timing vary by vendor.

## Addressing and functions

Separate protocol reference numbers (such as 30001/40001 notation) from zero-based PDU offsets. Record function code, table, offset, quantity, access mode and device-specific limits. Do not blindly subtract 40001 unless the vendor map explicitly uses that convention. Validate legal quantities and avoid crossing undocumented register boundaries.

## Data representation

Specify signedness, word order, byte order, scaling, engineering units, invalid sentinels and update rate for every multi-register value. Test IEEE-754 floats and 32/64-bit integers with known byte patterns. Preserve raw register values alongside converted values so field diagnostics can distinguish transport from scaling errors.

## Security and robustness

Treat Modbus as unauthenticated unless protected by a separate trusted network/security layer. Segment control networks, restrict write-capable clients and use allowlists for writable ranges. Validate unit ID, function code, quantity and payload length. Rate-limit expensive operations and never expose arbitrary register writes to an internet-facing endpoint.

## Interoperability tests

| Test | Expected result |
|---|---|
| Unknown unit ID | Defined timeout/ignore policy |
| Illegal address | Correct exception response |
| Read-only write | Rejected and logged |
| Swapped word order | Detected by known-pattern test |
| Maximum register quantity | Boundary validated |
| Duplicate request | Idempotent read; safe write policy |

## Agent rules

Keep a machine-readable register map with source document revision. Never infer units or scaling from register numbers. Use explicit conversion functions and test vectors. Record vendor-specific deviations and gateway behavior.

## Field evidence to capture

- Record the exact ESP32 SoC, module, board revision and schematic revision.
- Record framework, compiler, driver version and relevant configuration flags.
- Preserve raw measurements and error codes before applying filters or retries.
- Separate a suspected cause from a reproduced root cause and a verified fix.
- Link the test result to a reproducible fixture or documented manual procedure.

## Version and safety boundary

Check the selected target's datasheet, errata and framework release notes before choosing APIs or pin capabilities. Electrical protection, isolation, overcurrent limits and safe outputs must be designed independently of firmware. A passing host test is not evidence of electrical compliance or field reliability.

Files in this skill

  • LICENSE.txt824 B
  • SKILL.md2.8 KB

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in ai-agents →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.