This commit is contained in:
XAS-712 2019-01-30 17:42:52 +08:00
parent 2ae5a98a68
commit 4dc00d6794
3 changed files with 7 additions and 20 deletions

View File

@ -3,8 +3,6 @@ Microsoft Visual Studio Solution File, Format Version 11.00
# Visual Studio 2010
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "MifareOneTool", "MifareOneTool\MifareOneTool.csproj", "{CDB26016-FC77-403F-B22A-A011F8622FCF}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "DirectOP", "DirectOP\DirectOP.vcxproj", "{E17E8EAB-394B-4907-97CB-7CDFF40B3F78}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
@ -29,18 +27,6 @@ Global
{CDB26016-FC77-403F-B22A-A011F8622FCF}.Release|Win32.ActiveCfg = Release|x86
{CDB26016-FC77-403F-B22A-A011F8622FCF}.Release|x86.ActiveCfg = Release|x86
{CDB26016-FC77-403F-B22A-A011F8622FCF}.Release|x86.Build.0 = Release|x86
{E17E8EAB-394B-4907-97CB-7CDFF40B3F78}.Debug|Any CPU.ActiveCfg = Debug|Win32
{E17E8EAB-394B-4907-97CB-7CDFF40B3F78}.Debug|Mixed Platforms.ActiveCfg = Debug|Win32
{E17E8EAB-394B-4907-97CB-7CDFF40B3F78}.Debug|Mixed Platforms.Build.0 = Debug|Win32
{E17E8EAB-394B-4907-97CB-7CDFF40B3F78}.Debug|Win32.ActiveCfg = Debug|Win32
{E17E8EAB-394B-4907-97CB-7CDFF40B3F78}.Debug|Win32.Build.0 = Debug|Win32
{E17E8EAB-394B-4907-97CB-7CDFF40B3F78}.Debug|x86.ActiveCfg = Debug|Win32
{E17E8EAB-394B-4907-97CB-7CDFF40B3F78}.Release|Any CPU.ActiveCfg = Release|Win32
{E17E8EAB-394B-4907-97CB-7CDFF40B3F78}.Release|Mixed Platforms.ActiveCfg = Release|Win32
{E17E8EAB-394B-4907-97CB-7CDFF40B3F78}.Release|Mixed Platforms.Build.0 = Release|Win32
{E17E8EAB-394B-4907-97CB-7CDFF40B3F78}.Release|Win32.ActiveCfg = Release|Win32
{E17E8EAB-394B-4907-97CB-7CDFF40B3F78}.Release|Win32.Build.0 = Release|Win32
{E17E8EAB-394B-4907-97CB-7CDFF40B3F78}.Release|x86.ActiveCfg = Release|Win32
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE

View File

@ -374,7 +374,8 @@ namespace MifareOneTool
public void LoadFromMctTxt(string file)
{
if (!File.Exists(file)) { throw new IOException("加载的文件不存在。"); }
if (new FileInfo(file).Length < 2300 || new FileInfo(file).Length > 2400) { throw new IOException("加载的S50卡文件大小异常。"); }
long fileLength=new FileInfo(file).Length;
if (fileLength < 2200 || fileLength > 2400) { throw new IOException("加载的S50卡文件大小异常。"); }
List<string> lines = new List<string>(File.ReadAllLines(file));
List<string> invaild = new List<string>();
foreach (string line in lines)

View File

@ -156,12 +156,12 @@ namespace MifareOneTool
{
if (lprocess) { MessageBox.Show("有任务运行中,不可执行。", "设备忙", MessageBoxButtons.OK, MessageBoxIcon.Warning); return; } Form1.ActiveForm.Text = "MifareOne Tool - 运行中";
string rmfd = "MfRead.tmp";
string kt = "a";
string kt = "A";
string nn = "";
switch (MessageBox.Show("使用KeyA或KeyB还是不使用用于全新白卡取消", "KeyA/B/N", MessageBoxButtons.YesNoCancel, MessageBoxIcon.Information))
{
case DialogResult.No:
kt = "b";
kt = "B";
break;
case DialogResult.Cancel:
@ -280,12 +280,12 @@ namespace MifareOneTool
return;
}
if (!writecheck(rmfd)) { MessageBox.Show("将要写入的文件存在错误请用高级模式中的Hex工具打开查看。", "错误", MessageBoxButtons.OK, MessageBoxIcon.Error); return; }
string kt = "a";
string kt = "A";
string nn = "";
switch (MessageBox.Show("使用KeyA或KeyB还是不使用用于全新白卡取消", "KeyA/B/N", MessageBoxButtons.YesNoCancel, MessageBoxIcon.Information))
{
case DialogResult.No:
kt = "b";
kt = "B";
break;
case DialogResult.Cancel:
@ -760,7 +760,7 @@ namespace MifareOneTool
if (lprocess) { MessageBox.Show("有任务运行中,不可执行。", "设备忙", MessageBoxButtons.OK, MessageBoxIcon.Warning); return; }
if (keymfd == "") { MessageBox.Show("未选择有效key.mfd。", "无密钥", MessageBoxButtons.OK, MessageBoxIcon.Error); return; } Form1.ActiveForm.Text = "MifareOne Tool - 运行中";
string rmfd = keymfd;
string kt = "c";
string kt = "a";
switch (MessageBox.Show("使用KeyA或KeyB", "KeyA/B", MessageBoxButtons.YesNo, MessageBoxIcon.Information))
{
case DialogResult.No: