root README self-sha256

self-sha256

A program that prints its own SHA-256 checksum

This program outputs the SHA-256 checksum of its own source code without tricks like reading from disk or from environment variables and without language-dependent features like introspection and interpreter functions.

To generate the data[] buffer from the source code, use stringify.vim (source it, make a selection, run the macro).

Usage

make bin/self-sha256
bin/self-sha256
sha256sum self-sha256.c