各位高手能帮我看看这段用jad反编译的代码如何还原成正确的代码吗?万分感谢!
public FileID(String contentStr)
{
int firPos;
int endPos;
convertStr = "";
boundary = "file.jsp?ID=";
firPos = 0;
endPos = 0;
_L2:
boolean loopSign;
StringBuffer sb;
firPos = endPos;
loopSign = true;
sb = new StringBuffer();
endPos = contentStr.indexOf(boundary, firPos + 1);
if (endPos < 0)
break MISSING_BLOCK_LABEL_160;
endPos += 18;
this;
convertStr;
JVM INSTR new #31  <Class StringBuilder>;
JVM INSTR dup_x1 ;
JVM INSTR swap ;
String.valueOf();
StringBuilder();
contentStr.substring(firPos, endPos);
append();
toString();
convertStr;
while (loopSign) 
{
char thechar = contentStr.charAt(endPos);
if (ParamUtil.isNumber(thechar))
{
sb.append(thechar);
endPos++;
} else
{
loopSign = false;
}
}
this;
convertStr;
JVM INSTR new #31  <Class StringBuilder>;
JVM INSTR dup_x1 ;
JVM INSTR swap ;
String.valueOf();
StringBuilder();
EncryptBean.encrypt(sb.toString());
append();
toString();
convertStr;
continue; /* Loop/switch isn't completed */
this;
convertStr;
JVM INSTR new #31  <Class StringBuilder>;
JVM INSTR dup_x1 ;
JVM INSTR swap ;
String.valueOf();
StringBuilder();
contentStr.substring(firPos);
append();
toString();
convertStr;
if (endPos >= 0) goto _L2; else goto _L1
_L1:
}

解决方案 »

  1.   

    重发个易看的代码:
      public FileID(String contentStr)
      {
        int firPos;
        int endPos;
        convertStr = "";
        boundary = "file.jsp?ID=";
        firPos = 0;
        endPos = 0;
    _L2:
        boolean loopSign;
        StringBuffer sb;
        firPos = endPos;
        loopSign = true;
        sb = new StringBuffer();
        endPos = contentStr.indexOf(boundary, firPos + 1);
        if (endPos < 0)
          break MISSING_BLOCK_LABEL_160;
        endPos += 18;
        this;
        convertStr;
        JVM INSTR new #31  <Class StringBuilder>;
        JVM INSTR dup_x1 ;
        JVM INSTR swap ;
        String.valueOf();
        StringBuilder();
        contentStr.substring(firPos, endPos);
        append();
        toString();
        convertStr;
        while (loopSign) 
        {
          char thechar = contentStr.charAt(endPos);
          if (ParamUtil.isNumber(thechar))
          {
            sb.append(thechar);
            endPos++;
          } else
          {
            loopSign = false;
          }
        }
        this;
        convertStr;
        JVM INSTR new #31  <Class StringBuilder>;
        JVM INSTR dup_x1 ;
        JVM INSTR swap ;
        String.valueOf();
        StringBuilder();
        EncryptBean.encrypt(sb.toString());
        append();
        toString();
        convertStr;
        continue; /* Loop/switch isn't completed */
        this;
        convertStr;
        JVM INSTR new #31  <Class StringBuilder>;
        JVM INSTR dup_x1 ;
        JVM INSTR swap ;
        String.valueOf();
        StringBuilder();
        contentStr.substring(firPos);
        append();
        toString();
        convertStr;
        if (endPos >= 0) goto _L2; else goto _L1
    _L1:
      }