dev-vcs/trufflehog - 3.98.1 (bentoo)

Search

Install

Install this version:

emerge -a =dev-vcs/trufflehog-3.98.1

If this version is masked, you can unmask it using the autounmask tool or standard emerge options:

autounmask =dev-vcs/trufflehog-3.98.1

Or alternatively:

emerge --autounmask-write -a =dev-vcs/trufflehog-3.98.1

Package Information

Description:
Finds and verifies leaked credentials across git history and many sources
Homepage:
https://github.com/trufflesecurity/trufflehog
License:
AGPL-3 Apache-2.0 BSD BSD-2 CC0-1.0 ISC LGPL-3 MIT MPL-2.0 public-domain

Ebuild Details

Version EAPI Keywords Slot
3.98.1 8 ~amd64 ~arm64 0
View Raw Ebuild
# Copyright 1999-2026 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2

EAPI=8

inherit go-env go-module

DESCRIPTION="Finds and verifies leaked credentials across git history and many sources"
HOMEPAGE="https://github.com/trufflesecurity/trufflehog"
SRC_URI="https://github.com/trufflesecurity/trufflehog/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz"
# Vendored dependency tree, generated with `go mod vendor` and hosted by the
# overlay, so the build carries a checksum and needs no network.
# Regenerated for 3.98.1: go.mod bumped bubbletea, testify and ldap-verify.
# When a later release leaves go.mod/go.sum untouched, pin VENDOR_P to this
# version instead.
VENDOR_P="${P}"
SRC_URI+=" https://distfiles.obentoo.org/${VENDOR_P}-vendor.tar.xz"

LICENSE="AGPL-3"
# Dependent (bundled, statically linked) Go module licenses
LICENSE+=" Apache-2.0 BSD BSD-2 CC0-1.0 ISC LGPL-3 MIT MPL-2.0 public-domain"
SLOT="0"
KEYWORDS="~amd64 ~arm64"

BDEPEND=">=dev-lang/go-1.25"

# The suite reaches live credential-verification endpoints.
RESTRICT="test"

# go-module_src_unpack runs `go mod verify` (network) unless ${S}/vendor
# exists right after unpack; when VENDOR_P != P the tarball lands elsewhere,
# so move it in before that check instead of in src_prepare.
src_unpack() {
	default
	if [[ ${VENDOR_P} != ${P} ]]; then
		mv "${WORKDIR}/${VENDOR_P}/vendor" "${S}/" || die
	fi
	go-env_set_compile_environment
}

src_compile() {
	local version_pkg="github.com/trufflesecurity/trufflehog/v3/pkg/version"
	local go_ldflags=(
		-X "${version_pkg}.BuildVersion=${PV}"
	)
	ego build -trimpath -ldflags "${go_ldflags[*]}" -o trufflehog .
}

src_install() {
	dobin trufflehog
	einstalldocs
}

Inherited Eclasses

Dependencies

BDEPEND

>=dev-lang/go-1.25

Manifest for 3.98.1

Type File Size Source URLs
DIST trufflehog-3.98.1-vendor.tar.xz 14417980 bytes https://distfiles.obentoo.org/trufflehog-3.98.1-vendor.tar.xz
DIST trufflehog-3.98.1.tar.gz 6332020 bytes https://github.com/trufflesecurity/trufflehog/archive/refs/tags/v3.98.1.tar.gz