From: philsmd Date: Sun, 6 Mar 2016 12:31:12 +0000 (+0100) Subject: #244: ADL array out-of-bound fix X-Git-Tag: v3.00-beta~192^2 X-Git-Url: https://www.flypig.org.uk/git/?a=commitdiff_plain;h=4ede3c1f7e56fb9102411bda7e2a6b3e9836acf9;p=hashcat.git #244: ADL array out-of-bound fix --- diff --git a/include/ext_ADL.h b/include/ext_ADL.h index b90128b..0146b8b 100644 --- a/include/ext_ADL.h +++ b/include/ext_ADL.h @@ -160,11 +160,17 @@ typedef struct ADLODPerformanceLevel int iVddc; } ADLODPerformanceLevel; +/* + * Attention: we had to change this struct due to an out-of-bound problem mentioned here: + * https://github.com/hashcat/oclHashcat/issues/244 + * the change: ADLODPerformanceLevel aLevels [1] -> ADLODPerformanceLevel aLevels [2] + */ + typedef struct ADLODPerformanceLevels { int iSize; int iReserved; - ADLODPerformanceLevel aLevels [1]; + ADLODPerformanceLevel aLevels [2]; } ADLODPerformanceLevels; typedef struct ADLOD6FanSpeedInfo @@ -221,12 +227,18 @@ typedef struct ADLOD6PerformanceLevel int iMemoryClock; } ADLOD6PerformanceLevel; +/* + * Attention: we had to change this struct due to an out-of-bound problem mentioned here: + * https://github.com/hashcat/oclHashcat/issues/244 + * the change: ADLOD6PerformanceLevel aLevels [1] -> ADLOD6PerformanceLevel aLevels [2] + */ + typedef struct ADLOD6StateInfo { int iNumberOfPerformanceLevels; int iExtValue; int iExtMask; - ADLOD6PerformanceLevel aLevels [1]; + ADLOD6PerformanceLevel aLevels [2]; } ADLOD6StateInfo; typedef struct ADLOD6PowerControlInfo