Пример #1
0
        public CKR C_EX_SetLocalPIN(NativeULong slotId, byte[] userPin,
                                    byte[] newLocalPin, NativeULong localPinId)
        {
            if (_disposed)
            {
                throw new ObjectDisposedException(GetType().FullName);
            }

            NativeULong userPinLength = 0;

            if (userPin != null)
            {
                userPinLength = (NativeULong)(userPin.Length);
            }

            NativeULong newLocalPinLength = 0;

            if (newLocalPin != null)
            {
                newLocalPinLength = (NativeULong)(newLocalPin.Length);
            }

            NativeULong rv = _rutokenDelegates.C_EX_SetLocalPIN(slotId, userPin, userPinLength,
                                                                newLocalPin, newLocalPinLength, localPinId);

            return((CKR)rv);
        }