github.com/devseccon/trivy@v0.47.1-0.20231123133102-bd902a0bd996/pkg/fanal/types/const.go (about)

     1  package types
     2  
     3  type (
     4  	// TargetType represents the type of target
     5  	TargetType string
     6  
     7  	// OSType is an alias of TargetType for operating systems
     8  	OSType = TargetType
     9  
    10  	// LangType is an alias of TargetType for programming languages
    11  	LangType = TargetType
    12  
    13  	// ConfigType is an alias of TargetType for configuration files
    14  	ConfigType = TargetType
    15  )
    16  
    17  const (
    18  	ArtifactJSONSchemaVersion = 1
    19  	BlobJSONSchemaVersion     = 2
    20  )
    21  
    22  // Operating systems
    23  const (
    24  	Alma               OSType = "alma"
    25  	Alpine             OSType = "alpine"
    26  	Amazon             OSType = "amazon"
    27  	CBLMariner         OSType = "cbl-mariner"
    28  	CentOS             OSType = "centos"
    29  	Chainguard         OSType = "chainguard"
    30  	Debian             OSType = "debian"
    31  	Fedora             OSType = "fedora"
    32  	OpenSUSE           OSType = "opensuse"
    33  	OpenSUSELeap       OSType = "opensuse.leap"
    34  	OpenSUSETumbleweed OSType = "opensuse.tumbleweed"
    35  	Oracle             OSType = "oracle"
    36  	Photon             OSType = "photon"
    37  	RedHat             OSType = "redhat"
    38  	Rocky              OSType = "rocky"
    39  	SLES               OSType = "suse linux enterprise server"
    40  	Ubuntu             OSType = "ubuntu"
    41  	Wolfi              OSType = "wolfi"
    42  )
    43  
    44  // Programming language dependencies
    45  const (
    46  	Bundler    LangType = "bundler"
    47  	GemSpec    LangType = "gemspec"
    48  	Cargo      LangType = "cargo"
    49  	Composer   LangType = "composer"
    50  	Npm        LangType = "npm"
    51  	NuGet      LangType = "nuget"
    52  	DotNetCore LangType = "dotnet-core"
    53  	Pip        LangType = "pip"
    54  	Pipenv     LangType = "pipenv"
    55  	Poetry     LangType = "poetry"
    56  	CondaPkg   LangType = "conda-pkg"
    57  	PythonPkg  LangType = "python-pkg"
    58  	NodePkg    LangType = "node-pkg"
    59  	Yarn       LangType = "yarn"
    60  	Pnpm       LangType = "pnpm"
    61  	Jar        LangType = "jar"
    62  	Pom        LangType = "pom"
    63  	Gradle     LangType = "gradle"
    64  	GoBinary   LangType = "gobinary"
    65  	GoModule   LangType = "gomod"
    66  	JavaScript LangType = "javascript"
    67  	RustBinary LangType = "rustbinary"
    68  	Conan      LangType = "conan"
    69  	Cocoapods  LangType = "cocoapods"
    70  	Swift      LangType = "swift"
    71  	Pub        LangType = "pub"
    72  	Hex        LangType = "hex"
    73  	Bitnami    LangType = "bitnami"
    74  
    75  	K8sUpstream LangType = "kubernetes"
    76  	EKS         LangType = "eks" // Amazon Elastic Kubernetes Service
    77  	GKE         LangType = "gke" // Google Kubernetes Engine
    78  	AKS         LangType = "aks" // Azure Kubernetes Service
    79  	RKE         LangType = "rke" // Rancher Kubernetes Engine
    80  	OCP         LangType = "ocp" // Red Hat OpenShift Container Platform
    81  )
    82  
    83  // Config files
    84  const (
    85  	JSON           ConfigType = "json"
    86  	Dockerfile     ConfigType = "dockerfile"
    87  	Terraform      ConfigType = "terraform"
    88  	TerraformPlan  ConfigType = "terraformplan"
    89  	CloudFormation ConfigType = "cloudformation"
    90  	Kubernetes     ConfigType = "kubernetes"
    91  	Helm           ConfigType = "helm"
    92  	Cloud          ConfigType = "cloud"
    93  	AzureARM       ConfigType = "azure-arm"
    94  )
    95  
    96  // Language-specific file names
    97  const (
    98  	NuGetPkgsLock   = "packages.lock.json"
    99  	NuGetPkgsConfig = "packages.config"
   100  
   101  	GoMod = "go.mod"
   102  	GoSum = "go.sum"
   103  
   104  	MavenPom = "pom.xml"
   105  
   106  	NpmPkg     = "package.json"
   107  	NpmPkgLock = "package-lock.json"
   108  	YarnLock   = "yarn.lock"
   109  	PnpmLock   = "pnpm-lock.yaml"
   110  
   111  	ComposerLock = "composer.lock"
   112  	ComposerJson = "composer.json"
   113  
   114  	PyProject       = "pyproject.toml"
   115  	PipRequirements = "requirements.txt"
   116  	PipfileLock     = "Pipfile.lock"
   117  	PoetryLock      = "poetry.lock"
   118  
   119  	GemfileLock = "Gemfile.lock"
   120  
   121  	CargoLock = "Cargo.lock"
   122  	CargoToml = "Cargo.toml"
   123  
   124  	ConanLock = "conan.lock"
   125  
   126  	CocoaPodsLock = "Podfile.lock"
   127  	SwiftResolved = "Package.resolved"
   128  
   129  	PubSpecLock = "pubspec.lock"
   130  
   131  	MixLock = "mix.lock"
   132  )