You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by sigzero <si...@gmail.com> on 2012/11/06 14:23:32 UTC

Tomcat digest SHA

What level of SHA does the Tomcat digest script use?

Bob

Re: Tomcat digest SHA

Posted by Christopher Schultz <ch...@christopherschultz.net>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Bob,

On 11/6/12 8:23 AM, sigzero wrote:
> What level of SHA does the Tomcat digest script use?

$ bin/digest.sh
Usage: RealmBase -a <algorithm> [-e <encoding>] <credentials>

Whatever one you type on the command-line. It all comes down to the
JVM's support plus any extensions you've added (BouncyCastle, etc.) to
support other message digest algorithms.

$ bin/digest.sh  -a MD2 foo
foo:d11f8ce29210b4b50c5e67533b699d02

$ /usr/local/apache-tomcat-7.0.32/bin/digest.sh  -a MD5 foo
foo:acbd18db4cc2f85cedef654fccc4a4d8

$ bin/digest.sh  -a SHA-1 foo
foo:0beec7b5ea3f0fdbc95d0dd47f3c5bc275da8a33

$ bin/digest.sh  -a SHA-2 foo
foo:Nov 6, 2012 9:58:30 AM org.apache.catalina.realm.RealmBase Digest
SEVERE: java.security.NoSuchAlgorithmException: SHA-2 MessageDigest
not available
foo

$ bin/digest.sh  -a SHA-256 foo
foo:2c26b46b68ffc68ff99b453c1d30413413422d706483bfa0f98a5e886266e7ae

My JVM also supports SHA-384 and SHA-512.

- -chris
-----BEGIN PGP SIGNATURE-----
Version: GnuPG/MacGPG2 v2.0.17 (Darwin)
Comment: GPGTools - http://gpgtools.org
Comment: Using GnuPG with Mozilla - http://www.enigmail.net/

iEYEARECAAYFAlCZJm4ACgkQ9CaO5/Lv0PAopACdH+2zAR/njekMGN/cJuLo89Sv
y1gAn2V1kV9m2Jo2xu6mNXs1I8eufiHm
=XjT4
-----END PGP SIGNATURE-----

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: Tomcat digest SHA

Posted by Konstantin Kolinko <kn...@gmail.com>.
2012/11/6 sigzero <si...@gmail.com>:
> What level of SHA does the Tomcat digest script use?

1. What version of Tomcat?
2. Be more specific with your question. What digest and what "script"?
There are hardly any scripts in Tomcat.
3. Different versions of SHA produce digests of different lengths.
Once you have one, it should be self-explanatory which version of SHA
was used to produce it.

Best regards,
Konstantin Kolinko

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org