PAN LabyREnth CTF 2016: Windows Level 5 - RGB
In the btnCheck_Click method, I need to get the if statement to evaluate to true inorder to output the flag. Perfect chance to use Z3. Setting up z3 initially told me that the problem was unsatisfiable. Looking at the code again, I see that I can easily simplify the problem by hand.
If you look at what the method calls for successful values, a MessageBox is called using the output of the method szB. szB uses the g array.
Using this and the knowledge of the first character of the flag. We can figure out the value of value2.
Solving the equation:
113 xor 137 xor 80
This gives me a value2 of 168.
value = sbR = 83, value2 = sbG = 168, value3 = sbB = 203