Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
16 commits
Select commit Hold shift + click to select a range
85d526e
[APPX-14752] Remediate Arnica code risk findings for Agent SDK
Mat001 Nov 20, 2026
0498376
[APPX-14752] Address Arnica review: bump grpc 1.83.2 and x/net 0.62.0
Mat001 Nov 20, 2026
c3aef15
[APPX-14752] Fix acceptance CI: Python 3.9 unavailable on current runner
Mat001 Nov 20, 2026
41e90c1
[APPX-14752] Fix lint: pin golangci-lint analysis target to Go 1.24
Mat001 Nov 20, 2026
edc6b25
[APPX-14752] Revert acceptance-job Python bump; track infra rot separ…
Mat001 Nov 20, 2026
e607811
[APPX-14752] Raise golangci-lint timeout to 5m
Mat001 Nov 20, 2026
698c0bf
[APPX-14752] Upgrade golangci-lint to v2 for Go 1.26 compatibility
Mat001 Nov 20, 2026
578ea0d
[APPX-14752] Fix golangci-lint install: version-pin the install script
Mat001 Nov 23, 2026
ebcd453
[APPX-14752] Dockerfiles: set GOTOOLCHAIN=auto so pinned toolchain is…
Mat001 Nov 23, 2026
4c675e6
[APPX-14752] Fix acceptance CI: Python 3.12 + openapi_core 0.18.2
Mat001 Nov 23, 2026
4b44415
[APPX-14752] Bump otel to v1.47.0 for newly published GO-2026-6974
Mat001 Nov 23, 2026
0faac51
[APPX-14752] Bump go-sdk v2.5.0 -> v2.7.0 for holdout support (fixes …
Mat001 Nov 23, 2026
fda9d79
[APPX-14752] Re-trigger CI after FSC harness fix (compat-suite #710)
Mat001 Nov 24, 2026
e045669
[APPX-14752] Address review: HEALTHCHECK port env, govulncheck CI, co…
Mat001 Nov 24, 2026
0e4b000
[APPX-14752] govulncheck CI: generate statik package before scanning
Mat001 Nov 24, 2026
113c0a3
[APPX-14752] Pin govulncheck job tool versions
Mat001 Nov 25, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
43 changes: 32 additions & 11 deletions .github/workflows/agent.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ on:
branches: [ master ]

env:
GIMME_GO_VERSION: 1.24.0
GIMME_GO_VERSION: 1.26.11
GIMME_OS: linux
GIMME_ARCH: amd64

Expand All @@ -22,7 +22,7 @@ jobs:
persist-credentials: false
- uses: actions/setup-go@v3
with:
go-version: '1.24.0'
go-version: '1.26.11'
check-latest: true
- name: fmt
run: |
Expand All @@ -37,13 +37,34 @@ jobs:
persist-credentials: false
- uses: actions/setup-go@v3
with:
go-version: '1.24.0'
go-version: '1.26.11'
check-latest: true
- name: lint
run: |
make -e setup
make lint

govulncheck:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
persist-credentials: false
- uses: actions/setup-go@v3
with:
go-version: '1.26.11'
check-latest: true
- name: govulncheck
run: |
# Generate the statik package so all imports resolve for analysis.
# Tool versions are pinned (statik matches go.mod) and bumped deliberately
# so a govulncheck release can't flip this job independently of the code;
# the vulnerability database is still fetched live at run time.
go install github.com/rakyll/statik@v0.1.7
make static
go install golang.org/x/vuln/cmd/govulncheck@v1.10.0
govulncheck ./...

lint-docker:
runs-on: ubuntu-latest
env:
Expand All @@ -67,7 +88,7 @@ jobs:
persist-credentials: false
- uses: actions/setup-go@v3
with:
go-version: '1.24.0'
go-version: '1.26.11'
check-latest: true
- name: Start Redis
uses: supercharge/redis-github-action@1.5.0
Expand Down Expand Up @@ -104,12 +125,12 @@ jobs:
persist-credentials: false
- uses: actions/setup-go@v3
with:
go-version: '1.24.0'
go-version: '1.26.11'
check-latest: true
- name: Set up Python 3.9
uses: actions/setup-python@v3
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: 3.9
python-version: '3.12'
- name: Start Redis
uses: supercharge/redis-github-action@1.5.0
with:
Expand All @@ -135,7 +156,7 @@ jobs:
persist-credentials: false
- uses: actions/setup-go@v3
with:
go-version: '1.24.0'
go-version: '1.26.11'
check-latest: true
- name: Get the version
id: get_version
Expand Down Expand Up @@ -168,7 +189,7 @@ jobs:
persist-credentials: false
- uses: actions/setup-go@v3
with:
go-version: '1.24.0'
go-version: '1.26.11'
check-latest: true
- name: Get the version
id: get_version
Expand Down Expand Up @@ -225,7 +246,7 @@ jobs:
persist-credentials: false
- uses: actions/setup-go@v3
with:
go-version: '1.24.0'
go-version: '1.26.11'
check-latest: true
- name: Get the version
id: get_version
Expand Down
130 changes: 62 additions & 68 deletions .golangci.yml
Original file line number Diff line number Diff line change
@@ -1,79 +1,73 @@
linters-settings:
govet:
enable:
- shadow
gocyclo:
min-complexity: 30 # Increased to allow existing complex functions
dupl:
threshold: 200
misspell:
locale: US
revive:
min-confidence: 0
rules:
# Disabled: Would require breaking API changes (Ids -> IDs)
- name: var-naming
disabled: true
# Disabled: Parameters often required for interface compliance
- name: unused-parameter
disabled: true
# Disabled: Style preference, not a bug
- name: superfluous-else
disabled: true
# Disabled: Would require breaking API changes (stuttering names)
- name: exported
disabled: true
# Disabled: Style preference for context key types
- name: context-keys-type
disabled: true

version: "2"
run:
concurrency: 4
linters:
disable-all: true
default: none
enable:
- unused
- copyloopvar
- dupl
- gosec
# - gocritic # Temporarily disabled due to compatibility issues with Go 1.24
- gocyclo
- revive
- gosimple
- gosec
- govet
- ineffassign
- staticcheck
- misspell
- nakedret
- prealloc
- copyloopvar
- stylecheck
- typecheck
- revive
- staticcheck
- unconvert
- unparam

run:
concurrency: 4

issues:
exclude-dirs:
- vendor
exclude-rules:
- text: "weak cryptographic primitive"
linters:
- gosec
# Suppress unhandled errors in Redis cleanup code (non-critical)
- path: pkg/syncer/pubsub/redis.*\.go
linters:
- gosec
text: "G104"
# Suppress context key type warnings (would require refactoring)
- linters:
- staticcheck
text: "SA1029"
# Suppress comment format warnings (style preference)
- linters:
- stylecheck
text: "ST1020|ST1021"
# Suppress naked return warnings in rest_ups.go (existing code, refactoring is risky)
- path: plugins/userprofileservice/services/rest_ups\.go
linters:
- nakedret
exclude-use-default: false
- unused
settings:
dupl:
threshold: 200
gocyclo:
min-complexity: 30
govet:
enable:
- shadow
misspell:
locale: US
revive:
rules:
- name: var-naming
disabled: true
- name: unused-parameter
disabled: true
- name: superfluous-else
disabled: true
- name: exported
disabled: true
- name: context-keys-type
disabled: true
exclusions:
generated: lax
rules:
- linters:
- gosec
text: weak cryptographic primitive
- linters:
- gosec
path: pkg/syncer/pubsub/redis.*\.go
text: G104
- linters:
- staticcheck
text: SA1029
- linters:
- staticcheck
text: ST1020|ST1021
- linters:
- nakedret
path: plugins/userprofileservice/services/rest_ups\.go
paths:
- vendor
- third_party$
- builtin$
- examples$
formatters:
exclusions:
generated: lax
paths:
- third_party$
- builtin$
- examples$
6 changes: 3 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -55,13 +55,13 @@ cover: check-go static ## runs test suite with coverage profiling

setup: check-go ## installs all dev and ci dependencies, but does not install golang
# Install golangci-lint
@echo "Installing golangci-lint v1.64.2..."
curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(GOPATH)/bin v1.64.2
@echo "Installing golangci-lint v2.15.0..."
curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/v2.15.0/install.sh | sh -s -- -b $(GOPATH)/bin v2.15.0
@echo "Installing statik..."
go install github.com/rakyll/statik@latest

lint: check-go static ## runs `golangci-lint` linters defined in `.golangci.yml` file
$(GOLINT) run --out-format=tab --tests=false ./...
$(GOLINT) run --output.tab.path=stdout --tests=false ./...

run: $(TARGET) ## builds and executes the TARGET binary
$(GOBIN)/$(TARGET)
Expand Down
68 changes: 68 additions & 0 deletions docs/dependency-security-notes.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
# Dependency security notes

This document records decisions for Arnica (and similar SCA/supply-chain)
findings that are **accepted and documented** rather than remediated by a
version bump or replacement. Findings that were remediated (vulnerable
dependency upgrades, the Go toolchain bump, the notification handler change,
and the container healthchecks) are not listed here — they live in the code and
`go.mod`/requirements history.

Reviewed against the repository's Apache-2.0 license.

## Reputation: low-reputation dependencies (accepted)

All five flagged modules are **indirect** dependencies. They are not imported
directly by Agent code; each is pulled in by a well-maintained, widely used
direct dependency. They cannot be replaced without replacing their parent, and
no better-maintained drop-in exists. We accept them.

| Module | Pulled in by | Used for |
| --- | --- | --- |
| `github.com/lestrrat-go/httpcc` | `github.com/lestrrat-go/jwx/v2/jwk` | JWT/JWK verification (`pkg/middleware` auth) |
| `github.com/lestrrat-go/option` | `github.com/lestrrat-go/jwx/v2/jwk` | JWT/JWK verification (`pkg/middleware` auth) |
| `github.com/lestrrat-go/iter` | `github.com/lestrrat-go/jwx/v2/jwk` | JWT/JWK verification (`pkg/middleware` auth) |
| `github.com/VividCortex/gohistogram` | `github.com/go-kit/kit/metrics` | expvar/generic metrics (`pkg/metrics`) |
| `github.com/matttproud/golang_protobuf_extensions/v2` | `github.com/prometheus/client_golang` | Prometheus metrics (`pkg/metrics`) |

Notes:

- The `lestrrat-go/*` helpers are maintained as part of the `jwx` project, which
is the JWT library this service depends on for request authentication.
- `matttproud/golang_protobuf_extensions/v2` was mis-listed as `mattproud`
(single `t`) in the Arnica list view; the real module name has three `t`s. It
is an implementation detail of the Prometheus client and is only reachable
through it.

## License: MPL-2.0 dependencies (accepted)

MPL-2.0 is a weak, file-level reciprocal license. Its source-disclosure
obligation is triggered only when the MPL-licensed **files themselves** are
modified and distributed. Agent consumes all of these as unmodified upstream
dependencies, so no reciprocal obligation is triggered, and MPL-2.0 is
compatible with this Apache-2.0 project. We accept them.

| Dependency | Scope | Pulled in by |
| --- | --- | --- |
| `github.com/hashicorp/hcl@v1.0.0` | Go, indirect | `github.com/spf13/viper` (config parsing) |
| `github.com/hashicorp/go-multierror@v1.1.1` | Go, indirect | `github.com/optimizely/go-sdk/v2` client |
| `github.com/hashicorp/errwrap@v1.1.0` | Go, indirect | `github.com/hashicorp/go-multierror` |
| `certifi` | Python, `examples/requirements.txt` | example SSE client script only |

Notes:

- The `hashicorp/*` modules are unmodified, standard transitive dependencies and
are not vendored or patched.
- `certifi` ships only in the Python **example** requirements (not in the Agent
binary or any released artifact). It was also upgraded to the latest release
to clear its vulnerability finding.

## Container image healthchecks

- `scripts/dockerfiles/Dockerfile.alpine` defines a `HEALTHCHECK` that probes the
admin listener's `/health` endpoint using the `wget` bundled in the Alpine base
image.
- `scripts/dockerfiles/Dockerfile.static` is a `FROM scratch` image with no shell
or HTTP client to run a `HEALTHCHECK` command, and the binary exposes no health
subcommand. Health must be checked over HTTP against the `/health` endpoint via
the orchestrator (e.g. a Kubernetes liveness/readiness probe). This is
documented inline in that Dockerfile.
10 changes: 6 additions & 4 deletions examples/requirements.txt
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
certifi==2025.1.31
certifi==2026.10.23
Comment thread
arnica-github-connector[bot] marked this conversation as resolved.
Resolved
charset-normalizer==3.4.1
idna==3.10
requests==2.32.4
idna==3.20
requests==2.34.2
six==1.17.0
# sseclient 0.0.27 is the latest published release; pinned as-is. Its transitive
# dependencies (requests, urllib3) are pinned to current versions above.
sseclient==0.0.27
urllib3==2.6.0
urllib3==2.8.0
Loading
Loading