# awnumar/memguard

Software sandbox for storage of sensitive information in memory.

Repository: https://github.com/awnumar/memguard
Canonical: https://ross.abutalabs.com/products/memguard
Language: Go
License: Apache-2.0
License Family: permissive
Topics: security, golang, go, cryptography, memory, crypto
Last push: 2026-05-08T16:37:08+00:00

## Health v2 (maintenance only)
Score: 72/100 (v2, computed 2026-09-03T02:20:16.233290+00:00)
- activity 81, release rhythm 45, longevity 100
- inputs: {"age_days": 3420, "days_push": 117, "days_rel": 371, "gap_med": 0, "n_releases_24m": 2}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 2756, forks 135 (observed 2026-08-28T04:07:18.192712+00:00)

## What it is
MemGuard is a pure Go library that securely stores sensitive information in memory, encrypting it with XSalsa20Poly1305 and bypassing the garbage collector via direct system calls. It adds guard pages, canary values, memory locking, and constant-time operations to reduce exposure of secrets like keys and passwords.

## Use cases
- store encryption keys securely in memory in a Go application
- prevent secrets from being swapped to disk
- protect passwords from cold-boot attacks
- avoid garbage collector leaking sensitive buffers
- safely wipe secrets when a session ends
- detect buffer overflows touching sensitive data

## When to choose
- you write Go software handling keys, tokens, or passwords
- you need defense-in-depth against memory disclosure and core dumps
- you want a pure-Go, cross-platform secret storage enclave

## When to avoid
- your language is not Go
- you only need secrets at rest on disk (use a secrets manager or vault)
- you need a full HSM or hardware-backed key store

## Facets
- artifact type: library
- maturity: active
- function: security, cryptography, secrets-management
- domain: security, privacy, developer-tools
- platform: go, windows, cross-platform
- tags: memory-security, sensitive-data, guard-pages, cold-boot-attack, pure-go, linux, macos

## Member repositories
- awnumar/memguard (main) score 72

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:07:18.192712+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T08:18:50.410696+00:00, confidence not recorded.
  - readme: https://github.com/awnumar/memguard (fetched 2026-08-28T04:07:18.192712+00:00, sha c5ff2e1df662)
- Data as of 2026-08-30T08:39:29.467469+00:00.
