From 81bb6873f1c0291fecbf6e429ad15ac3db66a4c0 Mon Sep 17 00:00:00 2001 From: Aki Date: Tue, 12 Mar 2024 22:07:03 +0100 Subject: Legal notices updated Rename contrib -> third-party intendes to express the origin and purpose of that part of the code better. I plan to readd contrib/ again but with more in-project things like bash-completions, dev workflow scripts etc. --- contrib/sha1/include/Sha1.h | 89 --------------------------------------------- 1 file changed, 89 deletions(-) delete mode 100644 contrib/sha1/include/Sha1.h (limited to 'contrib/sha1/include') diff --git a/contrib/sha1/include/Sha1.h b/contrib/sha1/include/Sha1.h deleted file mode 100644 index ec64462..0000000 --- a/contrib/sha1/include/Sha1.h +++ /dev/null @@ -1,89 +0,0 @@ -/* -* Sha1.h -* -* Copyright (C) 1998 -* Paul E. Jones -* All Rights Reserved. -* -***************************************************************************** -* $Id: sha1.h,v 1.4 2001/03/20 06:25:06 paulej Exp $ -***************************************************************************** -* -* Description: -* This class implements the Secure Hashing Standard as defined -* in FIPS PUB 180-1 published April 17, 1995. -* -* Many of the variable names in this class, especially the single -* character names, were used because those were the names used -* in the publication. -* -* Please read the file sha1.cpp for more information. -* -*/ - -#ifndef _SHA1_H_ -#define _SHA1_H_ - -class SHA1 -{ - -public: - - SHA1(); - virtual ~SHA1(); - - /* - * Re-initialize the class - */ - void Reset(); - - /* - * Returns the message digest - */ - bool Result(unsigned *message_digest_array); - - /* - * Provide input to SHA1 - */ - void Input( const unsigned char *message_array, - unsigned length); - void Input( const char *message_array, - unsigned length); - void Input(unsigned char message_element); - void Input(char message_element); - SHA1& operator<<(const char *message_array); - SHA1& operator<<(const unsigned char *message_array); - SHA1& operator<<(const char message_element); - SHA1& operator<<(const unsigned char message_element); - -private: - - /* - * Process the next 512 bits of the message - */ - void ProcessMessageBlock(); - - /* - * Pads the current message block to 512 bits - */ - void PadMessage(); - - /* - * Performs a circular left shift operation - */ - inline unsigned CircularShift(int bits, unsigned word); - - unsigned H[5]; // Message digest buffers - - unsigned Length_Low; // Message length in bits - unsigned Length_High; // Message length in bits - - unsigned char Message_Block[64]; // 512-bit message blocks - int Message_Block_Index; // Index into message block array - - bool Computed; // Is the digest computed? - bool Corrupted; // Is the message digest corruped? - -}; - -#endif -- cgit v1.1