My requirement is to encrypt/decrypt a tcl file without a openssl password prompt, but read the password automatically from a file. my test_en.tcl has the following encrypt/decrypt commands:
exec openssl enc -aes-256-cbc -in test_en.tcl -out encrpt_test_en.tcl exec openssl enc -aes-256-cbc -d -in encrpt_test_en.tcl > new_test_en.tcl
How can I read the password from a file into tcl script and avoid manual entry to encrypt/decrypt the file automatically?
Please suggest correct way to send the password to tcl script.