Help us shape the future of Go! Take the 2026 Go Developer Survey

scan

package
v1.0.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 2, 2026 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Overview

Package scan scans a response body that would go into git, as public, for personal data and credentials, as a reader of the repository would see it: a capture's responses and the bodies of a baseline in git alike.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Public

func Public(d *pii.Detector, headers [][2]string, body []byte) (findings []pii.Finding, unscanned string)

Public scans a body a record would put into git for personal data and credentials, as a reader of the repository would see it: decoded from its Content-Encoding (gzip, deflate), and from gzip whatever the headers say (a .gz file served as JSON). A text is scanned as UTF-8 (text): a textual content type, or UTF-8 without a type or as application/octet-stream; a spreadsheet (XLSX) part by part. Anything else (an image, a PDF, an archive, a text that cannot be read as UTF-8) cannot be scanned: unscanned says why, and the body is stored private like one with personal data. The headers are the record's (lower-case names).

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL