anyangba 发表于 2021-8-12 23:22

C#反编译代码,他的加密方式

private static void Check()
{
   if (DateTime.UtcNow.Subtract(GpsReportsBll.Time).TotalMinutes > (double)GpsReportsBll.OutTime)
   {
    string text = ConfigurationManager.AppSettings["RegKey"];
    if (string.IsNullOrEmpty(text))
    {
   Logger.FatalFormat("检测授权:程序[{0}]状态key[{1}]", new object[]
   {
      GpsReportsBll.State,
      GpsReportsBll.CodeKey
   });
   return;
    }
    AuthorizeCode authorizeCode = AuthorizeCode.FromBase64String(text);
    AuthorizationClient authorizationClient = new AuthorizationClient();
    authorizationClient.Init(authorizeCode);
    authorizationClient.CheckCode(GpsReportsBll.CodeKey);
    GpsReportsBll.State = authorizationClient.State;
    GpsReportsBll.OutTime = new Random().Next(113, 400);
    GpsReportsBll.Time = DateTime.UtcNow;
    if (GpsReportsBll.State > AuthorizeState.Success)
    {
   Logger.FatalFormat("检测授权:程序[{0}]状态key[{1}]", new object[]
   {
      GpsReportsBll.State,
      GpsReportsBll.CodeKey
   });
    }
    if (!GpsReportsBll.IsInit)
    {
   GpsReportsBll.IsInit = true;
   Logger.FatalFormat("检测授权:注册key[{0}]过期时间[{1:yyyy-MM-dd}]", new object[]
   {
      GpsReportsBll.CodeKey,
      authorizeCode.ExpireTime
   });
    }
   }
}
他的加密方式是用什么转换成BASE64的

anyangba 发表于 2021-8-13 11:04

这段是检测授权状态的,如何跳过他,老大们,帮忙看看

0×Ret 发表于 2021-8-13 12:24

本帖最后由 0×Ret 于 2021-8-13 12:27 编辑

private static void Check()
{
   GpsReportsBll.IsInit = true;
}
试试这样

anyangba 发表于 2021-8-14 23:55

0×Ret 发表于 2021-8-13 12:24
private static void Check()
{
   GpsReportsBll.IsInit = true;


这个是初始化程序的

tianxico 发表于 2021-8-15 06:49

   if (!GpsReportsBll.IsInit)
    {
   GpsReportsBll.IsInit = true;
   Logger.FatalFormat("检测授权:注册key[{0}]过期时间[{1:yyyy-MM-dd}]", new object[]
   {
      GpsReportsBll.CodeKey,
      authorizeCode.ExpireTime
页: [1]
查看完整版本: C#反编译代码,他的加密方式