{
  "id": "fstar-lowstar",
  "name": "F* with Low* (KaRaMeL to C)",
  "aka": [
    "Low*",
    "LowStar",
    "KaRaMeL",
    "KReMLin"
  ],
  "summary": "Write low-level code in Low*, a C-like subset of F*, prove it safe and correct with F* and Z3, then compile it to readable C with KaRaMeL.",
  "use_if": [
    "You maintain or extend existing Low* code, such as HACL* cryptography or EverParse parsers.",
    "You need verified C that fits into an existing C code base, with memory safety, correctness and secret-independence proofs.",
    "You can work with an F* release from before April 2026, or the separate LowStar repository."
  ],
  "avoid_if": [
    "You are starting new low-level F* work; Low* was removed from F* in April 2026, and F* now ships Pulse as its built-in language for imperative code.",
    "Your code needs closures, recursive data types in C or concurrency; Low* targets sequential, first-order C-like code.",
    "You need the proof checked by a small proof kernel; F* relies on its type checker and Z3."
  ],
  "effort": "auto-active",
  "open": "open-source",
  "license": "Apache-2.0",
  "maintainers": [
    "Microsoft Research and the F* community"
  ],
  "links": {
    "homepage": "https://fstar-lang.org/",
    "repo": "https://github.com/FStarLang/LowStar",
    "docs": "https://fstarlang.github.io/lowstar/html/",
    "paper": "https://doi.org/10.1145/3110261",
    "tutorial": "https://fstarlang.github.io/lowstar/html/"
  },
  "components": [
    {
      "role": "frontend",
      "name": "F* parser and type checker",
      "assurance": "trusted",
      "note": "F* checks the same source it later extracts; there is no separate translator from another language."
    },
    {
      "role": "semantics",
      "name": "Low* libraries (HyperStack memory model, LowStar.Buffer)",
      "assurance": "trusted",
      "note": "Moved out of F* into the FStarLang/LowStar repository in 2026. The Low* language and its compilation to C are formalized on paper in the ICFP 2017 paper."
    },
    {
      "role": "translation",
      "name": "F* verification-condition generation (SMT encoding)",
      "assurance": "trusted"
    },
    {
      "role": "checker",
      "name": "Z3",
      "ref": "z3",
      "ref_kind": "prover",
      "assurance": "trusted"
    },
    {
      "role": "compiler",
      "name": "KaRaMeL (Low* to C), then a C compiler",
      "assurance": "trusted",
      "note": "KaRaMeL's translation has a paper proof relating Low* to CompCert's Clight; the tool itself is not verified."
    }
  ],
  "verifies": [
    {
      "target": "fstar",
      "note": "Code written in the Low* subset of F*; it is then compiled to C by KaRaMeL."
    }
  ],
  "properties": {
    "no-ub": {
      "status": "full",
      "note": "Low* code is proved memory safe (buffer bounds and liveness); HACL*'s README describes its code as verified for memory safety, functional correctness and secret independence.",
      "source": "https://github.com/hacl-star/hacl-star"
    },
    "functional": {
      "status": "full",
      "note": "Full functional specifications in F*; HACL* proves its code correct against mathematical specifications.",
      "source": "https://github.com/hacl-star/hacl-star"
    },
    "equivalence": {
      "status": "partial",
      "note": "No dedicated equivalence mode; you prove Low* code equal to a pure F* specification function by hand, which is how HACL* is structured."
    },
    "info-flow": {
      "status": "partial",
      "note": "HACL* proves secret independence (a defense against some timing side channels) by using abstract secret integer types in its libraries; this is a library discipline, not a built-in F* check.",
      "source": "https://github.com/hacl-star/hacl-star"
    },
    "concurrency": {
      "status": "none",
      "note": "Low* is for sequential, C-like code. F*'s Pulse language covers concurrency, but it is not part of Low*.",
      "source": "https://github.com/FStarLang/LowStar"
    },
    "termination": {
      "status": "full",
      "note": "F* proves that total functions terminate, using a measure that must decrease on each recursive call.",
      "source": "https://fstar-lang.org/tutorial/book/part1/part1_termination.html"
    }
  },
  "features": {
    "core.integers": {
      "status": "full",
      "note": "Machine integers are Low*'s base types, with both wrapping and checked operations.",
      "source": "https://fstarlang.github.io/lowstar/html/LowStar.html"
    },
    "core.floats": {
      "status": "unknown",
      "note": "Floating point is not mentioned in the Low* manual."
    },
    "core.heap": {
      "status": "full",
      "note": "Stack and heap allocation through the HyperStack memory model, with modifies clauses.",
      "source": "https://fstarlang.github.io/lowstar/html/LowStar.html"
    },
    "core.arrays": {
      "status": "full",
      "note": "Buffers with pointer arithmetic within bounds (LowStar.Buffer).",
      "source": "https://fstarlang.github.io/lowstar/html/LowStar.html"
    },
    "core.loops": {
      "status": "full",
      "note": "Ordinary control flow is supported; loops can be written as tail-recursive functions, which C compilers turn into loops.",
      "source": "https://fstarlang.github.io/lowstar/html/LowStar.html"
    },
    "core.recursion": {
      "status": "full",
      "note": "Recursive functions are allowed and compiled to C functions.",
      "source": "https://fstarlang.github.io/lowstar/html/LowStar.html"
    },
    "core.higher-order": {
      "status": "partial",
      "note": "Function pointers work to some extent; local closures are not supported because they have no natural C equivalent.",
      "source": "https://fstarlang.github.io/lowstar/html/LowStar.html"
    },
    "core.concurrency": {
      "status": "none",
      "note": "Low* covers sequential code only.",
      "source": "https://github.com/FStarLang/LowStar"
    },
    "core.io": {
      "status": "partial",
      "note": "C library functions are reached through Low* system libraries and assumed declarations, whose specifications are trusted.",
      "source": "https://fstarlang.github.io/lowstar/html/LowStar.html"
    },
    "core.stdlib": {
      "status": "partial",
      "note": "Low* libraries cover buffers, endianness, C strings and parts of the C standard library.",
      "source": "https://github.com/FStarLang/LowStar"
    }
  },
  "trust": {
    "checker": {
      "level": "amber",
      "summary": "F*'s type checker and the Z3 SMT solver decide; no small kernel, no proof certificates.",
      "source": "https://fstar-lang.org/tutorial/"
    },
    "semantics": {
      "level": "amber",
      "summary": "Low*'s memory model is a library inside F*; formalized on paper, not validated against C.",
      "source": "https://doi.org/10.1145/3110261"
    },
    "frontend": {
      "level": "green",
      "summary": "F* checks the same source it compiles; no separate translator is involved.",
      "source": "https://fstarlang.github.io/lowstar/html/LowStar.html"
    },
    "binary_gap": {
      "level": "red",
      "summary": "KaRaMeL (paper proof only) and the C compiler that builds the binary are not verified.",
      "source": "https://github.com/FStarLang/karamel"
    },
    "escape_hatches": {
      "level": "amber",
      "summary": "assume, admit and assume val skip proofs; found by searching the source.",
      "source": "https://fstar-lang.org/tutorial/book/part1/part1_prop_assertions.html"
    }
  },
  "stage_evidence": {
    "public_artifact": {
      "met": true,
      "evidence": "https://github.com/FStarLang/LowStar"
    },
    "published_use": {
      "met": true,
      "evidence": "https://doi.org/10.1145/3110261",
      "note": "Verified low-level programming embedded in F* (ICFP 2017); HACL* and EverCrypt are built with it."
    },
    "installs_on_current": {
      "met": true,
      "evidence": "https://github.com/FStarLang/FStar/releases/tag/v2026.03.24",
      "note": "F* v2026.03.24 (Linux, macOS, Windows binaries) is the last F* release that includes Low*. F* removed Low* in April 2026 (pull request 4161); the libraries now live in the FStarLang/LowStar repository, which pins an older F* branch, and HACL* builds with a frozen F* version. Whether Low* works with current F* releases is not documented."
    },
    "user_docs": {
      "met": true,
      "evidence": "https://fstarlang.github.io/lowstar/html/"
    },
    "external_users": {
      "met": true,
      "evidence": "https://research-development.nomadic-labs.com/improving-the-implementation-of-cryptography-in-tezos-octez.html",
      "note": "Nomadic Labs integrated HACL* (Low* code) into the Tezos Octez implementation."
    },
    "soundness_channel": {
      "met": true,
      "evidence": "https://github.com/FStarLang/FStar/issues?q=label%3Akind%2Funsoundness",
      "note": "Public F* issues with a 'kind/unsoundness' label."
    }
  },
  "production_users": [
    {
      "org": "Mozilla",
      "what": "HACL* code (for example Curve25519, ChaCha20-Poly1305, SHA-3) in NSS, the cryptography library used by Firefox.",
      "source": "https://github.com/mozilla/nss/tree/master/lib/freebl/verified"
    },
    {
      "org": "Python (CPython)",
      "what": "HACL* code for the built-in SHA1, SHA2-384, SHA2-512, SHA3 and MD5 in hashlib since Python 3.12, used when OpenSSL does not provide them.",
      "source": "https://docs.python.org/3/whatsnew/3.12.html"
    }
  ],
  "last_release": {
    "version": "F* v2026.03.24 (last F* release with Low*)",
    "date": "2026-03-24",
    "source": "https://github.com/FStarLang/FStar/releases/tag/v2026.03.24"
  },
  "used_for": [
    {
      "name": "HACL* verified cryptographic library",
      "url": "https://github.com/hacl-star/hacl-star",
      "note": "In maintenance mode; builds with a frozen F* version from before Low* was removed."
    },
    {
      "name": "Curve25519 in the Linux kernel",
      "url": "https://github.com/torvalds/linux/blob/master/lib/crypto/curve25519-hacl64.c",
      "note": "Generated from HACL* and then tweaked by hand for the kernel."
    },
    {
      "name": "Tezos Octez cryptography",
      "url": "https://research-development.nomadic-labs.com/improving-the-implementation-of-cryptography-in-tezos-octez.html"
    }
  ],
  "last_checked": "2026-11-26",
  "attestation": "maintainer",
  "claimed_by_authors": false,
  "sources": [
    {
      "url": "https://github.com/FStarLang/FStar/pull/4161",
      "title": "Merge fstar2 into master (removes Low* and monotonic heap modules), April 2026",
      "accessed": "2026-11-26"
    },
    {
      "url": "https://github.com/FStarLang/LowStar",
      "title": "LowStar repository (Low* libraries moved out of F*)",
      "accessed": "2026-11-26"
    },
    {
      "url": "https://github.com/FStarLang/FStar/blob/master/README.md",
      "title": "F* README (Custard extraction, Pulse)",
      "accessed": "2026-11-26"
    },
    {
      "url": "https://github.com/FStarLang/karamel",
      "title": "KaRaMeL README",
      "accessed": "2026-11-26"
    },
    {
      "url": "https://fstarlang.github.io/lowstar/html/LowStar.html",
      "title": "The Low* subset of F*",
      "accessed": "2026-11-26"
    },
    {
      "url": "https://github.com/hacl-star/hacl-star",
      "title": "HACL* README (maintenance mode, frozen F*)",
      "accessed": "2026-11-26"
    },
    {
      "url": "https://fstar-lang.org/",
      "title": "F* homepage (F* in production)",
      "accessed": "2026-11-26"
    }
  ],
  "computed": {
    "kind": "toolchains",
    "methodology_version": "0.1",
    "built": "2026-11-26",
    "links": {
      "html": "/toolchains/fstar-lowstar/",
      "json": "/toolchains/fstar-lowstar.json",
      "markdown": "/toolchains/fstar-lowstar.md"
    },
    "stage": {
      "stage": 2,
      "name": "Production",
      "criteria": [
        {
          "key": "public_artifact",
          "stage": 0,
          "label": "Publicly available",
          "met": true,
          "evidence": "https://github.com/FStarLang/LowStar",
          "computed": false
        },
        {
          "key": "published_use",
          "stage": 0,
          "label": "At least one published verification uses it",
          "met": true,
          "evidence": "https://doi.org/10.1145/3110261",
          "note": "Verified low-level programming embedded in F* (ICFP 2017); HACL* and EverCrypt are built with it.",
          "computed": false
        },
        {
          "key": "recent_release",
          "stage": 1,
          "label": "Released or updated in the last 12 months",
          "met": true,
          "evidence": "https://github.com/FStarLang/FStar/releases/tag/v2026.03.24",
          "note": "Latest release: F* v2026.03.24 (last F* release with Low*), 2026-03-24.",
          "computed": true
        },
        {
          "key": "installs_on_current",
          "stage": 1,
          "label": "Installs and runs on current platforms",
          "met": true,
          "evidence": "https://github.com/FStarLang/FStar/releases/tag/v2026.03.24",
          "note": "F* v2026.03.24 (Linux, macOS, Windows binaries) is the last F* release that includes Low*. F* removed Low* in April 2026 (pull request 4161); the libraries now live in the FStarLang/LowStar repository, which pins an older F* branch, and HACL* builds with a frozen F* version. Whether Low* works with current F* releases is not documented.",
          "computed": false
        },
        {
          "key": "user_docs",
          "stage": 1,
          "label": "User documentation or tutorial",
          "met": true,
          "evidence": "https://fstarlang.github.io/lowstar/html/",
          "computed": false
        },
        {
          "key": "external_users",
          "stage": 1,
          "label": "Used by a group other than its authors",
          "met": true,
          "evidence": "https://research-development.nomadic-labs.com/improving-the-implementation-of-cryptography-in-tezos-octez.html",
          "note": "Nomadic Labs integrated HACL* (Low* code) into the Tezos Octez implementation.",
          "computed": false
        },
        {
          "key": "production_users",
          "stage": 2,
          "label": "Verified code in production at two or more independent organizations",
          "met": true,
          "note": "2 recorded: Mozilla, Python (CPython).",
          "computed": true
        },
        {
          "key": "checker_not_red",
          "stage": 2,
          "label": "Checker axis is not red",
          "met": true,
          "computed": true
        },
        {
          "key": "semantics_not_red",
          "stage": 2,
          "label": "Semantics axis is not red",
          "met": true,
          "computed": true
        },
        {
          "key": "soundness_channel",
          "stage": 2,
          "label": "Public channel for soundness bugs",
          "met": true,
          "evidence": "https://github.com/FStarLang/FStar/issues?q=label%3Akind%2Funsoundness",
          "note": "Public F* issues with a 'kind/unsoundness' label.",
          "computed": false
        }
      ],
      "missing_for_next": []
    }
  }
}