text
stringlengths 0
14.1k
|
---|
) |
func TestParseHdbSignatureRow(t *testing.T) { |
signature := new(signature) |
sample := ""e11c2aff804ca144a3e49c42d6ac5783:1006:Exploit.CVE_2012_0779"" |
sig := parseHdbSignatureRow(sample, signature) |
if sig.Size != 1006 { |
t.Fatal(""Error parsing HDB or HSB signature length"") |
} |
if signature.SigHash != ""e11c2aff804ca144a3e49c42d6ac5783"" { |
t.Fatal(""Error parsing HDB or HSB signature hash"") |
} |
} |
" isc |
ibc/MediaSoup worker/deps/openssl/openssl/crypto/whrlpool/wp_block.c 34797 "/* |
* Copyright 2005-2019 The OpenSSL Project Authors. All Rights Reserved. |
* |
* Licensed under the OpenSSL license (the ""License""). You may not use |
* this file except in compliance with the License. You can obtain a copy |
* in the file LICENSE in the source distribution or at |
* https://www.openssl.org/source/license.html |
*/ |
/** |
* The Whirlpool hashing function. |
* |
* See |
* P.S.L.M. Barreto, V. Rijmen, |
* ``The Whirlpool hashing function,'' |
* NESSIE submission, 2000 (tweaked version, 2001), |
* <https://www.cosic.esat.kuleuven.ac.be/nessie/workshop/submissions/whirlpool.zip> |
* |
* Based on ""@version 3.0 (2003.03.12)"" by Paulo S.L.M. Barreto and |
* Vincent Rijmen. Lookup ""reference implementations"" on |
* <http://planeta.terra.com.br/informatica/paulobarreto/> |
* |
* ============================================================================= |
* |
* THIS SOFTWARE IS PROVIDED BY THE AUTHORS ''AS IS'' AND ANY EXPRESS |
* OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED |
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE |
* ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHORS OR CONTRIBUTORS BE |
* LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR |
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF |
* SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR |
* BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, |
* WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE |
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, |
* EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
* |
*/ |
#include ""wp_locl.h"" |
#include <string.h> |
typedef unsigned char u8; |
#if (defined(_WIN32) || defined(_WIN64)) && !defined(__MINGW32) |
typedef unsigned __int64 u64; |
#elif defined(__arch64__) |
typedef unsigned long u64; |
#else |
typedef unsigned long long u64; |
#endif |
#define ROUNDS 10 |
#define STRICT_ALIGNMENT |
#if !defined(PEDANTIC) && (defined(__i386) || defined(__i386__) || \ |
defined(__x86_64) || defined(__x86_64__) || \ |
defined(_M_IX86) || defined(_M_AMD64) || \ |
defined(_M_X64)) |
/* |
* Well, formally there're couple of other architectures, which permit |
* unaligned loads, specifically those not crossing cache lines, IA-64 and |
* PowerPC... |
*/ |
# undef STRICT_ALIGNMENT |
#endif |
#undef SMALL_REGISTER_BANK |
#if defined(__i386) || defined(__i386__) || defined(_M_IX86) |
# define SMALL_REGISTER_BANK |
# if defined(WHIRLPOOL_ASM) |
# ifndef OPENSSL_SMALL_FOOTPRINT |
/* |
* it appears that for elder non-MMX |
* CPUs this is actually faster! |
*/ |
# define OPENSSL_SMALL_FOOTPRINT |
# endif |
# define GO_FOR_MMX(ctx,inp,num) do { \ |
extern unsigned long OPENSSL_ia32cap_P[]; \ |
void whirlpool_block_mmx(void *,const void *,size_t); \ |
if (!(OPENSSL_ia32cap_P[0] & (1<<23))) break; \ |
whirlpool_block_mmx(ctx->H.c,inp,num); return; \ |
} while (0) |
# endif |
#endif |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.