WO2016086572A1 - 一种算法重构装置及方法 - Google Patents

一种算法重构装置及方法 Download PDF

Info

Publication number
WO2016086572A1
WO2016086572A1 PCT/CN2015/076944 CN2015076944W WO2016086572A1 WO 2016086572 A1 WO2016086572 A1 WO 2016086572A1 CN 2015076944 W CN2015076944 W CN 2015076944W WO 2016086572 A1 WO2016086572 A1 WO 2016086572A1
Authority
WO
WIPO (PCT)
Prior art keywords
algorithm
key parameter
reconstruction
user information
reconstructed
Prior art date
Application number
PCT/CN2015/076944
Other languages
English (en)
French (fr)
Inventor
谈剑锋
尤磊
赵晶晶
钱金金
盛学明
王力
Original Assignee
上海众人网络安全技术有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 上海众人网络安全技术有限公司 filed Critical 上海众人网络安全技术有限公司
Publication of WO2016086572A1 publication Critical patent/WO2016086572A1/zh

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L9/00Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
    • H04L9/14Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols using a plurality of keys or algorithms

Definitions

  • the present invention relates to the field of information security technologies, and in particular, to an algorithm reconstruction apparatus and method.
  • the dynamic password is based on a special algorithm to generate an unpredictable random number combination.
  • a password is valid once.
  • the dynamic password is a safe and convenient account anti-theft technology, which can effectively protect the authentication and security of transactions and logins. Change the password, safe and worry-free, thus ensuring the security of the system in the most basic password authentication, solving the major losses caused by password fraud, preventing malicious intruders or vandalism, and solving the intrusion caused by password leakage. problem.
  • the present invention provides a dynamic token algorithm reconstruction apparatus and method, including a dynamic token algorithm that can better protect users, so as to improve the use of dynamic passwords.
  • the security of the certified system avoids security risks and provides a better user experience.
  • Such an algorithm reconstruction apparatus includes:
  • a random number generating module the user generates a random number according to the obtained user information, and the random number is set as a key parameter;
  • the algorithm reconstruction module is connected to the random number generation module and configured to reconstruct the first algorithm by using a preset reconstruction mechanism.
  • the random number generated according to the user information, that is, the key parameter is unique and unpredictable, thus ensuring the uniqueness of the algorithm reconstructed according to the key parameter.
  • the application of the algorithm is extended to solve the security hazard caused by the fixed algorithm.
  • the uniqueness of the algorithm, that is, the algorithm corresponding to each user is different, the algorithm is also safe and difficult to decipher, even if the criminal Cracking a user does not affect other users, thereby improving the security of the algorithm in use.
  • the algorithm of the present invention performs security authentication, thereby avoiding security risks.
  • the algorithm reconstruction module includes at least one of the following units:
  • An operation sequence unit configured to determine an operation sequence of the reconstructed first algorithm according to the key parameter
  • a grouping unit configured to determine, according to the key parameter, a structure of a packet data block of the reconstructed first algorithm and an operation sequence of the packet data block;
  • a fixed parameter determining unit configured to determine, according to the key parameter, a fixed parameter in the reconstructed first algorithm.
  • the key parameter string is unpredictable, so that the operation order or the block data block structure of each algorithm reconstructed according to the key parameter is different or operated. Different sequences or fixed parameters of the algorithm are different, which increases the complexity of the algorithm and improves the security of the dynamic token.
  • the device further includes an information acquiring module, which is connected to the random number generating module, and is configured to acquire the user information.
  • the apparatus further includes a storage module, configured to store the first algorithm, the preset reconstruction mechanism, and a key parameter uniquely associated with the user information.
  • the device further includes a sending module, which is respectively connected to the information acquiring module and the storage module, and is configured to deliver the first algorithm according to the user information.
  • a sending module which is respectively connected to the information acquiring module and the storage module, and is configured to deliver the first algorithm according to the user information.
  • the device may select the first algorithm by using a sending module, and store it in a specific storage area of the memory, and the non-server side may not read or write the storage area, so that the illegal user cannot access the first algorithm, thereby improving The safety of the device.
  • the present invention also provides an algorithm reconstruction method, the method comprising:
  • the first algorithm is reconstructed by a preset reconstruction mechanism according to the key parameter.
  • the random number generated according to the user information, that is, the key parameter is unique and unpredictable, thus ensuring the uniqueness of the algorithm reconstructed according to the key parameter.
  • the application of the algorithm is extended to solve the security hazard caused by the fixed algorithm.
  • the uniqueness of the algorithm, that is, the algorithm corresponding to each user is different, the algorithm is also safe and difficult to decipher, even if the criminal Cracking a user does not affect other users, thereby improving the security of the algorithm in use.
  • the algorithm of the present invention performs security authentication, thereby avoiding security risks.
  • reconstructing the first algorithm by using a preset reconstruction mechanism includes at least one of the following steps:
  • the key parameter string is unpredictable, so that the operation order or the block data block structure of each algorithm reconstructed according to the key parameter is different or operated. Different sequences or fixed parameters of the algorithm are different, which increases the complexity of the algorithm and improves the security of the dynamic token.
  • the method further includes: delivering the first algorithm according to user information.
  • the generation of the key parameter according to the user information is unique and unpredictable, thus ensuring the uniqueness of the algorithm reconstructed according to the key parameter, ie, each user
  • the corresponding reconstructed algorithms are different, so the security of the algorithm is greatly improved, and it is difficult to decipher. Even if the criminals crack a user, they will not affect other users, and the user can use the algorithm of the present invention with confidence.
  • Reconstructing the reconstructed algorithm at the same time, due to the uniqueness of the reconstructed algorithm and the use in the present invention, the application field of the algorithm is greatly expanded, for example, applied to the authentication field, avoiding the problem caused by the fixed algorithm. Security risks.
  • FIG. 1 is a structural diagram of a first embodiment of an algorithm reconstruction apparatus according to the present invention.
  • FIG. 2 is a structural diagram of a key parameter according to an embodiment of the present invention.
  • FIG. 3 is a structural diagram of a second embodiment of an algorithm reconstruction apparatus according to the present invention.
  • FIG. 4 is a structural diagram of a third embodiment of an algorithm reconstruction apparatus according to the present invention.
  • FIG. 5 is a structural diagram of a fourth embodiment of an algorithm reconstruction apparatus according to the present invention.
  • FIG. 6 is a flowchart of a method for reconstructing a dynamic token algorithm according to an embodiment of the present invention.
  • the algorithm reconstruction apparatus specifically includes: a random number generation module, where a user generates a random number according to the acquired user information, and the random number is set as a key parameter.
  • the algorithm reconstruction module is coupled to the random number generation module for reconstructing the first algorithm by a preset reconstruction mechanism.
  • the user information includes a user name, a password, a mobile phone number, and the like, and the key parameter is represented by 8 bytes.
  • the specific content of the user information is not limited as long as it can uniquely identify the user, and is included in the content of the present invention; in addition, in other embodiments, the random number generated by the random number generating module (Key parameter) can also be 4 bytes, 16 bytes, etc., depending on the specific situation.
  • An operation sequence unit configured to determine an operation sequence of the reconstructed first algorithm according to the key parameter
  • a grouping unit configured to determine a structure of the packet data block of the reconstructed first algorithm according to the key parameter And the order of operations of the packet data blocks;
  • the fixed parameter determining unit is configured to determine a fixed parameter in the reconstructed first algorithm according to the key parameter.
  • the preset reconstruction mechanism is mainly implemented by the foregoing three methods, that is, changing the operation sequence of the first algorithm, the structure and sequence of the packet data block, and the fixed parameters included in the first algorithm, and
  • the preset reconstruction mechanism combines the key parameters generated by the random generation module to reconstruct the algorithm.
  • the key parameter is 8 bytes, wherein the first bit represents the operation order, the second bit represents the packet data block, and the third bit represents the fixed parameter, as shown in FIG. 2, and is brought into the preset weight.
  • the general operation order of an algorithm sequentially includes four main steps of W0, W1, W2, and W3, and each step includes a corresponding one.
  • Sub-steps, such as W1 include five sub-steps of t0, t1, t2, t3, and t4.
  • the operation order of the algorithm by using a bit in the key parameter to represent the operation order, thereby generating a new algorithm; specifically, if the key parameter is 01234567, where the first bit represents The operation sequence, if the operation order of the sub-steps of W1 represented by the first bit at this time, indicates that t0 is the first operation step among the five sub-steps, that is, the operation order of the sub-steps of W1 at this time is t0, t1, t2 , t3, t4; Similarly, if the first bit represents the operation order of the main step, it means that W0 is the first operation step in the operation process of the main step, then the operation order of the main step is W0, W1, W2, W3; if the key parameter is 21304567, and the first bit represents the operation order, if the first bit represents the operation sequence of the main step at this time, it indicates that step W2 is the first operation step in the main step, then the main step at this time The operation
  • the first operation step that is, the operation order of the sub-steps in W1 at this time is t2, t0, t1, t3, t4.
  • the number in the key parameter corresponds to the step to be run (eg, the first bit is 2, then W2 or t2 is the first step)
  • Other methods may be adopted.
  • W0, W1, W2, and W3 are included, and W1 includes five sub-steps of t0, t1, t2, t3, and t4.
  • the key parameter is 35471260, and the first bit represents the operation order.
  • the step W0 is performed as the third step, that is, the operation order of the main step is W1, W2, W0, W3;
  • the step t0 is performed as the third step in the sub-step, that is, the operation order of the sub-steps of W1 is t1, t2 , t0, t3, t4.
  • the key parameter is 76543210
  • the first bit 7 represents the operation order
  • the main steps are only four steps: W1, W2, W3, and W4.
  • step W7 cannot be found as the first operation step, then it is automatically skipped at this time, and the operation is performed directly in the original order; and so on.
  • the first bit 7 represents the operation sequence of the sub-steps in the main step W1
  • the step t7 is also not found as the first operation step, and the automatic operation is skipped at this time, and the operation is directly performed in the original order.
  • the first algorithm and the key parameter are not limited in how to change the operation order of the first algorithm, that is, the adjustment may be performed according to the actual situation, as long as the operation order is changed and the role of the algorithm is unchanged, the initial Purpose is included in the content of the present invention.
  • the first algorithm is reconstructed by changing the structure and operation order of the packet data block: wherein changing the structure of the packet data block includes the number of packet data blocks also including the change of the structure inside the data block.
  • changing the structure of the packet data block includes the number of packet data blocks also including the change of the structure inside the data block.
  • a new byte may be represented by a bit byte representing a change in the internal structure of the packet module, and another bit representing the operation sequence of the regrouped packet module is brought into the operation of the first algorithm to generate a new algorithm.
  • the general operation order of SM3 is: padding, grouping, iterative, and compression.
  • the algorithm first fills in the information in the process of computing, and the padded data m
  • the key parameter is 01234567
  • the first bit represents the operation order of the packet data block
  • the second represents the structure of the packet data block.
  • the positions of the data groups m1 and m0 are swapped in the operation to change the structure of the data block, and 0 indicates that the first data block B (0) is operated in the first step.
  • the key parameter is 24653107
  • the positions of m4 and m0 are swapped to change the structure of the data block during the operation, and 2 indicates that B (0) is operated in the third step.
  • the m1 represented by the second bit 1 can be performed with any array of m0-m7.
  • the swapping of the data group depends on the setting of the preset reconstruction mechanism. For example, in the above example, m1 and m0 are swapped. In other embodiments, m1 and m7 may also be set. Make a swap and so on.
  • the operation of the first algorithm may be performed according to a certain byte of the key parameter to represent the number of packet data blocks, and the other bit represents the operation sequence of the re-grouped packet data block to generate a new one.
  • the algorithm uses the SM3 hash algorithm as an example.
  • the conventional algorithm according to SM3 first fills the information m into 512-bit data, and in the present invention.
  • the 370-bit data can be grouped according to the data group of fixed length (for example, 200 bits per group), and then each group of data after the grouping is filled into 512 bits to change the structure of the packet data block, and then normal according to SM3.
  • the steps are performed.
  • the data may be grouped according to a fixed length of 50 bits, 100 bits, 150 bits, etc., and then filled into 512 bits. As long as it can attain the object of the present invention, it is included in the content of the present invention.
  • one of the key parameters may represent a fixed parameter, and participate in a programming operation of the preset reconstruction mechanism to change the fixed parameter.
  • a certain parameter of the key parameter representing a fixed parameter, participating in the programming operation of the preset reconstruction mechanism, changing the value of the fixed parameter a or b, thereby forming a new algorithm.
  • the key parameter is represented by 01234567
  • the device further includes an information acquiring module, which is connected to the random number generating module, for acquiring user information.
  • the user information includes a user name, a password, and a hand. Machine number, etc.
  • the information acquisition module may be a keyboard, a touch screen, a voice recognition, etc., and input user information.
  • the user information is sent to the random number generation module, and after the random number generation module acquires the user information, the corresponding key parameter is randomly generated according to the user information, and the algorithm reconstruction module is The first algorithm stored in the interior is reconstructed by combining the key parameter and the preset reconstruction mechanism.
  • the specific content of the user information is not limited as long as it uniquely identifies the user, and is included in the content of the present invention.
  • the apparatus further includes a storage module, configured to store the first algorithm, a preset reconstruction mechanism, and a key parameter uniquely associated with the user information.
  • the first algorithm and the preset reconstruction device are first stored in the storage module; after the information acquisition module obtains the user information, the user information is sent to the user information.
  • the random number generation module generates a key parameter, and finally sends it to the storage module along with the user information and the key parameter.
  • the storage module first associates the key parameter with the user information, and then stores the key parameter uniquely associated with the user information.
  • the device further includes a sending module, which is respectively connected to the information acquiring module and the storage module, and is configured to deliver the first algorithm according to the user information.
  • a plurality of types of first algorithms are included in the storage module, such as SM3, SM4, etc., and the user may perform an autonomous selection on the algorithm that needs to be reconstructed, and after the sending module receives the user information, The request information in the user information sends a signal to the storage module, selects from the first algorithm stored in the storage module, and finally sends the first algorithm selected by the user to the algorithm reconstruction module for reconstruction.
  • the delivery module can also communicate with the outside world through the internally stored communication unit, and the algorithm is downloaded.
  • the present invention further provides a reconstruction method, including:
  • the foregoing method reconfiguring the first algorithm by using a preset reconstruction mechanism includes at least one of the following steps:
  • the fixed parameter in the reconstructed first algorithm is determined according to the key parameter.
  • the preset reconstruction mechanism is mainly implemented by the foregoing three methods, which are respectively changing the operation order of the first algorithm, the structure and sequence of the packet data block, and the fixed parameters included in the first algorithm, and Further, the uniqueness and unpredictability of the reconstructed algorithm are further guaranteed.
  • the preset reconstruction mechanism combines the key parameters generated by the random generation module to reconstruct the algorithm. Specifically, it is assumed that the key parameter is 8 bytes, wherein the first bit represents the operation order, the second bit represents the packet data block, and the third bit represents the fixed parameter, as shown in FIG. 2, and is brought into the preset weight.
  • the method of the present invention further includes: transmitting the first algorithm according to the user information.
  • the user can make an autonomous selection of an algorithm that needs to be reconstructed.
  • the method of the present invention further includes: before the algorithm reconstruction method reconstructs the first algorithm, at least the following steps: pre-storing the first algorithm, pre-setting the reconstruction mechanism, and uniquely associated with the user information. Key parameter.

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Security & Cryptography (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Storage Device Security (AREA)
  • Mobile Radio Communication Systems (AREA)

Abstract

本发明提供一种算法重构装置及方法,所述装置包括:随机数生成模块,根据获取的用户信息生成随机数,所述随机数被设定为密钥参数;算法重构模块,与所述随机数生成模块连接,用于通过一预设重构机制重构第一算法。在本发明中,由于获取的用户信息的唯一性,因而根据该用户信息生成密钥参数是唯一且不可预见的,这样就确保了根据密钥参数重构的算法的唯一性,即每个用户对应的重构后的算法都不相同,因而算法的安全性大大提高能高,难以破译,即使不法分子破解了一个用户,也不会影响其他用户,进而用户能够放心的使用经过本发明的算法重构装置重构后的算法。

Description

一种算法重构装置及方法 技术领域
本发明涉及信息安全技术领域,尤指一种算法重构装置及方法。
背景技术
随着信息科技的发展,信息安全技术在各领域的应用更为广泛和深入。在信息安全领域,身份认证往往是信息系统使用的第一把钥匙,其安全性受到越来越多的重视。相应地,为了加强身份认证安全性的动态口令技术已经越来越多地应用于各个不同领域,尤其在网银、网游、电信运营商、电子政务、企业服务器等应用领域。另外,动态口令在企业应用也是当前的热点,越来越多的企业或实体采用动态口令保护其VPN(Virtual Private Network,虚拟专用网)、服务器、网络设备等。
动态口令是根据专门的算法生成一个不可预测的随机数字组合,一个密码使用一次有效,动态口令是一种安全便捷的帐号防盗技术,可以有效保护交易和登录的认证安全,采用动态口令就无需定期修改密码,安全省心,从而在最基本的密码认证这一环节保证了系统的安全性,解决了因口令欺诈而导致的重大损失,防止恶意入侵者或人为破坏,解决由口令泄密导致的入侵问题。
为了进一步保障信息系统使用过程中的安全,目前较为常用的是使用实体硬件作为动态口令的载体,其内置电池、芯片和显示屏,产生并显示动态密码,但是,这种动态令牌有一定的体积和厚度,长时间携带会给用户带来不便;当然,也有体积和厚度较小的令牌形式,如卡片式令牌,这种令牌虽然携带方便,但按键手感普遍较差,用户输入也不方便,同时成本也比较高;另外,人们也尝试在智能手机上开发软件令牌产品,但是其安全性无法保证,这种软件令牌只能用于安全性要求不是很高的场所。
然而,无论是实体硬件动态令牌还是软件动态令牌,都有一个共同的弱点,即其所有的令牌算法都是相同且公开的,仅通过密钥来实现不同用户的身份认 证过程,可一旦密钥被非法获得,不法分子即可任意获取动态密码,动态令牌将不再安全。
发明内容
本发明为了解决现有动态令牌安全性不太高的问题,从而提供一种动态令牌算法重构装置及方法,包括一种更能保障用户安全的动态令牌算法,以提高使用动态口令认证的系统的安全性,避免安全隐患,给用户带来更好的使用体验。
为了实现本发明以上发明目的,本发明提供的算法重构装置是通过以下技术方案实现的:
这种算法重构装置包括:
随机数生成模块,用户根据获取的用户信息生成随机数,所述随机数被设定为密钥参数;
算法重构模块,与所述随机数生成模块连接,用于通过一预设重构机制重构第一算法。
根据上述技术方案,由于用户信息的唯一性,因而根据该用户信息生成的随机数即密钥参数是唯一且不可预见的,这样就确保了根据密钥参数重构后的算法的唯一性,大大扩展了算法的应用,解决了目前由于算法的固定而引起的安全隐患;同时,由于算法的唯一性,即每个用户对应的算法都不相同,算法同样安全性能高,难以破译,即使不法分子破解了一个用户,也不会影响其他用户,进而提高了算法在使用过程中的安全性,在实际应用中通过本发明的算法进行安全认证,避免了安全隐患。
优选地,所述算法重构模块中至少包括以下一个单元:
运算顺序单元,用于根据所述密钥参数确定所述重构后的第一算法的运算顺序;
分组单元,用于根据所述密钥参数确定所述重构后的第一算法的分组数据块的结构以及所述分组数据块的运算顺序;
固定参数确定单元,用于根据所述密钥参数确定所述重构后的第一算法中的固定参数。
由于事先生成的随机数为不可预知的字符串,这就使得密钥参数字符串是不可预知的,从而每个根据密钥参数进行算法重构的算法的运算顺序或分组数据块结构不同或运算顺序不同或算法的固定参数不同,提高了算法的复杂度,进而提高了动态令牌的安全性。
优选地,所述装置还包括信息获取模块,与所述随机数生成模块连接,用于获取所述用户信息。
优选地,所述装置还包括存储模块,用于存储所述第一算法,所述预设重构机制以及与所述用户信息唯一关联的密钥参数。
优选地,所述装置还包括下发模块,分别与所述信息获取模块和所述存储模块连接,用于根据所述用户信息下发所述第一算法。
在本技术方案中,装置可以通过下发模块选择上述第一算法,并存储至存储器一特定存储区,非服务器端不可读写该存储区,从而非法用户不能存取所述第一算法,提高了装置的安全性。
为了实现本发明的发明目的,本发明还提供了一种算法重构方法,所述方法包括:
根据用户信息生成一随机数,所述随机数被设定为一密钥参数;
根据所述密钥参数,通过一预设重构机制重构第一算法。
根据上述技术方案,由于用户信息的唯一性,因而根据该用户信息生成的随机数即密钥参数是唯一且不可预见的,这样就确保了根据密钥参数重构后的算法的唯一性,大大扩展了算法的应用,解决了目前由于算法的固定而引起的安全隐患;同时,由于算法的唯一性,即每个用户对应的算法都不相同,算法同样安全性能高,难以破译,即使不法分子破解了一个用户,也不会影响其他用户,进而提高了算法在使用过程中的安全性,在实际应用中通过本发明的算法进行安全认证,避免了安全隐患。
优选地,通过一预设重构机制重构第一算法至少包括以下一个步骤:
根据所述密钥参数,确定重构后的第一算法的运算顺序;
根据所述密钥参数,确定重构后的第一算法的分组数据块的结构以及所述分组数据块的运算顺序;
根据所述密钥参数,确定重构后的第一算法中的固定参数。
由于事先生成的随机数为不可预知的字符串,这就使得密钥参数字符串是不可预知的,从而每个根据密钥参数进行算法重构的算法的运算顺序或分组数据块结构不同或运算顺序不同或算法的固定参数不同,提高了算法的复杂度,进而提高了动态令牌的安全性。
优选地,所述方法还包括:根据用户信息下发所述第一算法。
优选地,所述算法重构方法重构所述第一算法之前,至少还包括以下步骤:
预存所述第一算法,所述预设重构机制以及与所述用户信息唯一关联的密钥参数。
本发明能够带来以下有益效果:
在本发明中,由于获取的用户信息的唯一性,因而根据该用户信息生成密钥参数是唯一且不可预见的,这样就确保了根据密钥参数重构的算法的唯一性,即每个用户对应的重构后的算法都不相同,因而算法的安全性大大提高能高,难以破译,即使不法分子破解了一个用户,也不会影响其他用户,进而用户能够放心的使用经过本发明的算法重构装置重构后的算法;同时,由于本发明中重构后的算法与用于的唯一性,大大扩展了算法的应用领域,如应用于认证领域,避免了由于固定的算法而引起的安全隐患。
附图说明
下面结合附图和具体实施方式对本发明作进一步详细说明:
图1为本发明中算法重构装置第一实施例的结构图;
图2为本发明实施例密钥参数的结构图;
图3为本发明中算法重构装置第二实施例的结构图;
图4为本发明中算法重构装置第三实施例的结构图;
图5为本发明中算法重构装置第四实施例的结构图;
图6为本发明实施例动态令牌算法重构方法的流程图。
具体实施方式
为了更清楚地说明本发明实施例或现有技术中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本发明的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。
作为具体实施例一,如图1所示,为本发明提供的算法重构装置,具体包括:随机数生成模块,用户根据获取的用户信息生成随机数,且随机数被设定为密钥参数;算法重构模块,与随机数生成模块连接,用于通过一预设重构机制重构第一算法。具体地,在本实施例中,用户信息包括用户名、密码、手机号等,密钥参数采用8个字节进行表示。当随机数生成模块获取了用户信息之后,随即根据用户信息随机生成相应的密钥参数,算法重构模块则结合密钥参数和预设重构机制对内部存储的第一算法进行重构。特别地,在本发明中,对用户信息的具体内容不作限定,只要其能唯一标识该用户,都包括在本发明的内容中;另外,在其他实施例中,随机数生成模块生成的随机数(密钥参数)还可以是4个字节、16个字节等,根据具体情况而定。
在上述技术方案中,由于每个令牌的用户信息是唯一的,而根据该用户信息生成的随机数即密钥参数是唯一且不可预见的,同时该动态令牌的令牌算法与该密钥参数对应,这就确保每个动态令牌的令牌算法也是唯一的,从而使得该动态令牌生成的动态口令复杂度大大提高,使动态令牌的安全性更高,进而提高了使用动态口令进行认证的系统的安全性,避免安全隐患,给用户带来更好的使用体验。
以下我们对上述算法重构模块进行详细的描述,其中至少包括以下一个单元:
运算顺序单元,用于根据密钥参数确定重构后的第一算法的运算顺序;
分组单元,用于根据密钥参数确定重构后的第一算法的分组数据块的结构 以及分组数据块的运算顺序;
固定参数确定单元,用于根据密钥参数确定重构后的第一算法中的固定参数。
可以看出,在本发明中,预设重构机制主要通过上述三种方式进行实现,分别是改变第一算法的运算顺序、分组数据块结构和顺序以及第一算法中包括的固定参数,且为了进一步保障重构后的算法的唯一性和不可预见性,在本发明中,预设重构机制结合随机生成模块生成的密钥参数对算法进行重构。具体地,假设密钥参数为8个字节,其中,第一位代表运算顺序,第二位代表分组数据块,第三位代表固定参数,如图2所示,将其带入预设重构机制,通过预设重构机制对第一算法进行重构生成一个与用户信息相关的新算法,由此可以看出,由于密钥参数的随机性(其中包括的每个字节的参数都是随机的),因而将其带入预设重构机制对第一算法进行重构后的算法即具备了随机性,即每个用户对应的重构后的算法都不相同,因而算法的安全性能高,难以破译,即使不法分子破解了一个用户,也不会影响其他用户,进而提高了使用动态口令进行认证的过程中的安全性,避免了安全隐患。
以通过改变运算顺序重构第一算法来说:假定某一算法(上述第一算法)的一般运算顺序依次包括W0,W1,W2,W3四个主步骤,且每个步骤中分别包括相应的子步骤,如W1中包括t0,t1,t2,t3,t4五个子步骤。在本发明中,我们通过使用密钥参数中的某一位代表运算顺序来改变该算法的运算顺序,从而生成新的算法;具体来说,如果密钥参数为01234567,其中,第一位代表运算顺序,若此时第一位代表的W1中子步骤的运算顺序,则表示t0为五个子步骤中的第一个运算步骤,即此时W1中子步骤的运算顺序为t0,t1,t2,t3,t4;同理,若第一位代表主步骤的运算顺序,则说明在主步骤的运算过程中W0为第一运算步骤,则此时主步骤的运算顺序为W0,W1,W2,W3;如果密钥参数为21304567,且第一位代表运算顺序,若此时第一位代表主步骤的运算顺序,则表示步骤W2为主步骤中的第一运算步骤,则此时主步骤的运算顺序为W2,W0,W1,W3;同理,若此时第一位代表W1中子步骤的运算顺序,则表示步骤t2为五个子步骤中的 第一个运算步骤,即此时W1中子步骤的运算顺序为t2,t0,t1,t3,t4。且要说明的是,在上述的举例中,密钥参数中的数字与要运行的步骤是对应的(如第一位是2则W2或t2作为第一步骤),在其他实施例中,也可以采取其他的方式,如,同样地,第一算法中还是包括W0,W1,W2,W3四个主步骤,W1中包括t0,t1,t2,t3,t4五个子步骤,此时,若密钥参数为35471260,且第一位代表运算顺序,若此时第一位代表主步骤的运算顺序,则表示步骤W0作为第三步进行运算,即主步骤的运算顺序为W1,W2,W0,W3;同理,若此时第一位代表主步骤W1中的子步骤的运算顺序,则表示步骤t0作为子步骤中的第三步进行运算,即W1的子步骤的运算顺序为t1,t2,t0,t3,t4。特别地,在本发明中,假若此时密钥参数中代表运算顺序的位数大于算法运算过程中的步骤数量,如,密钥参数为76543210,第一位7代表运算顺序,而此时算法的主步骤只有W1,W2,W3,W4四个步骤,算法在运行的过程中,找不到步骤W7作为第一运算步骤,则此时自动跳过,直接按照原顺序进行运算;以此类推,若第一位7代表的是主步骤W1中子步骤的运算顺序,同样找不到步骤t7作为第一运算步骤,此时也自动跳过,直接按照原顺序进行运算。在本发明中,对上述的第一算法及密钥参数如何改变第一算法的运算顺序都不作限定,即可以根据实际情况进行调整,只要运算顺序改变后算法的作用不变,能达到最初的目的,都包括在本发明的内容中。
进一步地,以通过改变分组数据块的结构和运算顺序重构第一算法来说:其中,改变分组数据块的结构包括分组数据块的数量也包括数据块内部的结构的变化。例如:可以根据密钥参数中某一位字节代表分组模块的内部结构的改变,另一位代表重新分组过后的分组模块的运算顺序带入第一算法的运算从而生成新的算法。以SM3杂凑算法为例,SM3的一般运算顺序依次是:填充、分组、迭代、压缩,假若用户信息m的长度为24bit,则算法在运算的过程中首先对信息进行填充,填充后的数据m’的长度为512bit的整数倍,随后对填充后的数据按照512bit进行分组,即分组后的每组数据为512bit,m’=B(0)B(1)…B(n-1)。具体地,在本发明中,假若分组后的数据块 B(0)=[m0,m1,m2,m3…m7],密钥参数为01234567,且第一位代表分组数据块的运算顺序,第二代表分组数据块的结构,则此时在运算过程中数据组m1与m0的位置进行对换以此改变数据块的结构,0表示第一个数据块B(0)在第一步进行运算;类似地,若密钥参数为24653107,则在运算过程中m4与m0的位置进行对换来改变数据块的结构,2表示B(0)在第三步进行运算。当然,在本发明中,我们对改变数据块结构的方法不作具体限定,即在上述例子中,当密钥参数为01234567时,第二位1代表的m1可以与m0-m7中任一数组进行对换,在实际中数据组的对换取决于预设重构机制的设定,如,以上的例子中m1与m0进行对换,在其他的实施例中,也可以设定将m1与m7进行对换等。又例如,在本发明中,可以根据密钥参数中某一字节代表分组数据块的数量,另一位代表重新分组过后的分组数据块的运算顺序带入第一算法的运算从而生成新的算法,以SM3杂凑算法为例,在改变分组数据块的数量的过程中,假如用户信息m的长度为370bit,按照SM3传统的算法会首先将信息m进行填充为512bit的数据,而在本发明中,可以首先将370bit的数据按照定长(如,每组200bit)的数据组进行分组,随后再将分组过后的每组数据进行填充为512bit以改变分组数据块的结构,随后再按照SM3正常的步骤进行运算,当然,在本发明中,我们对上述的数据组的定长不作限定,如还可以将数据按照按照定长50bit、100bit、150bit等进行分组,再分别将其进行填充为512bit,只要其能达到本发明的目的,都包括在本发明的内容中。
进一步地,以改变固定参数来说:可以将密钥参数中的某一个位代表固定参数,参与到预设重构机制的编程运算中改变固定参数。以椭圆曲线算法为例:Y2=X3+aX+b,以密钥参数的某一位代表固定参数,参与到预设重构机制的编程运算中改变固定参数a或者b的值,从而形成新算法。如密钥参数用01234567来表示,且第三位固定参数2作为a的值,从而改变第一算法生成的新的算法即为Y2=X3+2X+b。
进一步地,如图3所示,装置还包括信息获取模块,与随机数生成模块连接,用于获取用户信息,特别地,在发明中,用户信息包括用户名、密码、手 机号等。信息获取模块可以是键盘、触摸屏、语音识别等,将用户信息进行输入。具体地,当信息获取模块获取了用户信息之后,随即将用户信息发送至随机数生成模块,随机数生成模块获取了用户信息之后,即根据用户信息随机生成相应的密钥参数,算法重构模块则结合密钥参数和预设重构机制对内部存储的第一算法进行重构。特别地,在本发明中,对用户信息的具体内容不作限定,只要其能唯一标识该用户,都包括在本发明的内容中。
进一步地,如图4所示,装置还包括存储模块,用于存储第一算法,预设重构机制以及与用户信息唯一关联的密钥参数。具体地,在本发明中,在对第一算法进行重构之前,首先在存储模块中存储第一算法以及预设重构装置;当信息获取模块获取到了用户信息之后,随即将用户信息发送至随机数生成模块生成密钥参数,最后连同用户信息与密钥参数一起发送至存储模块,存储模块首先将密钥参数与用户信息进行关联,随后存储与用户信息唯一关联的密钥参数。
进一步地,如图5所示,装置还包括下发模块,分别与信息获取模块和存储模块连接,用于根据用户信息下发第一算法。具体地,在本发明中,在存储模块中包括很多种类的第一算法,如SM3,SM4等,用户可以在对需要重构的算法进行自主的选择,下发模块接收到用户信息之后,针对用户信息中的请求信息将信号发送至存储模块,从存储模块中存储的第一算法进行选择,最后将用户选择的第一算法发送至算法重构模块中进行重构。特别地,在本发明中,如若存储模块中没有预先存储用户需要的第一算法,则下发模块还能够通过内部存储的通信单元与外界通信,对的算法进行下载。
如图6所示,为了实现本发明的发明目的,本发明还提供了一种重构方法,方法包括:
S101.根据用户信息生成一随机数,随机数被设定为一密钥参数;;
S102.根据密钥参数,通过一预设重构机制重构第一算法。
根据上述技术方案,由于每个令牌的用户信息是唯一的,而根据该用户信息生成的随机数即密钥参数是唯一且不可预见的,同时该动态令牌的令牌算法 与该密钥参数对应,这就确保每个动态令牌的令牌算法也是唯一的,从而使得该动态令牌生成的动态口令复杂度大大提高,使动态令牌的安全性更高,进而提高了使用动态口令进行认证的系统的安全性,避免安全隐患,给用户带来更好的使用体验。
进一步地,上述方法通过一预设重构机制重构第一算法至少包括以下一个步骤:
根据密钥参数,确定重构后的第一算法的运算顺序;
根据密钥参数,确定重构后的第一算法的分组数据块的结构以及分组数据块的运算顺序;
根据密钥参数,确定重构后的第一算法中的固定参数。
具体地,在本发明中,预设重构机制主要通过上述三种方式进行实现,分别是改变第一算法的运算顺序、分组数据块结构和顺序以及第一算法中包括的固定参数,且为了进一步保障重构后的算法的唯一性和不可预见性,在本发明中,预设重构机制结合随机生成模块生成的密钥参数对算法进行重构。具体地,假设密钥参数为8个字节,其中,第一位代表运算顺序,第二位代表分组数据块,第三位代表固定参数,如图2所示,将其带入预设重构机制,通过预设重构机制对第一算法进行重构生成一个与用户信息相关的新算法,由此可以看出,由于密钥参数的随机性,即其中包括的每个字节的参数都是随机的,因而将其带入预设重构机制对第一算法进行重构后的算法即具备了随机性,即每个用户对应的重构后的算法都不相同,因而算法的安全性能高,难以破译,即使不法分子破解了一个用户,也不会影响其他用户,进而提高了使用动态口令进行认证的过程中的安全性,避免了安全隐患。预设重构机制在装置中已经进行描述,再此不做赘述。
进一步地,本发明的方法中还包括:根据用户信息下发第一算法。具体地,在本发明中,用户可以在对需要重构的算法进行自主的选择。
进一步地,本发明的方法中还包括:算法重构方法重构第一算法之前,至少还包括以下步骤:预存第一算法,预设重构机制以及与用户信息唯一关联的 密钥参数。
以上所述仅是本发明的优选实施方式,应当指出,对于本技术领域的普通技术人员来说,在不脱离本发明原理的前提下,还可以做出若干改进和润饰,这些改进和润饰也应视为本发明的保护范围。

Claims (9)

  1. 一种算法重构装置,其特征在于,所述装置包括:
    随机数生成模块,根据获取的用户信息生成随机数,所述随机数被设定为密钥参数;
    算法重构模块,与所述随机数生成模块连接,用于通过一预设重构机制重构第一算法。
  2. 如权利要求1所述算法重构装置,其特征在于:所述算法重构模块中至少包括以下一个单元:
    运算顺序单元,用于根据所述密钥参数确定所述重构后的第一算法的运算顺序;
    分组单元,用于根据所述密钥参数确定所述重构后的第一算法的分组数据块的结构以及所述分组数据块的运算顺序;
    固定参数确定单元,用于根据所述密钥参数确定所述重构后的第一算法中的固定参数。
  3. 如权利要求1或2所述算法重构装置,其特征在于:所述装置还包括信息获取模块,与所述随机数生成模块连接,用于获取所述用户信息。
  4. 如权利要求3所述算法重构装置,其特征在于:所述装置还包括存储模块,用于存储所述第一算法,所述预设重构机制以及与所述用户信息唯一关联的密钥参数。
  5. 如权利要求4所述算法重构装置,其特征在于:所述装置还包括下发模块,分别与所述信息获取模块和所述存储模块连接,用于根据所述用户信息下发所述第一算法。
  6. 一种算法重构方法,其特征在于,所述方法至少包括以下步骤:
    根据用户信息生成一随机数,所述随机数被设定为一密钥参数;
    根据所述密钥参数,通过一预设重构机制重构第一算法。
  7. 如权利要求6所述算法重构方法,其特征在于,通过一预设重构机制重构第一算法至少包括以下一个步骤:
    根据所述密钥参数,确定重构后的第一算法的运算顺序;
    根据所述密钥参数,确定重构后的第一算法的分组数据块的结构以及所述分组数据块的运算顺序;
    根据所述密钥参数,确定重构后的第一算法中的固定参数。
  8. 如权利要求6或7所述算法重构方法,其特征在于,所述方法还包括:
    根据用户信息下发所述第一算法。
  9. 如权利要求8所述算法重构方法,其特征在于,所述算法重构方法重构所述第一算法之前,至少还包括以下步骤:
    预存所述第一算法,所述预设重构机制以及与所述用户信息唯一关联的密钥参数。
PCT/CN2015/076944 2014-12-03 2015-04-20 一种算法重构装置及方法 WO2016086572A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201410727339.1A CN104393991B (zh) 2014-12-03 2014-12-03 一种算法重构装置及方法
CN201410727339.1 2014-12-03

Publications (1)

Publication Number Publication Date
WO2016086572A1 true WO2016086572A1 (zh) 2016-06-09

Family

ID=52611827

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2015/076944 WO2016086572A1 (zh) 2014-12-03 2015-04-20 一种算法重构装置及方法

Country Status (2)

Country Link
CN (1) CN104393991B (zh)
WO (1) WO2016086572A1 (zh)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104393991B (zh) * 2014-12-03 2018-02-23 上海众人网络安全技术有限公司 一种算法重构装置及方法

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101459510A (zh) * 2007-12-14 2009-06-17 华为技术有限公司 实时传输数据的加密算法的实现方法及装置
CN102404123A (zh) * 2012-01-04 2012-04-04 王勇 一种基于算法变换思想的加密方法
CN104079413A (zh) * 2014-07-14 2014-10-01 上海众人科技有限公司 增强型一次性动态口令的认证方法及系统
CN104393991A (zh) * 2014-12-03 2015-03-04 上海众人科技有限公司 一种算法重构装置及方法

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6226383B1 (en) * 1996-04-17 2001-05-01 Integrity Sciences, Inc. Cryptographic methods for remote authentication

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101459510A (zh) * 2007-12-14 2009-06-17 华为技术有限公司 实时传输数据的加密算法的实现方法及装置
CN102404123A (zh) * 2012-01-04 2012-04-04 王勇 一种基于算法变换思想的加密方法
CN104079413A (zh) * 2014-07-14 2014-10-01 上海众人科技有限公司 增强型一次性动态口令的认证方法及系统
CN104393991A (zh) * 2014-12-03 2015-03-04 上海众人科技有限公司 一种算法重构装置及方法

Also Published As

Publication number Publication date
CN104393991B (zh) 2018-02-23
CN104393991A (zh) 2015-03-04

Similar Documents

Publication Publication Date Title
CN109150835B (zh) 云端数据存取的方法、装置、设备及计算机可读存储介质
WO2018046009A1 (zh) 一种区块链身份系统
CN104639516B (zh) 身份认证方法、设备及系统
US8984295B2 (en) Secure access to electronic devices
US9467430B2 (en) Device, method, and system for secure trust anchor provisioning and protection using tamper-resistant hardware
TWI715537B (zh) 基於雲環境的加密機金鑰注入系統、方法及裝置
US10659226B2 (en) Data encryption method, decryption method, apparatus, and system
TW201914256A (zh) 一種身份驗證方法、裝置及電子設備
CN109714176B (zh) 口令认证方法、装置及存储介质
CN108259171B (zh) Shader文件的保护方法及装置
CN110099048B (zh) 一种云存储方法及设备
CN103701919A (zh) 远程登录方法与系统
CN103124269A (zh) 云环境下基于动态口令与生物特征的双向身份认证方法
WO2012024872A1 (zh) 移动互联网加密通讯的方法、系统及相关装置
CN104468099A (zh) 基于cpk的动态口令生成和验证方法及装置
WO2016188053A1 (zh) 一种无线网络接入方法、装置及计算机存储介质
CN106789032A (zh) 服务器与移动设备间秘密共享的单一口令三方认证方法
CN111163164B (zh) 一种基于鲲鹏芯片的云桌面安全传输方法及装置
CN108600152A (zh) 基于量子通信网络的改进型Kerberos身份认证系统和方法
Shaju et al. BISC authentication algorithm: An efficient new authentication algorithm using three factor authentication for mobile banking
CN104410498B (zh) 一种动态口令认证方法及其系统
WO2016086572A1 (zh) 一种算法重构装置及方法
Sung et al. User authentication using mobile phones for mobile payment
CN113826096A (zh) 利用用户生物特征识别数据的用户认证及签名装置和方法
CN113904830B (zh) 一种spa认证的方法、装置、电子设备和可读存储介质

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 15865476

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 15865476

Country of ref document: EP

Kind code of ref document: A1