Well I just made a question asking how to simply
~(i + -1) < -1 which turned out to be i > 1
Making a JAVA deobfuscator and here is what I have so far.. I just want people to tell me which ones I did wrong? if any just double checking.
~i > -1 is i < 0
~i < -1 is i > 0
~i > ~classA.var is i < classA.var
~i >= ~j is i <= j
~i <= ~b is i >= b
~i == -1 is i == 0
~classA.var < -1 is classA.var > 0
~classA.var > -1 is classA.var < 0
~classA.var == ~classB.var is classA.var == classB.var
~(-1 + i) < -1 is i > 1
~(i + -1) < -1 is i > 1
~(i & 0x22) != -1 is (i & 0x22) == 0 <- seems wrong..
Seems the correct answer by Eng.Fouad is
~(i & 0x22) != -1 is (i & 0x22) != 0 <- correct so far.
These are all the patterns my deobfuscator supports so far.. probably will find a bunch more.
(Any wrong ones?) I Fear the ones with == signs may be wrong.. i’ve tested them and they seem to work..
Thanks I appreciate the support, i’m a beginner to programming only programmed half a year and math isn’t my strong point.
Just replace each
~xwith-x - 1:~i > -1==>-i - 1 > -1==>-i > 0==>i < 0~i < -1==>-i - 1 < -1==>-i < 0==>i > 0and so on.