Skip to content

Conversation

@Roardom
Copy link
Collaborator

@Roardom Roardom commented Jul 17, 2025

Questions:

What should be done if a value fails to decrypt during the migration (e.g. if the key was rotated and the old key no longer exists under APP_PREVIOUS_KEYS)? Right now the migration fails.

Possible options:

  • Don't migrate the record
  • Save an empty string (encrypted)
  • Save The value could not be decrypted (encrypted)
  • Delete the record

Note that laravel's native encrypted cast will throw an exception causing a 500 error if decryption fails instead of falling back to The value could not be decrypted like the current trait.

@what-the-diff
Copy link

what-the-diff bot commented Jul 17, 2025

PR Summary

  • Encryption Handling Overhaul for Donation and Seedbox Models
    Removal of Encryptable trait and adjustments to data encryption handling.
  • Type Change of 'transaction' Attribute in Donation Model
    Type updated to 'encrypted' indicating a shift in encryption methodology.
  • 'ip' Attribute Designated as 'Encrypted' in Seedbox Model
    Change reflective of the new encryption standards.
  • Deletion of Encryptable Trait
    No longer needed after encryption processes refactoring.
  • Inclusion of New Database Migration
    New file to re-encrypt existing 'transaction' and 'ip' data in respective tables.
  • MySQL Schema Updated
    New migration file included in the list of applied migrations.
  • Model Documentation Updated
    Adjustments to encapsulate changes to encryption standards and attributes.

@Roardom Roardom force-pushed the native-laravel-encrypted-cast branch 2 times, most recently from c0f4288 to f9b5021 Compare July 17, 2025 07:06
@Roardom Roardom force-pushed the native-laravel-encrypted-cast branch from f9b5021 to a9f7002 Compare July 17, 2025 09:53
@HDVinnie HDVinnie added the Stale label Sep 18, 2025
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