Skip to content

[ticket/17767] Add TLS support for MySQL connections - #7114

Open
thekevinbrown wants to merge 2 commits into
phpbb:masterfrom
thekevinbrown:ticket/17767
Open

thekevinbrown wants to merge 2 commits into
phpbb:masterfrom
thekevinbrown:ticket/17767

Conversation

@thekevinbrown

Copy link
Copy Markdown

Checklist:

  • Correct branch: master for new features; 3.3.x for fixes
  • Tests pass
  • Code follows coding guidelines: master and 3.3.x
  • Commit follows commit message format

Tracker ticket:

https://tracker.phpbb.com/browse/PHPBB-17767


Adds optional TLS for MySQL connections, used by both the mysqli driver and the Doctrine connection:

$dbsslmode = 'verify_identity'; // disabled (default), preferred, required or verify_identity
$dbsslca = '';                  // optional CA file; empty uses the system's trusted CAs
  • Modes follow MySQL's ssl-mode. Unset means disabled, so existing boards don't change.
  • preferred falls back to unencrypted only when the server has no TLS. Other connection errors fail as before.
  • mysqlnd verifies only when it's given a CA, so verify_identity always passes one, and refuses to connect if there isn't one.

Adds $dbsslmode (disabled, preferred, required or verify_identity, as
MySQL's ssl-mode) and $dbsslca to config.php. Both the mysqli driver and
the Doctrine pdo_mysql connection use them. Unset means disabled, so
existing boards are unaffected.

PHPBB-17767
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.

1 participant