Anti-AIClone

Log date · Wed

Can stripping symbols hide C++ STL logic?

Stripping removes names, not necessarily logic. We compare a C++ sample and explain what the STILL paper measured.

Can stripping hide C++ container logic?

Stripping symbols alone does not establish that C++ logic is hidden. We compared the same sample before and after stripping: matches for the target function symbol fell from one to zero, both programs printed 32, and the text-section hexadecimal output was identical line for line. The name disappeared while the executable instructions remained.

The STILL paper submitted on August 26, 2026 investigates predicting STL container semantics from stripped control-flow graphs and using hints to assist decompilation. [1] Our experiment illustrates the underlying issue with system tools; it is not a test of STILL or a reproduction of the paper’s results.

Results at a glance
QuestionFinding
Target function symbolOne match before stripping; zero after
Runtime resultBoth print total=32
Code sectionotool text-section hex output matches
Paper reports28.4% with hints; 17.4% without; 8.9% raw Ghidra

Sample and comparison

We wrote a vector<int> summation function that adds only values greater than 10. Its inputs are 4, 12 and 20, so the result is 32. Apple clang 21.0.0 compiled it with -O1 on arm64 macOS. We copied the executable and used the system strip -u -r on the copy, retaining the original for comparison. This test does not cover a complete application or other architectures.

Sample function; the complete source also has a noinline attribute and entry point.
int total(const std::vector<int>& v) {
    int result = 0;
    for (int x : v) if (x > 10) result += x;
    return result;
}

We ran both files, searched nm output for the target’s mangled name and compared otool -t output. The comparison covers the text section, not the entire binary; changing the symbol table itself changes the file. Clang documents optimization options that affect generated code, so use your actual release configuration when assessing a product. [2]

Verbatim transcript; the check compares text-section hexadecimal output.
== behavior ==
total=32
total=32
== total symbol matches ==
before: 1
after: 0
== text section hex output ==
text section output: identical

What the instructions retain

In the original file, the function name helps locate the instructions below; the stripped copy retains the same text-section instructions. They include a load, comparison with 10, conditional selection, addition and a loop branch. With the source in hand, these map readily to our sample. This fragment alone does not prove the container was a vector or recover the original variable names.

Excerpt from otool on the original; addresses and instructions depend on the build.
00000001000004f8	ldr	w10, [x8], #0x4
00000001000004fc	cmp	w10, #0xa
0000000100000500	csel	w10, w10, wzr, gt
0000000100000504	add	w0, w10, w0
0000000100000508	cmp	x8, x9
000000010000050c	b.ne	0x1000004f8

Disassembly displays machine instructions; decompilation tries to express them at a higher level. LLVM’s objdump documentation similarly distinguishes disassembling executable sections from displaying a symbol table. [3] Both are starting points for review, but readable output still needs contextual verification: a plausible inferred type is not automatically a source-code fact.

How to read the STILL result

Xiaohan Wang and Kevin Leach submitted STILL v1 at 21:20 UTC on 2026-08-26. The paper predicts function-level container semantics and renders them as compact hints for a downstream LLM. It evaluates semantic prediction on StlBench and hint utility on stripped HumanEval decompilation. [1] These evaluations answer different questions.

The paper reports executability of 28.4% for DeepSeek-chat with hints, 17.4% without hints and 8.9% for raw Ghidra output. The hinted result is 11 percentage points above the no-hint result; that is not an 11% relative increase. The authors also say hint utility depends on the downstream model. At 28.4%, most functions in that evaluation still did not meet the executability criterion; the result does not establish automatic reconstruction of an entire native library.

The distinction matters: our comparison shows what survives stripping in one sample; the paper trains and evaluates semantic prediction on datasets and measures the effect of hints on model output. Since we did not run its system, neither our 32 nor the symbol count can estimate its accuracy.

Recommendations by situation

These are engineering recommendations, not protection benefits measured by our experiment. Inventory the assets that matter first, then decide which logic must run on the client.

Recommendations by boundary
QuestionFinding
Release buildKeep the stripping baseline and matching symbol files; verify crash diagnosis.
High-value algorithmAssess server-side execution against latency and offline costs.
Keys and authorizationDo not rely on native-code obscurity for shared privileged keys or final authorization decisions.
Extra code processingCompare readability, performance, compatibility and diagnostics against the same release configuration.

Moving work to a server is not always practical: offline operation, latency and cost may require some logic on the device. Make those constraints explicit, then combine client review with server-side access controls. When evaluating additional processing, record build configuration and test results so a changed optimization level is not mistaken for an effect of the added measure.

Check your own application

Keep a read-only reference copy of your own macOS release artifact and record compiler version, architecture, optimization and stripping settings. The commands below inspect an existing artifact without modifying it; replace the path with a Mach-O file you are authorized to review. Tools and output differ by platform and file format.

Inspect your own release file on macOS; output can be long.
clang++ --version
nm path/to/your-release
otool -tvV path/to/your-release

Choose known important flows and compare visible symbols, constants, loops and call clues with the source. Record both findings and uncertainty. Do not rely only on a symbol count: it does not measure the work needed to understand logic or establish that no information is exposed. Keep the review scope consistent across versions, and retain internal findings and debug symbols under your team’s policy.

Finally exercise critical paths on test devices and verify that crash reports resolve using the symbol files for the matching build. Repeat the inspection on the final delivered artifact when stripping, signing or other release steps change. A successful build and the output of a single sample cannot replace application regression tests.

Your checklist

  • Record architecture, optimization and stripping settings for the release.
  • Inventory high-value logic that must remain on the client.
  • Compare visible clues in your release artifact with its source.
  • Retain matching symbol files and verify crash diagnosis.
  • Retest critical flows and the final artifact after release process changes.

Primary sources

All sources and reproduction status ↗