Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- bash-4.1$ echo 'one S56G one two three
- > four five V67X six' > file.txt
- bash-4.1$ cp file.txt result.txt
- bash-4.1$ cat file.txt | grep -o '[A-Z][0-9]\{2\}[A-Z]' | while read i ; do
- > sed -i "s/$i/$(echo $i | openssl dgst -sha1)/g" result.txt
- > done
- bash-4.1$ cat result.txt
- one (stdin)= 0a60d0eef7e4be51a2f3876758d3e565f2f60b74 one two three
- four five (stdin)= a4dac2fba8ece40837e10923c528c5c11299feec six
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement