Differences From Artifact [163ddcc8f1]:
- File
src/scrypt.m
— part of check-in
[63f5276b33]
at
2020-06-21 22:08:00
on branch trunk
— Move parameters for of_scrypt() to a struct
This should make it more readable for such a large number of parameters. (user: js, size: 6818) [annotate] [blame] [check-ins using] [more...]
To Artifact [b6bce8773e]:
- File src/scrypt.m — part of check-in [9d74d1b74e] at 2020-11-06 02:12:39 on branch trunk — OFData: Make parameter order more consistent (user: js, size: 6818) [annotate] [blame] [check-ins using] [more...]
︙ | ︙ | |||
162 163 164 165 166 167 168 | uint32_t *tmpItems, *bufferItems; if (param.costFactor > SIZE_MAX - 1 || (param.costFactor + 1) > SIZE_MAX / 128) @throw [OFOutOfRangeException exception]; tmp = [[OFSecureData alloc] | < | > < | > | 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 | uint32_t *tmpItems, *bufferItems; if (param.costFactor > SIZE_MAX - 1 || (param.costFactor + 1) > SIZE_MAX / 128) @throw [OFOutOfRangeException exception]; tmp = [[OFSecureData alloc] initWithCount: (param.costFactor + 1) * 128 itemSize: param.blockSize allowsSwappableMemory: param.allowsSwappableMemory]; tmpItems = tmp.mutableItems; if (param.parallelization > SIZE_MAX / 128) @throw [OFOutOfRangeException exception]; buffer = [[OFSecureData alloc] initWithCount: param.parallelization * 128 itemSize: param.blockSize allowsSwappableMemory: param.allowsSwappableMemory]; bufferItems = buffer.mutableItems; HMAC = [[OFHMAC alloc] initWithHashClass: [OFSHA256Hash class] allowsSwappableMemory: param.allowsSwappableMemory]; |
︙ | ︙ |