Skip to content

[17.0-stable] Bump alpine for openssh update - #7047

Closed
shjala wants to merge 2 commits into
lf-edge:17.0-stablefrom
shjala:backport/17.0-openssh-10.6p2
Closed

shjala wants to merge 2 commits into
lf-edge:17.0-stablefrom
shjala:backport/17.0-openssh-10.6p2

Conversation

@shjala

@shjala shjala commented Nov 5, 2026 •

Copy link
Copy Markdown
Member

Description

Backport of #7054 to 17.0-stable, using the two relevant commits from master:

  • fb4c22e409e14a824eae7b995560091ee3fea21d — alpine: Bump Alpine image
  • fc203c28772424f4d469cf9541edd827ee63e67e — Bump Alpine package for openssh update

Refresh the Alpine 3.22 package cache to pick up the OpenSSH musl password-authentication bypass fix (Alpine 10.0_p1-r11), and refresh dependent package image pins. Both commits retain cherry-pick provenance. The unrelated guacamole download workaround from #7054 is not included.

Resolve image-pin conflicts using the 17.0-stable sources: preserve its Go 1.25.11 setting, omit packages absent from this branch, and regenerate Alpine and downstream hashes. This updates the shared package cache and therefore has a broader build impact than a debug-only package change.

This replaces the previous manual APK overlay. The extra ADD --checksum and unused openssh-test stages are removed, addressing those review findings. Public-key-only SSH authentication is already present in the target branch and remains enabled.

How to test and validate this PR

  • Passed make check-docker-hashes-consistency, SPDX checks, and git diff --check on the replacement revision.
  • Independently verified linuxkit pkg show-tag pkg/debug matches the installer pin: b76f7b9595242f05de080757413415a6be38086b.
  • Verify CI builds the new stable Alpine cache and dependent packages on all supported architectures. Its tag is 09131e59512565db4e4227e33f01c7f86f5f168e.
  • Check the built cache/debug image supplies OpenSSH 10.0_p1-r11 or a newer fixed Alpine revision. Verify SSH authorized-key access, rejected password/keyboard-interactive authentication, and SFTP.
  • Run Eden/evetest after approval. Full image builds, runtime tests, and physical-device validation have not been repeated locally for this replacement; results from the previous manual-APK revision do not validate it.

Changelog notes

Refresh Alpine packages to include the OpenSSH password-authentication security fix. SSH access remains public-key only.

PR Backports

Checklist

  • I've provided a proper description
  • I've added the proper documentation (backport scope and validation instructions)
  • I've tested my PR on amd64 device
  • I've tested my PR on arm64 device
  • I've written the test verification instructions
  • I've added a reference link to the original PR
  • PR's title follows the template
  • I've provided validation limitations for unchecked items

@shjala shjala added stable Should be backported to stable release(s) security Provides a security fix labels Nov 5, 2026
@github-actions
github-actions Bot requested a review from eriknordmark November 5, 2026 16:58
@github-actions

github-actions Bot commented Nov 5, 2026 •

Copy link
Copy Markdown
Contributor

Claude finished @shjala's task in 2m 58s —— View job


Review: OpenSSH 10.6p2 backport to 17.0-stable

  • Fetch PR diff
  • Review pkg/debug/Dockerfile
  • Review pkg/debug/tests/openssh.sh
  • Review pkg/installer/Dockerfile pin
  • Post review

Overall this is a sound backport: the OpenSSH source build is checksum-pinned, the publickey-only drop-in (10-eve-pubkey-only.conf) is preserved, the test stage verifies the production sshd -T reports PasswordAuthentication no / KbdInteractiveAuthentication no, and all test accounts/keys live only in the disposable test stage (final image copies --from=build, not --from=test), so nothing is shipped. Two issues worth addressing, posted inline:

1. ADD --checksum vs. frontend version (pkg/debug/Dockerfile:28)
ADD --checksum needs Dockerfile frontend ≥ 1.6.0, but the file pins 1.5.0-rc2-labs. If the flag isn't honored, the tarball's only integrity guarantee is lost silently. Bump the # syntax= directive and confirm a wrong hash actually fails the build.

2. Dead openssh-test stage (pkg/debug/Dockerfile:48-51)
This stage is unreachable — nothing builds --target openssh-test, and the real run lives in the test stage. Remove it or wire it into a target.

