Repository navigation
Open
Description
Goal
Implement capture-backed MMS File Services parity for the IED Simulator and reusable ARStack core, using the real external IEC 61850 client Open / Download / Delete traces as the wire oracle.
Golden wire profile
- FileDirectory
[77]: root request keepsfileSpecificationpresent asA0 02 19 00. - FileOpen
[72]: rooted-backslash file name +initialPosition=0, returns per-association FRSM handle. - FileRead
[73]: one MMS response may be COTP-segmented across multiple TPKTs;moreFollowsis MMS-level, not TCP/TPKT-level. - FileClose
[74]: primitive FRSM request, empty successful response. - FileDelete
[76]: constructed request carrying the rooted-backslash GraphicString directly; successful response is primitive empty[76](9F 4C 00). - external IEC 61850 client groups physical COMTRADE companions client-side. Delete sends one FileDelete per physical path, then immediately refreshes FileDirectory.
Architecture
F0 — protocol/core
- Add service 76 to vector and span service enums/mappings.
- Add portable FileDelete request/response codecs and explicit destructive runtime API.
- Preserve the portable file layer as filesystem/socket/thread free.
F1 — server extension
- Add an external confirmed-service hook to the bounded static dispatcher/runtime rather than embedding host filesystem code in portable MMS core.
- Preserve existing negotiated MMS size handling and COTP response segmentation.
F2 — host simulator file backend
- Sandboxed
--file-root. - Per-association bounded FRSM table/cursors.
- Sorted bounded FileDirectory with size/timestamp.
- FileOpen/FileRead/FileClose.
- FileDelete only when explicitly enabled (
--allow-file-delete). - Reject traversal, drive/scheme ambiguity, symlink escape, invalid/missing handles and unsafe deletion.
- Shared root synchronization across simultaneous associations.
F3 — product wiring
- Simulator helper passes its managed file root.
- Files workspace can explicitly delete a physical remote file and refresh directory after success.
- Upload/rename remain out of scope.
F4 — regression / acceptance
- Exact BER regression for
[72,73,74,76,77]including external IEC 61850 client golden shapes. - Integration: Directory → Open → Read → Close.
- Integration: Delete physical companions → Directory refresh.
- Large FileRead proves one MMS response can be segmented by COTP.
- Multi-association handle isolation + path/symlink safety tests.
- Final acceptance requires a real external IEC 61850 client retest; CI/simulator evidence alone is not relabelled as third-party acceptance.
Keep PR #82 OPEN + DRAFT while this work is under external external IEC 61850 client acceptance.
Metadata
Metadata
Assignees
Labels
No labels
Activity
masarray commentedon Sep 15, 2026
F0 complete — capture-backed FileDelete protocol/core
Implemented on PR #82 at
21a98b3dabb12c0902952675e343dad1f121ab83.MmsFileDeleteRequest/Responseand exact external IEC 61850 client wire codec (BF 4Cconstructed request with direct GraphicString rooted path; primitive empty9F 4C 00success response).MmsFileTransferRuntime::remove()API.F1 next: portable external confirmed-service hook so the host simulator can implement real file services without putting filesystem dependencies into portable MMS core.
[-]IEDScout file-service golden parity: Directory/Open/Read/Close/Delete[/-][+]external IEC 61850 client file-service golden parity: Directory/Open/Read/Close/Delete[/+][-]external IEC 61850 client file-service golden parity: Directory/Open/Read/Close/Delete[/-][+]IEC 61850 file-service golden parity: Directory/Open/Read/Close/Delete[/+]