Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed #14508: Added PDO::MYSQL_ATTR_SSL_VERIFY_SERVER_CERT options to database.php … #14511

Merged
merged 1 commit into from
Apr 18, 2024

Conversation

jeffclay
Copy link
Contributor

@jeffclay jeffclay commented Mar 27, 2024

…and updated .env files to provide value for the new option.

Description

Added PDO::MYSQL_ATTR_SSL_VERIFY_SERVER_CERT options to database.php as documented here

Fixes #14508

Type of change

Please delete options that are not relevant.

  • New feature (non-breaking change which adds functionality)

How Has This Been Tested?

Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration

Tested locally

Test Configuration:

  • PHP version: 8.1.27
  • MySQL version 8
  • Webserver version apache
  • OS version Rocky Linux 9

Checklist:

…and updated .env files to provide value for the new option.
@jeffclay jeffclay requested a review from snipe as a code owner March 27, 2024 16:44
Copy link

welcome bot commented Mar 27, 2024

💖 Thanks for this pull request! 💖

We use semantic commit messages to streamline the release process and easily generate changelogs between versions. Before your pull request can be merged, you should update your pull request title to start with a semantic prefix if it doesn't have one already.

Examples of commit messages with semantic prefixes:

  • Fixed #<issue number>: don't overwrite prevent_default if default wasn't prevented
  • Added #<issue number>: add checkout functionality to assets
  • Improved Asset Checkout: use new notification method for checkout

Things that will help get your PR across the finish line:

  • Document any user-facing changes you've made.
  • Include tests when adding/changing behavior.
  • Include screenshots and animated GIFs whenever possible.

We get a lot of pull requests on this repo, so please be patient and we will get back to you as soon as we can.

Copy link

what-the-diff bot commented Mar 27, 2024

PR Summary

  • Addition to Environment Files
    Enhancements were added in the form of new code to multiple '.env' files. These changes make sure that our application communicates securely with the database.

  • Database Config File Update
    Modifications were done in our application's database configuration file. It involves the addition of certain attributes related to the verification of the SSL server. This strengthens our database connection security, providing a more secure environment for our data.

@jeffclay jeffclay changed the title Added PDO::MYSQL_ATTR_SSL_VERIFY_SERVER_CERT options to database.php … Fixed #14508: Added PDO::MYSQL_ATTR_SSL_VERIFY_SERVER_CERT options to database.php … Mar 27, 2024
@snipe snipe requested a review from uberbrady March 27, 2024 18:23
@@ -96,6 +96,7 @@
PDO::MYSQL_ATTR_SSL_CERT => env('DB_SSL_CERT_PATH'), // /path/to/cert.pem
PDO::MYSQL_ATTR_SSL_CA => env('DB_SSL_CA_PATH'), // /path/to/ca.pem
PDO::MYSQL_ATTR_SSL_CIPHER => env('DB_SSL_CIPHER'),
PDO::MYSQL_ATTR_SSL_VERIFY_SERVER_CERT => env('DB_SSL_VERIFY_SERVER'), //true/false
Copy link
Owner

Choose a reason for hiding this comment

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

Should we perhaps default this to something sane if folks don't add this value to their .env?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Good point, I wasn't thinking about upgrading existing installs without updating the .env file. Let me test the behavior when the value is set to null.

Copy link
Owner

Choose a reason for hiding this comment

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

Also check if the variable doesn't even exist in the .env :)

@snipe snipe merged commit e59b962 into snipe:develop Apr 18, 2024
8 checks passed
Copy link

welcome bot commented Apr 18, 2024

Congrats on merging your first pull request! 🎉🎉🎉

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants