1234567891011121314151617181920212223 |
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- namespace ShengJu_CUT100_DES.MessageEntity.Outgoing
- {
- /// <summary>
- /// 验证卡片原根密钥后格式化卡片,重新创建文件结构,并将根密钥修改成用户指定的密钥值。
- /// </summary>
- public class FormatCardRequest : MessageBase
- {
- public FormatCardRequest(byte[] oldKey, byte[] newKey)
- {
- if (oldKey == null || newKey == null)
- throw new ArgumentNullException("must provide oldKey and newKey");
- if (oldKey.Length != 16 || newKey.Length != 16)
- throw new ArgumentException("oldKey and newKey must has its length to 16");
- base.命令代码 = CommandType.DesFireEV1操作命令_格式化卡片;
- base.RawDataAndCheck = oldKey.Concat(newKey).ToList();
- }
- }
- }
|