encrypt_key is an NxN numpy matrix
(self, encrypt_key)
| 61 | toInt = numpy.vectorize(lambda x: round(x)) |
| 62 | |
| 63 | def __init__(self, encrypt_key): |
| 64 | """ |
| 65 | encrypt_key is an NxN numpy matrix |
| 66 | """ |
| 67 | self.encrypt_key = self.modulus(encrypt_key) # mod36 calc's on the encrypt key |
| 68 | self.checkDeterminant() # validate the determinant of the encryption key |
| 69 | self.decrypt_key = None |
| 70 | self.break_key = encrypt_key.shape[0] |
| 71 | |
| 72 | def checkDeterminant(self): |
| 73 | det = round(numpy.linalg.det(self.encrypt_key)) |
nothing calls this directly
no test coverage detected