Examination data integrity storage method and system based on asymmetric encryption
By using asymmetric encryption technology in the online examination system, the keys are randomly allocated and the answer sheet content is encrypted and decrypted between the candidate's browser and the server, the problem of online examination data being damaged under the situation of network fluctuations and high pressure on the server is solved, and the reliability and user experience of the examination data are improved.
Patent Information
- Application Number
- CN202411547883.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-01
- Publication Date
- 2025-03-07
AI Technical Summary
In the case of network fluctuations and high pressure on the server, the online examination system can easily lead to the damage to the integrity of the examination data, resulting in unreal scores and a decline in user experience.
Asymmetric encryption is used to randomly allocate asymmetric keys to each candidate and exam sessions, and the candidate stores the public keys in the browser and the server stores the private keys. During the exam, candidates will encrypt the answer sheet in the browser's offline cache through public key, and send it to the server regularly when the network is stable. The server will decrypt and store it using the private key.
It significantly improves the data integrity and reliability of the browser-side examination service, reduces dependence on network stability and server-side availability, and thus optimizes the examination experience.
Smart Images

Figure CN119583048A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of data preservation, and in particular to a method for preserving the integrity of test data based on asymmetric encryption and a system for preserving the integrity of test data based on asymmetric encryption. Background Art
[0002] The booming development of online education has brought unprecedented convenience and flexibility to learning. At the same time, browser-based online examination services have also been widely used as an effective means to reflect teaching effectiveness. Examinations are not only a key link in evaluating students' learning outcomes, but also an important means to maintain educational fairness and improve educational quality.
[0003] However, the browser environment that online exams rely on has many uncertainties, the most common of which are: fluctuations in the examinee's network, excessive pressure on the browser service, etc. Once these negative factors are encountered in the real environment, the most direct consequence is that the data integrity of the exam system is destroyed. For example, the answer sheet data of some examinees during the period of disconnection from the network cannot be sent to the server and is lost, etc. As a result, the exam results cannot truly reflect the examinee's learning situation, the user experience of the browser exam system is reduced, and it is no longer trusted by users.
[0004] In most examination systems, timed executors are usually used to ensure the integrity of examination data. However, in some negative scenarios, such as when some candidates participating in the examination are disconnected from the Internet for a long time and cannot connect to the server, or when the examination server encounters an unknown failure and cannot be restored in a short time, this solution cannot work because it relies on the connectivity between the browser and the server and the stability of the server. Summary of the invention
[0005] In order to solve the above technical problems, the present invention provides a method and system for preserving the integrity of examination data based on asymmetric encryption, which can significantly improve the reliability of browser-side examination services in terms of data integrity, reduce dependence on network stability and server availability, and thus optimize the examination experience.
[0006] The technical solution adopted by the present invention is as follows:
[0007] A method for preserving the integrity of examination data based on asymmetric encryption, comprising the following steps: randomly allocating an asymmetric key according to examinees and examination sessions, the asymmetric key comprising private key information and public key information, the public key information being stored in the examinee's browser, and the private key information being stored in the examination server; obtaining the time difference between the examinee's browser time and the examination server time, and returning the examination deadline to the examination server; encrypting the answer sheet content and saving it in the examinee's browser offline cache data through the public key information, and adding the examinee's browser timestamp and offline answer sheet flag; regularly sending the answer sheet content in the examinee's browser offline cache data to the examination server; decrypting the answer sheet content through the private key information, and adding the decrypted answer sheet content to the online cache data of the examination server; when the examinee's browser timestamp plus the time difference reaches the examination deadline, stopping encrypting and saving the answer sheet content in the examinee's browser offline cache data, and stopping the examination.
[0008] A method for preserving the integrity of examination data based on asymmetric encryption, further comprising: when a candidate enters the examination time, starting the offline time compliance monitoring of the candidate's browser and assigning a starting timestamp; regularly monitoring the time difference between the current timestamp of the candidate's browser and the last recorded timestamp; judging whether the time difference meets a preset interval step; if not, stopping encrypting and preserving the answer sheet content of the current candidate's browser.
[0009] A method for preserving the integrity of test data based on asymmetric encryption, further comprising: if the examinee's browser unexpectedly exits the test, when entering the examinee's browser again, the answer sheet content is automatically loaded and matched from the examinee's browser offline cache data or the test server's online cache data.
[0010] In one embodiment of the present invention, the decrypting of the answer sheet content by the private key information and adding the decrypted answer sheet content to the online cache data of the examination server specifically includes: after receiving the answer sheet content, the examination server decrypts the answer sheet content by the private key information; after decrypting the answer sheet content into plain text, the candidate, examination session and answer sheet update timestamp of the answer sheet content are verified; when the candidate and examination session match successfully and the answer sheet update timestamp plus the time difference matches the examination time, the answer sheet content is sent to the online cache data of the examination server; after the answer sheet content is successfully sent to the online cache data of the examination server, the online cache data and the candidate's browser offline cache data are cleared.
[0011] In one embodiment of the present invention, the encrypting and saving the answer sheet content through the public key information to the offline cache data of the examinee's browser specifically includes: obtaining the public key information assigned to the current examination; the examinee's browser monitors the real-time answer sheet operations performed by the examinee by monitoring events; when the examinee marks questions, selects answers and enters answers, the examinee's browser encrypts the current answer sheet content, the current examinee's browser timestamp, the offline answer sheet identifier, the examination session and the examinee to which it belongs using the public key information and saves them in the examinee's offline cache data.
[0012] A system for preserving the integrity of test data based on asymmetric encryption, comprising: a key distribution module, the key distribution module is used to randomly distribute asymmetric keys according to candidates and test sessions, the asymmetric keys include private key information and public key information, the public key information is stored in the candidate's browser, and the private key information is stored in the test server; a time acquisition module, the time acquisition module is used to obtain the time difference between the candidate's browser time and the test server time, and return the test deadline to the test server; an offline cache module, the offline cache module is used to encrypt the answer sheet content through the public key information and save it in the candidate's browser offline cache data , and add the examinee's browser timestamp and offline answer sheet mark; a data sending module, the data sending module is used to send the answer sheet content in the examinee's browser offline cache data to the examination server at a regular interval; an online cache module, the online cache module is used to decrypt the answer sheet content through the private key information, and add the decrypted answer sheet content to the online cache data of the examination server; a stop cache module, the stop cache module is used to stop encrypting and saving the answer sheet content to the examinee's browser offline cache data when the examinee's browser timestamp plus the time difference reaches the examination deadline, and stop the examination.
[0013] A system for preserving the integrity of examination data based on asymmetric encryption also includes a judgment module, which is specifically used to: when a candidate enters the examination time, start the offline time compliance monitoring of the candidate's browser and assign a starting timestamp; regularly monitor the time difference between the current timestamp of the candidate's browser and the last recorded timestamp; judge whether the time difference meets the preset interval step; if not, stop encrypting and saving the answer sheet content of the current candidate's browser.
[0014] A system for preserving the integrity of test data based on asymmetric encryption also includes an automatic matching module. The automatic matching module is used to automatically load and match the answer sheet content from the offline cache data of the candidate's browser or the online cache data of the test server when the candidate enters the browser if the candidate's browser exits the test unexpectedly.
[0015] In one embodiment of the present invention, the online cache module is also used for: after receiving the answer paper content, the examination server decrypts the answer paper content through the private key information; after decrypting the answer paper content into plain text, verifying the candidate, examination session and answer paper update timestamp to which the answer paper content belongs; when the candidate and examination session match successfully and the answer paper update timestamp plus the time difference matches the examination time, sending the answer paper content to the online cache data of the examination server; after the answer paper content is successfully sent to the online cache data of the examination server, clearing the online cache data and the candidate's browser offline cache data.
[0016] In one embodiment of the present invention, the offline cache module is also used to: obtain the public key information assigned to the current examination; the examinee's browser monitors the real-time answer operations performed by the examinee by monitoring events; when the examinee marks questions, selects answers and enters answers, the examinee's browser encrypts the current answer content, the current examinee browser timestamp, the offline answer identification, the examination session and the examinee to which it belongs using the public key information and saves them in the examinee's browser offline cache data.
[0017] Beneficial effects of the present invention:
[0018] The present invention randomly assigns asymmetric keys to examinees and examination sessions, then obtains the time difference between the examinee's browser time and the examination server time, encrypts the answer sheet content and saves it in the examinee's browser offline cache data through public key information, then sends the answer sheet content in the examinee's browser offline cache data to the examination server at regular intervals, decrypts the answer sheet content through private key information, and adds the decrypted answer sheet content to the online cache data of the examination server. When the examinee's browser timestamp plus the time difference reaches the examination deadline, the encryption and saving of the answer sheet content in the examinee's browser offline cache data is stopped, and the examination is stopped. As a result, the reliability of the browser-side examination service in terms of data integrity can be significantly improved, and the dependence on network stability and server availability can be reduced, thereby optimizing the examination experience. BRIEF DESCRIPTION OF THE DRAWINGS
[0019] Figure 1A flowchart of a method for preserving test data integrity based on asymmetric encryption according to an embodiment of the present invention;
[0020] Figure 2 The present invention is a block diagram of a system for preserving test data integrity based on asymmetric encryption according to an embodiment of the present invention. DETAILED DESCRIPTION
[0021] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0022] Figure 1 The present invention is a flowchart of a method for preserving the integrity of test data based on asymmetric encryption according to an embodiment of the present invention.
[0023] like Figure 1 As shown, the method for preserving the integrity of test data based on asymmetric encryption according to an embodiment of the present invention comprises the following steps:
[0024] S1, randomly assign asymmetric keys according to candidates and test sessions. Asymmetric keys include private key information and public key information. The public key information is stored in the candidate's browser, and the private key information is stored on the test server.
[0025] In one embodiment of the present invention, the generation of asymmetric keys can be realized on the test server. Each time the asymmetric key is called, a secure random number generated with the test session and the examinee as the random number seed can be passed in, so that the key is dynamically and randomly generated, and there is no duplicate key. When the examinee enters the test, the examinee plus the test session can be used as the minimum dimension to generate and obtain an asymmetric key, wherein the asymmetric key can include public key information and private key information, the public key information can be stored on the test server, and the private key information can be returned to the examinee's browser along with the test content, so that the examinee's browser can encrypt the examinee's answer sheet content.
[0026] S2, obtains the time difference between the examinee's browser time and the test server time, and returns the test deadline to the test server.
[0027] In one embodiment of the present invention, when a candidate enters the examination, the current timestamp information of the candidate's browser can be obtained from the candidate's browser and transmitted to the examination server, and compared with the timestamp information of the examination server to obtain the time offset of the current examination session.
[0028] In one embodiment of the present invention, when a candidate enters the test, the offline time compliance monitoring of the candidate's browser can be started and a starting timestamp can be assigned, wherein the offline time compliance monitoring of the candidate's browser can be run on the candidate's browser side and continuously run during the test time until the end of the test. Then, the time difference between the current timestamp of the candidate's browser and the last recorded timestamp can be regularly monitored, and it can be determined whether the time difference meets the preset interval step. If not, the candidate can be prompted that there is an act of tampering with the candidate's browser time and the test can be stopped.
[0029] Specifically, the compliance monitoring of the candidate's browser offline time can combine the candidate's browser time and the time difference to make a judgment, that is, the compliance monitoring of the candidate's browser offline time can obtain the revised examination deadline of the candidate's browser based on the examination deadline set by the server plus the time difference of the candidate's browser, and compare the revised examination deadline with the candidate's browser time. If the candidate's browser time exceeds the examination deadline, the end of the examination can be prompted.
[0030] It is understandable that time judgment generally needs to support a certain degree of deviation, such as 30 seconds to 60 seconds, to enhance the compatibility of the candidate's browser offline time compliance monitoring. At the same time, since the test server can no longer send a notification to the candidate's browser to stop the test in an offline environment, it is also necessary to use the candidate's browser offline time compliance monitoring to control it.
[0031] S3, encrypts the answer sheet content through the public key information and saves it in the candidate's browser offline cache data, and adds the candidate's browser timestamp and offline answer sheet mark.
[0032] Specifically, first, when the examinee enters the exam, the public key information assigned to the current exam is obtained. Then, when the examinee takes the exam through the examinee's browser, the examinee's browser can monitor the examinee's real-time answer sheet operations through monitoring events. When the examinee marks questions, selects answers, and enters answers, the examinee's browser can encrypt the current answer sheet content, the current examinee's browser timestamp, the offline answer sheet identifier, the exam session, and the examinee to whom it belongs with the public key information and save them in the examinee's browser offline cache data.
[0033] In one embodiment of the present invention, if the examinee's browser accidentally exits the test, when the examinee enters the examinee's browser here, the answer sheet content and the examinee's answer information can be automatically loaded and matched from the examinee's browser offline cache data, so that the examinee's answer sheet content will not be lost. Among them, accidents that occur in the examinee's browser include computer freezes, blue screens, network freezes, and test server freezes.
[0034] S4, sending the answer sheet content in the offline cache data of the examinee's browser to the examination server at regular intervals.
[0035] In one embodiment of the present invention, after the examinee enters the examination, the examinee's browser can use the timed execution mechanism to start scheduled network dynamic monitoring. The scheduled network dynamic monitoring can send data packets to the examination server at regular intervals to obtain the network connection status. If a network abnormality is found, the user can be reminded to check the network in time.
[0036] S5, decrypt the answer sheet content using the private key information, and add the decrypted answer sheet content to the online cache data of the test server.
[0037] Specifically, first, after receiving the answer sheet content, the test server can obtain the private key information of the current test session and candidate information, and decrypt the answer sheet content through the private key information. Then, after decrypting the answer sheet content into plain text, the candidate to whom the answer sheet content belongs, the test session, and the answer sheet update timestamp can be further verified. Only when the candidate and the test session match successfully, and the answer sheet update timestamp plus the time difference matches the test time, can the answer sheet content be sent to the online cache data of the test server. Finally, after the answer sheet content is successfully sent to the online cache data of the test server, the online cache data and the candidate's browser offline cache data can be cleared.
[0038] S6: When the timestamp of the examinee's browser plus the time difference reaches the test deadline, the encryption and storage of the answer sheet content into the examinee's browser offline cache data will stop, and the test will be stopped.
[0039] In one embodiment of the present invention, if the answer sheet content of the examinee fails to be successfully submitted to the examination server, at this time, the answer sheet content cached offline will exist in the cache data of the examinee's browser. The examinee's browser can perform a global offline cache detection. If the answer sheet content cached offline is found, it can be sent to the examination server at a fixed time. After receiving the answer sheet content, the examination server will decrypt the answer sheet through the private key information to verify whether the answer sheet content has been tampered with. After decrypting and obtaining the plain text, the examinee, the examination session and the answer sheet update timestamp of the answer sheet content can be further verified. Only when the examinee and the examination session are successfully matched and the answer sheet update timestamp plus the time difference matches the examination time, can the answer sheet content be sent to the online cache data of the examination server. If the decryption or verification fails, the offline cache data of the examinee's browser is deleted.
[0040] In another embodiment of the present invention, before the answer sheet content is sent to the online cache data of the examination server, it is necessary to verify whether the current examination session and the examinee already have successfully submitted answer sheet content. If so, there is no need to submit the answer sheet content here, and the offline cache data of the examinee's browser must be deleted.
[0041] According to the method for preserving the integrity of examination data based on asymmetric encryption in an embodiment of the present invention, asymmetric keys are randomly assigned to examinees and examination sessions, and then the time difference between the examinee's browser time and the examination server time is obtained. After the answer sheet content is encrypted and saved in the examinee's browser offline cache data through public key information, the answer sheet content in the examinee's browser offline cache data is sent to the examination server at a regular interval, and the answer sheet content is decrypted through private key information, and the decrypted answer sheet content is added to the online cache data of the examination server. When the examinee's browser timestamp plus the time difference reaches the examination deadline, the encryption and saving of the answer sheet content in the examinee's browser offline cache data is stopped, and the examination is stopped. As a result, the reliability of the browser-side examination service in terms of data integrity can be significantly improved, and the dependence on network stability and server availability can be reduced, thereby optimizing the examination experience.
[0042] In order to implement the method for preserving the integrity of test data based on asymmetric encryption in the above-mentioned embodiment, the present invention also proposes a system for preserving the integrity of test data based on asymmetric encryption.
[0043] like Figure 2 As shown, the preservation system of test data integrity based on asymmetric encryption according to the embodiment of the present invention includes: a key distribution module 100, a time acquisition module 200, an offline cache module 300, a data sending module 400, an online cache module 500 and a stop cache module 600, wherein the key distribution module 100 is used to randomly distribute asymmetric keys according to candidates and test sessions, and the asymmetric keys include private key information and public key information, the public key information is stored in the candidate's browser, and the private key information is stored in the test server; the time acquisition module 200 is used to obtain the time difference between the candidate's browser time and the test server time, and return the test deadline to the test server; The online cache module 300 is used to encrypt the answer sheet content through the public key information and save it in the offline cache data of the candidate's browser, and add the candidate's browser timestamp and offline answer sheet flag; the data sending module 400 is used to send the answer sheet content in the offline cache data of the candidate's browser to the examination server at a regular interval; the online cache module 500 is used to decrypt the answer sheet content through the private key information, and add the decrypted answer sheet content to the online cache data of the examination server; the stop cache module 600 is used to stop encrypting and saving the answer sheet content in the offline cache data of the candidate's browser and stop the examination when the candidate's browser timestamp plus the time difference reaches the examination deadline.
[0044] In one embodiment of the present invention, the key distribution module 100 can realize the generation of asymmetric keys on the test server. Each time the asymmetric key is called, a secure random number generated with the test session and the examinee as the random number seed can be passed in, so that the key is dynamically and randomly generated, and there is no duplicate key. When the examinee enters the test, the examinee plus the test session can be used as the minimum dimension to generate and obtain an asymmetric key, wherein the asymmetric key may include public key information and private key information, the public key information can be stored on the test server, and the private key information can be returned to the examinee's browser along with the test content, so that the examinee's browser can encrypt the examinee's answer sheet content.
[0045] In one embodiment of the present invention, when a candidate enters the examination, the current timestamp information of the candidate's browser can be obtained from the candidate's browser according to the time acquisition module 200 and transmitted to the examination server, and compared with the timestamp information of the examination server to obtain the time offset of the current examination session.
[0046] In one embodiment of the present invention, the preservation system of the integrity of the test data based on asymmetric encryption may also include a judgment module 700, which may be specifically used to: start the offline time compliance monitoring of the examinee's browser when the examinee enters the test, and assign a starting timestamp, wherein the offline time compliance monitoring of the examinee's browser may be run on the examinee's browser side, and continue to run during the test time until the end of the test. Then, the time difference between the current timestamp of the examinee's browser and the last recorded timestamp is regularly monitored, and it is judged whether the time difference meets the preset interval step. If not, the examinee may be prompted that there is an act of tampering with the examinee's browser time and the test is stopped.
[0047] Specifically, the compliance monitoring of the candidate's browser offline time can combine the candidate's browser time and the time difference to make a judgment, that is, the compliance monitoring of the candidate's browser offline time can obtain the revised examination deadline of the candidate's browser based on the examination deadline set by the server plus the time difference of the candidate's browser, and compare the revised examination deadline with the candidate's browser time. If the candidate's browser time exceeds the examination deadline, the end of the examination can be prompted.
[0048] It is understandable that time judgment generally needs to support a certain degree of deviation, such as 30 seconds to 60 seconds, to enhance the compatibility of the candidate's browser offline time compliance monitoring. At the same time, since the test server can no longer send a notification to the candidate's browser to stop the test in an offline environment, it is also necessary to use the candidate's browser offline time compliance monitoring to control it.
[0049] In one embodiment of the present invention, the offline cache module 300 can also be used to obtain the public key information assigned to the current test session when the examinee enters the test. Then, when the examinee takes the test through the examinee's browser, the examinee's browser can monitor the examinee's real-time answer sheet operations through monitoring events. When the examinee marks questions, selects answers, and enters answers, the examinee's browser can encrypt the current answer sheet content, the current examinee's browser timestamp, the offline answer sheet identifier, the test session, and the examinee's public key information and save them in the examinee's browser offline cache data.
[0050] In one embodiment of the present invention, if the examinee's browser accidentally exits the test, when the examinee enters the examinee's browser here, the answer sheet content and the examinee's answer information can be automatically loaded and matched from the examinee's browser offline cache data, so that the examinee's answer sheet content will not be lost. Among them, accidents that occur in the examinee's browser include computer freezes, blue screens, network freezes, and test server freezes.
[0051] In one embodiment of the present invention, after the examinee enters the examination, the data sending module 400 can use the timed execution mechanism to start the scheduled network dynamic monitoring. The scheduled network dynamic monitoring can send data packets to the examination server at regular intervals to obtain the network connection status. If a network abnormality is found, the user can be reminded to check the network in time.
[0052] In one embodiment of the present invention, the online cache module 500 can also be used for: after receiving the answer sheet content, the test server can obtain the private key information of the current test session and the candidate information, and decrypt the answer sheet content through the private key information. Then, after decrypting the answer sheet content into plain text, the candidate to whom the answer sheet content belongs, the test session and the answer sheet update timestamp can be further verified. Only when the candidate to whom the answer sheet content belongs matches the test session successfully and the answer sheet update timestamp plus the time difference matches the test time, can the answer sheet content be sent to the online cache data of the test server. Finally, after the answer sheet content is successfully sent to the online cache data of the test server, the online cache data and the candidate's browser offline cache data can be cleared.
[0053] In one embodiment of the present invention, if the answer sheet content of the examinee fails to be successfully submitted to the examination server, at this time, the answer sheet content cached offline will exist in the cache data of the examinee's browser. The examinee's browser can perform a global offline cache detection. If the answer sheet content cached offline is found, it can be sent to the examination server at a fixed time. After receiving the answer sheet content, the examination server will decrypt the answer sheet through the private key information to verify whether the answer sheet content has been tampered with. After decrypting and obtaining the plain text, the examinee, the examination session and the answer sheet update timestamp of the answer sheet content can be further verified. Only when the examinee and the examination session are successfully matched and the answer sheet update timestamp plus the time difference matches the examination time, can the answer sheet content be sent to the online cache data of the examination server. If the decryption or verification fails, the offline cache data of the examinee's browser is deleted.
[0054] In another embodiment of the present invention, before the answer sheet content is sent to the online cache data of the examination server, it is necessary to verify whether the current examination session and the examinee already have successfully submitted answer sheet content. If so, there is no need to submit the answer sheet content here, and the offline cache data of the examinee's browser must be deleted.
[0055] In summary, the embodiment of the present invention randomly allocates asymmetric keys to candidates and examination sessions through a key distribution module, and then obtains the time difference between the candidate's browser time and the examination server time through a time acquisition module, encrypts the answer sheet content and saves it in the candidate's browser offline cache data through an offline cache module, and sends the answer sheet content in the candidate's browser offline cache data to the examination server at a regular interval through a data sending module, and decrypts the answer sheet content through an online cache module, and adds the decrypted answer sheet content to the online cache data of the examination server. When the candidate's browser timestamp plus the time difference reaches the examination deadline, the caching module stops encrypting and saving the answer sheet content in the candidate's browser offline cache data, and stops the examination. As a result, the reliability of the browser-side examination service in terms of data integrity can be significantly improved, and the dependence on network stability and server availability can be reduced, thereby optimizing the examination experience.
[0056] In the description of the present invention, the terms "first" and "second" are used for descriptive purposes only and should not be understood as indicating or implying relative importance or implicitly indicating the number of the indicated technical features. Therefore, the features defined as "first" and "second" may explicitly or implicitly include one or more of the features. "Multiple" means two or more, unless otherwise clearly and specifically defined.
[0057] In the present invention, unless otherwise clearly specified and limited, the terms "installed", "connected", "connected", "fixed" and the like should be understood in a broad sense, for example, it can be a fixed connection, a detachable connection, or an integral connection; it can be a mechanical connection or an electrical connection; it can be a direct connection or an indirect connection through an intermediate medium, it can be the internal connection of two elements or the interaction relationship between two elements. For ordinary technicians in this field, the specific meanings of the above terms in the present invention can be understood according to specific circumstances.
[0058] In the present invention, unless otherwise clearly specified and limited, a first feature being "above" or "below" a second feature may mean that the first and second features are in direct contact, or the first and second features are in indirect contact through an intermediate medium. Moreover, a first feature being "above", "above" or "above" a second feature may mean that the first feature is directly above or obliquely above the second feature, or simply means that the first feature is higher in level than the second feature. A first feature being "below", "below" or "below" a second feature may mean that the first feature is directly below or obliquely below the second feature, or simply means that the first feature is lower in level than the second feature.
[0059] In the description of this specification, the description with reference to the terms "one embodiment", "some embodiments", "example", "specific example", or "some examples" etc. means that the specific features, structures, materials or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present invention. In this specification, the schematic representations of the above terms do not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials or characteristics described may be combined in any one or more embodiments or examples in a suitable manner. In addition, those skilled in the art may combine and combine the different embodiments or examples described in this specification and the features of the different embodiments or examples, unless they are contradictory.
[0060] Any process or method description in a flowchart or otherwise described herein may be understood to represent a module, segment or portion of code that includes one or more executable instructions for implementing the steps of a specific logical function or process, and the scope of the preferred embodiments of the present invention includes alternative implementations in which functions may not be performed in the order shown or discussed, including performing functions in a substantially simultaneous manner or in the reverse order depending on the functions involved, which should be understood by those skilled in the art to which the embodiments of the present invention belong.
[0061] The logic and / or steps represented in the flowchart or otherwise described herein, for example, can be considered as an ordered list of executable instructions for implementing logical functions, and can be embodied in any computer-readable medium for use by an instruction execution system, device or apparatus (such as a computer-based system, a system including a processor, or other system that can fetch instructions from an instruction execution system, device or apparatus and execute instructions), or in combination with these instruction execution systems, devices or apparatuses. For the purposes of this specification, a "computer-readable medium" can be any device that can contain, store, communicate, propagate or transmit a program for use by an instruction execution system, device or apparatus, or in combination with these instruction execution systems, devices or apparatuses. More specific examples of computer-readable media (a non-exhaustive list) include the following: an electrical connection with one or more wires (electronic devices), a portable computer disk box (magnetic device), a random access memory (RAM), a read-only memory (ROM), an erasable and programmable read-only memory (EPROM or flash memory), a fiber optic device, and a portable compact disk read-only memory (CDROM). In addition, the computer-readable medium may even be paper or other suitable medium on which the program is printed, since the program may be obtained electronically, for example, by optically scanning the paper or other medium and then editing, interpreting or processing in other suitable ways if necessary, and then stored in a computer memory.
[0062] It should be understood that the various parts of the present invention can be implemented by hardware, software, firmware or a combination thereof. In the above-mentioned embodiments, a plurality of steps or methods can be implemented by software or firmware stored in a memory and executed by a suitable instruction execution system. For example, if implemented by hardware, as in another embodiment, it can be implemented by any one of the following technologies known in the art or their combination: a discrete logic circuit having a logic gate circuit for implementing a logic function for a data signal, a dedicated integrated circuit having a suitable combination of logic gate circuits, a programmable gate array (PGA), a field programmable gate array (FPGA), etc.
[0063] A person skilled in the art may understand that all or part of the steps in the method for implementing the above-mentioned embodiment may be completed by instructing related hardware through a program, and the program may be stored in a computer-readable storage medium, which, when executed, includes one or a combination of the steps of the method embodiment.
[0064] In addition, each functional unit in each embodiment of the present invention may be integrated into a processing module, or each unit may exist physically separately, or two or more units may be integrated into one module. The above-mentioned integrated module may be implemented in the form of hardware or in the form of a software functional module. If the integrated module is implemented in the form of a software functional module and sold or used as an independent product, it may also be stored in a computer-readable storage medium.
[0065] Although the embodiments of the present invention have been shown and described above, it is to be understood that the above embodiments are exemplary and are not to be construed as limitations of the present invention. A person skilled in the art may change, modify, replace and vary the above embodiments within the scope of the present invention.
Claims
1. A method for preserving the integrity of test data based on asymmetric encryption, characterized in that: The following steps are involved: Randomly assign an asymmetric key based on the examinee and the test session. The asymmetric key includes private key information and public key information. The public key information is stored in the examinee's browser, and the private key information is stored on the test server. Obtain the time difference between the examinee's browser time and the test server time, and return the test deadline to the test server; The answer sheet content is encrypted and saved in the candidate's browser offline cache data through the public key information, and the candidate's browser timestamp and offline answer sheet mark are added; Sending the answer sheet content in the offline cache data of the examinee's browser to the examination service end at a regular interval; Decrypting the answer sheet content by using the private key information, and adding the decrypted answer sheet content to the online cache data of the test server; When the timestamp of the examinee's browser plus the time difference reaches the test deadline, the encryption and storage of the answer sheet content into the offline cache data of the examinee's browser is stopped, and the test is stopped.
2. The method for preserving the integrity of test data based on asymmetric encryption according to claim 1, characterized in that: Also includes: When the examinee enters the examination time, start the examinee's browser offline time compliance monitoring and assign a starting timestamp; Regularly monitor the time difference between the current timestamp of the examinee's browser and the last recorded timestamp; Determining whether the time difference meets a preset interval step; If it does not meet the requirements, stop encrypting and saving the answer sheet content in the current candidate's browser.
3. The method for preserving the integrity of test data based on asymmetric encryption according to claim 2, characterized in that: Also includes: If the examinee's browser exits the test unexpectedly, when the examinee's browser is entered again, the answer sheet content is automatically loaded and matched from the examinee's browser's offline cache data or the test server's online cache data.
4. The method for preserving the integrity of test data based on asymmetric encryption according to claim 3, characterized in that: The decrypting of the answer sheet content by the private key information and adding the decrypted answer sheet content to the online cache data of the test server specifically includes: After receiving the answer sheet content, the test server decrypts the answer sheet content using the private key information; After decrypting the answer sheet content into plain text, verifying the examinee to whom the answer sheet content belongs, the examination session, and the answer sheet update timestamp; When the candidate and the examination session are successfully matched and the answer sheet update timestamp plus the time difference matches the examination time, the answer sheet content is sent to the online cache data of the examination server; After the answer sheet content is successfully sent to the online cache data of the examination server, the online cache data and the offline cache data of the examinee's browser are cleared.
5. The method for preserving the integrity of test data based on asymmetric encryption according to claim 3, characterized in that: The method of encrypting the answer sheet content and saving it to the candidate's browser offline cache data through the public key information specifically includes: Obtain the public key information assigned to this examination; The examinee's browser monitors the real-time answering operation performed by the examinee by monitoring events; When the examinee marks questions, selects answers and enters answers, the examinee's browser encrypts the current answer sheet content, the current examinee's browser timestamp, the offline answer sheet identifier, the test session and the examinee to which it belongs using the public key information and saves them in the examinee's browser offline cache data.
6. A system for preserving the integrity of test data based on asymmetric encryption, characterized in that: include: A key distribution module, which is used to randomly distribute asymmetric keys according to candidates and test sessions. The asymmetric keys include private key information and public key information. The public key information is stored in the candidate's browser, and the private key information is stored in the test server. A time acquisition module, which is used to obtain the time difference between the examinee's browser time and the test server time, and return the test deadline to the test server; An offline cache module, which is used to encrypt the answer sheet content through the public key information and save it to the candidate's browser offline cache data, and add the candidate's browser timestamp and offline answer sheet mark; A data sending module, the data sending module is used to send the answer sheet content in the offline cache data of the examinee's browser to the examination server at a regular time; An online cache module, the online cache module is used to decrypt the answer sheet content by using the private key information, and add the decrypted answer sheet content to the online cache data of the test server; The cache stop module is used to stop encrypting and saving the answer sheet content into the offline cache data of the examinee's browser and stop the examination when the timestamp of the examinee's browser plus the time difference reaches the examination deadline.
7. The test data integrity preservation system based on asymmetric encryption according to claim 6 is characterized in that: It also includes a judgment module, which is specifically used to: When the examinee enters the examination time, start the examinee's browser offline time compliance monitoring and assign a starting timestamp; Regularly monitor the time difference between the current timestamp of the examinee's browser and the last recorded timestamp; Determining whether the time difference meets a preset interval step; If it does not meet the requirements, stop encrypting and saving the answer sheet content in the current candidate's browser.
8. The test data integrity preservation system based on asymmetric encryption according to claim 7 is characterized in that: Also includes: The automatic matching module is used for automatically loading and matching the answer sheet content from the offline cache data of the candidate's browser or the online cache data of the test server when the candidate enters the browser again if the candidate's browser exits the test unexpectedly.
9. The test data integrity preservation system based on asymmetric encryption according to claim 8, characterized in that: The online cache module is also used for: After receiving the answer sheet content, the test server decrypts the answer sheet content using the private key information; After decrypting the answer sheet content into plain text, verifying the examinee to whom the answer sheet content belongs, the examination session, and the answer sheet update timestamp; When the candidate and the examination session are successfully matched and the answer sheet update timestamp plus the time difference matches the examination time, the answer sheet content is sent to the online cache data of the examination server; After the answer sheet content is successfully sent to the online cache data of the examination server, the online cache data and the offline cache data of the examinee's browser are cleared.
10. The test data integrity preservation system based on asymmetric encryption according to claim 9, characterized in that: The offline cache module is also used for: Obtain the public key information assigned to this examination; The examinee's browser monitors the real-time answering operation performed by the examinee by monitoring events; When the examinee marks questions, selects answers and enters answers, the examinee's browser encrypts the current answer sheet content, the current examinee's browser timestamp, the offline answer sheet identifier, the test session and the examinee to which it belongs using the public key information and saves them in the examinee's browser offline cache data.