Source Transformation Integrity in Legacy COBOL Systems: A Static Analysis Approach to Detecting Format-Dependent Semantic Divergence

The compilation format flag for COBOL fixed-format source code is not stored in the source file — it lives in the build system, CI configuration, or operator invocation. When that flag changes, the positional semantics of column 7 (the indicator area) change with it: a comment under -fixed may become active code under -free, or the program may fail to compile entirely. We demonstrate this with a single unmodified file: compiled with cobc -fixed it executes and produces correct output; compiled with cobc -free (GnuCOBOL 3.1.2, same version) it produces ten compilation errors. We present cobol-shield, a static analysis toolkit that detects format boundary conditions before transformation occurs and classifies findings under a three-tier evidence framework. Validation against three open-source COBOL projects yields two confirmed findings with observable proof-of-concept outputs, a systemic defect in 25 of 29 IBM CICS modules, and a characterization of the false positive profile of each detection rule. All artifacts are publicly available at https://github.com/LuisCastellanos-dev/cobol-shield.

Authors

Institutions

Publication Details

Journal
Zenodo (CERN European Organization for Nuclear Research)
Published
2026-08-17
DOI
https://doi.org/10.5281/zenodo.21974261
Primary Topic
Software Engineering Research
Type
preprint
Controls
|||
ALL TIME
JAN
FEB
MAR
APR
MAY
JUN
JUL
AUG
SEP
OCT
preprint

Source Transformation Integrity in Legacy COBOL Systems: A Static Analysis Approach to Detecting Format-Dependent Semantic Divergence

Luis Fidel Castellanos Diaz
Zenodo (CERN European Organization for Nuclear Research)
Software Engineering Research
preprint

Source Transformation Integrity in Legacy COBOL Systems: A Static Analysis Approach to Detecting Format-Dependent Semantic Divergence

Luis Fidel Castellanos Diaz
preprint en

Abstract

The compilation format flag for COBOL fixed-format source code is not stored in the source file — it lives in the build system, CI configuration, or operator invocation. When that flag changes, the positional semantics of column 7 (the indicator area) change with it: a comment under -fixed may become active code under -free, or the program may fail to compile entirely. We demonstrate this with a single unmodified file: compiled with cobc -fixed it executes and produces correct output; compiled with cobc -free (GnuCOBOL 3.1.2, same version) it produces ten compilation errors. We present cobol-shield, a static analysis toolkit that detects format boundary conditions before transformation occurs and classifies findings under a three-tier evidence framework. Validation against three open-source COBOL projects yields two confirmed findings with observable proof-of-concept outputs, a systemic defect in 25 of 29 IBM CICS modules, and a characterization of the false positive profile of each detection rule. All artifacts are publicly available at https://github.com/LuisCastellanos-dev/cobol-shield.

Zenodo (CERN European Organization for Nuclear Research)
AIR Worldwide (United Kingdom) (GB)
Peace, Justice and strong institutions
Software Engineering Research
AI Navigator

Ask Laika to Summarize, Analyze, and Connect papers live on the map.

Summarize Papers & Methodologies

Extract key findings, datasets, and comparative methods across publications.

Benchmark Rankings & Visual Analytics

Rank top research institutions, authors, funders, topics, and journals by Field-Weighted Citation Impact (FWCI) and paper volume with instant charts.

Connect Distant Disciplines

Bridge topological clusters on the map to find hidden collaborative intersections.

Source Transformation Integrity in Legacy COBOL Systems: A Static Analysis Approach to Detecting Format-Dependent Semantic Divergence — Luis Fidel Castellanos Diaz · Zenodo (CERN European Organization for Nuclear Research) (2026) | TGRS Research Map | TGRS