SHA256.cs 962 B

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. //
  2. // System.Security.Cryptography SHA256 Class implementation
  3. //
  4. // Authors:
  5. // Matthew S. Ford ([email protected])
  6. //
  7. // Copyright 2001 by Matthew S. Ford.
  8. //
  9. using System.Security.Cryptography;
  10. namespace System.Security.Cryptography {
  11. /// <summary>
  12. /// Common base class for all derived SHA256 iplementations.
  13. /// Abstract.
  14. /// </summary>
  15. public abstract class SHA256 : HashAlgorithm {
  16. /// <summary>
  17. /// Called from constructor of derived class.
  18. /// </summary>
  19. protected SHA256 () {
  20. }
  21. /// <summary>
  22. /// Creates the default derived class.
  23. /// </summary>
  24. public static new SHA256 Create () {
  25. return new SHA256Managed ();
  26. }
  27. /// <summary>
  28. /// Creates a new derived class.
  29. /// </summary>
  30. /// <param name="st">FIXME: No clue. Specifies which derived class to create?</param>
  31. public static new SHA256 Create (string st) {
  32. return Create ();
  33. }
  34. }
  35. }