repositories

daemon-sec-lotl

DÆMONBins: GTFOBins × LOLBAS × WADComs × LOOBins in one filterable catalog

clonegit clone https://git.daemon-sec.xyz/daemon-sec-lotl.git
index.astroAstro249 lines10.2 KiBraw download
---
import Base from '../layouts/Base.astro';
import HeroDeck from '../components/HeroDeck.astro';
import Marquee from '../components/Marquee.astro';
import Callout from '../components/Callout.astro';
import SourcesFlow from '../components/SourcesFlow.astro';
import facets from '../data/facets.json';
import { SOURCES, SOURCE_META, SOURCE_ROUTE, PLATFORMS, PLATFORM_META } from '../lib/taxonomy';
import { url } from '../lib/url';
import { website, dataset } from '../lib/jsonld';
import allTechniques from '../data/techniques.json';
import type { Technique } from '../lib/techniques';
import { totalFacetCounts } from '../lib/render-row';
import { QUICK_STARTS, buildBreakdown, catalogHref, renderBreakdown } from '../lib/insights';

const c = facets.counts;

const marqueeTitles = [
  { n: 'NIX', title: 'GTFOBins', accent: 'foam' },
  { n: 'WIN', title: 'LOLBAS', accent: 'iris' },
  { n: 'AD', title: 'WADComs', accent: 'gold' },
  { n: 'MAC', title: 'LOOBins', accent: 'rose' },
  { n: 'DMN', title: 'DÆMON', accent: 'love' },
  { n: '01', title: 'SUID · sudo', accent: 'gold' },
  { n: '02', title: 'AWL Bypass', accent: 'iris' },
  { n: '03', title: 'ADCS · ESC', accent: 'gold' },
  { n: '04', title: 'Coercion', accent: 'love' },
];
const marqueeMeta = [
  { tag: 'gtfo', text: `${c.bySource.GTFOBins} techniques`, accent: 'foam' },
  { tag: 'lolbas', text: `${c.bySource.LOLBAS} techniques`, accent: 'iris' },
  { tag: 'wadcoms', text: `${c.bySource.WADComs} upstream`, accent: 'gold' },
  { tag: 'daemon', text: `${c.added} authored here`, accent: 'love' },
  { tag: 'mitre', text: 'ATT&CK mapped', accent: 'pine' },
  { tag: 'gpl', text: 'GPL-3.0', accent: 'rose' },
];

// The same panel the catalog draws, as links: every bar opens the catalog
// already narrowed to it.
const breakdown = buildBreakdown(totalFacetCounts(allTechniques as unknown as Technique[]), { left: ['context', 'source'], right: 'capability', limit: 8 });

const platformStats = PLATFORMS.filter((p) => c.byPlatform[p]).map((p) => ({
  label: p,
  accent: PLATFORM_META[p].accent,
  n: c.byPlatform[p],
}));
---
<Base
  title="DÆMONBins — the Off-the-Land Almanac"
  description="One filterable catalog merging GTFOBins, LOLBAS, WADComs and LOOBins — plus DÆMON additions. Living-off-the-land and offensive techniques by platform, access, environment and evidence state."
  jsonLd={[website(Astro.site), dataset(Astro.site, c, facets.commits)]}
>
  <HeroDeck />

  <Marquee titles={marqueeTitles} meta={marqueeMeta} manifest={`${c.techniques} techniques`} />

  <section class="home-platforms wrap">
    <h2 class="eyebrow" style="--acc: var(--foam);">
      <span class="eyebrow__n">01</span>
      <span class="eyebrow__mark">^:</span>
      <span>By platform</span>
      <span class="eyebrow__rule" aria-hidden="true"></span>
    </h2>
    <div class="home-platforms__grid">
      {platformStats.map((p) => (
        <a class="home-platstat" data-reveal href={catalogHref({ platform: [p.label] })} style={`--acc: var(--${p.accent});`} aria-label={`${p.n.toLocaleString()} ${p.label} techniques — open in the catalog`}>
          <b data-count={p.n}>{p.n.toLocaleString()}</b>
          <span>{p.label === 'ActiveDirectory' ? 'Active Directory' : p.label}</span>
          <i aria-hidden="true">Filter the catalog →</i>
        </a>
      ))}
    </div>
  </section>

  <section class="home-find wrap">
    <h2 class="eyebrow" style="--acc: var(--love);">
      <span class="eyebrow__n">02</span>
      <span class="eyebrow__mark">^:</span>
      <span>Start from what you have</span>
      <span class="eyebrow__rule" aria-hidden="true"></span>
    </h2>
    <nav class="quick home-find__quick" aria-label="Quick starts">
      <span class="quick__lbl">Quick starts</span>
      {QUICK_STARTS.map((q) => (
        <a class="quick__chip" href={catalogHref(q.filters)} style={`--acc: var(--${q.accent});`}>{q.label}</a>
      ))}
    </nav>
    <div class="bd" data-reveal style="--acc: var(--love);" set:html={renderBreakdown(breakdown, { mode: 'link', note: `All ${c.techniques.toLocaleString()} techniques. Every bar opens the catalog filtered to it.` })} />
  </section>

  <section class="home-sources wrap">
    <h2 class="eyebrow" style="--acc: var(--iris);">
      <span class="eyebrow__n">03</span>
      <span class="eyebrow__mark">^:</span>
      <span>The collections</span>
      <span class="eyebrow__rule" aria-hidden="true"></span>
    </h2>
    <div class="home-sources__grid">
      {SOURCES.map((id, i) => {
        const s = SOURCE_META[id];
        return (
          <a class="home-source" data-reveal href={url(SOURCE_ROUTE[id])} style={`--acc: var(--${s.accent});`}>
            <div class="home-source__top">
              <span class="home-source__tag">{String(i + 1).padStart(2, '0')} · {s.tag}</span>
              <span class="home-source__n">{c.bySource[id] ?? 0}</span>
            </div>
            <h3 class="home-source__name">{s.label}</h3>
            <p class="home-source__blurb">{s.blurb}</p>
            <span class="home-source__go">Browse {s.label} →</span>
          </a>
        );
      })}
    </div>
  </section>

  <section class="home-flow wrap">
    <h2 class="eyebrow" style="--acc: var(--love);">
      <span class="eyebrow__n">04</span>
      <span class="eyebrow__mark">^:</span>
      <span>How it is assembled</span>
      <span class="eyebrow__rule" aria-hidden="true"></span>
    </h2>
    <SourcesFlow />
  </section>

  <section class="home-scope wrap">
    <Callout tone="warning" label="Scope">
      Everything here is placeholder-only reference material — lab IPs, <code>test.local</code>,
      <code>john</code> / <code>password123</code> — in the same spirit as GTFOBins, LOLBAS, WADComs and
      MITRE ATT&CK. For authorized testing, CTFs, detection engineering and education only. Know your scope.
    </Callout>
    <p class="home-scope__cred">
      GTFOBins, LOLBAS, WADComs and LOOBins are GPL-3.0 projects; this merged work is GPL-3.0. See <a href={url('credits')}>credits &amp; licenses</a>.
    </p>
  </section>
