---
import Base from '../../layouts/Base.astro';
import SectionBanner from '../../components/SectionBanner.astro';
import RecordRow from '../../components/RecordRow.astro';
import Icon from '../../components/Icon.astro';
import { hackTricksBySection } from '../../lib/hacktricks';
import { url } from '../../lib/url';
const sections = await hackTricksBySection();
const totalPages = sections.reduce((total, section) => total + section.count, 0);
const sha = sections[0]?.items[0]?.data.sha ?? '';
const accents = ['gold', 'love', 'foam', 'pine', 'iris'];
---
<Base
title="HackTricks Library — DÆMON//SEC"
description="A searchable, attributed selection of HackTricks covering network services, web, Windows, Linux, and mobile pentesting."
>
<SectionBanner
n="05"
label="Adapted mirror · CC BY-NC 4.0"
title="HackTricks Library"
blurb="A broad on-site selection of HackTricks field references, searchable alongside the rest of the vault and linked back to every upstream source page."
accent="gold"
stats={[
{ label: 'Sections', value: String(sections.length).padStart(2, '0'), accent: true },
{ label: 'Pages', value: totalPages },
{ label: 'License', value: 'BY-NC' },
]}
/>
<div class="wrap">
<nav class="breadcrumb" style="margin-top:1.6rem;">
<a href={url('')}>~</a><span class="sep">/</span><span class="muted">hacktricks</span>
</nav>
<aside class="patt-credit corners" style="margin-top:1.4rem;--bracket:var(--gold);border-left-color:var(--gold);">
<span class="patt-badge" style="color:var(--gold);">adapted mirror</span>
<span class="patt-credit__text">
Adapted from HackTricks by Carlos Polop and contributors. GitBook wrappers and training banners are removed; links are rewritten for this site.
<span class="patt-lic">CC BY-NC 4.0 · non-commercial use only · <a href={url('credits')}>full attribution and license</a>{sha && <> · <code>{sha.slice(0, 7)}</code></>}</span>
</span>
<a class="patt-src" href="https://github.com/HackTricks-wiki/hacktricks" target="_blank" rel="noopener">
<Icon name="github" /> upstream
</a>
</aside>
<div class="index" style="margin-bottom:3rem;">
{sections.map((section, index) => (
<RecordRow
href={url(`hacktricks/section/${section.slug}`)}
n={String(index + 1).padStart(2, '0')}
title={section.title}
kind="HackTricks"
kindIcon="layers"
accent={accents[index % accents.length]}
meta={`${section.count} pages`}
/>
))}
</div>
</div>
</Base>