Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I want any tool (freeware) can convert any file to ascii output, like gpg -a.

the program should give me something like,

-----BEGIN PGP MESSAGE-----
Version: GnuPG v2.0.17 (MingW32)

jA0EAwMCxCbCmUr9TrG1ye1EJ3koyybtcdu6WuiYg0dL9UBWapeePCdw+/URfL4Z
UkxMtUjWb2PB4iBt2luEj8dYD5XzMIb6fOAo9nmnmYc8WwoPMq8F2aTmbUf/72Kg
nDOJZpK7M8mWf3uuCwCLiO+TCPAGWKTp5w40fj+CcJwNmGGabHDFuR6aiEEyj3Wg
6oFgBX/yzxJ5d6VUnfq9id830sLTSwaC/Zji2fYz53AMNMVPhfqINvLkaYO3Lqby
-----END PGP MESSAGE-----

I google alot finding nothing, is there such a tool or no, I dont want the tool to ask for any passwords just convert file to ascii so I can send by email.

share|improve this question

closed as off topic by Nifle, Dave M, 8088, ChrisF, Windos Jan 29 '13 at 0:28

Questions on Super User are expected to relate to computer software or computer hardware within the scope defined by the community. Consider editing the question or leaving comments for improvement if you believe the question can be reworded to fit within the scope. Read more about reopening questions here.If this question can be reworded to fit the rules in the help center, please edit the question.

add comment

2 Answers 2

up vote 2 down vote accepted

GnuPG has this functionality as the --store option, which just wraps incoming data inside an OpenPGP "Literal Data" packet, which can be ASCII-armored. For decoding, use gpg -d. (There is also an --enarmor option, which adds no OpenPGP headers at all, just applies the "armor", and requires the corresponding --dearmor option to unwrap.)

However, the "ASCII armor" used in OpenPGP is just a modified version of Base64 encoding, a very common algorithm for which many tools are available, many of them called just base64 or b64encode, or openssl base64 -e.

However, all email clients that support MIME – that is, practically every single email client nowadays – already have built-in Base64 encoding functions. You just need to find the "Attach file" option, and the attachment will be automatically encoded when sending.

Another similar algorithm is Uuencode, which is similar to Base64 but specific to mail & netnews, and rarely used elsewhere. See also binary-to-text encoding for a general overview.

share|improve this answer
    
'gpg --enarmor' works, u save my day... thanks –  user193514 Jan 28 '13 at 20:53
add comment

Are you thinking of base64 (http://en.wikipedia.org/wiki/Base64)? That will convert a file into ascii characters that you can email and then reform into the file. There are numerous ways to convert a file to base64; http://www.opinionatedgeek.com/dotnet/tools/base64encode/ is an example of an online tool.

share|improve this answer
add comment

Not the answer you're looking for? Browse other questions tagged or ask your own question.