</Base>

<style>
  /* The section eyebrows are h2s so the page outlines h1 → h2 → h3 for
     heading navigation; they keep the <p> eyebrow's metrics exactly. */
  h2.eyebrow { margin: 1em 0; font-weight: 400; }

  /* ---- How it is assembled: the sources diagram (SourcesFlow.astro) -------- */
  .home-flow { margin: clamp(2.6rem, 5vw, 4rem) auto 0; }

  /* ---- By platform -------------------------------------------------------- */
  .home-platforms { margin: clamp(2.6rem, 5vw, 4rem) auto 0; }
  .home-platforms__grid {
    margin-top: 1rem;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1px;
    background: var(--rule);
    border: 1px solid var(--rule);
  }
  @media (max-width: 560px) { .home-platforms__grid { grid-template-columns: repeat(2, 1fr); } }
  .home-platstat {
    display: block;
    background: var(--bg);
    padding: 1.4rem 1.2rem;
    border-top: 2px solid var(--acc);
    text-decoration: none;
    transition: background-color 200ms ease;
  }
  .home-platstat:hover, .home-platstat:focus-visible { background: color-mix(in srgb, var(--acc) 10%, var(--bg)); }
  .home-platstat i {
    display: block;
    margin-top: 0.7rem;
    font-family: var(--font-mono);
    font-style: normal;
    font-size: 10px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--acc);
    opacity: 0;
    transform: translateX(-4px);
    transition: opacity 200ms ease, transform 200ms var(--ease);
  }
  .home-platstat:hover i, .home-platstat:focus-visible i { opacity: 1; transform: none; }
  @media (hover: none) { .home-platstat i { opacity: 1; transform: none; } }

  /* ---- Start from what you have ------------------------------------------- */
  .home-find { margin: clamp(2.6rem, 5vw, 4rem) auto 0; }
  .home-find__quick { padding: 0.2rem 0 1.1rem; }
  .home-platstat b {
    display: block;
    font-family: var(--font-display);
    font-weight: 800;
    font-stretch: 84%;
    font-size: clamp(1.8rem, 4vw, 2.7rem);
    letter-spacing: -0.03em;
    line-height: 1;
    color: var(--acc);
    font-variant-numeric: tabular-nums;
  }
  .home-platstat span {
    display: block;
    margin-top: 0.4rem;
    font-family: var(--font-mono);
    font-size: 11px;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--fg-faint);
  }

  /* ---- The collections ---------------------------------------------------- */
  .home-sources { margin: clamp(2.6rem, 5vw, 4rem) auto 0; }
  .home-sources__grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1px;
    background: var(--rule);
    border: 1px solid var(--rule);
    margin-top: 1rem;
  }
  @media (max-width: 720px) { .home-sources__grid { grid-template-columns: 1fr; } }
  .home-source {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    padding: 1.5rem 1.5rem 1.4rem;
    background: var(--bg);
    text-decoration: none;
    color: var(--fg);
    position: relative;
  }
  .home-source::before {
    content: '';
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 3px;
    background: var(--acc);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 220ms var(--ease);
  }
  .home-source:hover::before { transform: scaleX(1); }
  .home-source__top { display: flex; align-items: center; justify-content: space-between; }
  .home-source__tag { font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--acc); }
  .home-source__n { font-family: var(--font-mono); font-size: 12px; color: var(--fg-faint); }
  .home-source__name { font-family: var(--font-display); font-weight: 800; font-stretch: 84%; text-transform: uppercase; letter-spacing: -0.02em; font-size: clamp(24px, 3.5vw, 34px); margin: 0; color: var(--fg); }
  .home-source__blurb { margin: 0; font-size: 13.5px; line-height: 1.55; color: var(--fg-dim); }
  .home-source__go { margin-top: auto; font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--acc); }

  /* ---- Scope -------------------------------------------------------------- */
  .home-scope { margin: clamp(2.6rem, 5vw, 4rem) auto 5rem; }
  .home-scope__cred { margin-top: 1rem; font-size: 13px; color: var(--fg-dim); }
  .home-scope__cred a { color: var(--accent); }
</style>