analyzershader

package
v0.6.0 Latest Latest
Warning

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

Go to latest
Published: Sep 22, 2026 License: AGPL-3.0, AGPL-3.0-or-later Imports: 10 Imported by: 0

Documentation

Overview

Package analyzershader is an unregistered, admission-candidate-only shader extractor. It accepts immutable caller bytes and deliberately has no ambient filesystem, process, network, compiler, or dynamic-loader dependency.

Index

Constants

View Source
const (
	Profile     = "corvint-analyzer-candidate/experimental"
	Family      = "shader"
	CEMOCMState = "UNSUPPORTED"
)

Variables

This section is empty.

Functions

func Analyze

func Analyze(frame []byte) []byte

Analyze accepts exactly one canonical JSON/LF frame and emits exactly one canonical JSON/LF frame. It is pure: all data used is reachable from frame.

Types

type Echo

type Echo struct {
	Handle string `json:"handle"`
	SHA256 string `json:"sha256"`
}

type Fact

type Fact struct {
	Kind           string `json:"kind"`
	InputHandle    string `json:"input_handle"`
	RelatedHandle  string `json:"related_handle"`
	Subject        string `json:"subject"`
	Predicate      string `json:"predicate"`
	Value          string `json:"value"`
	InstanceID     string `json:"instance_id"`
	Span           Span   `json:"span"`
	WitnessBase64  string `json:"witness_base64"`
	WitnessSHA256  string `json:"witness_sha256"`
	EvidenceSHA256 string `json:"evidence_sha256"`
}

type Input

type Input struct {
	Handle        string `json:"handle"`
	Family        string `json:"family"`
	Path          string `json:"path"`
	SHA256        string `json:"sha256"`
	ContentBase64 string `json:"content_base64"`
}

type Position

type Position struct {
	Byte   uint32 `json:"byte"`
	Line   uint32 `json:"line"`
	Column uint32 `json:"column"`
}

type Request

type Request struct {
	Profile           string  `json:"profile"`
	Family            string  `json:"family"`
	ShaderProfile     string  `json:"shader_profile"`
	ShaderLanguage    string  `json:"shader_language"`
	ShaderVersion     string  `json:"shader_version"`
	ShaderToolchain   string  `json:"shader_toolchain"`
	RequestID         string  `json:"request_id"`
	ScopeID           string  `json:"scope_id"`
	CompilationUnitID string  `json:"compilation_unit_id"`
	Target            Target  `json:"target"`
	Inputs            []Input `json:"inputs"`
}

type Span

type Span struct {
	Start Position `json:"start"`
	End   Position `json:"end"`
}

type Target

type Target struct {
	OS           string   `json:"os"`
	Architecture string   `json:"architecture"`
	ABI          string   `json:"abi"`
	Features     []string `json:"features"`
}

Jump to

Keyboard shortcuts

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