Skip to content

Missing SPDX License Identifier

SAFE-0256 Best Practice Checked automatically by the scanner
1

What goes wrong

The source has no SPDX-License-Identifier. Beyond a compiler warning, it signals loose hygiene and complicates verification and reuse; auditors treat missing metadata as a smell.

2

The vulnerable pattern

proof of concept — how it is exploited
// solc emits: Warning: SPDX license identifier not provided
// verification tooling and downstream reuse become ambiguous.
3

How to fix it

the pattern that is safe
// SPDX-License-Identifier: MIT
Add an SPDX identifier at the top of every file.
4

Where this has happened

Largest recorded losses in the same failure class — related, not the same bug:

Check your own contract for this

The SaferICO scanner runs 201 detectors over your Solidity source, SAFE-0256 among them. Paste an address or the source itself — a small per-scan fee, shown before you sign, or unlimited on any plan.

Run the scanner See how it is attacked Read the docs