Skip to content

improvement(pam): explicitly disable LOCAL INFILE on MySQL backend connections - #398

Merged
lb-vn merged 2 commits into
mainfrom
PAM-477
Sep 15, 2026
Merged

lb-vn merged 2 commits into
mainfrom
PAM-477

Conversation

@lb-vn

@lb-vn lb-vn commented Sep 15, 2026

Copy link
Copy Markdown
Member

Description 📣

Addresses PAM-477

Type ✨

  • Bug fix
  • New feature
  • Improvement
  • Breaking change
  • Documentation

Tests 🛠️

Just connect with MySQL as a smoke test


@lb-vn
lb-vn requested a review from bernie-g September 15, 2026 02:03
@linear

linear Bot commented Sep 15, 2026

Copy link
Copy Markdown

PAM-477

@greptile-apps

greptile-apps Bot commented Sep 15, 2026

Copy link
Copy Markdown
Contributor

RetriggerConfidence Score: 4/5

The PR appears safe to merge from a current-runtime security perspective, but the capability should be disabled before handshake negotiation so the intended hardening is effective.

Findings

  1. P2 Capability Cleared Too Late

Summary

This PR attempts to harden PAM's MySQL backend connection by clearing the CLIENT_LOCAL_FILES capability after connecting.

  • The capability is currently cleared only after handshake negotiation, so the backend still sees it advertised.
  • The installed go-mysql version independently rejects LOCAL INFILE responses and does not access local files.

Reviews (1) · Last reviewed commit: "improvement(pam): explicitly disable LOC..."

Comment thread packages/pam/handlers/mysql/proxy.go Outdated
@lb-vn
lb-vn merged commit 43861c3 into main Sep 15, 2026
32 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants