chore(deps)(deps): bump alpine from 865b95f to 2510918 in /gearbox in the docker-images group - #2
Merged
github-actions[bot] merged 1 commit intoFeb 1, 2026
Conversation
Contributor
Author
LabelsThe following labels could not be found: Please fix the above issues or remove invalid values from |
dependabot
Bot
force-pushed
the
dependabot/docker/gearbox/docker-images-60be0b6e22
branch
from
February 1, 2026 09:15
70a1762 to
5515944
Compare
Bumps the docker-images group in /gearbox with 1 update: alpine. Updates `alpine` from `865b95f` to `2510918` --- updated-dependencies: - dependency-name: alpine dependency-version: '3.23' dependency-type: direct:production update-type: version-update:semver-patch dependency-group: docker-images ... Signed-off-by: dependabot[bot] <support@github.com>
dependabot
Bot
force-pushed
the
dependabot/docker/gearbox/docker-images-60be0b6e22
branch
from
February 1, 2026 15:08
5515944 to
e5e0702
Compare
dependabot
Bot
deleted the
dependabot/docker/gearbox/docker-images-60be0b6e22
branch
February 1, 2026 15:10
4 tasks
3 tasks
sarg3nt
added a commit
that referenced
this pull request
May 11, 2026
* fix(security): validate haproxy.backend.name + haproxy.acl.ip labels Both labels flowed unvalidated from Docker Compose YAML into HAProxy config via fmt.Sprintf in the generator. An author with push access to a scraped repo could embed newlines plus arbitrary HAProxy directives in either label and have them executed by HAProxy at the next reload, which runs with the agent's privileges (root in the documented deployment). Concrete impact: - haproxy.backend.name flows to "backend %s", " server %s_srv", and " use_backend %s if is_%s". Newline injection lands directly inside the backend block, so directives like lua-load (arbitrary Lua exec at startup if Lua is compiled in) or errorfile <path> (arbitrary host-file read at startup) become attacker-controlled. - haproxy.acl.ip flows to " acl ip_allowed_* src %s". Same shape; an injected "acl admin src 0.0.0.0/0" silently widens any IP allowlist. Fix: - New validBackendName regex (DNS-label-style) enforced at parser time. Default-generated names from sanitizeName always pass it; user-supplied names from the label must match or the backend is rejected entirely. - New validateACLIPList helper that splits on comma, trims whitespace, and requires every entry to parse as net.ParseCIDR or net.ParseIP. Embedded whitespace (newlines, tabs) is rejected up front. Both failure modes reject the whole backend rather than silently dropping the offending field, since fall-through to "no ACL = open access" or "no backend name = whatever the generator produces" is worse than just not routing that service. Tests added that round-trip the actual exploit payloads through ParseFile and assert zero backends are returned. P0-1 and P0-2 from the 2026-05 security audit. * docs(security): correct bcrypt cost + remove false encryption-at-rest claim Two doc errors caught by the 2026-05 security audit (P0-3): 1. SECURITY.md claimed bcrypt cost 10. The code has been using cost 12 since gearbox/internal/framework/auth/password.go was written; the doc just never caught up. Cost 12 is the 2026 OWASP baseline, so the code is right and the doc was lagging. 2. SECURITY.md claimed "Credential Encryption: API keys encrypted at rest (AES-256-GCM)". That implementation does not exist anywhere in the codebase — a grep for "aes" / "GCM" / "cipher" returns zero hits in gearbox-agent. Secrets are protected by filesystem permissions (mode 0600) only. The claim is replaced with an honest description of the actual posture, plus guidance on how to layer real encryption-at-rest underneath (FDE / KMS). Also adds the 2026-05 audit to the Security Audit History table. The "real fix" for #2 (implementing envelope encryption with a KMS- or TPM-backed key) is tracked separately; co-locating the decryption key with the ciphertext on the same filesystem buys nothing real and the honest doc is more defensible than the theatrical implementation. * fix(security): tighten ?return=... allowlist on login + logout The post-login redirect honored an arbitrary ?return= query value as long as it wasn't literally /login or /logout. An attacker phishing a victim to https://gearbox.example.com/login?return=https://attacker would land them on the attacker's harvest page immediately after a successful login, with the URL bar showing only the moment of redirect from a legitimate origin. The Logout handler had the same shape and could relay the value back to the login page. Replace the two-string blocklist with a same-origin allowlist: isSafeReturnURL accepts only relative paths starting with `/`, rejects protocol-relative `//host`, rejects `/\…` (some browsers normalize the backslash to a forward slash, opening another protocol-relative path), rejects any embedded backslash, and rejects schemed URIs entirely. Applies to both LoginPost and Logout. Test pins down the accept/reject matrix including the textbook bypasses (`//evil.example.com`, `/\evil.example.com`, `javascript:`, `data:`). P0-4 from the 2026-05 security audit.
sarg3nt
added a commit
that referenced
this pull request
May 14, 2026
- Lint: golangci-lint's `unused` check runs without the `dev` build tag, so the shared constants in dev_bypass.go were flagged. Delete the shared file and inline the two constants into dev_bypass_on.go where they are actually referenced. - Doc accuracy (Copilot #1, #2): the `-tags dev` flag is set by the `dev:` target in gearbox/Makefile via `air --build.cmd "$(DEV_BUILD_CMD)"`, not by `.air.toml` (which is gitignored per-developer). Update the package doc and four function/header comments in dev_bypass_on.go, and the corresponding section in gearbox/docs/development.md, to reference the Makefile and drop the broken `../.air.toml` link. - Security (Copilot #3): EnsureDevUserExists previously returned early if a `dev` row already existed, leaving its password_hash untouched. A developer who manually set a password on that row could then form- login as a `dev` admin, contradicting the "form-login can never authenticate as this user" claim. Always rewrite password_hash to the caller-supplied dummyPasswordHash, plus reset status and must_change_password back to the safe defaults, on every call. Other fields (role, names) are still preserved across runs. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
sarg3nt
added a commit
that referenced
this pull request
May 14, 2026
* feat(#83): dev-only loopback auto-login bypass Compiled in only when the binary is built with `-tags dev` (which the `make dev` target now passes via air's --build.cmd). When all three of these hold the request is auto-authenticated as the seeded `dev` user: 1. Build tag `dev` is set. 2. GEARBOX_DEV_AUTO_LOGIN=1 in the environment. 3. Post-RealIP RemoteAddr is a loopback IP. Production builds (`make build`) replace every entry point with a no-op stub via dev_bypass_off.go, so the bypass code, env-var check, loopback check, seed function, and banner are not present in release binaries at all. Verified: - dev binary contains GEARBOX_DEV_AUTO_LOGIN and seed/banner strings; prod binary contains only the tryDevBypass no-op stub symbol. - cookieless GET / -> 303 /haproxy (auto-login). - cookieless GET / with X-Forwarded-For: 1.2.3.4 -> 303 /login (chi.RealIP rewrites RemoteAddr, loopback check declines). The seeded `dev` user has the package-level dummyPasswordHash so the form-login path can never authenticate as it; only the loopback bypass can. The seed is itself build-tag-gated (users_dev.go) so prod doesn't even contain the seed function. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com> * fix(#83): address Copilot review on #84 - Lint: golangci-lint's `unused` check runs without the `dev` build tag, so the shared constants in dev_bypass.go were flagged. Delete the shared file and inline the two constants into dev_bypass_on.go where they are actually referenced. - Doc accuracy (Copilot #1, #2): the `-tags dev` flag is set by the `dev:` target in gearbox/Makefile via `air --build.cmd "$(DEV_BUILD_CMD)"`, not by `.air.toml` (which is gitignored per-developer). Update the package doc and four function/header comments in dev_bypass_on.go, and the corresponding section in gearbox/docs/development.md, to reference the Makefile and drop the broken `../.air.toml` link. - Security (Copilot #3): EnsureDevUserExists previously returned early if a `dev` row already existed, leaving its password_hash untouched. A developer who manually set a password on that row could then form- login as a `dev` admin, contradicting the "form-login can never authenticate as this user" claim. Always rewrite password_hash to the caller-supplied dummyPasswordHash, plus reset status and must_change_password back to the safe defaults, on every call. Other fields (role, names) are still preserved across runs. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Bumps the docker-images group in /gearbox with 1 update: alpine.
Updates
alpinefrom865b95fto2510918Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting
@dependabot rebase.Dependabot commands and options
You can trigger Dependabot actions by commenting on this PR:
@dependabot rebasewill rebase this PR@dependabot recreatewill recreate this PR, overwriting any edits that have been made to it@dependabot mergewill merge this PR after your CI passes on it@dependabot squash and mergewill squash and merge this PR after your CI passes on it@dependabot cancel mergewill cancel a previously requested merge and block automerging@dependabot reopenwill reopen this PR if it is closed@dependabot closewill close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually@dependabot show <dependency name> ignore conditionswill show all of the ignore conditions of the specified dependency@dependabot ignore <dependency name> major versionwill close this group update PR and stop Dependabot creating any more for the specific dependency's major version (unless you unignore this specific dependency's major version or upgrade to it yourself)@dependabot ignore <dependency name> minor versionwill close this group update PR and stop Dependabot creating any more for the specific dependency's minor version (unless you unignore this specific dependency's minor version or upgrade to it yourself)@dependabot ignore <dependency name>will close this group update PR and stop Dependabot creating any more for the specific dependency (unless you unignore this specific dependency or upgrade to it yourself)@dependabot unignore <dependency name>will remove all of the ignore conditions of the specified dependency@dependabot unignore <dependency name> <ignore condition>will remove the ignore condition of the specified dependency and ignore conditions