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

Request for support for relationships when using encrypted columns #28

Open
lduf opened this issue Jan 17, 2023 · 0 comments
Open

Request for support for relationships when using encrypted columns #28

lduf opened this issue Jan 17, 2023 · 0 comments

Comments

@lduf
Copy link

lduf commented Jan 17, 2023

Description :

I am currently using the elgiborsolution/laravel-database-encryption package to encrypt certain columns in my database. However, I am running into issues when trying to use relationships (such as hasManyThrough) with encrypted columns. The package is not able to search the related columns as they are encrypted.

I believe it would be extremely useful to have support for relationships when using encrypted columns, as it would make it much easier to work with encrypted data in a Laravel application.

I would greatly appreciate it if the developers could consider adding this feature in a future update to the package.

Additional context:

  • Package version : * 1.1.0
  • Laravel Version : Laravel Framework 9.46.0

Example :

In the following example, I need to access to 'value' which is encrypted

class Event extends Model {
    public function persons() {
        return $this->hasManyThrough(Person::class, FieldPerson::class, 'value', 'id', 'id', 'person_id');
    }
}

Please let me know if you need any more help or if there is anything else that I can do to assist you.

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

No branches or pull requests

1 participant