From 0361a7d1a8649c67175883a530f9e62e6e5ec89d Mon Sep 17 00:00:00 2001 From: Markus Humm Date: Sun, 29 Oct 2023 15:29:37 +0100 Subject: [PATCH 1/2] Updated contributors list and copyright year --- NOTICE.txt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/NOTICE.txt b/NOTICE.txt index b2cec1ff..0ef92e60 100644 --- a/NOTICE.txt +++ b/NOTICE.txt @@ -2,7 +2,7 @@ DEC - Delphi Encryption Compendium Version 6.5 Copyright (c) 2018 - 2020 Norman Gallery (ng931884 [at] gmx [dot] de) -Copyright (c) 2016 - 2022 Markus Humm (markus [dot] humm [at] googlemail [dot] com) (main contact) +Copyright (c) 2016 - 2023 Markus Humm (markus [dot] humm [at] googlemail [dot] com) (main contact) Copyright (c) 2008 - 2019 Frederik A. Winkelsdorf (winkelsdorf [at] gmail [dot] com) Copyright (c) 1999 - 2008 Hagen Reddmann (HaReddmann [at] T-Online [dot] de) @@ -27,6 +27,7 @@ Gloegg pierangelodalben denovosoftware alexrayne +Stevie Parts of the work loosely based on the works of Wolfgang Erhardt, who is unfortunately dead already. From 2627cfd61ec5bc1b738852f76a7b78c71ef5662d Mon Sep 17 00:00:00 2001 From: Edwin Date: Wed, 15 Nov 2023 12:52:34 +0100 Subject: [PATCH 2/2] Prevent rangechecking Error --- Source/DECCipherModesGCM.pas | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/Source/DECCipherModesGCM.pas b/Source/DECCipherModesGCM.pas index 4975c895..9abd207b 100644 --- a/Source/DECCipherModesGCM.pas +++ b/Source/DECCipherModesGCM.pas @@ -608,7 +608,8 @@ procedure TGCM.DecodeGCM(Source, Dest: TBytes; Size: Integer); a_tag := XOR_T128(CalcGaloisHash(DataToAuthenticate, Source, Size), FE_K_Y0); Setlength(FCalcAuthenticationTag, FCalcAuthenticationTagLength); - Move(a_tag[0], FCalcAuthenticationTag[0], FCalcAuthenticationTagLength); + if (FCalcAuthenticationTagLength > 0) then + Move(a_tag[0], FCalcAuthenticationTag[0], FCalcAuthenticationTagLength); // Check for correct authentication result is in Done of DECCipherModes // if not IsEqual(FExpectedAuthenticationTag, FCalcAuthenticationTag) then @@ -646,7 +647,8 @@ procedure TGCM.EncodeGCM(Source, Dest: TBytes; Size: Integer); AuthTag := XOR_T128(CalcGaloisHash(DataToAuthenticate, Dest, Size), FE_K_Y0); Setlength(FCalcAuthenticationTag, FCalcAuthenticationTagLength); - Move(AuthTag[0], FCalcAuthenticationTag[0], FCalcAuthenticationTagLength); + if (FCalcAuthenticationTagLength > 0) then + Move(AuthTag[0], FCalcAuthenticationTag[0], FCalcAuthenticationTagLength); end; function TGCM.EncodeT128(Value: T128): T128;