using rot13 and tr command for having an encrypted email address

前端 未结 5 2084
旧时难觅i
旧时难觅i 2020-12-13 06:04

I have read many tutorials on the internet about the usage of the \'tr\' command. However, I am not able to understand how to encrypt an email address with a shell script sh

5条回答
  •  [愿得一人]
    2020-12-13 06:41

    Ruby(1.9+)

    $ ruby -ne 'print $_.tr( "A-Za-z", "N-ZA-Mn-za-m") ' file
    

    Python

    $ echo "test" | python -c 'import sys; print sys.stdin.read().encode("rot13")'
    

提交回复
热议问题