I have a text file containing strings to encrypt. These strings are indicated by tags.
Example:
This is an <tag> example </tag>.
What is the best way in UNIX (using the common tools like sed, bash, etc. ) to search all occurrences and at the same time replace it with the encrypted value (this is a function of the string inside the tags)?
Result:
This is an <tag> <encrypted value here> </tag>.
Thanks in advance!
Ok, I was able to find a solution a few days ago.
I used bash and regular expressions.
Here is how I did it: