예제 #1
0
 public SCP0102Wrapper(GPKeySet sessionKeys, SCPVersions scp, List <APDUMode> securityLevel, byte[] icv, byte[] ricv, int bs)
 {
     this.blockSize   = bs;
     this.sessionKeys = sessionKeys;
     this.icv         = icv;
     this.ricv        = ricv;
     SetSCPVersion(scp);
     SetSecurityLevel(securityLevel);
 }
예제 #2
0
        public SCP03Wrapper(GPKeySet sessionKeys, SCPVersions scp, List <APDUMode> securityLevel, byte[] icv, byte[] ricv, int bs)
        {
            this.sessionKeys = sessionKeys;
            this.blockSize   = bs;
            // initialize chaining value.
            Array.Copy(GPCrypto.null_bytes_16, 0, chaining_value, 0, GPCrypto.null_bytes_16.Length);
            // initialize encryption counter.
            Array.Copy(GPCrypto.null_bytes_16, 0, encryption_counter, 0, GPCrypto.null_bytes_16.Length);

            SetSecurityLevel(securityLevel);
        }
예제 #3
0
 private GPPlaintextKeys(GPKeySet keys, Diversification div)
 {
     staticKeys  = keys;
     diversifier = div;
     System.Diagnostics.Debug.WriteLine(String.Format("static keys: {0}", staticKeys.ToString()));
 }