There have been many people in the garden for SQL Prompt cracking. I do not want to repeat the ideas, do not know can refer to: http://www.cnblogs.com/jintan/archive/2008/06/16/1223282.html
Official: http://downloads.red-gate.com/SQLToolbelt.exe
Next, let's talk about how to do it. Let me talk about the simplest and most foolish practices, and do not need to understand IL to crack them!
Preparation: required tools: VS2005 | VS2008, DotNet Helper, and Reflector
1. download and install the latest SQL Prompt 3.9. I installed it in the D: \ Program Files \ Red Gate \ SQL Prompt 3 directory.
2. Use DotNet Helper to decompile RedGate. Licensing. Client. dll into IL. DotNet Helper is indeed very convenient, used for visual decompilation and compilation, Interface
Click the decompile button to decompile RedGate. Licensing. Client. dll into IL, for example:
3. Use Reflector to open RedGate. Licensing. Client. dll, find the DaysLeftInTrial attribute of the License class, select the language to IL, and view the method get_DaysLeftInTrial under this attribute,
4. Here is the remaining number of days for trial. If I change the logic of this attribute to 9999, it will not expire. But what if IL is not used? Simple. Use VS to create a console application and create a property under the class. The property returns 9999:
Public int GetStudyzy
{
Get
{
Return 9999;
}
}
5. Compile the program in. Then use Reflector to view the program and find the property:
6. Isn't that what we want to return the 9999 IL? Open RedGate. Licensing. Client. il in the text editor, search for the get_DaysLeftInTrial string, find the definition of the method, and modify the content to return the IL content of 9999:
. Method public hidebysig specialname instance int32
Get_DaysLeftInTrial () cel managed
{
. Maxstack 1
. Locals init (
[0] int32 CS $1 $0000)
L_0000: nop
L_0001: ldc. i4 0x270f
L_0006: stloc.0
L_0007: br. s L_0009
L_0009: ldloc.0
L_000a: ret
} // End of method Licence: get_DaysLeftInTrial
7. Save the changes to IL. Use DotNet Helper and click the "compile" button to compile the modified assembly: RedGate. Licensing. Client_Output.dll and replace the original assembly.
8. Remove Strong names.
Note: The sn command is used to remove the strong name, and this command is in. net framework 2.0 SDK. If you haven't installed the SDK, you still have to install one. This SDK has been downloaded from the official Microsoft website, or you can install it through the VS installation CD. After installation, the SDK command prompt is displayed at the following location:
Enter the SDK command line mode and enter the following command:
Installation path of cd dll
Sn-Vr RedGate. Licensing. Client. dll
9. Open the database management tool and view the current days:
It seems to have succeeded !!!!!
I still want to change TrialStatus in the same way for the sake of insurance. Modify:
Public TrialStatus
{
Get {return TrialStatus. InTrain ;}
Set {.}
}
The specific method is the same. In VS, write the code for the result you want to return, compile the code, Reflector view the code, and overwrite the IL content in the License.
Okay, so much. Purely learning and communication, we try to crack it, if you just want to use the software to download this DLL: http://files.cnblogs.com/studyzy/RedGate.Licensing.Client.rar
Finally, I want to add that the version of the dll file I cracked is 2.6.0.64. All other RedGate tools that use this version can use this file. Of course, do not forget to remove the strong name. Otherwise, an error will be reported. The following figure shows the effect of using the software: