Hi Guys,
We can create encrypted files using the vim editor. Lets have a look how to do this.
1. use the switch 'x' with vim editor to create encrypted file.
#vim -x file.txt
2. The file called 'file.txt' will open up and there will be a prompt saying "
Enter encryption key:" there we have to enter the encryption key
3. Confirm the encryption key again and press 'i' to input to the file. then save the file using 'wq'
4. Try to view the file content using cat command we will get some encrypted data.
#cat file.txt
VimCrypt~01!dJH!�W�γ4l�fF&�
5. Open the file with vim editor again and provide the encryption key, then only we can see the original data.
Thank you.