Skip to content

Commit 7496bd6

Browse files
chore: update TestAPI spec to include Reachability evidence and path (#382)
1 parent cdd02bd commit 7496bd6

File tree

3 files changed

+130
-2
lines changed

3 files changed

+130
-2
lines changed
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
2025-06-10T15:14:12Z main 2aa850323f50687fbb96ed4a7f76151d339e1206
1+
2025-07-15T16:03:28Z main cfb74bfba29b6c71eb0b8a0870d5c7c1b004f0a6

pkg/apiclients/testapi/2024-10-15/spec.yaml

Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -450,10 +450,12 @@ components:
450450
dependency_path: '#/components/schemas/DependencyPathEvidence'
451451
execution_flow: '#/components/schemas/ExecutionFlowEvidence'
452452
other: '#/components/schemas/OtherEvidence'
453+
reachability: '#/components/schemas/ReachabilityEvidence'
453454
propertyName: source
454455
oneOf:
455456
- $ref: '#/components/schemas/DependencyPathEvidence'
456457
- $ref: '#/components/schemas/ExecutionFlowEvidence'
458+
- $ref: '#/components/schemas/ReachabilityEvidence'
457459
- $ref: '#/components/schemas/OtherEvidence'
458460
ExecutionFlowEvidence:
459461
description: Indicate a program flow of execution as additional evidence for
@@ -1217,6 +1219,58 @@ components:
12171219
required:
12181220
- severity
12191221
type: object
1222+
ReachabilityEvidence:
1223+
description: Indicate the reachability signals as additional evidence for the
1224+
finding.
1225+
properties:
1226+
paths:
1227+
description: |-
1228+
Sequence of locations within this flow of execution.
1229+
1230+
For example, a sequence of locations connecting the "source" location
1231+
where input data is obtained, to a "sink" location where it is used.
1232+
items:
1233+
$ref: '#/components/schemas/ReachablePath'
1234+
minItems: 1
1235+
type: array
1236+
reachability:
1237+
$ref: '#/components/schemas/ReachabilityType'
1238+
source:
1239+
enum:
1240+
- reachability
1241+
type: string
1242+
required:
1243+
- source
1244+
- paths
1245+
- reachability
1246+
type: object
1247+
ReachabilityType:
1248+
description: Reachability enum for reachability signal.
1249+
enum:
1250+
- none
1251+
- function
1252+
- no_info
1253+
- not_applicable
1254+
type: string
1255+
ReachablePath:
1256+
description: ReachablePath represents the paths to a vulnerable function.
1257+
properties:
1258+
call_paths:
1259+
description: Paths in code bundle that call the vulnerable function.
1260+
items:
1261+
type: string
1262+
type: array
1263+
function_name:
1264+
description: Vulnerable function name.
1265+
type: string
1266+
location:
1267+
allOf:
1268+
- $ref: '#/components/schemas/FileRegion'
1269+
description: Location in a file where the vulnerability can be found.
1270+
required:
1271+
- function_name
1272+
- call_paths
1273+
type: object
12201274
Risk:
12211275
description: Risk represents Snyk's risk assessment of a finding.
12221276
properties:

pkg/apiclients/testapi/testapi.gen.go

Lines changed: 75 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)