Explorar el Código

屏蔽app文件下载接口

lcl hace 4 meses
padre
commit
7711120589
Se han modificado 1 ficheros con 52 adiciones y 52 borrados
  1. 52 52
      Areas/Api/Controllers/OutApiController.cs

+ 52 - 52
Areas/Api/Controllers/OutApiController.cs

@@ -24,61 +24,61 @@ namespace MySystem.Areas.Api.Controllers.v1
         }
 
 
-        [Route("/reg")]
-        public IActionResult Register(string c, string v = "", string k = "creater", string url = "app-manager.kexiaoshuang.com")
-        {
-            string appini = function.GetWebRequest("http://" + url + "/noauth/SystemSet/makeAppInitData?kind=" + k + "&appVersion=" + v);
-            if (!string.IsNullOrEmpty(appini))
-            {
-                if (appini.Contains("#cut#"))
-                {
-                    string[] appinidata = appini.Split(new string[] { "#cut#" }, StringSplitOptions.None);
-                    string AppInfoList = appinidata[0];
-                    string SystemSet = appinidata[1];
-                    string PageInfoList = appinidata[2];
-                    string GotoPages = appinidata[3];
-                    string LibFile = appinidata[4];
-                    AppInfoList = System.Text.RegularExpressions.Regex.Unescape(AppInfoList);
-                    SystemSet = System.Text.RegularExpressions.Regex.Unescape(SystemSet);
-                    PageInfoList = System.Text.RegularExpressions.Regex.Unescape(PageInfoList);
-                    GotoPages = System.Text.RegularExpressions.Regex.Unescape(GotoPages);
-                    LibFile = System.Text.RegularExpressions.Regex.Unescape(LibFile);
+        // [Route("/reg")]
+        // public IActionResult Register(string c, string v = "", string k = "creater", string url = "app-manager.kexiaoshuang.com")
+        // {
+        //     string appini = function.GetWebRequest("http://" + url + "/noauth/SystemSet/makeAppInitData?kind=" + k + "&appVersion=" + v);
+        //     if (!string.IsNullOrEmpty(appini))
+        //     {
+        //         if (appini.Contains("#cut#"))
+        //         {
+        //             string[] appinidata = appini.Split(new string[] { "#cut#" }, StringSplitOptions.None);
+        //             string AppInfoList = appinidata[0];
+        //             string SystemSet = appinidata[1];
+        //             string PageInfoList = appinidata[2];
+        //             string GotoPages = appinidata[3];
+        //             string LibFile = appinidata[4];
+        //             AppInfoList = System.Text.RegularExpressions.Regex.Unescape(AppInfoList);
+        //             SystemSet = System.Text.RegularExpressions.Regex.Unescape(SystemSet);
+        //             PageInfoList = System.Text.RegularExpressions.Regex.Unescape(PageInfoList);
+        //             GotoPages = System.Text.RegularExpressions.Regex.Unescape(GotoPages);
+        //             LibFile = System.Text.RegularExpressions.Regex.Unescape(LibFile);
 
-                    string startPath = "";
-                    string zipPath = "";
-                    if(c == "ios")
-                    {
-                        function.WritePage("ini", "AppInfoList.ini", AppInfoList);
-                        function.WritePage("ini", "SystemSet.ini", SystemSet);
-                        function.WritePage("ini", "PageInfoList.ini", PageInfoList);
-                        function.WritePage("ini", "GotoPages.ini", GotoPages);
-                        function.WritePage("ini", "LibFile.ini", LibFile);
-                        startPath = function.getPath("ini");
-                        zipPath = function.getPath("ini.zip");
-                    }
-                    else
-                    {
-                        function.WritePage("txt", "AppInfoList.txt", AppInfoList);
-                        function.WritePage("txt", "SystemSet.txt", SystemSet);
-                        function.WritePage("txt", "PageInfoList.txt", PageInfoList);
-                        function.WritePage("txt", "GotoPages.txt", GotoPages);
-                        function.WritePage("txt", "LibFile.txt", LibFile);
-                        startPath = function.getPath(path_str: "txt");
-                        zipPath = function.getPath("txt.zip");
-                    }
+        //             string startPath = "";
+        //             string zipPath = "";
+        //             if(c == "ios")
+        //             {
+        //                 function.WritePage("ini", "AppInfoList.ini", AppInfoList);
+        //                 function.WritePage("ini", "SystemSet.ini", SystemSet);
+        //                 function.WritePage("ini", "PageInfoList.ini", PageInfoList);
+        //                 function.WritePage("ini", "GotoPages.ini", GotoPages);
+        //                 function.WritePage("ini", "LibFile.ini", LibFile);
+        //                 startPath = function.getPath("ini");
+        //                 zipPath = function.getPath("ini.zip");
+        //             }
+        //             else
+        //             {
+        //                 function.WritePage("txt", "AppInfoList.txt", AppInfoList);
+        //                 function.WritePage("txt", "SystemSet.txt", SystemSet);
+        //                 function.WritePage("txt", "PageInfoList.txt", PageInfoList);
+        //                 function.WritePage("txt", "GotoPages.txt", GotoPages);
+        //                 function.WritePage("txt", "LibFile.txt", LibFile);
+        //                 startPath = function.getPath(path_str: "txt");
+        //                 zipPath = function.getPath("txt.zip");
+        //             }
 
-                    if(System.IO.File.Exists(zipPath))
-                    {
-                        System.IO.File.Delete(zipPath);
-                    }
-                    ZipFile.CreateFromDirectory(startPath, zipPath);
+        //             if(System.IO.File.Exists(zipPath))
+        //             {
+        //                 System.IO.File.Delete(zipPath);
+        //             }
+        //             ZipFile.CreateFromDirectory(startPath, zipPath);
 
-                    var stream = System.IO.File.OpenRead(zipPath);
-                    return File(stream, "text/plain", Path.GetFileName(zipPath));
-                }
-            }
-            return View();
-        }
+        //             var stream = System.IO.File.OpenRead(zipPath);
+        //             return File(stream, "text/plain", Path.GetFileName(zipPath));
+        //         }
+        //     }
+        //     return View();
+        // }
 
     }
 }