-
Notifications
You must be signed in to change notification settings - Fork 281
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
[Bug][Seatunnel-web] Support encyrption of datasource data #189
base: main
Are you sure you want to change the base?
Conversation
I will review and test this PR in 1-2 days |
datasourceConfig.replace( | ||
Constants.PASSWORD, | ||
ConfigShadeUtils.encryptOption( | ||
datasourceEncryptionType, datasourceConfig.get(Constants.PASSWORD))); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
password is not a mandatory field, it can be empty also, then this code will throw NPE. Encrypt only if passord is not empty.
How this feature works? I see encryption only, I do not see any decryption. How it will be able to connnect to databases, it will fail. |
Thank you for reviewing. Decryption is done on the engine side. There is a ConfigShadeUtils which takes care of the decryption of password while connecting to the datasource. Sure, i can share the details. |
|
d3afefb
to
0034129
Compare
Hi @arshadmohammad |
Currently Datasource passwords are stored as it is in database and also is sent to seatunnel-engine in .profile file. All sensitive information like password should be encrypted. Also the API response should be encrypted for datasource password.
This patch handles the encryption of data using the encryption type available in seatunnel-engine. We can use base64 encryption type.
When we enable this encryption type, we need it configure it in job env like below:
env {
"shade.identifier" =base64
}
add shade.identifier to your env. you can refer to below doc for more understanding
https://seatunnel.apache.org/docs/2.3.2/connector-v2/Config-Encryption-Decryption/