This commit is contained in:
Philippe Teuwen 2021-10-16 23:43:31 +02:00
commit 232843477c
37 changed files with 115 additions and 129 deletions

View file

@ -408,7 +408,7 @@ static inline uint32_t sm_right(const uint8_t *ks, uint8_t *mask, vector<uint64_
for (it = bincstates.begin(); it != bincstates.end(); ++it) {
pcrstates->push_back(it->second);
}
// Reverse the vector order (so the higest bin comes first)
// Reverse the vector order (so the highest bin comes first)
reverse(pcrstates->begin(), pcrstates->end());
return topbits;
@ -588,7 +588,7 @@ static inline void sm_left(const uint8_t *ks, uint8_t *mask, vector<cs_t> *pcsta
for (it = bincstates.begin(); it != bincstates.end(); ++it) {
pcstates->push_back(it->second);
}
// Reverse the vector order (so the higest bin comes first)
// Reverse the vector order (so the highest bin comes first)
reverse(pcstates->begin(), pcstates->end());
}
@ -733,8 +733,8 @@ int main(int argc, const char *argv[]) {
uint64_t nCi; // Card random
uint64_t nQ; // Reader random
uint64_t nCh; // Reader challange
uint64_t nCi_1; // Card anwser
uint64_t nCh; // Reader challenge
uint64_t nCi_1; // Card answer
if ((argc != 2) && (argc != 5)) {
printf("SecureMemory recovery - (c) Radboud University Nijmegen\n\n");