cryptest fails, but only when redirecting output to a file

Bart Vandewoestyne <[email protected]>
Newsgroups gmane.comp.encryption.cryptopp
Message-ID <[email protected]>
Hello,

I have built Crypto++ 8.20 on Windows using Visual Studio 2019 in both 
Debug and Release configuration using something like

msbuild cryptest.sln /t:cryptlib;cryptest 
/p:Configuration="Debug";Platform=Win32;PlatformToolset=v142;WholeProgramOptimization="false""

For both the Debug and Release build, when I run the cryptest.exe as 
follows:

cryptest.exe v

it seems to run fine because I get:

-------------------------------------------------------------------------------------------------------------------------------------
Using seed: 1616082124

Testing Settings...

passed:  Your machine is little endian.
passed:  Aligned data access.
passed:  sizeof(byte) == 1
passed:  sizeof(word16) == 2
passed:  sizeof(word32) == 4
passed:  sizeof(word64) == 8
passed:  sizeof(hword) == 2, sizeof(word) == 4, sizeof(dword) == 8
passed:  cacheLineSize == 64
hasSSE2 == 1, hasSSSE3 == 1, hasSSE4.1 == 1, hasSSE4.2 == 1, hasAVX == 1, 
hasAVX2 == 1, hasAESNI == 1, hasCLMUL == 1, hasRDRAND == 1, hasRDSEED == 1, 
hasSHA == 0, isP4 == 0

Testing operating system provided nonblocking random number generator...

passed:  10240 generated bytes compressed to 10245 bytes by DEFLATE
passed:  IncorporateEntropy with 128 bytes
passed:  GenerateWord32 and Crop
passed:  DiscardBytes with 1024 bytes

Testing RandomPool generator...

passed:  10240 generated bytes compressed to 10245 bytes by DEFLATE
passed:  IncorporateEntropy with 128 bytes
passed:  GenerateWord32 and Crop
passed:  DiscardBytes with 1024 bytes

Testing AutoSeeded RandomPool generator...

passed:  10240 generated bytes compressed to 10245 bytes by DEFLATE
passed:  IncorporateEntropy with 128 bytes
passed:  GenerateWord32 and Crop
passed:  DiscardBytes with 1024 bytes

Testing OldRandomPool generator...

passed:  10240 generated bytes compressed to 10245 bytes by DEFLATE
passed:  IncorporateEntropy with 128 bytes
passed:  GenerateWord32 and Crop
passed:  DiscardBytes with 1024 bytes
passed:  Expected sequence from PGP-style RandomPool (circa 2007)

Testing AutoSeeded X917 generator...

passed:  10240 generated bytes compressed to 10245 bytes by DEFLATE
passed:  IncorporateEntropy with 128 bytes
passed:  GenerateWord32 and Crop
passed:  DiscardBytes with 1024 bytes

Testing Padlock RNG generator...

Padlock RNG generator not available, skipping test.

Testing RDRAND generator...

passed:  10240 generated bytes compressed to 10245 bytes by DEFLATE
passed:  IncorporateEntropy with 128 bytes
passed:  GenerateWord32 and Crop
passed:  DiscardBytes with 1024 bytes
passed:  Maurer Randomness Test returned value 1.000000

Testing RDSEED generator...
-------------------------------------------------------------------------------------------------------------------------------------
However, when (in a script or on my windows cmd prompt) I try to redirect 
the output to a file using

cryptest.exe v > output.txt
or
cryptest.exe v > output.txt 2>&1

then i get my cmd prompt back, but the output.txt file only contains

Using seed: 1616082222      

and that's it.  What am I doing wrong here?

Regards,
Bart

-- 
You received this message because you are subscribed to the Google Groups "Crypto++ Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].
To view this discussion on the web visit https://groups.google.com/d/msgid/cryptopp-users/680b1e29-3ac1-4f60-a9e6-f93c44637630n%40googlegroups.com.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.