Skip to content

Commit 4a5ca3e

Browse files
Merge pull request #14 from fetsko/DEVPROD-15194/use-silkbomb-2.0
use Silkbomb 2.0
2 parents be1d596 + cc01d1d commit 4a5ca3e

File tree

7 files changed

+21
-116
lines changed

7 files changed

+21
-116
lines changed

etc/update-sbom.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ echo "pkg:github/mongodb/libmongocrypt@${LIBMONGOCRYPT_VERSION}" > $PURLS_FILE
1313

1414
# Use silkbomb to update the sbom.json file
1515
docker run --platform="linux/amd64" -it --rm -v ${ROOT_DIR}:/pwd \
16-
artifactory.corp.mongodb.com/release-tools-container-registry-public-local/silkbomb:1.0 \
16+
artifactory.corp.mongodb.com/release-tools-container-registry-public-local/silkbomb:2.0 \
1717
update --sbom-in /pwd/sbom.json --purls /pwd/purls.txt --sbom-out /pwd/sbom.json
1818

1919
rm $PURLS_FILE

ext/libmongocrypt/libmongocrypt/Earthfile

Lines changed: 10 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -461,7 +461,7 @@ sign:
461461
#
462462
# See https://docs.devprod.prod.corp.mongodb.com/mms/python/src/sbom/silkbomb/ for documentation of silkbomb.
463463
silkbomb:
464-
FROM artifactory.corp.mongodb.com/release-tools-container-registry-public-local/silkbomb:1.0
464+
FROM artifactory.corp.mongodb.com/release-tools-container-registry-public-local/silkbomb:2.0
465465
# Alias the silkbom executable to a simpler name:
466466
RUN ln -s /python/src/sbom/silkbomb/bin /usr/local/bin/silkbomb
467467

@@ -484,39 +484,24 @@ sbom-generate:
484484
# Save the result back to the host:
485485
SAVE ARTIFACT /s/cyclonedx.sbom.json AS LOCAL etc/cyclonedx.sbom.json
486486

487-
# sbom-download:
488-
# Download the Augmented SBOM file from Silk.
487+
# sbom-augment:
488+
# Augment the SBOM file with vulnerability information from Kondukto.
489489
#
490490
# See https://wiki.corp.mongodb.com/display/DRIVERS/Using+AWS+Secrets+Manager+to+Store+Testing+Secrets for instructions to get secrets from AWS Secrets Manager. Secrets are available under `drivers/libmongocrypt`.
491491
#
492-
sbom-download:
492+
sbom-augment:
493493
ARG --required out
494494
ARG --required branch
495495
FROM +silkbomb
496496
WORKDIR /s
497+
COPY etc/cyclonedx.sbom.json /s/
497498
# Download the Augmented SBOM file:
498-
RUN --no-cache --secret silk_client_id --secret silk_client_secret \
499-
SILK_CLIENT_ID=${silk_client_id} \
500-
SILK_CLIENT_SECRET=${silk_client_secret} \
501-
silkbomb download \
499+
RUN --no-cache --secret kondukto_token KONDUKTO_TOKEN=${kondukto_token} \
500+
silkbomb augment \
501+
--sbom-in cyclonedx.sbom.json \
502502
--sbom-out cyclonedx.augmented.sbom.json \
503-
--silk-asset-group libmongocrypt-${branch}
503+
--repo mongodb/libmongocrypt-helper-ruby \
504+
--branch ${branch}
504505
# Save the result back to the host:
505506
SAVE ARTIFACT /s/cyclonedx.augmented.sbom.json AS LOCAL ${out}
506507
RUN echo "Augmented SBOM saved to ${out}"
507-
508-
# silk-create-asset-group:
509-
# Create an asset group for Silk.
510-
#
511-
# See https://wiki.corp.mongodb.com/display/DRIVERS/Using+AWS+Secrets+Manager+to+Store+Testing+Secrets for instructions to get secrets from AWS Secrets Manager. Secrets are available under `drivers/libmongocrypt`.
512-
#
513-
silk-create-asset-group:
514-
ARG --required branch
515-
FROM +env.alpine
516-
RUN __install curl jq
517-
COPY etc/silk-create-asset-group.sh /s/silk-create-asset-group.sh
518-
RUN --no-cache --secret silk_client_id --secret silk_client_secret \
519-
silk_client_id=${silk_client_id} \
520-
silk_client_secret=${silk_client_secret} \
521-
branch=${branch} \
522-
/s/silk-create-asset-group.sh

ext/libmongocrypt/libmongocrypt/bindings/python/update-sbom.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,5 +10,5 @@ else
1010
fi
1111

1212
echo "pkg:github/mongodb/libmongocrypt@$LIBMONGOCRYPT_VERSION" > purls.txt
13-
$DOCKER run --platform="linux/amd64" -it --rm -v $(pwd):$(pwd) artifactory.corp.mongodb.com/release-tools-container-registry-public-local/silkbomb:1.0 update --purls=$(pwd)/purls.txt -o $(pwd)/sbom.json
13+
$DOCKER run --platform="linux/amd64" -it --rm -v $(pwd):$(pwd) artifactory.corp.mongodb.com/release-tools-container-registry-public-local/silkbomb:2.0 update --purls=$(pwd)/purls.txt -o $(pwd)/sbom.json
1414
rm purls.txt

