Skip to content

Commit 31582fc

Browse files
committed
Add api schema and changelog for looking vulnerabilities from CPE
Signed-off-by: Tushar Goel <tushar.goel.dav@gmail.com>
1 parent 55aee23 commit 31582fc

2 files changed

Lines changed: 44 additions & 1 deletion

File tree

CHANGELOG.rst

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,8 @@ Version v30.0.0
1919

2020
- Add support for nix as a Linux deployemnet target.
2121

22+
- Lookup vulnerabilities from CPE
23+
2224

2325

2426
Version v20.10

vulnerablecode/static/api_doc/api_schema.yaml

Lines changed: 42 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,6 +77,47 @@ paths:
7777
schema:
7878
$ref: '#/components/schemas/Package'
7979
description: ''
80+
/api/cpes/:
81+
get:
82+
operationId: cpes_list
83+
description: ''
84+
tags:
85+
- cpe
86+
security:
87+
- cookieAuth: []
88+
- basicAuth: []
89+
- {}
90+
responses:
91+
'200':
92+
content:
93+
application/json:
94+
schema:
95+
$ref: '#/components/schemas/PaginatedPackageList'
96+
description: ''
97+
/api/cpes?cpe={cpe}:
98+
get:
99+
operationId: cpes_retrieve
100+
description: ''
101+
parameters:
102+
- in: path
103+
name: cpe
104+
schema:
105+
type: string
106+
description: A CPE, more info on CPE can be found here https://nvd.nist.gov/products/cpe
107+
required: true
108+
tags:
109+
- cpe
110+
security:
111+
- cookieAuth: []
112+
- basicAuth: []
113+
- {}
114+
responses:
115+
'200':
116+
content:
117+
application/json:
118+
schema:
119+
$ref: '#/components/schemas/Package'
120+
description: ''
80121
/api/packages/bulk_search/:
81122
post:
82123
operationId: packages_bulk_search
@@ -420,4 +461,4 @@ components:
420461
cookieAuth:
421462
type: apiKey
422463
in: cookie
423-
name: Session
464+
name: Session

0 commit comments

Comments
 (0)