Embodiment
The invention will be further described below in conjunction with drawings and Examples.
Fig. 3 shows a kind of simple scheme that has adopted program actuator of the present invention and the client flow process at an embodiment of the enterprising line program exploitation of this program actuator platform.This scheme is a newly-increased block decoding circuit on the basis of existing program actuator, and it will give program actuator after the machine code program decoding from the CLIENT PROGRAM storer again.Below in conjunction with Fig. 3 this flow process is described in detail.
Step S31: client A obtains program actuator from manufacturer or suppliers, and the compiling tag slot of this program actuator is not configured, and promptly compiling the tag slot is default value.Program actuator has increased a compiling identification hardware encrypted circuit newly, and the function of this hardware encryption circuit is only grasped by manufacturer, the input end of its output terminal link edition tag slot.Offered simultaneously the compiling sign config. number of client A correspondence by manufacturer, this compiling identifies config. number to have uniqueness and manufacturer is only arranged and client A knows.Client A writes this compiling sign config. number to program actuator after taking program actuator, this compiling sign config. number by described newly-increased compiling identification hardware encrypted circuit verification and computing after form the compiling sign and be stored to and compile in the tag slot.Wherein compiling sign config. number and compiling sign can be binary strings, and the arithmetic operation of described hardware encryption circuit is based on the bit arithmetic of binary string, can be the negate computing, with exclusive disjunction, rearrangement etc.Because the information of compiling tag slot can only be imported modification by described hardware encryption circuit, and the function of hardware encryption circuit is maintained secrecy, compiling sign config. number also only has manufacturer and client just to know, so even the cracker reads the compiling sign on the compiling tag slot, but owing to do not know the function of described hardware encryption circuit, the compiling sign config. number that just can't retrodict out corresponding also just can't write the compiling sign of wanting to the compiling tag slot of program actuator.For instance, the compiling sign config. number that manufacturer distributes to client A is " 1010 ", client A inputs to compiling identification hardware encrypted circuit with this identification number, the function of this hardware encryption circuit is output after repeating 6 times again after the binary string first and last position exchange that will import, so this hardware encryption circuit converts compiling sign " 001100110011001100110011 " to " 1010 " and deposits in the compiling tag slot of client A.
Should be understood that above-mentioned hardware encryption circuit is not necessary, carry out one section program by program actuator, the function of this program is identical with the function of above-mentioned hardware encryption circuit, also can play the effect that compiling sign config. number is converted to the compiling sign.Perhaps a hardware circuit and a suite are got up to realize same function.As long as can play the implementation method of same function, all should be included in protection scope of the present invention.
Step S32: the source program that client A develops on computers is compiled into general machine code program in computing machine.In general, the source program of client development is senior language program such as assembly routine or C programmer.Assembly routine is based on that the assembly instruction collection writes, and these assembly instructions concentrate and comprise instructions such as ADD commonly used, MOV, LOAD.But machine itself can't be discerned these assembly instructions, and machine can only be discerned the binary sequence of forming by 0 and 1, also is machine code instruction.So to a certain program actuator, have the corresponding relation of assembly instruction collection and machine code instruction collection,, assembly routine can be converted to the machine code program that machine can be discerned according to this corresponding relation.Such as, in 8086 chips, its binary command form is 16, an assembly statement " MOV AX, BX " is interpreted into the machine code instruction of " 1000101111000011 ".If source program is an assembly routine, then can assembly routine be compiled into machine code program on computers according to the corresponding relation between assembly instruction collection and the general-purpose machinery code instruction collection.If source program is C language or other high level language, then need earlier it to be compiled into assembly routine, again assembly routine is compiled into machine code program.This step belongs to prior art, is the same with the step S12 of Fig. 1.
Step S33: determine a kind of conversion regime according to the compiling of client A sign, the general-purpose machinery coded program that previous step is obtained in rapid with this conversion regime converts the custom-built machine coded program of client A to.The decoding function of decoding scheme inverse process each other among this conversion regime and the step S35.This conversion regime of step S33 is a kind of corresponding relation of the custom-built machine code instruction collection of general-purpose machinery code instruction collection among the step S31 and client A.Still the compiling sign " 001100110011001100110011 " with client A among the step S31 is an example, and this compiling identifier declaration is in step S35, and the interpretation procedure of program actuator is the front two negate of elder generation with the machine code instruction of client A.Significantly, it is contrary handles is front two negate with every instruction of original general-purpose machinery coded program, so corresponding conversion regime also is that front two negate with every instruction of original general-purpose machinery coded program is to generate the custom-built machine coded program of client A in this step.Be example still, behind step S 32, be interpreted into the machine code instruction of " 1000101111000011 ", after above-mentioned conversion regime conversion, generate the machine code instruction of " 0100101111000011 " with assembly statement " MOV AX, BX ".Here, conversion regime is that manufacturer offers client A and secret by manufacturer and client A, can be a kind of text description to this conversion regime, also can be the corresponding tables of two cover machine code instruction collection, also this conversion regime can be embodied as a program module.Client A can also can use the said procedure module to change automatically on computers according to the text description of above-mentioned conversion regime or the manual conversion of corresponding tables of two cover machine code instruction collection when doing conversion.Not should be understood that and should concrete conversion method be limited.
Step S34: the custom-built machine coded program that is converted to client A is written in the nonvolatile memory of program actuator, and this nonvolatile memory can design in the sheet of program actuator chip, also can be arranged on outer and this actuator electric connection of sheet.Generally speaking, this nonvolatile memory is ROM (read-only memory) (ROM).This step also is a prior art, is identical with step S13 among Fig. 1.Through above-mentioned conversion means,, also can't realize imitated fast or dis-assembling becomes assembly routine even the cracker has read the custom-built machine coded program of the client A that is stored among the ROM.Because being stored in the custom-built machine coded program of the client A among the ROM crosses through step S33 conversion process, machine code instruction collection in it and the ordinary procedure actuator is also incompatible, also promptly can not be discerned by common program actuator, so even the cracker removes the program actuator of the same model of buying on the market, owing to lacked the interpreter operation corresponding with conversion operations, also just can't move this custom-built machine coded program, so can not realize imitated fast.Again because conversion regime is that client A is exclusive, machine code instruction after the conversion and the corresponding relation between the assembly instruction have not been original disclosed general corresponding relations, the cracker can't convert this custom-built machine coded program to assembly routine by dis-assembling under the situation that can't know this conversion regime.So the cracker can't be known the design philosophy and the algorithm of program, program is improved also just do not known where to begin.
Step S35: the custom-built machine coded program of client A converts original general-purpose machinery coded program to through a decoding scheme.The transfer process of this step and step S33 is reciprocal.It all is the same giving the decoding scheme of all clients' program actuator, but this decoding scheme of different compilings sign may command shows different decoding functions.As mentioned above, the general-purpose machinery code instruction collection of custom-built machine coded program after step S33 conversion and program actuator nuclear can't be compatible, can not be discerned by it.Decoding scheme by the compiling of client A sign be configured to function for the custom-built machine coded program with client A convert to once more can with the general-purpose machinery coded program of the general-purpose machinery code instruction collection compatibility of program actuator nuclear.Still the compiling with above-mentioned client A is designated example, assembly statement " MOV AX; BX " becomes the binary machine code of " 0100101111000011 " after the compiling conversion, but this binary machine code can't be discerned by program actuator nuclear, decoding scheme identifies the front two negate that is configured to machine code instruction according to the compiling of client A, therefore through decoding scheme, machine code instruction is reduced into " 1000101111000011 ", and this just can be discerned by program actuator nuclear.Program actuator can carry out correct operation according to this machine code instruction: the value among the register BX is moved among the register AX.
Decoding scheme is realized its specific function with logic circuit device, is example with above-mentioned this function of front two negate with machine code instruction, the implementation of this decoding scheme frame of broken lines as shown in Figure 4.Even on the data line of preceding two positions (bit) of program actuator 42, reverser 43A, a 43B are set respectively at ROM 41, do not establish any device on remaining position datawire and directly connect ROM 41 and program actuator 42.Certainly, actual decoding scheme does not have only a kind of design, as long as reach required decoding function, all is included in the claim scope of the present invention.
Fig. 5 shows another program of having adopted program actuator of the present invention and the client flow process at another embodiment of the enterprising line program exploitation of this program actuator platform.Below in conjunction with Fig. 5 this flow process is described in detail.
Step S51: this step is identical with step S31 embodiment illustrated in fig. 3.Just no longer be repeated in this description at this.For instance, the compiling sign config. number that manufacturer distributes to client B is " 1101 ", client B should compile the sign config. number and input to hardware circuit, and this hardware circuit converts compiling sign " 110111011101110111011101 " to " 1101 " and deposits in the compiling tag slot.
Step S52: the storehouse of designing corresponding relation between a storage assembly instruction collection and the machine code instruction collection, contain many tables in this storehouse, wherein every corresponding client's of table compiling sign is stored the corresponding relation between assembly instruction collection and the peculiar machine code instruction collection of this client.For instance, client B has the table of corresponding relation between an assembly instruction collection and the machine code instruction collection, the compiling sign " 110111011101110111011101 " of client B is meant two exchanges in end with machine code instruction, therefore assembly statement " MOV CL, 55H " is interpreted into the machine code instruction of " 1011000101010110 " in this table in table.
Step S53: during the compiling source program, identify pairing compile mode with the compiling that compiles the tag slot source program is compiled into machine code program.With client B is example, source program is compiled on the custom-built machine code instruction collection of client B.In compilation process, find that table of client B correspondence, assembly statement " MOV CL, 55H " is become the machine code instruction of " 1011000101010110 " by direct compilation.In fact finished the process of machine code program conversion this moment, it and difference embodiment illustrated in fig. 3 are, the embodiment of Fig. 3 can be compiled into " MOV CL; 55H " earlier the machine code instruction of general " 1011000101010101 ", and the mode according to two exchanges in end converts " 1011000101010110 " to then; And present embodiment has changed the mode of compiling, directly the conversion regime with two exchanges in end is embedded in the compilation process, also promptly using compiler that " MOV CL, 55H " this assembly statement is compiled the machine code instruction that the back has just directly formed " 1011000101010110 ".
Step S54: will compile in the nonvolatile memory of custom-built machine coded program write-in program actuator of the client B that obtains.
Step S55: the custom-built machine coded program of client B is explained execution in program actuator.Be that with difference embodiment illustrated in fig. 3 program actuator in the present embodiment has a plurality of machine code instruction collection, wherein each machine code instruction set pair is answered a compiling sign.Program actuator is chosen corresponding machine code instruction collection and is carried out according to the compiling sign.With client B is example, and program actuator is according to the compiling of client B sign, chooses behind the corresponding machine code instruction collection the directly custom-built machine coded program of operation client B.
Should be understood that step S55 also can adopt the step S35 of Fig. 3 embodiment to realize, promptly increase a decoding scheme two exchanges in end of machine code instruction.Decoding scheme is realized its specific function with logic circuit device, and exchanging this function with above-mentioned two at end with machine code instruction is example, the implementation of this decoding scheme frame of broken lines as shown in Figure 6.At ROM 61 module 62 that two signals are exchanged is set on two (bit) data lines in the end of program actuator 63 even, does not establish any device on remaining position datawire and directly connect ROM 61 and program actuator 63.Wherein position datawire 64 is connected on the input port A of module 62, and position datawire 65 is connected on the input port B of module 62, after module 62 is handled, and the signal that delivery outlet C output input port B receives, and the signal that delivery outlet D output input port A receives.Certainly, actual decoding scheme does not have only a kind of design, as long as reach required decoding function, all is included in the claim scope of the present invention.
Fig. 7 shows another program of having adopted program actuator of the present invention and the client flow process at another embodiment of the enterprising line program exploitation of this program actuator platform.This scheme has increased a compiling identification hardware encrypted circuit, a compiling identification hardware decrypt circuit and a configurable decoding scheme on the basis of existing program actuator, this decoding scheme will be given program actuator after the machine code program decoding from the outer client's program storage of sheet again.Below in conjunction with Fig. 7 this flow process is described in detail.
Step S71: client C obtains program actuator from manufacturer or suppliers, and the compiling tag slot of this program actuator is not configured, and promptly compiling the tag slot is default value.Manufacturer provides the corresponding relation of compiling sign config. number and Compilation Method simultaneously, promptly how to obtain corresponding Compilation Method by compiling sign config. number, and how to release corresponding compiling sign config. number by the Compilation Method of client's design.In this example, manufacturer offers the compiling sign config. number of client C and the corresponding relation of Compilation Method is: by general, disclosed Compilation Method client's source program is compiled into general machine code program earlier, the conversion method of determining by compiling sign config. number is changed each bar machine code instruction one by one again, to obtain and to compile the corresponding custom-built machine coded program of sign config. number; It is wide that all instructions of program actuator in this example are 8Bit, all can do to give program actuator nuclear after the rearrangement according to compiling sign config. number by a newly-increased configurable decoding scheme from the 8Bit of every instruction of the outer client's program storage of sheet and carry out; Compiling sign config. number is 24Bit altogether, is divided into 8 groups, and every group of 3Bit determines a position; The client can design a kind of sort method voluntarily, 8Bit to every instruction of general-purpose machinery coded program according to said method resequences, can get the custom-built machine coded program of oneself, and then generate the compiling sign config. number that is complementary of sort method therewith, it can make described configurable decoding scheme to doing opposite processing from every instruction of the outer client's program storage of sheet, to restore original general-purpose machinery code instruction, give program actuator nuclear again.
Step S72: the client designs a kind of Compilation Method voluntarily, and the corresponding relation of the compiling that provides according to manufacturer sign config. number and Compilation Method, release corresponding compiling sign config. number, again this config. number loading routine actuator is generated the compiling sign, finish configuration program actuator.In this example, the Compilation Method of client C design be with the 8Bit of every instruction of general-purpose machinery coded program (use respectively from high to low<7,<6 〉,<5 〉,<4 〉,<3 〉,<2 〉,<1 〉,<0〉mark) according to<3 〉,<5 〉,<0 〉,<7 〉,<2 〉,<6〉order,<1 〉,<4〉rearranges to obtain the custom-built machine coded program.In order to make described configurable decoding scheme from the custom-built machine coded program, restore the general-purpose machinery coded program, the compiling sign config. number that provides according to step S71 manufacturer and the corresponding relation of Compilation Method, can release corresponding compiling sign config. number and can be expressed as " 42607315 " with 8 systems, the 7th to the 0th of the instruction that its representation program actuator nuclear obtains comes from the 4th, the 2nd, the 6th, the 0th, the 7th, the 3rd, the 1st, the 5th of instruction of custom-built machine coded program respectively.Apparently, the client tackles the Compilation Method of oneself and compiles the sign config. number and maintains secrecy.
Client C generates this compiling sign config. number " 42607315 " (8 system) write-in program actuator chip the compiling sign and deposits described compiling tag slot in after a newly-increased compiling identification hardware encrypted circuit is handled in the program actuator sheet then.The concrete function of this compiling identification hardware encrypted circuit is maintained secrecy by manufacturer.In this example, the concrete function of this hardware encryption circuit is to exchange with the preceding 12Bit negate of the compiling sign config. number of client input and with last 12Bit.Therefore the compiling that writes the client C of compiling tag slot at last is designated " 73153517 " (8 system).Because the information of compiling tag slot can only be imported modification by described newly-increased compiling identification hardware encrypted circuit, and the function of this encrypted circuit is maintained secrecy, so even the cracker reads the compiling sign in the compiling tag slot, but, just can't release corresponding compiling sign config. number owing to do not know the concrete function of described hardware encryption circuit; And client C also maintains secrecy to oneself compiling sign config. number and Compilation Method, so the cracker can't write the compiling sign of client C to the compiling tag slot of program actuator.The cracker also may attempt writing different compiling sign config. number to program actuator, and notes the compiling sign that is stored in the compiling tag slot of generation; Obtain a large amount of such " compiling sign config. number--compiling sign " and to after, the concrete function of guess compiling identification hardware encrypted circuit in view of the above.For increasing the difficulty that this cracks work, can take following measure: 1. compile the identification hardware encrypted circuit and should possess certain complexity; 2. compiling the tag slot can adopt disposable programmable ROM (read-only memory) (OTP ROM) to realize; 3. compile the tag slot and forbid reading, can be by in the compiling sign, setting up check bit, it is correct to confirm by program actuator output compiling sign check results whether the compiling sign writes.
Step S73: the client finishes the source program design, and by general Compilation Method it is compiled into general machine code program.This step belongs to prior art, is the same with the step S12 of Fig. 1.
Step S74: the client is according to self-designed Compilation Method in step S72, the machine code instruction of the general-purpose machinery coded program that obtains among the step S73 changed one by one, to obtain and oneself the corresponding custom-built machine coded program of compiling sign config. number.In this example, concrete conversion method be with the 8Bit of every instruction of general-purpose machinery coded program (use respectively from high to low<7,<6 〉,<5 〉,<4 〉,<3 〉,<2 〉,<1 〉,<0〉mark) according to<3 〉,<5 〉,<0 〉,<7 〉,<2 〉,<6〉order,<1 〉,<4〉rearranges to obtain the custom-built machine coded program.
Certainly, step S73 and S74 also can merge execution, promptly according to the corresponding relation of assembly instruction collection to the corresponding relation of general-purpose machinery code instruction collection and general-purpose machinery code instruction collection to client's custom-built machine code instruction collection, release the corresponding relation of assembly instruction collection, directly client's source program is compiled into client's custom-built machine coded program then to client's custom-built machine code instruction collection.So, as described in claim 6, also can understand this process like this: the compiling sign config. number " 42607315 " of client C has been determined the proprietary machine code instruction collection of a cover client C, and directly the source program with client C is compiled into the custom-built machine coded program that can obtain client C on this machine code instruction collection.
Step S75: client's custom-built machine coded program is write in the CLIENT PROGRAM storer.In this example, therefore the CLIENT PROGRAM storer can write by general cd-rom recorder outside sheet.This step also is a prior art, is identical with step S13 among Fig. 1.
After finishing these steps, when powering on working procedure to program actuator, described program actuator can restore compiling sign config. number according to the compiling sign earlier at every turn.In this example, the main body that realizes being generated by the compiling sign corresponding compiling sign config. number is a newly-increased compiling identification hardware decrypt circuit, and its concrete function is the back 12Bit negate of 24Bit compiling sign that will the compiling tag slot and exchanges with preceding 12Bit.Certainly this function manufacturer also maintains secrecy.The compiling sign config. number that restores is delivered to configurable decoding scheme, and described configurable decoding scheme is all the same in every program actuator chip, but it can show different decoding functions according to different compiling sign config. number.In this example, described configurable decoding scheme selects 1 MUX to form by 88, and they will give program actuator nuclear after the 8Bit rearrangement from every instruction of CLIENT PROGRAM storer again.Described configurable decoding scheme is according to the compiling of client C sign config. number " 42607315 " (8 system) specific decoding function of showing is to give program actuator nuclear again with coming the 7th to the 0th respectively from the 4th, the 2nd, the 6th, the 0th, the 7th, the 3rd, the 1st, the 5th of the instruction of CLIENT PROGRAM storer.The conversion process of integrating step S74, configurable as can be known decoding scheme just in time restores the general-purpose machinery code instruction.If described configurable decoding scheme and program actuator nuclear are merged to get up to see, this merging body shows as the configurable program actuator nuclear of machine code instruction collection, and concrete configuration result is by the decision of compiling sign.As described in claim 9, can regard this merging body as and release and executive routine according to the definite machine code instruction collected explanations or commentaries of compiling sign.And the machine code instruction collection that the existing program actuator chip that does not adopt this patent all has only a cover to determine.
Because the conversion of step S74 has been arranged,, also can't realize imitated fast or dis-assembling becomes assembly routine even the cracker has read the custom-built machine coded program of the client C in the CLIENT PROGRAM storer.Because the custom-built machine coded program of client C has been to handle through step S74, it and general machine code instruction collection and incompatible, also promptly can not be discerned by common program actuator, so even the cracker removes the program actuator of the same model of buying on the market, owing to lacked the decoded operation corresponding with the S74 conversion operations, also just can't move this machine code program, so can not realize imitated fast.Maintain secrecy because of the conversion method of step S74 again, client's custom-built machine coded program after the conversion and the corresponding relation between the assembly routine have not been original general, disclosed corresponding relations, so the cracker under the situation that can't know this conversion method, can't become assembly routine with client's custom-built machine coded program dis-assembling.So the cracker can't be known the design philosophy and the algorithm of program, program is improved also just do not known where to begin.
Fig. 8 is the block diagram of the program actuator in this example, is configurable decoding scheme 83 in the frame of broken lines wherein.Compiling identification hardware encrypted circuit 84 generates the compiling sign after receiving compiling sign config. number, writes compiling tag slot 85; Compiling sign then passes to compiling identification hardware decrypt circuit 86, restores compiling sign config. number, is used to dispose configurable decoding scheme 83.Configurable decoding scheme selects 1 MUX to form by 88.Compiling sign config. number is 24Bit altogether, is divided into 8 groups, and every group of 3Bit controls a MUX, and they will export to program actuator nuclear 82 after the 8Bit rearrangement from every instruction of CLIENT PROGRAM storer 81.Certainly, actual configurable decoding scheme does not have only a kind of design, as long as reach required decoding function, all is included in the claim scope of the present invention.
Fig. 9 shows another program of having adopted program actuator of the present invention and the client flow process at another embodiment of the enterprising line program exploitation of this program actuator platform.Below in conjunction with Fig. 9 this flow process is described in detail.
Step S91: the client obtains program actuator from manufacturer or suppliers, and the compiling tag slot of this program actuator is not configured, and promptly compiling the tag slot is default value.The client selects a compiling sign config. number at random then, and should compile sign config. number loading routine actuator to generate the compiling sign, finishes the configuration to program actuator.Such as, requiring compiling sign config. number in this example is 30Bit, the compiling sign config. number that client D selects can be expressed as with 16 systems " 3A73 FF5A ".Client D is with this compiling sign config. number " 3A73 FF5A " write-in program actuator chip, generate the compiling sign and deposit described compiling tag slot in after a newly-increased compiling identification hardware encrypted circuit is handled in the program actuator sheet.The concrete function of this compiling identification hardware encrypted circuit is maintained secrecy by manufacturer.In this example, the concrete function of this hardware encryption circuit is that the compiling sign config. number that the client imports is divided into 3 10Bit and addition, gives up carry then with 10Bit additive operation negate as a result, generates the compiling sign.Config. number with client D " 3A73 FF5A " be example, be divided into 3 10Bit earlier: " 3A7 ", " OFF ", " 35A ", after the addition " 800 ", give up after the carry last 10Bit for " 000 ", negate must compile and be designated " 3FF ".Therefore the compiling that writes the client D of compiling tag slot at last is designated " 3FF ".Because the information of compiling tag slot can only be imported modification by described newly-increased compiling identification hardware encrypted circuit, and the function of this encrypted circuit is maintained secrecy, so even the cracker reads the compiling sign in the compiling tag slot, but, just can't release corresponding compiling sign config. number owing to do not know the concrete function of described hardware encryption circuit; And client D also maintains secrecy to the compiling sign config. number of oneself, so the cracker can't write the compiling sign of client D to the compiling tag slot of program actuator.
Step S92: this step is identical with step S73 embodiment illustrated in fig. 7, and promptly the client finishes the source program design, and by general Compilation Method it is compiled into general machine code program.
Step S93: with the general-purpose machinery coded program loading routine actuator of step S92 gained, described general-purpose machinery coded program is handled the custom-built machine coded program that the back generates the client, the CLIENT PROGRAM storer in the sheet of restoring by one in the sheet newly-increased configurable decoding scheme.Finish by the general-purpose machinery coded program to the conversion work of custom-built machine coded program be configurable decoding scheme in the sheet, therefore this can be regarded as the program actuator chip and also partly participate in compiling work from assembly routine to client's custom-built machine coded program.
Described configurable decoding scheme is between interior CLIENT PROGRAM storer of sheet and the program actuator nuclear, and its concrete processing capacity is determined by the compiling sign configuration of compiling tag slot.When program actuator powered on operation, this decoding scheme was responsible for that the custom-built machine coded program in the CLIENT PROGRAM storer in the sheet is reduced to the general-purpose machinery coded program and is given the execution of program actuator nuclear again.In this example, described configurable decoding scheme is made up of 10 XOR gate, and they are with the address bus of program actuator instruction addressing address bus of authorizing out and the compiling sign step-by-step XOR rear drive CLIENT PROGRAM storer that compiles the tag slot.The CLIENT PROGRAM storer is 1K byte (BYTE) capacity in the sheet, instruction of every byte (BYTE) storage, and the corresponding address bus also is that 10Bit is wide.So this configurable decoding scheme is through the compiling of client D sign " 3FF " after the configuration, the decoding function that shows is the address bus that drives the CLIENT PROGRAM storer after the instruction addressing address bus step-by-step negate that program actuator is authorized out again.Certainly, the client during to program actuator input general-purpose machinery coded program, the address bus of CLIENT PROGRAM storer is also crossed by identical rule treatments by configurable decoding scheme, so what obtain during the program actuator operation will be correct general-purpose machinery coded program.Can allow configurable decoding scheme also work during read routine from the program actuator chip the client, whether the client can obtain the general-purpose machinery coded program of original input like this, write correct with proving program.Certain danger---the cracker also can carry out the fetch program from the program actuator chip, and he will directly obtain the general-purpose machinery coded program of client D if so certainly design has.Can consider to take following measure to stop the generation of this situation, simultaneously allow client D to verify whether its program writes correct again: the sign of input compiling earlier config. number when 1. each CLIENT PROGRAM storer in the program actuator sheet is read program, through with the compiling tag slot in compiling identify and just allow to read after checking coupling; 2. forbid the operation of any read routine, whether by adding check bit at program termination, it is correct to come proving program to write by program actuator execution verification.
As mentioned above, when the general-purpose machinery coded program is transfused to program actuator, every instruction is all directed address newly, the CLIENT PROGRAM storer has formed the custom-built machine coded program in sheet then.This conversion operations is specifically carried out by configurable decoding scheme.Even therefore the cracker has read the custom-built machine coded program of the client D in the CLIENT PROGRAM storer, under the situation of the concrete function of the configurable decoding scheme that can't know client D, also can't obtain the general-purpose machinery coded program of correct order or the assembly routine that dis-assembling goes out correct order.The cracker also can remove the program actuator of the same model of buying on the market and import the custom-built machine coded program of client D, even there is the compiling of client D to identify the auxiliary of " 3FF ", what finally write the CLIENT PROGRAM storer still can be a mixed and disorderly program.It is not enough having to the custom-built machine coded program of client D, because it can't not write with not being changed CLIENT PROGRAM storer in the sheet, and comprises that client D also can't understand it; The general-purpose machinery coded program that obtains client D is only significant.
The cracker will obtain the general-purpose machinery coded program from the custom-built machine coded program of client D, must analyze the concrete function that configurable decoding scheme shows after the compiling sign configuration of client D earlier.Import some particular machines coded programs such as the program actuator that the cracker can identify to the compiling with client D, contrast with the machine code program that finally in sheet, produces on the CLIENT PROGRAM storer then, to guess the concrete function of configurable decoding scheme.In order to increase the difficulty that this cracks work, can consider to adopt following measure: 1. the CLIENT PROGRAM storer adopts disposable programmable ROM (read-only memory) (OTP ROM) to realize in the sheet again; 2. the sign of input compiling earlier config. number when the program actuator write-in program at every turn, through with the compiling tag slot in compiling identify and just allow to write after checking coupling; 3. configurable decoding scheme should possess certain complexity, and should be as much as possible with program actuator nuclear power road Mixed Design together.
Figure 10 is the block diagram of the program actuator in this example, is configurable decoding scheme 103 in the frame of broken lines wherein.Compiling identification hardware encrypted circuit 104 generates the compiling sign after receiving compiling sign config. number, writes compiling tag slot 105; Compiling sign then passes to configurable decoding scheme 103.Configurable decoding scheme is made up of 10 XOR gate, and they are with program actuator instruction addressing address bus of authorizing out and the address bus that compiles sign step-by-step XOR rear drive CLIENT PROGRAM storer.
Among above-mentioned two embodiment, the mode of compiling and read, explaining all is static, promptly identical compiling and read, interpretation procedure is applicable to whole compilation process.In order to increase the cost that cracks, improve the complexity that cracks, the mode that also can compile and read, explain is set to dynamically.What is called dynamically is meant: a condition can be set, under different situations, carry out different compilings and read, interpreter operation.Illustrated for an embodiment again.Figure 11 shows another program of having adopted program actuator of the present invention and the client flow process at another embodiment of the enterprising line program exploitation of this program actuator platform.Below in conjunction with Figure 11 this flow process is described in detail.
Step S111: the client obtains program actuator from manufacturer or suppliers, and the compiling tag slot of this program actuator is not configured, and promptly compiling the tag slot is default value.
Step S112: the client finishes the source program design, and by general Compilation Method it is compiled into general machine code program.
Step S113: with the general-purpose machinery coded program loading routine actuator of the rapid gained of previous step, the interior newly-increased random number generator circuit of described program actuator will produce a random number earlier and deposit the compiling tag slot in as compiling to identify during input, and this compiling sign also is used to dispose the configurable decoding scheme that another piece in the sheet increases newly simultaneously; The general-purpose machinery coded program of input is handled the custom-built machine coded program that the back generates the client by this configurable decoding scheme, and deposits the CLIENT PROGRAM storer in the sheet in.
Compare with embodiment illustrated in fig. 9, present embodiment has substituted the operation of being imported compiling sign config. number by the client with a randomizer, make that client's flow process of development sequence on program actuator is in full accord in the flow process of present embodiment and the prior art shown in Figure 1 from client's viewpoint of measures.But final result is different, and what deposit the interior CLIENT PROGRAM storer of program actuator sheet in this example at last in is not the general-purpose machinery coded program that the client imports, but has passed through the custom-built machine coded program of conversion.Comprise that the client also can't understand this custom-built machine coded program, but it can correctly be reduced and carry out by program actuator.The operation that writing compiling sign config. number, being transformed into the custom-built machine coded program by the general-purpose machinery coded program among preceding two embodiment is all finished by the newly-increased circuit in the program actuator sheet in this example, and need not the client intervene.
How the program actuator of specifically telling about below in this example operates.Such as, client E is when program actuator input general-purpose machinery coded program: 1. a newly-increased random number generator circuit produces a 48Bit random number earlier in the sheet, available 16 systems are expressed as " E80B 44C7 9A15 ", and this random number is used as the compiling sign and deposits the compiling tag slot in; 2. the newly-increased configurable decoding scheme of another piece in the sheet is through the compiling sign of compiling tag slot " E80B 44C7 9A15 " after the configuration, the concrete function that shows is: the address is belonged to 000 to 3FF (16 system) 1K bar machine code instruction, carry out the front two negate of every instruction; Ensuing address is belonged to 400 to 7FF (16 system) 1K bar machine code instruction, carry out two exchanges in end of every instruction; Repeat said process (alleged on-the-flier compiler method that Here it is) then; 3. the general-purpose machinery coded program of client E input generates the custom-built machine coded program after described configurable decoding scheme is handled, and deposits the CLIENT PROGRAM storer in the sheet in.After finishing these steps, when later on each program actuator powers on operation, its configurable decoding scheme can be read the compiling sign from the compiling tag slot earlier " E80B 44C7 9A15 " in order to dispose self, then to doing identical processing: the address is belonged to first 1K from the instruction of CLIENT PROGRAM storer, the 3rd 1K, the front two negate of every instruction is carried out in the instruction of the 5th 1K......, the address is belonged to second 1K, the 4th 1K, two exchanges in end of every instruction are carried out in the instruction of the 6th 1K......, and the instruction after the processing is given program actuator nuclear again and carried out.As seen, when program actuator powered on operation, its configurable decoding scheme had just in time restored the general-purpose machinery coded program of original client E input.
In this example, the program actuator that has been written into program forbids that program reads.Because the compiling of program actuator sign is generated at random by program actuator oneself in this example,, can only forbid program to read so it can't screen legal client E and illegal cracker.In order to allow client E can proving program whether correctly write, can add check bit at program termination, whether carrying out verification by program actuator, to come proving program to write correct.
In this example, manufacturer is still secret to the concrete function of configurable decoding scheme.Even, also can't therefrom restore the general-purpose machinery coded program so the cracker has read the custom-built machine coded program of client E.If cracker's attempt writes the concrete function of the program of some particular design with conjecture configurable decoding scheme wherein to the program actuator of client E, also be futile, because the randomizer when writing in the program actuator sheet will produce new compiling and identify and override original compiling and identify, thereby also changed the concrete function of configurable decoding scheme.Even write same machine code program to program actuator, the compiling sign of at every turn writing fashionable randomizer generation also is different.The compiling sign that randomizer generates in this example has 48Bit, can provide 262144G (1G ≈ 1,000,000,000) to plant combination.The identical probability of compiling sign that this means twice generation of randomizer has only 1/262144G.If ceaselessly do this trial, once be example to attempt for 1 second, the times of this probability being brought up to 1 ‰ needs are about 8925.If so there is the people to want to allow randomizer generate certain specific compiling sign, he needs patient especially.In this sense, can think that any client can't write other clients' compiling sign in the compiling tag slot.
Figure 12 is the block diagram of the program actuator in this example, is configurable decoding scheme 123 in the frame of broken lines wherein, and it selects 1 MUX 123C to form by two submodule 123A, 123B and one 2.When client E write the general-purpose machinery coded program, randomizer 124 generated a random number " E80B 44C7 9A15 " as the compiling sign, write compiling tag slot 125; Compiling sign then passes to configurable decoding scheme 123.Under this compiling sign configuration, the function of 123A is the front two negate to every instruction, the function of 123B is not two exchanges to every instruction, the function of 123C exports to 122 for selection 123A's when the program actuator nuclear 122 instruction addressing addresses of sending belong to first 1K, the 3rd 1K, the 5th 1K......, and selection 123B's exports to 122 when the program actuator nuclear 122 instruction addressing addresses of sending belong to second 1K, the 4th 1K, the 6th 1K.......
Should be understood that in the present embodiment that substituting the method for importing compiling sign config. number by the client with a randomizer also can be used for generating in the aforementioned embodiment the compiling sign, the method that generates the compiling sign in the same previous embodiment also can be used for present embodiment.In addition, as described in claim 2, compiling sign among these embodiment can also adopt another kind of mode to realize, be that manufacturer just writes corresponding compiling sign according to customer information in advance before program actuator dispatches from the factory in the compiling tag slot, this compiling tag slot adopts disposable programmable ROM (read-only memory) (OTP ROM) to realize.That is to say that in a single day program actuator dispatches from the factory, the compiling tag slot of its inside just can't be erasable.
Should be understood that of the present invention focusing on also can't directly use or dis-assembling even make the cracker obtain these machine code programs by obtain to be stored in the machine code program on the CLIENT PROGRAM storer with the compiling of the exclusive compile mode of client.The above-mentioned concrete instruction of mentioning, concrete compiling and interpreting mode, the specific implementation of configurable decoding scheme etc. are only as example, are not used for limiting the present invention.
The foregoing description provides to those of ordinary skills and realizes or use of the present invention; those of ordinary skills can be under the situation that does not break away from invention thought of the present invention; the foregoing description is made various modifications or variation; thereby protection scope of the present invention do not limit by the foregoing description, and should be the maximum magnitude that meets the inventive features that claims mention.