ext/libmongocrypt/libmongocrypt/doc/releasing.md

Lines changed: 7 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ Version numbers of libmongocrypt must follow the format 1.[0-9].[0-9] for releas
99

1010
### Check for Vulnerabilities
1111

12-
Snyk and Silk are used to satisfy vulnerability scanning requirements of [DRIVERS-714](https://jira.mongodb.org/browse/DRIVERS-714). Prior to releasing, ensure necessary reported vulnerabilities meet requirements described in: [MongoDB Software Security Development Lifecycle Policy](https://docs.google.com/document/d/1u0m4Kj2Ny30zU74KoEFCN4L6D_FbEYCaJ3CQdCYXTMc/edit?tab=t.0#bookmark=id.l09k96qt24jm).
12+
Snyk and Kondukto are used to satisfy vulnerability scanning requirements of [DRIVERS-714](https://jira.mongodb.org/browse/DRIVERS-714). Prior to releasing, ensure necessary reported vulnerabilities meet requirements described in: [MongoDB Software Security Development Lifecycle Policy](https://docs.google.com/document/d/1u0m4Kj2Ny30zU74KoEFCN4L6D_FbEYCaJ3CQdCYXTMc/edit?tab=t.0#bookmark=id.l09k96qt24jm).
1313

1414
#### Check Snyk
1515

@@ -44,16 +44,15 @@ snyk monitor \
4444

4545
Check the updated reference targets in Snyk for detected vulnerabilities.
4646

47-
#### Check Silk
47+
#### Check Kondukto
4848

49-
Get credentials for Silk from the `drivers/libmongocrypt` vault in [AWS Secrets Manager](https://wiki.corp.mongodb.com/display/DRIVERS/Using+AWS+Secrets+Manager+to+Store+Testing+Secrets).
49+
Get credentials for Kondukto from the `drivers/libmongocrypt` vault in [AWS Secrets Manager](https://wiki.corp.mongodb.com/display/DRIVERS/Using+AWS+Secrets+Manager+to+Store+Testing+Secrets).
5050

5151
Download the Augmented SBOM using:
5252
```bash
5353
./.evergreen/earthly.sh \
54-
--secret silk_client_id=${silk_client_id} \
55-
--secret silk_client_secret=${silk_client_secret} \
56-
+sbom-download \
54+
--secret kondukto_token=${kondukto_token} \
55+
+sbom-augment \
5756
--out cyclonedx.augmented.sbom.json \
5857
--branch <branch>
5958
```
@@ -86,9 +85,8 @@ Do the following when releasing:
8685
- Attach the Augmented SBOM file. Download the Augmented SBOM using:
8786
```bash
8887
./.evergreen/earthly.sh \
89-
--secret silk_client_id=${silk_client_id} \
90-
--secret silk_client_secret=${silk_client_secret} \
91-
+sbom-download \
88+
--secret kondukto_token=${kondukto_token} \
89+
+sbom-augment \
9290
--out cyclonedx.augmented.sbom.json \
9391
--branch <branch>
9492
```
@@ -99,14 +97,6 @@ Do the following when releasing:
9997

10098
- If this is a new minor release (e.g. `x.y.0`):
10199
- File a DOCSP ticket to update the installation instructions on [Install libmongocrypt](https://www.mongodb.com/docs/manual/core/csfle/reference/libmongocrypt/). ([Example](https://jira.mongodb.org/browse/DOCSP-36863))
102-
- Create a new Silk asset group. Use the newly created release branch (e.g. `rx.y`) as the `--branch` argument:
103-
```bash
104-
./.evergreen/earthly.sh \
105-
--secret silk_client_id=${silk_client_id} \
106-
--secret silk_client_secret=${silk_client_secret} \
107-
+silk-create-asset-group \
108-
--branch <branch>
109-
```
110100
- Create a new Snyk reference target. The following instructions use the example branch `rx.y`:
111101

112102
Run `cmake` to ensure generated source files are present:

ext/libmongocrypt/libmongocrypt/etc/silk-create-asset-group.sh

Lines changed: 0 additions & 70 deletions
This file was deleted.

ext/libmongocrypt/libmongocrypt/etc/ssdlc_compliance_report.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ Not available. <!-- DRIVERS-2892: replace with link to public-facing document on
1010

1111
## Tool used to track third party vulnerabilities
1212

13-
Silk and Snyk.
13+
Kondukto and Snyk.
1414

1515
## Third-Party Dependency Information
1616

ext/libmongocrypt/libmongocrypt/etc/third_party_vulnerabilities.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ This section provides a template that may be used for actual vulnerability repor
1515

1616
- **Date Detected:** YYYY-MM-DD
1717
- **Severity:** Low, Medium, High, or Critical
18-
- **Detector:** Silk or Snyk
18+
- **Detector:** Kondukto or Snyk
1919
- **Description:** A short vulnerability description.
2020
- **Dependency:** Name and version of the 3rd party dependency.
2121
- **Upstream Status:** False Positive, Won't Fix, Fix Pending, or Fix Available. This is the fix status for the 3rd party dependency, not libmongocrypt. "Fix Available" should include the version and/or date when the fix was released, e.g. "Fix Available (1.2.3, 1970-01-01)".

0 commit comments

Comments
 (0)