Skip to content

Commit 224b654

Browse files
step-security-botShaojieZhuIntel
authored andcommitted
[StepSecurity] Apply security best practices (#70)
Signed-off-by: StepSecurity Bot <[email protected]>
1 parent 1d9ec04 commit 224b654

File tree

8 files changed

+46
-6
lines changed

8 files changed

+46
-6
lines changed

.github/workflows/pr-request-release-note.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,11 @@ jobs:
1919
steps:
2020
# We need to pull the script from the main branch, so that we ensure
2121
# we get the latest version of this script.
22+
- name: Harden Runner
23+
uses: step-security/harden-runner@91182cccc01eb5e619899d80e4e971d6181294a7 # v2.10.1
24+
with:
25+
egress-policy: audit
26+
2227
- name: Checkout Scripts
2328
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
2429
with:

.github/workflows/scorecard.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,11 @@ jobs:
3333
# actions: read
3434

3535
steps:
36+
- name: Harden Runner
37+
uses: step-security/harden-runner@91182cccc01eb5e619899d80e4e971d6181294a7 # v2.10.1
38+
with:
39+
egress-policy: audit
40+
3641
- name: "Checkout code"
3742
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
3843
with:

.pre-commit-config.yaml

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
repos:
2+
- repo: https://github.com/digitalpulp/pre-commit-php
3+
rev: 1.4.0
4+
hooks:
5+
- id: php-lint-all
6+
- repo: https://github.com/gitleaks/gitleaks
7+
rev: v8.16.3
8+
hooks:
9+
- id: gitleaks
10+
- repo: https://github.com/jumanjihouse/pre-commit-hooks
11+
rev: 3.0.0
12+
hooks:
13+
- id: shellcheck
14+
- repo: https://github.com/pocc/pre-commit-hooks
15+
rev: v1.3.5
16+
hooks:
17+
- id: cpplint
18+
- repo: https://github.com/pre-commit/mirrors-eslint
19+
rev: v8.38.0
20+
hooks:
21+
- id: eslint
22+
- repo: https://github.com/pre-commit/pre-commit-hooks
23+
rev: v4.4.0
24+
hooks:
25+
- id: end-of-file-fixer
26+
- id: trailing-whitespace
27+
- repo: https://github.com/pylint-dev/pylint
28+
rev: v2.17.2
29+
hooks:
30+
- id: pylint

bolt/utils/docker/Dockerfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM ubuntu:20.04 AS builder
1+
FROM ubuntu:20.04@sha256:8e5c4f0285ecbb4ead070431d29b576a530d3166df73ec44affc1cd27555141b AS builder
22

33
ARG DEBIAN_FRONTEND=noninteractive
44
ENV TZ=UTC
@@ -26,6 +26,6 @@ RUN mkdir build && \
2626
ninja install-llvm-bolt install-perf2bolt install-merge-fdata \
2727
install-llvm-boltdiff install-bolt_rt
2828

29-
FROM ubuntu:20.04
29+
FROM ubuntu:20.04@sha256:8e5c4f0285ecbb4ead070431d29b576a530d3166df73ec44affc1cd27555141b
3030

3131
COPY --from=builder /home/bolt/install /usr/local

clang/tools/clang-fuzzer/Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
#
77
#===----------------------------------------------------------------------===//
88
# Produces an image that builds clang-proto-fuzzer
9-
FROM ubuntu:16.04
9+
FROM ubuntu:16.04@sha256:1f1a2d56de1d604801a9671f301190704c25d604a416f59e03c04f5c6ffee0d6
1010
RUN apt-get update -y
1111
RUN apt-get install -y autoconf automake libtool curl make g++ unzip wget git \
1212
binutils liblzma-dev libz-dev python-all cmake ninja-build subversion \

clang/utils/analyzer/Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM ubuntu:bionic
1+
FROM ubuntu:bionic@sha256:152dc042452c496007f07ca9127571cb9c29697f42acbfad72324b2bb2e43c98
22

33
RUN apt-get update && apt-get install -y \
44
apt-transport-https \

libc/utils/buildbot/Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM debian:10
1+
FROM debian:10@sha256:58ce6f1271ae1c8a2006ff7d3e54e9874d839f573d8009c20154ad0f2fb0a225
22

33
# Installing dependencies.
44
RUN dpkg --add-architecture i386

libcxx/utils/ci/Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -164,7 +164,7 @@ EOF
164164
# Android Buildkite Image
165165
# ===----------------------------------------------------------------------===##
166166

167-
FROM ubuntu:jammy AS android-builder-base
167+
FROM ubuntu:jammy@sha256:0e5e4a57c2499249aafc3b40fcd541e9a456aab7296681a3994d631587203f97 AS android-builder-base
168168

169169
ARG ANDROID_CLANG_VERSION
170170
ARG ANDROID_CLANG_PREBUILTS_COMMIT

0 commit comments

Comments
 (0)