Say, I have encrypted data in a database. How wise is it to break a secret encryption key into several parts and save each one in a different place?
key1 = get_key1_from_remote_server() key2 = get_key2_from_env_variable() key3 = get_key3_from_some_protected_storage() full_key = key1 + key2 + key3 enc_data = encrypt(data, full_key)
Thus a hacker will have to gain access to all those locations to decrypt data.
Is this more secure than to have a whole key stored in one place?