diff options
Diffstat (limited to 'CLAUDE.md')
| -rw-r--r-- | CLAUDE.md | 84 |
1 files changed, 16 insertions, 68 deletions
@@ -32,81 +32,29 @@ Each package lives in its own top-level subfolder: Packages in this repo fall into several categories — the SlackBuild style differs accordingly. -### 1. Source builds (Go) +### 1. Source builds (Python) -Packages such as `ffuf`, `gobuster`, `nuclei` are built from upstream source -tarballs using `go build`. Key points: - -- Set `GOPATH`, `GOPROXY`, `GOFLAGS` before building -- Use `-buildmode=pie -trimpath -mod=readonly -modcacherw` -- Strip ELF binaries after build -- Clean up `$GOPATH` / Go module cache before packaging -- `REQUIRES="google-go-lang"` in the `.info` file +Packages such as `netexec` are built from upstream source using the Python +build backend (see `~/Templates/SlackBuilds/python-template.SlackBuild`). ### 2. Source builds (autotools / cmake) -Packages such as `hydra`, `cadaver` are built from source using `./configure` -or `cmake`. Follow standard SBo template conventions. - -### 3. Binary repacks — Debian `.deb` - -Packages such as `metasploit-framework-bin` are repacked from upstream `.deb` -archives (SBo convention: `.deb`/binary repacks take a `-bin` suffix): - -- Extract with: `ar p <file>.deb data.tar.gz | tar xzv` -- Set `DOWNLOAD="UNSUPPORTED"` and use `DOWNLOAD_x86_64` / `MD5SUM_x86_64` -- These packages are x86_64 only; exit with an error for other arches -- Strip ELF binaries after extraction - -#### `metasploit-framework-bin`: msfvenom bash-completion - -The shipped `msfvenom.bash-completion` is a **pre-generated snapshot**, not a -static file. Upstream (kali) no longer ships it; they generate it at build -time with a ruby script that loads the framework and dumps the live -payload/encoder/arch/platform/format lists. We ship a snapshot instead of -running ruby at build time (hermetic build, no build-time dep). - -**Regenerate it on every version bump.** After building and installing the -new package so `/opt/metasploit-framework` is live, pull the current -generator and run it against the installed framework's bundled ruby: - -```bash -curl -o /tmp/gen.rb \ - https://gitlab.com/kalilinux/packages/metasploit-framework/-/raw/kali/master/debian/generate-msfvenom-bash-completion.rb -/opt/metasploit-framework/embedded/bin/ruby \ - -I/opt/metasploit-framework/embedded/framework/lib /tmp/gen.rb \ - > metasploit-framework-bin/msfvenom.bash-completion -``` - -Verify the output is non-empty and the `%s` slots were filled (grep for real -payload names like `windows/meterpreter`), then commit it with the bump. - -#### `metasploit-framework-bin`: man pages - -The .deb ships **no** metasploit man pages (its `share/man` tree is only for -bundled deps like postgres/ruby). We ship `msfconsole.1` and `msfvenom.1` -from kali, who maintain them by hand (no generator script). The SlackBuild -gzips them into `/usr/man/man1`. **Refresh them on version bumps** in case -kali has updated them: - -```bash -for p in msfconsole msfvenom ; do - curl -o metasploit-framework-bin/$p.1 \ - https://gitlab.com/kalilinux/packages/metasploit-framework/-/raw/kali/master/debian/extra/$p.1 -done -``` - -### 4. Binary repacks — RPM - -Packages such as `nessus` are repacked from upstream `.rpm` archives: +Packages such as `cadaver` are built from source using `./configure` or +`cmake`. Follow standard SBo template conventions. -- Extract with: `rpm2cpio <file>.rpm | cpio -idmv` -- Set `DOWNLOAD="UNSUPPORTED"` and use `DOWNLOAD_x86_64` / `MD5SUM_x86_64` +### 3. Data / archive packages -### 5. Data / archive packages +Packages such as `webshells`, `windows-binaries` install data files rather +than compiled binaries. No stripping needed. -Packages such as `SecLists`, `exploitdb`, `webshells`, `windows-binaries` -install data files rather than compiled binaries. No stripping needed. +> Several packages that used to live here (the Go builds `ffuf`/`gobuster`/ +> `nuclei`, the Rust build `feroxbuster`, the `.deb` repack +> `metasploit-framework-bin`, and the data packages `SecLists`/`exploitdb`) +> are now danix-official on SlackBuilds.org and maintained in the separate +> [sbo-slackbuilds](https://github.com/danixland/sbo-slackbuilds) repo. Their +> build strategies (Go/Rust source builds, `.deb` repack, the metasploit +> msfvenom-completion and man-page regeneration) are documented in that repo's +> `CLAUDE.md`. --- |
