1
0
mirror of https://github.com/moparisthebest/xeps synced 2024-12-21 23:28:51 -05:00

fixed openssl examples

git-svn-id: file:///home/ksmith/gitmigration/svn/xmpp/trunk@305 4b5297f7-1745-476d-ba37-a9c6900126ab
This commit is contained in:
Peter Saint-Andre 2007-01-03 22:23:12 +00:00
parent d5f22dffb8
commit b4931fb363

View File

@ -215,8 +215,14 @@
</query>
</iq>
]]></code>
<p>Some examples (e.g., SASL examples) include strings that are encoded using Base64 (see &rfc3548;). An easy way to generate these is to place the source text in a file and use the <link url='http://www.openssl.org/'>OpenSSL</link> "enc" command to generate the base64-encoded equivalent. For example, if the file "tmp.txt" contains the string "bard@shakespeare.lit" then the command 'openssl enc -base64 -in tmp.txt' will generate the base64-encoded string "YmFyZEBzaGFrZXNwZWFyZS5saXQK".</p>
<p>Some examples (e.g., avatar examples) include strings that are SHA-1 hashes (see &rfc3174;). An easy way to generate these is to place the source text in a file and use the <link url='http://www.openssl.org/'>OpenSSL</link> "dgst" command to generate the SHA-1 hash. For example, if the file "tmp.txt" contains the string "bard@shakespeare.lit" then the command 'openssl dgst -sha1 tmp.txt' will generate the SHA-1 hash "e87f5008d779053ac53b29b335b7be8820d5c303".</p>
<p>Some examples (e.g., SASL examples) include strings that are encoded using Base64 (see &rfc3548;). An easy way to generate these is to use the <link url='http://www.openssl.org/'>OpenSSL</link> "enc" command to generate the base64-encoded equivalent. For example, the following command will generate the base64-encoded string "YmFyZEBzaGFrZXNwZWFyZS5saXQ=":</p>
<code>
echo -n 'bard@shakespeare.lit' | openssl enc -base64
</code>
<p>Some examples (e.g., avatar examples) include strings that are SHA-1 hashes (see &rfc3174;). An easy way to generate these is to use the <link url='http://www.openssl.org/'>OpenSSL</link> "dgst" command to generate the SHA-1 hash. For example, the following command will generate the SHA-1 hash "9f5f9fdab9da7fc12e3c52b258acbcb4bb8e66ac":</p>
<code>
echo -n 'bard@shakespeare.lit' | openssl dgst -sha1
</code>
</section2>
<section2 topic='Conformance Terms' anchor='style-conf'>
<p>Conformance terms (e.g,, "MUST" and "SHOULD") are specified in RFC 2119. Use them. When such terms are not in ALL CAPS, the special conformance sense does not apply (this should be obvious but may not be to all authors).</p>