Backport-specific verification (can't check here):

  • The installer pin lfedge/eve-debug:927734a2… must be the hash produced by this branch's pkg/debug build, not master's — the 17.0-stable branch may pin different base-image hashes (Alpine/recovertpm/bpftrace), which would change the computed tag. Worth re-confirming linuxkit pkg show-tag pkg/debug on this branch matches the pin after the full build completes.

Minor note: the openssh.sh regression test only runs under the test/CI target, not during the actual package/image build — consistent with the existing collect-info-test pattern, so this is expected, not a defect.
· branch backport/17.0-openssh-10.6p2

Comment thread pkg/debug/Dockerfile Resolved
Comment thread pkg/debug/Dockerfile Resolved
@codecov

codecov Bot commented Nov 5, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 24.15%. Comparing base (1797593) to head (665b394).
⚠️ Report is 1 commits behind head on 17.0-stable.

Additional details and impacted files
@@               Coverage Diff               @@
##           17.0-stable    #7047      +/-   ##
===============================================
+ Coverage        23.53%   24.15%   +0.61%     
===============================================
  Files              517      527      +10     
  Lines            95834    97411    +1577     
===============================================
+ Hits             22559    23527     +968     
- Misses           71358    72012     +654     
+ Partials          1917     1872      -45     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@shjala
shjala force-pushed the backport/17.0-openssh-10.6p2 branch from c7138d1 to 25a33ed Compare November 6, 2026 09:22
@shjala shjala changed the title [17.0-stable] debug: upgrade OpenSSH to 10.6p2 [17.0-stable] debug: use Alpine OpenSSH password-authentication fix Nov 6, 2026
@shjala
shjala force-pushed the backport/17.0-openssh-10.6p2 branch from 25a33ed to f9fb451 Compare November 6, 2026 15:16
@github-actions

github-actions Bot commented Nov 6, 2026 •

Copy link
Copy Markdown
Contributor

Claude finished @shjala's task in 3m 6s —— View job


Review: OpenSSH password-auth fix backport to 17.0-stable

  • Fetch current branch diff (note: branch was updated to the Alpine signed-APK approach — the earlier bot comments about a 10.6p2 source build are stale)
  • Review pkg/debug/Dockerfile
  • Review pkg/debug/tests/openssh.sh
  • Review pkg/installer/Dockerfile pin
  • Post inline findings

Sound backport overall. The pinned r11 APKs are checksum-anchored per architecture, offline apk add --no-network fits LinuxKit's network-disabled build, the install is asserted with grep -Fx "openssh-server-10.0_p1-r11", the production publickey-only drop-in (10-eve-pubkey-only.conf) and the sshd -T assertion are preserved, and the disposable test accounts/keys live only in the test/openssh-test stages — the final FROM scratch copies --from=build, so nothing is shipped. Keeping openssh-client openssh-server in PKGS is what lets the pinned APKs resolve their deps offline, so that's intentional, not redundant.

Findings (posted inline):

  1. ADD --checksum vs. frontend pin — pkg/debug/Dockerfile:14 uses ADD --checksum, which needs frontend 1.6.0+, but line 1 still pins 1.5.0-rc2-labs. This checksum is the only integrity control before the offline apk add (the Alpine signature DB isn't consulted). Bump the # syntax= directive to a stable 1.6.0+ and confirm enforcement by corrupting a hash. Still unaddressed from the prior revision. Fix this →

  2. Dead openssh-test stage — pkg/debug/Dockerfile:67-70 is never targeted; the identical run already exists in the reachable test stage. Remove it.

  3. Installer pin (CI must verify) — pkg/installer/Dockerfile:31: confirm b30ec859… is the tag from this branch's pkg/debug build, not master's, since base-image pins may differ.

No blocking correctness or shipping-security issues found; #1 is the one worth resolving before merge.
· branch backport/17.0-openssh-10.6p2

Comment thread pkg/debug/Dockerfile Resolved
Comment thread pkg/debug/Dockerfile Resolved
Comment thread pkg/installer/Dockerfile Resolved
rene added 2 commits November 9, 2026 17:56
Bump Alpine to the latest built image so it picks up the latest openssh
package with a critical vulnerability fixed.

Signed-off-by: Renê de Souza Pinto <rene@renesp.com.br>
(cherry picked from commit fb4c22e)
This commits bumps Alpine package to its latest version so it picks up a
critical fix for openssh.

Signed-off-by: Renê de Souza Pinto <rene@renesp.com.br>
(cherry picked from commit fc203c2)

Backport adjustments: retain the 17.0-stable package sources and Go
1.25.11 setting; omit packages absent from this branch and regenerate
the Alpine and dependent image tags from the stable tree.

Signed-off-by: Shahriyar Jalayeri <shahriyar@posteo.de>
@shjala
shjala force-pushed the backport/17.0-openssh-10.6p2 branch from f9fb451 to 665b394 Compare November 9, 2026 16:59
@shjala shjala changed the title [17.0-stable] debug: use Alpine OpenSSH password-authentication fix [17.0-stable] Bump alpine for openssh update Nov 9, 2026
@shjala
shjala marked this pull request as ready for review November 9, 2026 16:59
Comment thread pkg/alpine/Dockerfile
# DON'T FORGET TO UPDATE THE HASH WHEN SOMETHING CHANGES!
# please see https://github.com/lf-edge/eve/blob/master/docs/BUILD.md#how-to-update-eve-alpine-package
FROM lfedge/eve-alpine:e9cb3b035e264f89523f8eca848e8baa68a1fbfd AS cache-build
FROM lfedge/eve-alpine:8c9af5568049068f10bc630065793c15d52fa931 AS cache-build

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

afaiu it should be
lfedge/eve-alpine:4635a9f93267ec0e24005aa80f2e7b1b828e5d17

@rene

rene commented Nov 11, 2026

Copy link
Copy Markdown
Contributor

@shjala , Alpine bump went along with the Go update, so we are good on 17.0-stable now.... I'm ok if you wan to use this PR to bump again on top of the latest image, and not on top of alpine-base, as it was bootstrapped again to pick the new OpenSSH....

@shjala

shjala commented Nov 12, 2026

Copy link
Copy Markdown
Member Author

Closing as superseded by the latest 17.0-stable: commit 8ef4f32 (pkg/alpine: Bootstrap from eve-alpine-base for OpenSSH fix), together with the Go/Alpine update, already supplies the OpenSSH fix. This also matches René’s confirmation in this PR. Replaying this older cache bump is no longer needed for the security fix; any future cache refresh should start from the current stable image.

@shjala shjala closed this Nov 12, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

security Provides a security fix stable Should be backported to stable release(s)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants