Summary of the invention
The embodiment of the invention provides a kind of software version dissemination method, system and device, to prevent owing to terminal iidentification quilts such as IMEI or hardware ID are distorted the Version Control risk that causes.
A kind of software version dissemination method comprises:
When needs carry out the version activation, obtain the version authorization code, the described version authorization code random information that to be the authorized party obtain according to the deciphering to the version application code in the version application documents that receive generates, and described version application code is that terminal generates according to terminal iidentification number and random information when the mandate of application version;
The decrypted version authorization code obtains the random information in the version authorization code;
When the random information in the version authorization code is identical with the random information that generates the version application code, the activating software version.
A kind of software version delivery system comprises:
Terminal, be used for when needs carry out the version activation, using terminal iidentification number and random information to generate new version application code and leave in the version application documents sends, receive the version authority, and the version authorization code in the decrypted version authority, obtain the random information in the version authorization code, and the random information of the random information in the version authorization code and generation version application code is when identical, the activating software version;
Server, be used for after receiving the version application documents, obtain the version application code in the version application documents, decipher described version application code, obtain terminal iidentification number and random information, determine that described terminal iidentification number is not recorded in when authorizing in the list, encrypt the version authority that this random information generates version authorization code and comprises the version authorization code, and described terminal iidentification number added to describedly authorize in the list.
A kind of software version distributing device comprises:
Version authorization code acquiring unit, be used for when needs carry out the version activation, obtain the version authorization code, the described version authorization code random information that to be the authorized party obtain according to the deciphering to the version application code in the version application documents that receive generates, and described version application code is that terminal generates according to terminal iidentification number and random information when the mandate of application version;
Version authorization code decryption unit is used for the decrypted version authorization code, obtains the random information in the version authorization code;
Activate the unit, be used for random information in the random information of version authorization code and generation version application code when identical, the activating software version.
A kind of software version distributing device comprises:
Version application code acquiring unit is used for after receiving the version application documents, obtains the version application code in the version application documents;
Version application code decryption unit is used to decipher described version application code, obtains terminal iidentification number and random information;
Processing unit is used for determining that described terminal iidentification number is not recorded in when authorizing list, encrypts the version authority that this random information generates version authorization code and comprises the version authorization code, and described terminal iidentification number is added to describedly authorize in the list.
The embodiment of the invention provides a kind of software version dissemination method, system and device, use terminal iidentifications such as IMEI or hardware ID number and random information to generate the version application code and carry out the version application to authorized party's server, server generates the version authorization code based on the random information of deciphering out from the version application code and returns to terminal, terminal deciphering version authorization code, if the random information that decrypts is identical with random information in the version application code, then version activates successfully, can use the version corresponding function.Like this, even other terminal has been distorted terminal iidentifications such as IMEI or hardware ID number, because random information difference, also have no idea to use server to carry out version for the version authorization code of terminal iidentification terminal grantings such as this IMEI or hardware ID and activate, and then effectively prevent because terminal iidentification quilts such as IMEI or hardware ID are distorted the Version Control risk that causes.
Embodiment
The embodiment of the invention provides a kind of software version dissemination method, system and device, use terminal iidentifications such as IMEI or hardware ID number and random information to generate the version application code and carry out the version application to authorized party's server, server generates the version authorization code based on the random information of deciphering out from the version application code and returns to terminal, terminal deciphering version authorization code, if the random information that decrypts is identical with random information in the version application code, then version activates successfully, can use the version corresponding function.
Owing in application code and authorization code, all carry random information, and verify the correctness of authorization code by random information, even other terminal has been distorted terminal iidentifications such as IMEI or hardware ID number, because random information is different with authorization code in the application code that other terminal generates, use server to carry out version for the version authorization code of terminal iidentification terminal grantings such as this IMEI or hardware ID so have no idea and activate, and then effectively prevent because terminal iidentification quilts such as IMEI or hardware ID are distorted the Version Control risk that causes.
As shown in Figure 1, the software version dissemination method that provides of the embodiment of the invention comprises:
Step S101, when needs carry out version when activating, obtain the version authorization code;
Wherein, the version authorization code random information that to be the authorized party obtain according to the deciphering to the version application code in the version application documents that receive generates, and the version application code is that terminal generates according to terminal iidentification number and random information when the mandate of application version;
Step S102, decrypted version authorization code obtain the random information in the version authorization code;
When step S103, the random information in the version authorization code are identical with the random information that generates the version application code, the activating software version.
In step S101, the mode of obtaining the software version authorization code comprises two kinds, a kind ofly be to use terminal iidentification number and random information to generate new version application code and leave in the version application documents to send to the authorized party, after the version authority that the reception authorized party returns, obtain the version authorization code in the version authority; Another kind is after using terminal iidentification number and random information to generate new version application code, or after verifying that already present version application code can be used, obtains the version authorization code of user's input.
Usually the user first after the install software or restarting terminal, carry out under the situations such as system update, all need to carry out the activation of software version, at this moment, then can generate the version application code that version application code or checking have generated, the version check code is stored in the version application documents usually, describes the flow process that generates the version application code below in detail.
As shown in Figure 2, the flow process of generation version application code specifically comprises:
Step S201, version application code begin to generate;
Step S202, check whether there are the version application documents that generated, if exist, execution in step S203, if there is no, execution in step S205;
Step S203, regenerate the completeness check code of version application code in the version application documents, the create-rule of completeness check code has a lot, usually generate according to already present version application code and other fixing reference information, by the integrity verification sign indicating number, can judge the attributes such as correctness of version application code;
Step S204, determine whether the completeness check code that regenerates is identical with the completeness check code of being stored, if, then the version application code in the explanation generation version application documents is errorless, can continue to use, finish the generation of version application documents, if not, then mistake appears in the version application code in the explanation generation version application documents, need regenerate the version application code, continue execution in step S205;
Step S205, obtain terminal iidentification number and random information and encrypt to generate the version application code;
Step S206, generate completeness check code according to the version application code that generates;
Step S207, version application code and the completeness check code that generates deposited in the version application documents.
When carrying out the version activation, terminal need be obtained the version authorization code, the mode of obtaining the version authorization code that the embodiment of the invention provides comprises two kinds, a kind of is that terminal is after generating the version application code, the version application documents that carry the version application code are directly sent to the authorized party by wireless connections or wired connection, it is server, server is after receiving the version application documents, version application code in the decrypted version application documents, and the random information in the acquisition version application code, according to this random information, encrypt to generate the version authorization code, and the version authorization code that generates is carried in the version authority sends it back terminal; Another kind is that the terminal notifying user imports the version authorization code or imports the version authority.
These the two kinds modes of obtaining the version authorization code can be used separately, the use of also can arranging in pairs or groups, for example, can be not successfully when the authorized party obtains the version authorization code in terminal, reresenting the user imports the version authorization code or imports the version authority, also can fail when activating, apply for the version authorization code to the authorized party again at the version authorization code of user's input.
Terminal can deposit the version authorization code in the version authority after the prompting user imports the version authorization code, activates according to the version authority again.For guaranteeing the correctness of version authorization code, usually when the prompting user imports the version authorization code, also need the user to import the completeness check code of version authorization code, and all deposit the completeness check code of version authorization code and version authorization code in the version authority, utilize the version authority to activate again.
Further, the authorized party is receiving the version application documents, and obtain version application code in the version application documents, and decrypted version application code, after obtaining terminal iidentification number and random information, can also obtain additional random information and be combined into combining random information with random information, and number be not recorded in when authorizing in the list at definite terminal iidentification, the encrypted combination random information generates the version authorization code and comprises the version authority of version authorization code, and terminal iidentification number is added to authorize in the list.Use predefined array mode to form combining random information, and use combining random information to generate the version authorization code, can further increase confidentiality.
Fig. 3 shown when terminal by wired connection to the flow process that the authorized party applies for the version authorization code, comprising:
Step S301, terminal connect authorized party's server;
Step S302, terminal send the version application documents to the authorized party;
Step S303, terminal receive the version authority that the authorized party returns;
Step S304, terminal activate according to the version authority that receives.
The authorized party can also receive the version application documents, obtain the version application code in the version application documents, and decrypted version application code, after obtaining terminal iidentification number and random information, further determine whether terminal iidentification number is recorded in and authorized in the list, determining not to be recorded in when having authorized in the list, encrypt the version authority that this random information generates version authorization code and comprises the version authorization code again, and terminal iidentification number added to authorize in the list.Can prevent repetitive endowment like this to same terminal hardware number.
Fig. 4 has shown that working as terminal obtains the flow process that the version application code of user's input activates, and comprising:
Step S401, terminal notifying user import the completeness check code of version authorization code and version authorization code;
Step S402, terminal receive the version authorization code of user's input and the completeness check code of version authorization code;
Step S403, terminal deposit the version authorization code of user's input and the completeness check code of version authorization code in the version authority;
Step S404, terminal activate according to the version authority.
After activating successfully, can allow the user to use this software version, if activate not success, can further point out the user to import version authorization code or importing version authority.
When activating, terminal at first obtains version authorization code and deciphering from the version authority, obtain random information in the version authorization code, whether compare this random information more identical with random information in the version application code, if what the decrypted version authorization code obtained is combining random information, so also need from combining random information, to obtain random information, compare again according to combination rule.
Concrete, as shown in Figure 5, the flow process that activates according to the version authorization code specifically comprises:
Step S501, determine that version application documents and version authority exist and all passed through integrity detection;
Version authorization code in step S502, the decrypted version authority obtains combining random information;
Step S503, remove additional random information, obtain the random information in the version authorization code according to the combination rule of setting;
When step S504, the random information in the version authorization code are identical with the random information that generates the version application code, the activating software version.
Carry out the process that software version activates with a specific embodiment explanation below.
Terminal is used based on IMEI number and random information IMEI_Rand_1 and is generated version application code VerAppCode through encrypting the back.Even cause the IMEI number of other-end the same owing to reason such as distorting, but because random information is uncertain such as time and random number, so the version application code that each terminal generated all is unique, behind the generation version application code VerAppCode version application code VerAppCode is left among the version application documents Imei.apply.
The version authorized party deciphers the unique version application code of the version that comprises among Imei.apply VerAppCode, obtains IMEI_Rand_1.Increase additional random information on this basis such as version information (Version), form new combination IMEI_Rand_2, encrypt then and generate the version authority Imei.auth that comprises unique authorization code VerAuthCode.
Version application side obtains behind the Imei.auth its entry terminal, terminal obtains IMEI_Rand_2 by deciphering VerAuthCode, remove additional random information acquisition IMEI_Rand_3 again, compare with the IMEI_Rand_1 of VerAppCode among the version application documents Imei.appy that is stored on the terminal, if identical then allow the user to use the part or all of function of version.
Accordingly, the embodiment of the invention also provides a kind of software version delivery system, as shown in Figure 6, comprises terminal 601 and server 602, wherein:
Terminal 601, be used for when needs carry out the version activation, use terminal iidentification number and random information to generate new version application code and leave in and send to server 602 in the version application documents, the version authority that reception server 602 returns, and the version authorization code in the decrypted version authority, obtain the random information in the version authorization code, and the random information of the random information in the version authorization code and generation version application code is when identical, the activating software version;
Server 602, be used for behind the version application documents that receive terminal 601 transmissions, obtain the version application code in the version application documents, the decrypted version application code, obtain terminal iidentification number and random information, determine that terminal iidentification number is not recorded in when authorizing in the list, encrypt the version authority that this random information generates version authorization code and comprise the version authorization code and send to terminal 601, and terminal iidentification number added to authorize in the list.
In order further to increase confidentiality, server 602 specifically is used for: after receiving the version application documents, obtain the version application code in the version application documents, the decrypted version application code, obtain terminal iidentification number and random information, obtain additional random information and be combined into combining random information with random information, and number be not recorded in when authorizing in the list at definite terminal iidentification, the encrypted combination random information generates the version authorization code and comprises the version authority of version authorization code, and terminal iidentification number is added to authorize in the list.
Accordingly, terminal 601 specifically is used for: when needs carry out the version activation, using terminal iidentification number and random information to generate new version application code and leave in the version application documents sends, receive the version authority, and the version authorization code in the decrypted version authority, obtain the combining random information in the version authorization code, from combining random information, obtain random information according to combination rule and obtain random information in the version authorization code, and the random information in the version authorization code is when identical with the random information that generates the version application code, the activating software version.
The embodiment of the invention is also corresponding to provide a kind of software version distributing device, and this device can be specially a kind of terminal, as shown in Figure 7, comprises in the device: version authorization code acquiring unit 701, version authorization code decryption unit 702 and activate unit 703, wherein:
Version authorization code acquiring unit 701, be used for when needs carry out the version activation, obtain the version authorization code, wherein, the version authorization code random information that to be the authorized party obtain according to the deciphering to the version application code in the version application documents that receive generates, and the version application code is that terminal generates according to terminal iidentification number and random information when the mandate of application version;
Version authorization code decryption unit 702 is used for the decrypted version authorization code, obtains the random information in the version authorization code;
Activate unit 703, be used for random information in the random information of version authorization code and generation version application code when identical, the activating software version.
The obtain manner of two kinds of version authorization codes that provide at the embodiment of the invention respectively, version authorization code acquiring unit 701 specifically is used for:
Use terminal iidentification number and random information to generate new version application code and leave in the version application documents and send, and receive the version authority that the authorized party returns, obtain the version authorization code in the version authority; Perhaps
After checking has existed the version application documents to use, obtain the version authorization code of user's input.
When generating the version authorization code by combining random information, version authorization code decryption unit 702 specifically is used for:
The decrypted version authorization code obtains the combining random information in the version authorization code, and obtains random information according to combination rule from combining random information.
The embodiment of the invention is also corresponding to provide a kind of software version distributing device, and this device can be specially a kind of server, as shown in Figure 8, comprises in this device:
Version application code acquiring unit 801 is used for after receiving the version application documents, obtains the version application code in the version application documents;
Version application code decryption unit 802 is used for the decrypted version application code, obtains terminal iidentification number and random information;
Processing unit 803 is used for determining that terminal iidentification number is not recorded in when authorizing list, encrypts the version authority that this random information generates version authorization code and comprises the version authorization code, and terminal iidentification number is added to authorize in the list.
When generating the version authorization code by combining random information, processing unit 803 specifically is used for:
Obtain additional random information and be combined into combining random information with random information, and number be not recorded in when authorizing in the list at definite terminal iidentification, the encrypted combination random information generates the version authorization code and comprises the version authority of version authorization code, and terminal iidentification number is added to authorize in the list.
The embodiment of the invention provides a kind of software version dissemination method, system and device, use terminal iidentifications such as IMEI or hardware ID number and random information to generate the version application code and carry out the version application to authorized party's server, server generates the version authorization code based on the random information of deciphering out from the version application code and returns to terminal, terminal deciphering version authorization code, if the random information that decrypts is identical with random information in the version application code, then version activates successfully, can use the version corresponding function.Like this, even other terminal has been distorted terminal iidentifications such as IMEI or hardware ID number, because random information difference, also have no idea to use server to carry out version for the version authorization code of terminal iidentification terminal grantings such as this IMEI or hardware ID and activate, and then effectively prevent because terminal iidentification quilts such as IMEI or hardware ID are distorted the Version Control risk that causes.
Obviously, those skilled in the art can carry out various changes and modification to the present invention and not break away from the spirit and scope of the present invention.Like this, if of the present invention these revise and modification belongs within the scope of claim of the present invention and equivalent technologies thereof, then the invention is intended to also comprise these changes and modification interior.