I'm not a cryptography expert myself, and know enough to know that I shouldn't design my own crypto schemes, so I thought I'd seek advice here.
In an application, let's say we have two database tables: Lawyers and Clients. There exists a many-to-many relationship between these two models, so a Lawyer can have many Clients and a Client can have many Lawyers. As is typical in relational databases, there is a Join Table containing pointers to rows in each table in order to define the relationships between them.
The columns for the Join Table might look like this:
id | client_id | lawyer_id
Now let's say that in our security model, information about lawyers and information about clients are not considered privileged information on their own, so there's no need to encrypt them in any way. However, information about the relationship between Lawyers and Clients is privileged information that we would like to protect in the event an attacker gains access to the database.
Does there exist a common encryption scheme that securely encrypts
lawyer_id without rendering the Join Table useless?