Overview
Comment: | scrypt: Add swaps for big endian systems |
---|---|
Downloads: | Tarball | ZIP archive | SQL archive |
Timelines: | family | ancestors | descendants | both | trunk |
Files: | files | file ages | folders |
SHA3-256: |
33b1eb838708d722a5168d4783119e4e |
User & Date: | js on 2016-10-08 15:57:43 |
Other Links: | manifest | tags |
Context
2016-10-08
| ||
15:57 | Never override CoreFoundations's forward handler check-in: c70fd7d7f3 user: js tags: trunk | |
15:57 | scrypt: Add swaps for big endian systems check-in: 33b1eb8387 user: js tags: trunk | |
15:57 | Initialize with nil to make old Apple GCC happy check-in: 7b81264b58 user: js tags: trunk | |
Changes
Modified src/scrypt.m from [76cf8287ce] to [434e17ebe7].
︙ | |||
28 29 30 31 32 33 34 | 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 | - + | void of_salsa20_8_core(uint32_t buffer[16]) { uint32_t tmp[16]; for (uint_fast8_t i = 0; i < 16; i++) |
︙ | |||
66 67 68 69 70 71 72 | 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 | + - + | tmp[12] ^= OF_ROL(tmp[15] + tmp[14], 7); tmp[13] ^= OF_ROL(tmp[12] + tmp[15], 9); tmp[14] ^= OF_ROL(tmp[13] + tmp[12], 13); tmp[15] ^= OF_ROL(tmp[14] + tmp[13], 18); } for (uint_fast8_t i = 0; i < 16; i++) buffer[i] = OF_BSWAP32_IF_BE(OF_BSWAP32_IF_BE(buffer[i]) + |
︙ | |||
119 120 121 122 123 124 125 | 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 | - + + | for (size_t i = 0; i < costFactor; i++) { memcpy(tmp2 + i * 32 * blockSize, tmp, 128 * blockSize); of_scrypt_block_mix(tmp, tmp2 + i * 32 * blockSize, blockSize); } for (size_t i = 0; i < costFactor; i++) { |
︙ |