summaryrefslogtreecommitdiff
path: root/strciphr.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Try fix ProcessData in CFB_CipherTemplate and AdditiveCipherTemplateJeffrey Walton2022-02-131-56/+14
| | | | | This commit attempts to restore performance while taming the optimizer. Also see GH #683, GH #1010, GH #1088, GH #1103.
* Update comments in strcpher.cppJeffrey Walton2021-11-291-25/+31
|
* Add ASSERT in ProcessData to warn of non-distinct buffers (GH #1088)Jeffrey Walton2021-11-281-0/+8
|
* Update AdditiveCipherTemplate<S>::ProcessData (GH #1010)Jeffrey Walton2021-04-091-2/+6
|
* Clear Clang warningsJeffrey Walton2021-03-211-0/+2
|
* Update tempOutString buffer length calculationJeffrey Walton2021-03-171-2/+2
|
* Update commentsJeffrey Walton2021-03-171-11/+0
|
* Update commentsJeffrey Walton2021-03-171-2/+2
|
* Fix CTR mode when using FileSource (GH #683, GH #1010)Jeffrey Walton2021-03-171-47/+80
| | | | | | | | We think this is another instance problem that surfaced under GH #683 when inString==outString. It violates aliasing rules and the compiler begins removing code. The ultimate workaround was to add a member variable m_tempOutString as scratch space when inString==outString. We did not loose much in the way of perforamce for some reason. It looks like AES/CTR lost about 0.03-0.05 cpb. When combined with the updated xorbuf from GH #1020, the net result was a speedup of 0.1-0.6 cpb. In fact, some ciphers like RC6, gained almost 5 cpb.
* Avoid memcpy in AdditiveCipherTemplate<S>::ProcessData (GH #683, GH #1010, ↵Jeffrey Walton2021-03-161-26/+40
| | | | | PR #1019) We found we can avoid the memcpy in the previous workaround by using a volatile pointer. The pointer appears to tame the optimizer so the compiler does not short-circuit some calls when outString == inString.
* Cleanup CFB mode for Cryptogams AESJeffrey Walton2020-04-131-18/+23
|
* Add ability to Seek64 in test framework (GH #732)Jeffrey Walton2018-11-041-11/+5
| | | | Also see https://github.com/randombit/botan/pull/1728
* Update commentsJeffrey Walton2018-10-141-3/+2
|
* Enable same buffer for in and out on ARM A-32 (GH #683)Jeffrey Walton2018-10-131-13/+14
|
* Clear unused variable warningJeffrey Walton2018-07-141-1/+1
|
* Increase use of ptrdiff_t when performing pointer mathJeffrey Walton2018-07-121-5/+5
|
* Revert "Increase use of ptrdiff_t when performing pointer math"Jeffrey Walton2018-07-121-6/+43
| | | | This reverts commit bbf9a109f268. It did not fix A-32. Something got crossed in my test case.
* Increase use of ptrdiff_t when performing pointer mathJeffrey Walton2018-07-121-43/+6
| | | | This fixes the incorrect result with CFB mode on A-32 in CFB_CipherTemplate<BASE>::ProcessData
* Update commentsJeffrey Walton2018-07-121-3/+34
|
* Disable same buffer for in and out on ARM A-32 (GH #683)Jeffrey Walton2018-07-121-1/+6
|
* Add ARM AES asm implementation from Cryptogams (GH #683)Jeffrey Walton2018-07-111-0/+1
|
* Add PtrAdd and PtrSub helper functionsJeffrey Walton2018-07-101-44/+37
| | | | This helps contain UB on pointer subtraction by ensuring a ptrdiff_t is used. The code is a little uglier but it is also more portable.
* Squash MS LNK4221 and libtool warningsJeffrey Walton2018-07-061-0/+5
|
* Revert AltiVec and Power8 commitsJeffrey Walton2017-09-051-21/+12
| | | | | The strategy of "cleanup under-aligned buffers" is not scaling well. Corner cases are still turing up. The library has some corner-case breaks, like old 32-bit Intels. And it still has not solved the AltiVec and Power8 alignment problems. For now we are backing out the changes and investigating other strategies
* Fixup under-aligned buffers for stream ciphers on AltiVec and Power8Jeffrey Walton2017-09-041-12/+21
| | | | | | | | This commit supports the upcoming AltiVec and Power8 processor support for stream ciphers. This commit affects GlobalRNG() most because its an AES-based generator. The commit favors AlignedSecByteBlock over SecByteBlock in places where messages are handled on the AltiVec and Power8 processor data paths. The data paths include all block cipher modes of operation, and some filters like FilterWithBufferedInput. Intel and ARM processors are tolerant of under-aligned buffers when using crypto instructions. AltiVec and Power8 are less tolerant, and they simply ignore the three low-order bits to ensure an address is aligned. The AltiVec and Power8 have caused a fair number of wild writes on the stack and in the heap. Testing on a 64-bit Intel Skylake show a marked improvement in performance. We suspect GCC is generating better code since it knows the alignment of the pointers, and does not have to emit fixup code for under-aligned and mis-aligned data. Testing on an mid-2000s 32-bit VIA C7-D with SSE2+SSSE3 showed no improvement, and no performance was lost.
* Change file preamble to include "originally written by Wei Dai"Jeffrey Walton2017-01-271-1/+1
| | | | We have made a fair number of changes, and we don't want WD to receive credit for issues he was not part of
* Add CRYPTOPP_ASSERT (Issue 277, CVE-2016-7420)Jeffrey Walton2016-09-161-4/+4
| | | | trap.h and CRYPTOPP_ASSERT has existed for over a year in Master. We deferred on the cut-over waiting for a minor version bump (5.7). We have to use it now due to CVE-2016-7420
* CRYPTOPP 5.6.3 RC6 checkinJeffrey Walton2015-11-051-253/+252
|
* Cut-in CRYPTOPP_ASSERT in all remaining header and source filesJeffrey Walton2015-07-261-4/+4
|
* Added "trap.h" include for header and source files that assertJeffrey Walton2015-07-261-0/+1
|
* changes for 5.6: weidai2009-03-021-35/+31
| | | | | | - added AuthenticatedSymmetricCipher interface class and Filter wrappers - added CCM, GCM (with SSE2 assembly), CMAC, and SEED - improved AES speed on x86 and x64 - removed WORD64_AVAILABLE; compiler 64-bit int support is now required
* add IncorporateEntropy and GenerateIntoBufferedTransformation to RNG interfaceweidai2007-05-041-16/+0
|
* SSE2 optimizationsweidai2007-04-151-16/+64
|
* update version number, port to Sun C++ 5.8weidai2006-12-181-0/+29
|
* port to Borland C++Builder 2006weidai2006-12-141-1/+1
|
* port to MSVC .NET 2005 beta 2weidai2005-07-121-6/+6
|
* port to GCC 3.4weidai2004-06-191-7/+7
|
* add CFB mode FIPS variantweidai2004-04-291-0/+2
|
* fix bugs in 64-bit CPU supportweidai2003-07-251-1/+1
|
* create DLL version, fix GetNextIV() bug in CTR and OFB modesweidai2003-07-041-0/+5
|
* fix warnings for VC7 and GCCweidai2003-03-201-1/+1
|
* add script-driven testingweidai2002-12-061-1/+1
|
* Initial revisionweidai2002-10-041-0/+188