public class inspect {
    public static boolean inspect(String input_str) {
        try {
            // 将输入字符串转换为UTF-8字节数组
            byte[] input_flag = input_str.getBytes(StandardCharsets.UTF_8);
            
            // 获取密钥字符串并转换为UTF-8字节数组
            byte[] str2 = jni.getkey().getBytes(StandardCharsets.UTF_8);
            
            // 将密钥字节数组的前8个字节复制到一个新的字节数组中
            byte[] copyOf = Arrays.copyOf(str2, 8);
            
            // 使用AES算法将密钥字节数组生成SecretKeySpec对象
            SecretKeySpec key = new SecretKeySpec(str2, "AES");
            
            // 获取初始化向量并转换为UTF-8字节数组,生成IvParameterSpec对象
            IvParameterSpec iv = new IvParameterSpec(jni.getiv().getBytes(StandardCharsets.UTF_8));
            
            // 获取一个使用DES算法、CBC模式、PKCS5填充的Cipher实例
            Cipher cipher = Cipher.getInstance("DES/CBC/PKCS5Padding");
            
            // 用密钥和初始化向量初始化Cipher实例,设置为加密模式
            cipher.init(1, key, iv);
            
            // 对输入字节数组进行加密,并将结果编码为Base64字符串
            String encrypted = Base64.encodeToString(cipher.doFinal(input_flag), 0).trim();
            
            // 将加密结果与硬编码的字符串进行比较
            if (!encrypted.equals("JqslHrdvtgJrRs2QAp+FEVdwRPNLswrnykD/sZMivmjGRKUMVIC/rw==")) {
                return true; // 如果不相等,返回true
            }
            return false; // 如果相等,返回false
        } catch (Exception exception) {
            // 捕获异常并打印堆栈跟踪信息,返回true
            exception.printStackTrace();
            return true;
        }
    }
}
 

加载 so secret

void getiv_fixed(void)
{
  _BYTE *v0; // x9
  __int64 v1; // x12
  char v2; // w13
  unsigned __int64 v3; // x14
  unsigned __int64 v4; // x10
  _BYTE *v5; // x11
  _BYTE *v6; // x9
  _BYTE *v7; // x13
  unsigned __int64 v8; // x16
  int v9; // w0
  int v10; // w17
  unsigned int v11; // w2
  _BOOL4 v12; // w2
  _BYTE *v13; // x1
  unsigned __int64 v14; // x2
  _QWORD *v15; // x20
  __int64 v16; // x0
  unsigned int v17; // w21
  _BYTE *v18; // x10
  char v19; // w14
  int v20; // w15
  int v21; // w13
  unsigned __int8 v22; // [xsp+0h] [xbp-40h] BYREF
  _BYTE v23[7]; // [xsp+1h] [xbp-3Fh] BYREF
  unsigned __int64 v24; // [xsp+8h] [xbp-38h]
  void *v25; // [xsp+10h] [xbp-30h]
  char v26; // [xsp+18h] [xbp-28h] BYREF
  char v27[23]; // [xsp+19h] [xbp-27h] BYREF
  char v28[8]; // [xsp+30h] [xbp-10h] BYREF
  __int64 v29; // [xsp+38h] [xbp-8h]
 
  v29 = *(_QWORD *)(_ReadStatusReg(ARM64_SYSREG(3, 3, 13, 0, 2)) + 40);
  v26 = 24;
  strcpy(v27, "F2IjBOh1mRW=");
  std::string::basic_string(&v22, &v26);
  v1 = v24;
  v0 = v25;
  v2 = v22 & 1;
  v3 = (unsigned __int64)v22 >> 1;
  if ( (v22 & 1) != 0 )
    v4 = v24;
  else
    v4 = (unsigned __int64)v22 >> 1;
  if ( (v22 & 1) != 0 )
    v5 = v25;
  else
    v5 = v23;
  if ( !v4 )
    goto LABEL_22;
  v6 = v5;
  if ( v4 == 1 )
    goto LABEL_33;
  v7 = v5 + 1;
  v6 = &v5[v4 & 0xFFFFFFFFFFFFFFFELL];
  v8 = v4 & 0xFFFFFFFFFFFFFFFELL;
  do
  {
    v9 = (unsigned __int8)*(v7 - 1);
    v10 = (unsigned __int8)*v7;
    v11 = v10 - 65;
    if ( (unsigned int)(v9 - 65) <= 0x19 )
      *(v7 - 1) = (char)(v9 - 49) % 26 + 65;
    if ( v11 <= 0x19 )
      *v7 = (char)(v10 - 49) % 26 + 65;
    v12 = (unsigned int)(v10 - 97) < 0x1A && v11 > 0x19;
    if ( (unsigned int)(v9 - 97) <= 0x19 && (unsigned int)(v9 - 65) >= 0x1A )
      *(v7 - 1) = (v9 - 81) % 26 + 97;
    if ( v12 )
      *v7 = (v10 - 81) % 26 + 97;
    v8 -= 2LL;
    v7 += 2;
  }
  while ( v8 );
  if ( v4 != (v4 & 0xFFFFFFFFFFFFFFFELL) )
  {
LABEL_33:
    v18 = &v5[v4];
    do
    {
      v21 = (unsigned __int8)*v6;
      if ( (unsigned int)(v21 - 65) < 0x1A )
      {
        v19 = 65;
        v20 = -49;
      }
      else
      {
        if ( (unsigned int)(v21 - 97) > 0x19 )
          goto LABEL_36;
        v19 = 97;
        v20 = -81;
      }
      *v6 = v19 + (v20 + v21) % 26;
LABEL_36:
      ++v6;
    }
    while ( v18 != v6 );
  }
  v1 = v24;
  v0 = v25;
  v2 = v22 & 1;
  v3 = (unsigned __int64)v22 >> 1;
LABEL_22:
  if ( v2 )
    v13 = v0;
  else
    v13 = v23;
  if ( v2 )
    v14 = v1;
  else
    v14 = v3;
  v15 = (_QWORD *)std::__put_character_sequence<char,std::char_traits<char>>(&std::cout, v13, v14);
  std::ios_base::getloc((std::ios_base *)((char *)v15 + *(_QWORD *)(*v15 - 24LL)));
  v16 = std::locale::use_facet(v28, &std::ctype<char>::id);
  v17 = (*(__int64 (__fastcall **)(__int64, __int64))(*(_QWORD *)v16 + 56LL))(v16, 10LL);
  std::locale::~locale((std::locale *)v28);
  std::ostream::put(v15, v17);
  std::ostream::flush(v15);
  didi(&v22);
  if ( (v22 & 1) != 0 )
    operator delete(v25);
  if ( (v26 & 1) != 0 )
    operator delete(*(void **)&v27[15]);
}