Publics/FileDeleteFB.ashx.cs

(开头部分) 4KB

这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。

using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.IO;
using System.Data;
using System.Data.SqlClient;
using System.Configuration;
using System.Text;
using System.Web.SessionState;

namespace 客户订单管理2
{
    public class FileDeleteFB : IHttpHandler, IRequiresSessionState
    {
        string fieldName, keyValue, tableName, keyName;
        public void ProcessRequest(HttpContext context)
        {
            #region 权限检查
            if (context.Session["login"] == null || context.Session["login"].ToString() != "true")
            {
                context.Response.Write("<script>top.location.href='../Default.aspx';</script>");
                context.Response.End();
                return;
            }
            if (!系统.权限检查(context.Session["pageTitle"].ToString(), context.Session["username"].ToString(), context.Session["userclass"].ToString()))
            {
                context.Response.Write("<script>alert('缺少访问权限 !(请联系管理员)');</script>");
                context.Response.Write("<script>history.go(-1);</script>");
                context.Response.End();
                return;
            }
            #endregion
            
            tableName = context.Request.QueryString["Table"].ToString();
            tableName = 系统.解密(tableName.Replace("_", "+"), 系统.key2, 系统.iv2);
            fieldName = context.Request.QueryString["Field"].ToString();
            fieldName = 系统.解密(fieldName.Replace("_", "+"), 系统.key2, 系统.iv2);
            keyName = context.Request.QueryString["Key"].ToString();
            keyName = 系统.解密(keyName.Replace("_", "+"), 系统.key2, 系统.iv2);
            keyValue = context.Request.QueryString["keyValue"].ToString();
            keyValue = 系统.解密(keyValue.Replace("_", "+"), 系统.key2, 系统.iv2);
            
            string cPath = System.Web.HttpContext.Current.Server.MapPath("../DownLoad_3PX0TMP31/" + tableName + "/") + fieldName + "/" + keyValue;
            FileInfo fileinfo = new FileInfo(cPath);
            if (fileinfo.Exists) 
            {
                bool isDel = true;
                try
                {
                    fileinfo.Delete();
                }
                catch
                {
                    isDel = false;
                }
                if (isDel)
                {
后面还有 53 行代码,解锁后查看完整代码

24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明

AI 解读 AI

登录后可用,每次 10 算力,解读结果公开显示在下面。

还没有人解读过这个文件。