Esempio n. 1
0
        public OpenTitan_AES(Machine machine) : base(machine)
        {
            DefineRegisters();
            initializationVector = new ByteArrayWithAccessTracking(this, InitializationVectorLengthInBytes / sizeof(uint), sizeof(uint), "IV");
            initialKeyShare_0    = new ByteArrayWithAccessTracking(this, InitialKeyShareLengthInBytes / sizeof(uint), sizeof(uint), "initialKeyShare_0");
            initialKeyShare_1    = new ByteArrayWithAccessTracking(this, InitialKeyShareLengthInBytes / sizeof(uint), sizeof(uint), "initialKeyShare_1");
            inputData            = new ByteArrayWithAccessTracking(this, DataLengthInBytes / sizeof(uint), sizeof(uint), "DATA_IN");
            outputData           = new ByteArrayWithAccessTracking(this, DataLengthInBytes / sizeof(uint), sizeof(uint), "DATA_OUT");

            key    = new byte[InitialKeyShareLengthInBytes];
            aes    = new AesManaged();
            random = new PseudorandomNumberGenerator();
            Reset();
        }
 public void Setup()
 {
     testArray = new ByteArrayWithAccessTracking(new StubPeripheral(), 4, 4, "TestArray");
 }