WO2020093722A1 - 一种基于区块链的处方数据校验方法、设备及服务器 - Google Patents

一种基于区块链的处方数据校验方法、设备及服务器 Download PDF

Info

Publication number
WO2020093722A1
WO2020093722A1 PCT/CN2019/095055 CN2019095055W WO2020093722A1 WO 2020093722 A1 WO2020093722 A1 WO 2020093722A1 CN 2019095055 W CN2019095055 W CN 2019095055W WO 2020093722 A1 WO2020093722 A1 WO 2020093722A1
Authority
WO
WIPO (PCT)
Prior art keywords
prescription data
block
prescription
data block
target patient
Prior art date
Application number
PCT/CN2019/095055
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 WO2020093722A1 publication Critical patent/WO2020093722A1/zh

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/60Protecting data
    • G06F21/64Protecting data integrity, e.g. using checksums, certificates or signatures

Definitions

  • This application relates to the field of computer technology, and in particular to a blockchain-based prescription data verification method, device, and server.
  • the diagnosis and treatment terminal collects the prescription data information of each patient in real time and uploads it to the server, so that medical staff, patients and other third-party users can query the prescription data information of each patient.
  • this method carries out data-related operations at all times, including data collection, data transmission, and data storage. Data is vulnerable to malicious attacks and illegal tampering operations at every link. Therefore, how to improve the security of data is very important.
  • Embodiments of the present application provide a prescription data verification method, device, and server based on a blockchain, which can improve the safety of prescription data.
  • an embodiment of the present application provides a blockchain-based prescription data verification method.
  • the method includes:
  • the prescription data includes any one or more of the name of the drug, the quantity of the drug, and the usage and dosage of the drug;
  • an embodiment of the present application provides a data verification device.
  • the data verification device includes a unit for performing the method of the first aspect.
  • an embodiment of the present application provides a server, including a processor, an input device, an output device, and a memory, where the processor, input device, output device, and memory are connected to each other, wherein the memory is used for storage support
  • the data verification device executes the computer program of the above method, the computer program includes program instructions, and the processor is configured to call the program instructions to perform the method of the first aspect.
  • an embodiment of the present application provides a computer-readable storage medium that stores a computer program, where the computer program includes program instructions, which when executed by a processor causes The processor executes the method of the first aspect described above.
  • the embodiment of the present application verifies the prescription data block of the target patient. If the verification fails, the prescription data acquisition request is rejected to avoid the occurrence of illegally tampered prescription data blocks.
  • the third party has improved the data security.
  • FIG. 1 is a schematic flowchart of a blockchain-based prescription data verification method provided by an embodiment of the present application
  • FIG. 2 is a schematic flowchart of another blockchain-based prescription data verification method provided by an embodiment of the present application.
  • FIG. 3 is a schematic flowchart of another blockchain-based prescription data verification method provided by an embodiment of the present application.
  • FIG. 4 is a schematic block diagram of a data verification device provided by an embodiment of the present application.
  • FIG. 5 is a schematic block diagram of a server provided by an embodiment of the present application.
  • the blockchain-based prescription data verification method provided by the embodiments of the present application may be performed by a data verification system, which includes a data verification device and a diagnosis and treatment terminal.
  • the The data verification device can be set on servers such as mobile phones, computers, tablets, and smart watches.
  • a communication connection may be established between the data verification device and the diagnosis and treatment terminal for two-way communication.
  • the data verification device may be installed on a server, and in some embodiments, the data verification device may be spatially independent of the server.
  • the diagnosis and treatment terminal may include a smart terminal such as a mobile phone, a computer, a tablet, and a smart watch.
  • the diagnosis and treatment terminal may send the collected prescription data blocks of each patient to the server, and after acquiring the prescription data blocks of each patient sent by the diagnosis and treatment terminal, the server may The patient's prescription data block generates a prescription data block chain, wherein the prescription data block is generated by the diagnosis and treatment terminal according to each patient's prescription data, and the prescription data includes the drug name, the number of drugs, and the usage and usage Any one or more of them.
  • the server can verify the data blocks of each party corresponding to the target patient in the prescription data blockchain, if the school If the verification fails, it is determined that there is a prescription data block in which prescription data has been illegally tampered in the data block of each party corresponding to the target patient in the prescription data blockchain, and the third party's prescription data acquisition request is rejected.
  • the server may determine the target prescription data block illegally tampered in the data blocks of various parties corresponding to the target patient, and send prompt information to the third party, where the prompt information is used to prompt the target prescription data area
  • the prescription data of the block has been tampered with illegally. In this way, illegally tampered prescription data can be avoided from being sent to third parties, and the security of the data is improved.
  • FIG. 1 is a schematic flowchart of a blockchain-based prescription data verification method provided by an embodiment of the present application. As shown in FIG. 1, the method may be performed by a data verification device.
  • the verification device is provided on the server, and the specific explanation of the data verification device is as described above, and will not be repeated here.
  • the method in the embodiment of the present application includes the following steps.
  • S101 Obtain the prescription data block of each patient sent by the diagnosis and treatment terminal, and generate a prescription data block chain according to the prescription data block of each patient.
  • the server may acquire the prescription data block of each patient sent by the diagnosis and treatment terminal, and generate a prescription data block chain according to the prescription data block of each patient.
  • the prescription data block is generated by the diagnosis and treatment terminal according to the prescription data of each patient, and the prescription data includes any one or more of the name of the drug, the number of drugs, and the usage and dosage of the drugs .
  • the prescription data block includes a patient identification and a block identification.
  • the server when the server generates a prescription data block chain based on each patient's prescription data block, the server can obtain the number of each patient's prescription data block, and according to the number of the prescription data block, the server The patients are sorted, and the prescription data block chain is generated according to the sorted prescription data blocks. For example, assuming that the server obtains the prescription data blocks of n patients sent by the diagnosis and treatment terminal, the server may sequentially sort the n patients according to the order of the number of data blocks of various parties, and according to The sorted n data blocks of each patient generate the prescription data blockchain. In this way, it is advantageous for the server to search for prescription data according to the number of data blocks of various parties corresponding to the patient identification of each patient, which improves the search efficiency of prescription data.
  • the prescription data acquisition request includes identity verification information
  • the server performs integrity on the prescription data blockchain after receiving a prescription data acquisition request sent by a third party for the prescription data of the target patient
  • the identity verification information may be acquired according to the prescription data acquisition request, where the identity verification information includes any one or more types of information in a password, fingerprint, and voice, and the identity verification information Match with the preset identity verification information, and if the match is successful, trigger the step of performing the integrity check on the prescription data blockchain.
  • the identity verification of the third party that sends the prescription data acquisition request can ensure the safety of the third party, avoid sending the prescription data to unauthorized illegal users, and further ensure the safety of the prescription data.
  • S102 When receiving a prescription data acquisition request sent by a third party for the prescription data of the target patient, verify each data block corresponding to the target patient in the prescription data blockchain.
  • the server when receiving a prescription data acquisition request sent by a third party for the prescription data of the target patient, the server may verify the data blocks of each party corresponding to the target patient in the prescription data blockchain .
  • the prescription data block includes a block hash code
  • the server may use the block hash code to compare data of various parties corresponding to the target patient in the prescription data blockchain Block verification.
  • the prescription data block includes a block hash code
  • the prescription data acquisition request carries encrypted information
  • the server may use the block hash code and the encrypted information according to the block hash code To verify the data blocks of all parties corresponding to the target patient in the prescription data blockchain.
  • the server fails to verify each data block corresponding to the target patient in the prescription data blockchain, it can determine the corresponding There is a prescription data block in which prescription data is illegally tampered in each prescription data block, and the third party's prescription data acquisition request is rejected.
  • S104 Determine the target prescription data block illegally tampered in the data blocks of various parties corresponding to the target patient, and send prompt information to the third party.
  • the server may determine the target patient after determining that there is a prescription data block in the prescription data block corresponding to the target patient in the data block of each party that has illegally tampered prescription data Corresponding target prescription data blocks in the data blocks of various parties that have been illegally tampered with, and sending prompt information to the third party, wherein the prompt information is used to prompt that the prescription data of the target prescription data blocks has been illegally tampered with .
  • the server may acquire the prescription data block of each patient sent by the diagnosis and treatment terminal, and generate a prescription data block chain according to the prescription data block of each patient, when receiving the prescription data sent by the third party to the target patient
  • each data block corresponding to the target patient in the prescription data blockchain is verified. If the verification fails, the target patient in the prescription data blockchain can be determined
  • Corresponding data blocks of various parties have prescription data blocks with illegally tampered prescription data, and reject the third-party prescription data acquisition request, and determine that the various data blocks corresponding to the target patient have been illegally tampered with Target the prescription data block and send prompt information to the third party. In this way, the illegally tampered prescription data block is prevented from being sent to the third party, and the data security is improved.
  • FIG. 2 is a schematic flowchart of another blockchain-based prescription data verification method provided by an embodiment of the present application. As shown in FIG. 2, the method may be performed by a data verification device. The specific explanation of the verification device is as described above, and will not be repeated here. The difference between the embodiment of the present application and the embodiment described in FIG. 1 above is that the embodiment of the present application is an implementation process of verifying various data blocks corresponding to the target patient in the prescription data blockchain Detailed explanation. Specifically, the method in the embodiment of the present application includes the following steps.
  • S201 Acquire the prescription data block of each patient sent by the diagnosis and treatment terminal, and generate a prescription data block chain according to the prescription data block of each patient.
  • the server may acquire the prescription data block of each patient sent by the diagnosis and treatment terminal, and generate a prescription data block chain according to the prescription data block of each patient.
  • the explanation of the prescription data block is as described above, and the explanation of the prescription data is as described above, which will not be repeated here.
  • S202 When receiving a prescription data acquisition request sent by a third party for the prescription data of the target patient, acquire a block hash code of various data blocks corresponding to the target patient in the prescription data blockchain.
  • the server when receiving a prescription data acquisition request sent by a third party for the prescription data of the target patient, the server may acquire the block of each data block corresponding to the target patient in the prescription data blockchain Hash code.
  • the block hash code is obtained by the server encrypting the prescription data block according to a preset encryption algorithm before generating a prescription data block chain from each party data block .
  • the preset encryption algorithm may be a preset hash algorithm, and the embodiments of the present application do not specifically limit the preset encryption algorithm. For example, assuming that the patient identification of the target patient acquired by the server is a, the server may acquire block hash codes of data blocks of various parties corresponding to the target patient a in the prescription data blockchain.
  • step S203 Detect whether the block hash codes between the prescription data blocks adjacent to the various data blocks corresponding to the target patient are related, if the detection result is yes, then execute step S204, if the detection result is no, Then step S205 is executed.
  • the server may detect the data area of each party corresponding to the target patient Whether the block hash codes between the adjacent prescription data blocks of the block are related, if the detection result is yes, step S204 is executed, and if the detection result is no, step S205 is executed.
  • the prescription data block adjacent to the prescription data block corresponding to the target patient may include the prescription data block corresponding to the target patient, or may include The prescription data blocks of other patients adjacent to each prescription data block.
  • the server may detect whether the block hash codes between the adjacent prescription data blocks corresponding to the target patient are related, and detect the data blocks of each party corresponding to the target patient and Whether the corresponding other prescription data blocks in the adjacent prescription data block chain are related.
  • the server may detect whether block hash codes between 1, 2, 3,, n, n consecutive prescription data blocks corresponding to the target patient a are associated, and detect the prescription Whether the block hash code between the data block x and the prescription data block 1 is correlated, and it is detected whether the block hash code between the prescription data block y and the prescription data block n is correlated.
  • the prescription data block includes a patient identification
  • the server may obtain the information related to the target prescription data block that is illegally tampered in the data block of each party corresponding to the target patient. At least one tampered prescription data block that is not associated with the block hash code between the prescription data blocks adjacent to the various data blocks corresponding to the target patient, and according to the block identification in each tampered prescription data block, The target prescription data block illegally tampered in the data blocks of each party corresponding to the target patient is determined.
  • the tampered prescription data block may include any one or more of the various data blocks corresponding to the target patient, and may also include adjacent to the target patient's prescription data One or more prescription data blocks.
  • the patient identifier of the target patient obtained by the server is a
  • the target patient a corresponds to 1, 2, 3, n, n consecutive prescription data blocks
  • the block identifiers of the n prescription data blocks correspond to 1, 2, 3,, n
  • the block identifier of one prescription data block adjacent to the prescription data block 1 of the target patient a Is x
  • the block identifier of one prescription data block adjacent to the prescription data block n of the target patient a is y.
  • the server can determine the target prescription data that has been illegally tampered in the data blocks of each party corresponding to the target patient according to the block identifier in each tampered prescription data block
  • the blocks are prescription data block 2 and prescription data block 3.
  • the server may determine the The verification is successful.
  • the server may send data blocks of various parties corresponding to the target patient to the third party.
  • step S205 Determine that the verification of the prescription data blockchain fails, and execute step S206.
  • step S206 is executed.
  • S206 Determine that there is a prescription data block in the prescription data block corresponding to the target patient in the prescription data block where the prescription data is illegally tampered with, and reject the third-party prescription data acquisition request.
  • the server may determine that the prescription data in each data block corresponding to the target patient in the prescription data blockchain is illegally tampered with The prescription data block of the website, and reject the request for obtaining prescription data from the third party. In this way, avoid sending illegally tampered prescription data blocks to third parties.
  • S207 Determine the target prescription data block illegally tampered in the data blocks of various parties corresponding to the target patient, and send prompt information to the third party.
  • the server may determine the target prescription data block illegally tampered in the data blocks of various parties corresponding to the target patient, and send prompt information to the third party, wherein the prompt information is used for prompting
  • the prescription data of the target prescription data block is illegally tampered with.
  • the patient identifier of the target patient obtained by the server is a
  • the target patient a corresponds to 1, 2, 3, n, n consecutive prescription data blocks
  • the block identifiers of the n prescription data blocks correspond to 1, 2, 3,, n
  • the block identifier of one prescription data block adjacent to the prescription data block 1 of the target patient a Is x
  • the block identifier of one prescription data block adjacent to the prescription data block n of the target patient a is y.
  • the server may send a prompt to a third party Information to remind the third party that the prescription data block 2 and the prescription data block 3 of the target patient a have been illegally tampered with.
  • the server may send a prompt message to the terminal corresponding to the target patient after determining the target prescription data block illegally tampered in the data block corresponding to the target patient to remind the The target prescription data block of the target patient's terminal is illegally tampered with, so that the target patient's terminal can re-upload the target prescription data block.
  • the patient terminal can re-upload the illegally tampered prescription data block, complete the prescription data block of the prescription data block chain, and ensure the integrity of the data in the prescription data block chain.
  • the patient identification of the target patient obtained by the server is a
  • the target patient a corresponds to 1, 2, 3,, n, n consecutive prescription data blocks
  • the n The block identifiers of the prescription data blocks correspond to 1, 2, 3,, and n
  • the block identifier of one prescription data block adjacent to the prescription data block 1 of the target patient a is x
  • the block identifier of one prescription data block adjacent to the prescription data block n of the target patient a is y.
  • the server may send a request to the target patient
  • the terminal corresponding to a sends a prompt message to indicate that the prescription data block 2 and the prescription data block 3 of the target patient a's terminal have been illegally tampered so that the target patient a's terminal can re-upload the prescription data area Block 2 and prescription data block 3.
  • the server may acquire the prescription data block of each patient sent by the diagnosis and treatment terminal, and generate a prescription data block chain according to the prescription data block of each patient.
  • the block hash code of each data block corresponding to the target patient in the prescription data blockchain is acquired.
  • the block hash code between the prescription data blocks adjacent to the various data blocks corresponding to the target patient is associated, it is determined that the verification of the prescription data blockchain is successful, if If the block hash codes between the prescription data blocks adjacent to the various data blocks corresponding to the target patient are not correlated, it can be determined that the verification of the prescription data block chain fails, and the prescription data is determined There is a prescription data block in which prescription data is illegally tampered with in the data block of each party corresponding to the target patient in the blockchain, and the third party's request for obtaining prescription data is rejected.
  • the server may determine the target prescription data block illegally tampered in the data blocks of various parties corresponding to the target patient, and send a prompt message to the third party to remind the third party of the prescription data of the target prescription data block Was tampered with illegally. In this way, it is possible to avoid sending illegally tampered prescription data blocks to third parties, improve data security, and ensure the integrity of data in the prescription data block chain.
  • FIG. 3 is a schematic flowchart of yet another blockchain-based prescription data verification method provided by an embodiment of the present application. As shown in FIG. 3, this method may be performed by a data verification device. The specific explanation of the verification device is as described above, and will not be repeated here. The difference between the embodiment of the present application and the embodiment described in FIG. 2 above is that the embodiment of the present application is another implementation process of verifying data blocks of various parties corresponding to the target patient in the prescription data blockchain Give a detailed explanation. Specifically, the method in the embodiment of the present application includes the following steps.
  • S301 Obtain the prescription data block of each patient sent by the diagnosis and treatment terminal, and generate a prescription data block chain according to the prescription data block of each patient.
  • the server may acquire the prescription data block of each patient sent by the diagnosis and treatment terminal, and generate a prescription data block chain according to the prescription data block of each patient.
  • the explanation of the prescription data block is as described above, and the explanation of the prescription data is as described above, which will not be repeated here.
  • S302 When receiving a prescription data acquisition request sent by a third party for the prescription data of the target patient, acquire the encrypted information carried in the prescription data acquisition request.
  • the server when receiving a prescription data acquisition request sent by a third party for the prescription data of the target patient, the server may acquire the encrypted information carried in the prescription data acquisition request.
  • the encrypted information includes an encryption algorithm and a key.
  • the encryption algorithm may include a preset hash algorithm. In this embodiment of the present application, the preset hash The algorithm is not specifically limited.
  • S303 Perform encryption processing on the data blocks of various parties corresponding to the target patient according to the encrypted information to generate a check hash code of the data blocks of various parties corresponding to the target patient.
  • the server may perform encryption processing on data blocks of various parties corresponding to the target patient according to the encrypted information to generate a check hash code of data blocks of various parties corresponding to the target patient.
  • the server may perform encryption processing on data blocks corresponding to the target patient according to the encryption algorithm and key in the encrypted information to generate data areas corresponding to the target patient The check hash code of the block.
  • the encryption algorithm obtained by the server is the hash algorithm SHA256, and the key is xyz. If the target patient ’s patient ID is a, and the target patient a corresponds to 1, 2, 3, and n , N consecutive prescription data blocks, the server can encrypt the data blocks of each party corresponding to the target patient according to the hash algorithm SHA256 and the key xyz to generate each corresponding to the target patient The check hash code of the prescription data block.
  • step S304 Detect whether the check hash code corresponding to the data block of each party matches the block hash code corresponding to the data block of each party. If it matches, perform step S305; if it does not match, perform step S306.
  • the server may detect whether the verification hash code corresponding to the data block of each party matches the block hash code corresponding to the data block of each party, and if it matches, step S305 is executed if If they do not match, step S306 is executed.
  • the server may execute step S306.
  • the server may determine the prescription data block The verification of the chain was successful.
  • the server may send data blocks of various parties corresponding to the target patient to the third party.
  • step S307 if the server detects that the verification hash code corresponding to the data block of each party does not match the block hash code corresponding to the data block of each party, it may determine the prescription data area The verification of the block chain fails, and step S307 is executed.
  • the server may determine that the prescription data in various data blocks corresponding to the target patient in the prescription data blockchain is illegally tampered with The prescription data block of the website, and reject the request for obtaining prescription data from the third party. In this way, avoid sending illegally tampered prescription data blocks to third parties.
  • S308 Determine the target prescription data block illegally tampered in the data blocks of various parties corresponding to the target patient, and send prompt information to the third party.
  • the server may determine the target prescription data block illegally tampered in the data blocks of various parties corresponding to the target patient, and send prompt information to the third party.
  • the specific embodiments and examples are as described above and will not be repeated here.
  • the server may send a prompt message to the terminal corresponding to the target patient after determining the target prescription data block illegally tampered in the data block corresponding to the target patient to remind the The target prescription data block of the target patient's terminal is illegally tampered with, so that the target patient's terminal can re-upload the target prescription data block.
  • the patient terminal can re-upload the illegally tampered prescription data block, complete the prescription data block of the prescription data block chain, and ensure the integrity of the data in the prescription data block chain.
  • the server may acquire the prescription data block of each patient sent by the diagnosis and treatment terminal, and generate a prescription data block chain according to the prescription data block of each patient, when receiving the prescription data sent by the third party to the target patient
  • obtain the encrypted information carried in the prescription data acquisition request obtain the encrypted information carried in the prescription data acquisition request, and encrypt the data blocks of the parties corresponding to the target patient according to the encrypted information to generate the parties corresponding to the target patient
  • the check hash code of the data block may be obtained by the diagnosis and treatment terminal, and generate a prescription data block chain according to the prescription data block of each patient, when receiving the prescription data sent by the third party to the target patient.
  • FIG. 4 is a schematic block diagram of a data verification device according to an embodiment of the present application.
  • the data verification device of this embodiment includes: an acquisition unit 401, a verification unit 402, a first determination unit 403, and a second determination unit 404.
  • the obtaining unit 401 is used to obtain the prescription data blocks of each patient sent by the diagnosis and treatment terminal, and generate a prescription data block chain based on the prescription data blocks of each patient, wherein the prescription data block is based on The patient's prescription data is generated, and the prescription data includes any one or more of the drug name, the number of drugs, and the usage and dosage of the drugs;
  • the verification unit 402 is configured to verify the data blocks of various parties corresponding to the target patient in the prescription data block chain when receiving a prescription data acquisition request sent by a third party for the prescription data of the target patient;
  • the first determining unit 403 is used to determine if there is a prescription data block in which prescription data is illegally tampered in the data block of each party corresponding to the target patient in the prescription data blockchain if the verification fails, and reject all The third-party prescription data acquisition request;
  • the second determining unit 404 is used to determine the target prescription data block illegally tampered in the data blocks of various parties corresponding to the target patient, and send prompt information to the third party, wherein the prompt information is used to prompt The prescription data of the target prescription data block is illegally tampered with.
  • the prescription data block includes a block hash code
  • the verification unit 402 is specifically used when verifying data blocks of various parties corresponding to the target patient in the prescription data block chain :
  • the prescription data block includes a block identifier; when the first determining unit 403 determines the target prescription data block illegally tampered in the data block of each party corresponding to the target patient, it is specifically used for:
  • the target prescription data block illegally tampered in the data blocks of each party corresponding to the target patient is determined.
  • the prescription data block includes a block hash code, and the prescription data acquisition request carries encrypted information; the verification unit 402 corresponds to each of the target patients in the prescription data block chain. When the prescription data block is verified, it is specifically used for:
  • the prescription data block includes a block identifier; when the first determining unit 403 determines the target prescription data block illegally tampered in each prescription data block corresponding to the target patient, it is specifically used for:
  • the block identifiers of the various data blocks corresponding to the target patient determine the verification hash codes of the various data blocks corresponding to the target patient and the blocks of the various data blocks corresponding to the target patient
  • the prescription data block whose hash code does not match is the target prescription data block that has been illegally tampered with.
  • the obtaining unit 401 when the obtaining unit 401 generates a prescription data blockchain based on each patient's prescription data block, it is specifically used to:
  • the prescription data block chain is generated according to the sorted prescription data blocks.
  • the prescription data acquisition request includes identity verification information; the verification unit 402 performs integrity on the prescription data blockchain after receiving a prescription data acquisition request sent by a third party for the prescription data of the target patient Before verification, it is also used to:
  • the identity verification information includes any one or more types of information in a password, a fingerprint, and a voice;
  • the step of performing the integrity check on the prescription data blockchain is triggered.
  • the server may acquire the prescription data block of each patient sent by the diagnosis and treatment terminal, and generate a prescription data block chain according to the prescription data block of each patient, when receiving the prescription data sent by the third party to the target patient
  • each data block corresponding to the target patient in the prescription data blockchain is verified. If the verification fails, the target patient in the prescription data blockchain can be determined
  • Corresponding data blocks of various parties have prescription data blocks with illegally tampered prescription data, and reject the third-party prescription data acquisition request, and determine that the various data blocks corresponding to the target patient have been illegally tampered with Target the prescription data block and send prompt information to the third party. In this way, the illegally tampered prescription data block is prevented from being sent to the third party, and the data security is improved.
  • FIG. 5 is a schematic block diagram of a server provided by an embodiment of the present application.
  • the server in this embodiment may include: one or more processors 501; one or more input devices 502, one or more output devices 503, and a memory 504.
  • the above processor 501, input device 502, output device 503, and memory 504 are connected via a bus 505.
  • the memory 504 is used to store a computer program, and the computer program includes program instructions, and the processor 501 is used to execute the program instructions stored in the memory 504.
  • the processor 501 is configured to call the program instruction to execute:
  • the prescription data includes any one or more of the name of the drug, the quantity of the drug, and the usage and dosage of the drug;
  • the prescription data block includes a block hash code.
  • the processor 501 verifies data blocks of various parties corresponding to the target patient in the prescription data block chain, it is specifically used for:
  • the prescription data block includes a block identifier; when the processor 501 determines the target prescription data block illegally tampered in the data block of each party corresponding to the target patient, it is specifically used for
  • the target prescription data block illegally tampered in the data blocks of various parties corresponding to the target patient is determined.
  • the prescription data block includes a block hash code, and the prescription data acquisition request carries encrypted information; the processor 501 responds to all parties corresponding to the target patient in the prescription data block chain When verifying the data block, it is specifically used for:
  • the prescription data block includes a block identifier; when the processor 501 determines the target prescription data block illegally tampered in the data block of each party corresponding to the target patient, it is specifically used to:
  • the block identifiers of the various data blocks corresponding to the target patient determine the verification hash codes of the various data blocks corresponding to the target patient and the blocks of the various data blocks corresponding to the target patient
  • the prescription data block whose hash code does not match is the target prescription data block that has been illegally tampered with.
  • the processor 501 when the processor 501 generates a prescription data blockchain based on each patient's prescription data block, it is specifically used to:
  • the prescription data block chain is generated according to the sorted prescription data blocks.
  • the prescription data acquisition request includes identity verification information; after receiving the prescription data acquisition request sent by the third party to the target patient's prescription data, the processor 501 performs integrity check on the prescription data blockchain Before the test, it is also used to:
  • the identity verification information includes any one or more types of information in a password, a fingerprint, and a voice;
  • the step of performing the integrity check on the prescription data blockchain is triggered.
  • the server may acquire the prescription data block of each patient sent by the diagnosis and treatment terminal, and generate a prescription data block chain according to the prescription data block of each patient, when receiving the prescription data sent by the third party to the target patient
  • each data block corresponding to the target patient in the prescription data blockchain is verified. If the verification fails, the target patient in the prescription data blockchain can be determined
  • Corresponding data blocks of various parties have prescription data blocks with illegally tampered prescription data, and reject the third-party prescription data acquisition request, and determine that the various data blocks corresponding to the target patient have been illegally tampered with Target the prescription data block and send prompt information to the third party. In this way, the illegally tampered prescription data block is prevented from being sent to the third party, and the data security is improved.
  • the so-called processor 501 may be a central processing unit (Central Processing Unit, CPU), and the processor may also be other general-purpose processors, digital signal processors (Digital Signal Processor, DSP) , Application Specific Integrated Circuit (Application Specific Integrated Circuit, ASIC), ready-made programmable gate array (Field-Programmable Gate Array, FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc.
  • the general-purpose processor may be a microprocessor or the processor may be any conventional processor or the like.
  • the input device 502 may include a touch panel, a microphone, and the like
  • the output device 503 may include a display (LCD, etc.), a speaker, and the like.
  • the memory 504 may include a read-only memory and a random access memory, and provide instructions and data to the processor 501. A portion of the memory 504 may also include non-volatile random access memory. For example, the memory 504 may also store device type information.
  • the processor 501, the input device 502, and the output device 503 described in the embodiments of the present application may execute the positioning detection method provided in the embodiments of the present application in the method embodiments shown in FIG. 1, FIG. 2, or FIG.
  • the described implementation may also implement the implementation of the data verification device described in FIG. 4 or the implementation of the server described in FIG. 5 in the embodiment of the present application, and details are not described herein again.
  • An embodiment of the present application also provides a computer-readable storage medium that stores a computer program, and when the computer program is executed by a processor, the embodiment corresponding to FIG. 1, FIG. 2, or FIG. 3 is implemented.
  • the positioning detection method described in the present invention may also implement the data verification device of the embodiment corresponding to FIG. 4 of the present application or the server described in FIG. 5, which will not be repeated here.
  • the computer-readable storage medium may be an internal storage unit of the data verification device described in any of the foregoing embodiments, such as a hard disk or a memory of the data verification device.
  • the computer-readable storage medium may also be an external storage device of the data verification device, such as a plug-in hard disk equipped on the data verification device, a smart memory card (Smart Media, Card, SMC), and a secure digital ( Secure (Digital, SD) card, flash card (Flash Card), etc.
  • the computer-readable storage medium may also include both an internal storage unit of the data verification device and an external storage device.
  • the computer-readable storage medium is used to store the computer program and other programs and data required by the data verification device.
  • the computer-readable storage medium may also be used to temporarily store data that has been or will be output.

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Security & Cryptography (AREA)
  • Theoretical Computer Science (AREA)
  • Health & Medical Sciences (AREA)
  • Bioethics (AREA)
  • General Health & Medical Sciences (AREA)
  • Computer Hardware Design (AREA)
  • Software Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Medical Treatment And Welfare Office Work (AREA)

Abstract

本申请实施例公开了一种基于区块链的处方数据校验方法、设备及服务器,该方法包括:获取诊疗终端发送的各患者的处方数据区块,并根据各患者的处方数据区块生成处方数据区块链;当接收到第三方针对目标患者的处方数据发送的处方数据获取请求时,对所述处方数据区块链中所述目标患者对应的各处方数据区块进行校验;如果校验失败,则确定所述处方数据区块链中所述目标患者对应的各处方数据区块中存在处方数据被非法篡改的处方数据区块,并拒绝所述第三方的处方数据获取请求;确定所述目标患者对应的各处方数据区块中被非法篡改的目标处方数据区块,并向所述第三方发送提示信息。通过这种方式,提高了处方数据的安全性。

Description

一种基于区块链的处方数据校验方法、设备及服务器
本申请要求于2018年11月07日提交中国专利局、申请号为201811323418.0、申请名称为“一种基于区块链的处方数据校验方法、设备及服务器”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
技术领域
本申请涉及计算机技术领域,尤其涉及一种基于区块链的处方数据校验方法、设备及服务器。
背景技术
目前,随着互联网的快速发展,各种数据信息均可以通过网络的方式进行存储,以便用户可以更方便地获取所需数据。例如医学领域中的处方数据,诊疗终端通过实时采集各患者的处方数据信息,并上传至服务器,以方便医护人员、患者等第三方用户查询各患者的处方数据信息。然而,这种方式每时每刻都在进行着与数据有关的操作,包括数据采集、数据传输和数据存储等环节,数据在每一个环节都容易受到恶意攻击和非法篡改操作。因此,如何提高数据的安全性非常重要。
发明内容
本申请实施例提供一种基于区块链的处方数据校验方法、设备及服务器,可提高处方数据的安全性。
第一方面,本申请实施例提供了一种基于区块链的处方数据校验方法,该方法包括:
获取诊疗终端发送的各患者的处方数据区块,并根据各患者的处方数据区块生成处方数据区块链,其中,所述处方数据区块是所述诊疗终端根据各患者的处方数据生成的,所述处方数据包括药品名称、药品数量、药品的用法用量中的任意一种或多种;
当接收到第三方针对目标患者的处方数据发送的处方数据获取请求时,对所述处方数据区块链中所述目标患者对应的各处方数据区块进行校验;
如果校验失败,则确定所述处方数据区块链中所述目标患者对应的各处方数据区块中存在处方数据被非法篡改的处方数据区块,并拒绝所述第三方的处方数据获取请求;
确定所述目标患者对应的各处方数据区块中被非法篡改的目标处方数据区块,并向所述第三方发送提示信息,其中,所述提示信息用于提示所述目标处方数据区块的处方数据被非法篡改。
第二方面,本申请实施例提供了一种数据校验设备,该数据校验设备包括用于执行上述第一方面的方法的单元。
第三方面,本申请实施例提供了一种服务器,包括处理器、输入设备、输出设备和存储器,所述处理器、输入设备、输出设备和存储器相互连接,其中,所述存储器用于存储支持数据校验设备执行上述方法的计算机程序,所述计算机程序包括程序指令,所述处理器被配置用于调用所述程序指令,执行上述第一方面的方法。
第四方面,本申请实施例提供了一种计算机可读存储介质,所述计算机可读存储介质存储有计算机程序,所述计算机程序包括程序指令,所述程序指令当被处理器执行时使所述处理器执行上述第一方面的方法。
本申请实施例在接收到处方数据获取请求时,对目标患者的处方数据区块进行校验,如果校验失败,则拒绝该处方数据获取请求,避免将被非法篡改的处方数据区块发生给第三方,提高了数据的安全性。
附图说明
图1是本申请实施例提供的一种基于区块链的处方数据校验方法的示意流程图;
图2是本申请实施例提供的另一种基于区块链的处方数据校验方法的示意流程图;
图3是本申请实施例提供的又一种基于区块链的处方数据校验方法的示意流程图;
图4是本申请实施例提供的一种数据校验设备的示意框图;
图5是本申请实施例提供的一种服务器的示意框图。
具体实施方式
下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例是本申请一部分实施例,而不是全部的实施例。基于本申请中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都属于本申请保护的范围。
本申请实施例提供的基于区块链的处方数据校验方法可以由一种数据校验系统执行,所述数据校验系统包括数据校验设备和诊疗终端,在某些实施例中,所述数据校验设备可以设置在手机、电脑、平板、智能手表等服务器上。在某些实施例中,所述数据校验设备和所述诊疗终端之间可以建立通信连接,以进行双向通信。在某些实施例中,所述数据校验设备可以安装在服务器上,在某些实施例中,所述数据校验设备可以在空间上独立于所述服务器。在某些实施例中,所述诊疗终端可以包括:手机、电脑、平板、智能手表等可智能终端。
该数据校验系统中所述诊疗终端可以将采集到的各患者的处方数据区块发送给服务器,所述服务器在获取到所述诊疗终端发送的各患者的处方数据区块之后,可以根据各患者的处方数据区块生成处方数 据区块链,其中,所述处方数据区块是所述诊疗终端根据各患者的处方数据生成的,所述处方数据包括药品名称、药品数量、药品的用法用量中的任意一种或多种。当服务器接收到第三方针对目标患者的处方数据发送的处方数据获取请求时,所述服务器可以对所述处方数据区块链中所述目标患者对应的各处方数据区块进行校验,如果校验失败,则确定所述处方数据区块链中所述目标患者对应的各处方数据区块中存在处方数据被非法篡改的处方数据区块,并拒绝所述第三方的处方数据获取请求。所述服务器可以确定所述目标患者对应的各处方数据区块中被非法篡改的目标处方数据区块,并向所述第三方发送提示信息,所述提示信息用于提示所述目标处方数据区块的处方数据被非法篡改。通过这种方式可以避免将被非法篡改的处方数据发送给第三方,提高了数据的安全性。下面结合附图对本申请实施例的定位检测方法进行示意性说明。
请参见图1,图1是本申请实施例提供的一种基于区块链的处方数据校验方法的示意流程图,如图1所示,该方法可以由数据校验设备执行,所述数据校验设备设置于服务器上,所述数据校验设备的具体解释如前所述,此处不再赘述。具体地,本申请实施例的所述方法包括如下步骤。
S101:获取诊疗终端发送的各患者的处方数据区块,并根据各患者的处方数据区块生成处方数据区块链。
本申请实施例中,服务器可以获取诊疗终端发送的各患者的处方数据区块,并根据各患者的处方数据区块生成处方数据区块链。在某些实施例中,所述处方数据区块是所述诊疗终端根据各患者的处方数据生成的,所述处方数据包括药品名称、药品数量、药品的用法用量中的任意一种或多种。在某些实施例中,所述处方数据区块中包括患者标识和区块标识。
在一个实施例中,所述服务器在根据各患者的处方数据区块生成处方数据区块链时,可以获取各患者的处方数据区块的数量,根据所述处方数据区块的数量,对所述各患者进行排序,按照排序后的处方数据区块生成所述处方数据区块链。例如,假设所述服务器获取到诊疗终端发送的n个患者的处方数据区块,则所述服务器可以根据各处方数据区块的数量的大小顺序,依次对所述n个患者进行排序,并按照排序后的n各患者的各处方数据区块生成所述处方数据区块链。通过这种方式,有利于服务器可以根据各患者的患者标识对应的各处方数据区块的数量,查找处方数据,提高了处方数据的查找效率。
在一个实施例中,所述处方数据获取请求包括身份验证信息,所述服务器在接收到第三方针对目标患者的处方数据发送的处方数据获取请求之后,对所述处方数据区块链进行完整性校验之前,可以根据所述处方数据获取请求,获取所述身份验证信息,其中,所述身份验证信息包括密码、指纹、语音中的任意一种或多种信息,并将所述身份验证信息与预设的身份验证信息进行匹配,如果匹配成功,则触发 执行所述对所述处方数据区块链进行完整性校验的步骤。通过这种方式对发送处方数据获取请求的第三方进行身份验证,可以确保第三方的安全性,避免将所述处方数据发送给没有授权的非法用户,进一步确保了所述处方数据的安全性。
S102:当接收到第三方针对目标患者的处方数据发送的处方数据获取请求时,对所述处方数据区块链中所述目标患者对应的各处方数据区块进行校验。
本申请实施例中,当接收到第三方针对目标患者的处方数据发送的处方数据获取请求时,服务器可以对所述处方数据区块链中所述目标患者对应的各处方数据区块进行校验。
在一个实施例中,所述处方数据区块中包括区块哈希码,所述服务器可以根据所述区块哈希码对所述处方数据区块链中所述目标患者对应的各处方数据区块进行校验。
在一个实施例中,所述处方数据区块中包括区块哈希码,以及所述处方数据获取请求中携带了加密信息,所述服务器可以根据所述区块哈希码和所述加密信息,对所述处方数据区块链中所述目标患者对应的各处方数据区块进行校验。
S103:如果校验失败,则确定所述处方数据区块链中所述目标患者对应的各处方数据区块中存在处方数据被非法篡改的处方数据区块,并拒绝所述第三方的处方数据获取请求。
本申请实施例中,服务器如果对所述处方数据区块链中所述目标患者对应的各处方数据区块的校验失败,则可以确定所述处方数据区块链中所述目标患者对应的各处方数据区块中存在处方数据被非法篡改的处方数据区块,并拒绝所述第三方的处方数据获取请求。
S104:确定所述目标患者对应的各处方数据区块中被非法篡改的目标处方数据区块,并向所述第三方发送提示信息。
本申请实施例中,所述服务器在确定所述处方数据区块链中所述目标患者对应的各处方数据区块中存在处方数据被非法篡改的处方数据区块之后,可以确定所述目标患者对应的各处方数据区块中被非法篡改的目标处方数据区块,并向所述第三方发送提示信息,其中,所述提示信息用于提示所述目标处方数据区块的处方数据被非法篡改。
本申请实施例中,服务器可以获取诊疗终端发送的各患者的处方数据区块,并根据各患者的处方数据区块生成处方数据区块链,当接收到第三方针对目标患者的处方数据发送的处方数据获取请求时,对所述处方数据区块链中所述目标患者对应的各处方数据区块进行校验,如果校验失败,则可以确定所述处方数据区块链中所述目标患者对应的各处方数据区块中存在处方数据被非法篡改的处方数据区块,并拒绝所述第三方的处方数据获取请求,并确定所述目标患者对应的各处方数据区块中被非法篡改的目标处方数据区块,并向所述第三方发送提示信息,通过这种方式,避免了将被非法篡改的处方数据区块发 生给第三方,提高了数据的安全性。
请参见图2,图2是本申请实施例提供的另一种基于区块链的处方数据校验方法的示意流程图,如图2所示,该方法可以由数据校验设备执行,该数据校验设备的具体解释如前所述,此处不再赘述。本申请实施例与上述图1所述实施例的区别在于,本申请实施例是对所述处方数据区块链中所述目标患者对应的各处方数据区块进行校验的一种实施过程进行详细的说明。具体地,本申请实施例的所述方法包括如下步骤。
S201:获取诊疗终端发送的各患者的处方数据区块,并根据各患者的处方数据区块生成处方数据区块链。
本申请实施例中,服务器可以获取诊疗终端发送的各患者的处方数据区块,并根据各患者的处方数据区块生成处方数据区块链。其中,所述处方数据区块的解释如前所述,以及所述处方数据的解释如前所述,此处不再赘述。
S202:当接收到第三方针对目标患者的处方数据发送的处方数据获取请求时,获取所述处方数据区块链中所述目标患者对应的各处方数据区块的区块哈希码。
本申请实施例中,当接收到第三方针对目标患者的处方数据发送的处方数据获取请求时,服务器可以获取所述处方数据区块链中所述目标患者对应的各处方数据区块的区块哈希码。在某些实施例中,所述区块哈希码是所述服务器在根据各处方数据区块生成处方数据区块链之前,根据预设的加密算法对所述处方数据区块进行加密得到的。在某些实施例中,所述预设的加密算法可以是预设的哈希算法,本申请实施例对所述预设的加密算法不做具体的限定。例如,假设所述服务器获取到的目标患者的患者标识为a,则所述服务器可以获取所述处方数据区块链中所述目标患者a对应的各处方数据区块的区块哈希码。
S203:检测与所述目标患者对应的各处方数据区块相邻的处方数据区块间的区块哈希码是否相关联,如果检测结果为是,则执行步骤S204,如果检测结果为否,则执行步骤S205。
本申请实施例中,服务器在获取到所述处方数据区块链中所述目标患者对应的各处方数据区块的区块哈希码之后,可以检测与所述目标患者对应的各处方数据区块相邻的处方数据区块间的区块哈希码是否相关联,如果检测结果为是,则执行步骤S204,如果检测结果为否,则执行步骤S205。
在一个实施例中,所述与所述目标患者对应的各处方数据区块相邻的处方数据区块可以包括所述目标患者对应的各处方数据区块,也可以包括与所述目标患者的各处方数据区块相邻的其他患者的处方数据区块。
在一个实施例中,所述服务器可以检测所述目标患者对应的各相邻处方数据区块之间的区块哈希码是否相关联,以及检测所述目标患者对应的各处方数据区块与相邻的所述处方数据区块链中对应的其他处方数据区块之间是否相关联。
具体可举例说明,假设所述服务器获取到的所述目标患者的患者标识为a,且所述目标患者a对应包括1、2、3、、、n,n个连续的处方数据区块,以及与所述目标患者a的处方数据区块1相邻的1个处方数据区块x,以及与所述目标患者a的处方数据区块n相邻的1个处方数据区块y。则所述服务器可以检测所述所述目标患者a对应的1、2、3、、、n,n个连续的处方数据区块之间的区块哈希码是否相关联,以及检测所述处方数据区块x与处方数据区块1之间的区块哈希码是否相关联,以及检测所述处方数据区块y与处方数据区块n之间的区块哈希码是否相关联。
在一个实施例中,所述处方数据区块中包括患者标识,所述服务器在确定所述目标患者对应的各处方数据区块中被非法篡改的目标处方数据区块时,可以获取与所述目标患者对应的各处方数据区块相邻的处方数据区块间的区块哈希码之间不关联的至少一个篡改处方数据区块,并根据各篡改处方数据区块中的区块标识,确定所述目标患者对应的各处方数据区块中被非法篡改的目标处方数据区块。
在某些实施例中,所述篡改处方数据区块可以包括所述目标患者对应的各处方数据区块中的任意一种或多种,也可以包括与所述目标患者的处方数据相邻的一种或多种处方数据区块。
具体可以举例说明,假设所述服务器获取到的所述目标患者的患者标识为a,且所述目标患者a对应包括1、2、3、、、n,n个连续的处方数据区块,且所述n个处方数据区块的区块标识对应为1、2、3、、、n,以及与所述目标患者a的处方数据区块1相邻的1个处方数据区块的区块标识为x,以及与所述目标患者a的处方数据区块n相邻的1个处方数据区块的区块标识为y。如果所述服务器获取到与所述目标患者a对应的各处方数据区块相邻的处方数据区块间的区块哈希码之间不关联的篡改处方数据区块包括处方数据区块x、处方数据区块2、处方数据区块3,则所述服务器可以根据各篡改处方数据区块中的区块标识,确定所述目标患者对应的各处方数据区块中被非法篡改的目标处方数据区块为处方数据区块2和处方数据区块3。
S204:确定所述处方数据区块链的校验成功。
本申请实施例中,服务器如果检测到与所述目标患者对应的各处方数据区块相邻的处方数据区块间的区块哈希码相关联,则可以确定所述处方数据区块链的校验成功。
在一个实施例中,所述服务器在确定所述处方数据区块链的校验成功之后,可以将所述目标患者对应的各处方数据区块发送给所述第三方。
S205:确定所述处方数据区块链的校验失败,并执行步骤S206。
本申请实施例中,服务器如果检测到与所述目标患者对应的各处方数据区块相邻的处方数据区块间存在不相关联的区块哈希码,则可以确定所述处方数据区块链的校验失败,并在校验失败之后,执行步骤S206。
S206:确定所述处方数据区块链中所述目标患者对应的各处方数据区块中存在处方数据被非法篡改的处方数据区块,并拒绝所述第三方的处方数据获取请求。
本申请实施例中,服务器在对所述处方数据区块链的校验失败之后,可以确定所述处方数据区块链中所述目标患者对应的各处方数据区块中存在处方数据被非法篡改的处方数据区块,并拒绝所述第三方的处方数据获取请求。通过这种方式,避免将被非法篡改后的处方数据区块发送给第三方。
S207:确定所述目标患者对应的各处方数据区块中被非法篡改的目标处方数据区块,并向所述第三方发送提示信息。
本申请实施例中,服务器可以确定所述目标患者对应的各处方数据区块中被非法篡改的目标处方数据区块,并向所述第三方发送提示信息,其中,所述提示信息用于提示所述目标处方数据区块的处方数据被非法篡改。
具体可以举例说明,假设所述服务器获取到的所述目标患者的患者标识为a,且所述目标患者a对应包括1、2、3、、、n,n个连续的处方数据区块,且所述n个处方数据区块的区块标识对应为1、2、3、、、n,以及与所述目标患者a的处方数据区块1相邻的1个处方数据区块的区块标识为x,以及与所述目标患者a的处方数据区块n相邻的1个处方数据区块的区块标识为y。如果所述服务器确定出所述目标患者对应的各处方数据区块中被非法篡改的目标处方数据区块为处方数据区块2和处方数据区块3,则所述服务器可以向第三方发送提示信息,以提示所述第三方所述目标患者a的处方数据区块2和处方数据区块3被非法篡改。
在一个实施例中,所述服务器可以在确定所述目标患者对应的各处方数据区块中被非法篡改的目标处方数据区块之后,向所述目标患者对应的终端发送提示信息,以提示所述目标患者的终端所述目标处方数据区块被非法篡改,以使所述目标患者的终端可以重新上传所述目标处方数据区块。通过这种方式可以使患者终端重新上传被非法篡改的处方数据区块,补全所述处方数据区块链的处方数据区块,确保所述处方数据区块链中数据的完整性。
例如,假设所述服务器获取到的所述目标患者的患者标识为a,且所述目标患者a对应包括1、2、3、、、n,n个连续的处方数据区块,且所述n个处方数据区块的区块标识对应为1、2、3、、、n,以及与所述目标患者a的处方数据区块1相邻的1个处方数据区块的区块标识为x,以及与所述目标患者a的处方数据区块n相邻的1个处方数据区块的区块标识为y。如果所述服务器确定出所述目标患者对 应的各处方数据区块中被非法篡改的目标处方数据区块为处方数据区块2和处方数据区块3,则所述服务器可以向所述目标患者a对应的终端发送提示信息,以所述目标患者a的终端所述处方数据区块2和处方数据区块3被非法篡改,以使所述目标患者a的终端可以重新上传所述处方数据区块2和处方数据区块3。
本申请实施例中,服务器可以获取诊疗终端发送的各患者的处方数据区块,并根据各患者的处方数据区块生成处方数据区块链,当接收到第三方针对目标患者的处方数据发送的处方数据获取请求时,获取所述处方数据区块链中所述目标患者对应的各处方数据区块的区块哈希码。如果检测到与所述目标患者对应的各处方数据区块相邻的处方数据区块间的区块哈希码相关联,则确定所述处方数据区块链的校验成功,如果检测到与所述目标患者对应的各处方数据区块相邻的处方数据区块间的区块哈希码不相关联,则可以确定所述处方数据区块链的校验失败,并确定所述处方数据区块链中所述目标患者对应的各处方数据区块中存在处方数据被非法篡改的处方数据区块,拒绝所述第三方的处方数据获取请求。服务器可以确定所述目标患者对应的各处方数据区块中被非法篡改的目标处方数据区块,并向所述第三方发送提示信息,以提示所述第三方该目标处方数据区块的处方数据被非法篡改。通过这种方式,可以避免将被非法篡改后的处方数据区块发送给第三方,提高数据的安全性,确保所述处方数据区块链中数据的完整性。
请参见图3,图3是本申请实施例提供的又一种基于区块链的处方数据校验方法的示意流程图,如图3所示,该方法可以由数据校验设备执行,该数据校验设备的具体解释如前所述,此处不再赘述。本申请实施例与上述图2所述实施例的区别在于,本申请实施例是对所述处方数据区块链中所述目标患者对应的各处方数据区块进行校验的另一种实施过程进行详细的说明。具体地,本申请实施例的所述方法包括如下步骤。
S301:获取诊疗终端发送的各患者的处方数据区块,并根据各患者的处方数据区块生成处方数据区块链。
本申请实施例中,服务器可以获取诊疗终端发送的各患者的处方数据区块,并根据各患者的处方数据区块生成处方数据区块链。其中,所述处方数据区块的解释如前所述,以及所述处方数据的解释如前所述,此处不再赘述。
S302:当接收到第三方针对目标患者的处方数据发送的处方数据获取请求时,获取所述处方数据获取请求中携带的加密信息。
本申请实施例中,当接收到第三方针对目标患者的处方数据发送的处方数据获取请求时,服务器可 以获取所述处方数据获取请求中携带的加密信息。在某些实施例中,所述加密信息包括加密算法和密钥,在某些实施例中,所述加密算法可以包括预设的哈希算法,本申请实施例对所述预设的哈希算法不做具体限定。
S303:根据所述加密信息,对所述目标患者对应的各处方数据区块进行加密处理,生成所述目标患者对应的各处方数据区块的校验哈希码。
本申请实施例中,服务器可以根据所述加密信息,对所述目标患者对应的各处方数据区块进行加密处理,生成所述目标患者对应的各处方数据区块的校验哈希码。
在一个实施例中,所述服务器可以根据所述加密信息中的加密算法和密钥,对所述目标患者对应的各处方数据区块进行加密处理,生成所述目标患者对应的各处方数据区块的校验哈希码。
例如,假设所述服务器获取到的加密算法为哈希算法SHA256,密钥为xyz,如果所述目标患者的患者标识为a,且所述目标患者a对应包括1、2、3、、、n,n个连续的处方数据区块,则所述服务器可以根据所述哈希算法SHA256和密钥xyz对所述目标患者对应的各处方数据区块进行加密处理,生成所述目标患者对应的各处方数据区块的校验哈希码。
S304:检测所述各处方数据区块对应的校验哈希码是否与所述各处方数据区块对应的区块哈希码匹配,如果匹配,则执行步骤S305,如果不匹配,则执行步骤S306。
本申请实施例中,服务器可以检测所述各处方数据区块对应的校验哈希码是否与所述各处方数据区块对应的区块哈希码匹配,如果匹配,则执行步骤S305,如果不匹配,则执行步骤S306。
例如,如果所述服务器检测到计算所述目标患者a对应的处方数据区块2的校验哈希码与所述处方数据区块2的区块哈希码不匹配,以及所述目标患者a对应的处方数据区块3的校验哈希码与所述处方数据区块3的区块哈希码不匹配,则所述服务器可以执行步骤S306。
S305:确定所述处方数据区块链的校验成功。
本申请实施例中,服务器如果检测到所述各处方数据区块对应的校验哈希码与所述各处方数据区块对应的区块哈希码匹配,则可以确定所述处方数据区块链的校验成功。
在一个实施例中,所述服务器在确定所述处方数据区块链的校验成功之后,可以将所述目标患者对应的各处方数据区块发送给所述第三方。
S306:确定所述处方数据区块链的校验失败,并执行步骤S307。
本申请实施例中,服务器如果检测到所述各处方数据区块对应的校验哈希码与所述各处方数据区块对应的区块哈希码不匹配,则可以确定所述处方数据区块链的校验失败,并执行步骤S307。
S307:确定所述处方数据区块链中所述目标患者对应的各处方数据区块中存在处方数据被非法篡改 的处方数据区块,并拒绝所述第三方的处方数据获取请求。
本申请实施例中,服务器在确定所述处方数据区块链的校验失败之后,可以确定所述处方数据区块链中所述目标患者对应的各处方数据区块中存在处方数据被非法篡改的处方数据区块,并拒绝所述第三方的处方数据获取请求。通过这种方式,避免将被非法篡改后的处方数据区块发送给第三方。
S308:确定所述目标患者对应的各处方数据区块中被非法篡改的目标处方数据区块,并向所述第三方发送提示信息。
本申请实施例中,服务器可以确定所述目标患者对应的各处方数据区块中被非法篡改的目标处方数据区块,并向所述第三方发送提示信息。具体实施例及举例说明如前所述,此处不再赘述。
在一个实施例中,所述服务器可以在确定所述目标患者对应的各处方数据区块中被非法篡改的目标处方数据区块之后,向所述目标患者对应的终端发送提示信息,以提示所述目标患者的终端所述目标处方数据区块被非法篡改,以使所述目标患者的终端可以重新上传所述目标处方数据区块。通过这种方式可以使患者终端重新上传被非法篡改的处方数据区块,补全所述处方数据区块链的处方数据区块,确保所述处方数据区块链中数据的完整性。具体实施例的举例说明如前所述,此处不再赘述。
本申请实施例中,服务器可以获取诊疗终端发送的各患者的处方数据区块,并根据各患者的处方数据区块生成处方数据区块链,当接收到第三方针对目标患者的处方数据发送的处方数据获取请求时,获取所述处方数据获取请求中携带的加密信息,根据所述加密信息,对所述目标患者对应的各处方数据区块进行加密处理,生成所述目标患者对应的各处方数据区块的校验哈希码。通过检测所述各处方数据区块对应的校验哈希码是否与所述各处方数据区块对应的区块哈希码匹配,如果匹配,则确定所述处方数据区块链的校验成功,如果不匹配,则确定所述处方数据区块链的校验失败,并确定所述处方数据区块链中所述目标患者对应的各处方数据区块中存在处方数据被非法篡改的处方数据区块,并拒绝所述第三方的处方数据获取请求,进一步确定所述目标患者对应的各处方数据区块中被非法篡改的目标处方数据区块,并向所述第三方发送提示信息。通过这种方式,可以避免将被非法篡改后的处方数据区块发送给第三方,确保所述处方数据区块链中数据的完整性,提高数据安全性。
本申请实施例还提供了一种数据校验设备,该数据校验设备用于执行前述任一项所述的方法的单元。具体地,参见图4,图4是本申请实施例提供的一种数据校验设备的示意框图。本实施例的数据校验设备包括:获取单元401、校验单元402、第一确定单元403、第二确定单元404。
获取单元401,用于获取诊疗终端发送的各患者的处方数据区块,并根据各患者的处方数据区块生成处方数据区块链,其中,所述处方数据区块是所述诊疗终端根据各患者的处方数据生成的,所述处方 数据包括药品名称、药品数量、药品的用法用量中的任意一种或多种;
校验单元402,用于当接收到第三方针对目标患者的处方数据发送的处方数据获取请求时,对所述处方数据区块链中所述目标患者对应的各处方数据区块进行校验;
第一确定单元403,用于如果校验失败,则确定所述处方数据区块链中所述目标患者对应的各处方数据区块中存在处方数据被非法篡改的处方数据区块,并拒绝所述第三方的处方数据获取请求;
第二确定单元404,用于确定所述目标患者对应的各处方数据区块中被非法篡改的目标处方数据区块,并向所述第三方发送提示信息,其中,所述提示信息用于提示所述目标处方数据区块的处方数据被非法篡改。
进一步地,所述处方数据区块包括区块哈希码,所述校验单元402对所述处方数据区块链中所述目标患者对应的各处方数据区块进行校验时,具体用于:
获取所述处方数据区块链中所述目标患者对应的各处方数据区块的区块哈希码;
检测与所述目标患者对应的各处方数据区块相邻的处方数据区块间的区块哈希码是否相关联;
如果检测结果为是,则确定所述处方数据区块链的校验成功;
如果检测结果为否,则确定所述处方数据区块链的校验失败。
进一步地,所述处方数据区块中包括区块标识;第一确定单元403确定所述目标患者对应的各处方数据区块中被非法篡改的目标处方数据区块时,具体用于:
获取与所述目标患者对应的各处方数据区块相邻的处方数据区块间的区块哈希码之间不关联的至少一个篡改处方数据区块;
根据各篡改处方数据区块中的区块标识,确定所述目标患者对应的各处方数据区块中被非法篡改的目标处方数据区块。
进一步地,所述处方数据区块包括区块哈希码,所述处方数据获取请求中携带了加密信息;所述校验单元402对所述处方数据区块链中所述目标患者对应的各处方数据区块进行校验时,具体用于:
获取所述处方数据获取请求中携带的加密信息,其中,所述加密信息包括加密算法和密钥;
根据所述加密信息,对所述目标患者对应的各处方数据区块进行加密处理,生成所述目标患者对应的各处方数据区块的校验哈希码;
检测所述各处方数据区块对应的校验哈希码是否与所述各处方数据区块对应的区块哈希码匹配;
如果检测结果为是,则确定所述处方数据区块链的校验成功;
如果检测结果为否,则确定所述处方数据区块链的校验失败。
进一步地,所述处方数据区块中包括区块标识;所述第一确定单元403确定所述目标患者对应的各 处方数据区块中被非法篡改的目标处方数据区块时,具体用于:
根据所述目标患者对应的各处方数据区块的区块标识,确定所述目标患者对应的各处方数据区块的校验哈希码与所述目标患者对应的各处方数据区块的区块哈希码不匹配的处方数据区块为被非法篡改的目标处方数据区块。
进一步地,所述获取单元401根据各患者的处方数据区块生成处方数据区块链时,具体用于:
获取各患者的处方数据区块的数量;
根据所述处方数据区块的数量,对所述各患者进行排序;
按照排序后的处方数据区块生成所述处方数据区块链。
进一步地,所述处方数据获取请求包括身份验证信息;所述校验单元402在接收到第三方针对目标患者的处方数据发送的处方数据获取请求之后,对所述处方数据区块链进行完整性校验之前,还用于:
根据所述处方数据获取请求,获取所述身份验证信息,其中,所述身份验证信息包括密码、指纹、语音中的任意一种或多种信息;
将所述身份验证信息与预设的身份验证信息进行匹配;
如果匹配成功,则触发执行所述对所述处方数据区块链进行完整性校验的步骤。
本申请实施例中,服务器可以获取诊疗终端发送的各患者的处方数据区块,并根据各患者的处方数据区块生成处方数据区块链,当接收到第三方针对目标患者的处方数据发送的处方数据获取请求时,对所述处方数据区块链中所述目标患者对应的各处方数据区块进行校验,如果校验失败,则可以确定所述处方数据区块链中所述目标患者对应的各处方数据区块中存在处方数据被非法篡改的处方数据区块,并拒绝所述第三方的处方数据获取请求,并确定所述目标患者对应的各处方数据区块中被非法篡改的目标处方数据区块,并向所述第三方发送提示信息,通过这种方式,避免了将被非法篡改的处方数据区块发生给第三方,提高了数据的安全性。
请参见图5,图5是本申请实施例提供的一种服务器的示意框图。如图所示的本实施例中的服务器可以包括:一个或多个处理器501;一个或多个输入设备502,一个或多个输出设备503和存储器504。上述处理器501、输入设备502、输出设备503和存储器504通过总线505连接。存储器504用于存储计算机程序,所述计算机程序包括程序指令,处理器501用于执行存储器504存储的程序指令。其中,处理器501被配置用于调用所述程序指令执行:
获取诊疗终端发送的各患者的处方数据区块,并根据各患者的处方数据区块生成处方数据区块链,其中,所述处方数据区块是所述诊疗终端根据各患者的处方数据生成的,所述处方数据包括药品名称、药品数量、药品的用法用量中的任意一种或多种;
当接收到第三方针对目标患者的处方数据发送的处方数据获取请求时,对所述处方数据区块链中所述目标患者对应的各处方数据区块进行校验;
如果校验失败,则确定所述处方数据区块链中所述目标患者对应的各处方数据区块中存在处方数据被非法篡改的处方数据区块,并拒绝所述第三方的处方数据获取请求;
确定所述目标患者对应的各处方数据区块中被非法篡改的目标处方数据区块,并向所述第三方发送提示信息,其中,所述提示信息用于提示所述目标处方数据区块的处方数据被非法篡改。
进一步地,所述处方数据区块包括区块哈希码,所述处理器501对所述处方数据区块链中所述目标患者对应的各处方数据区块进行校验时,具体用于:
获取所述处方数据区块链中所述目标患者对应的各处方数据区块的区块哈希码;
检测与所述目标患者对应的各处方数据区块相邻的处方数据区块间的区块哈希码是否相关联;
如果检测结果为是,则确定所述处方数据区块链的校验成功;
如果检测结果为否,则确定所述处方数据区块链的校验失败。
进一步地,所述处方数据区块中包括区块标识;所述处理器501确定所述目标患者对应的各处方数据区块中被非法篡改的目标处方数据区块时,具体用于:
获取与所述目标患者对应的各处方数据区块相邻的处方数据区块间的区块哈希码之间不关联的至少一个篡改处方数据区块;
根据各篡改处方数据区块中的区块标识,确定所述目标患者对应的各处方数据区块中被非法篡改的目标处方数据区块。
进一步地,所述处方数据区块包括区块哈希码,所述处方数据获取请求中携带了加密信息;所述处理器501对所述处方数据区块链中所述目标患者对应的各处方数据区块进行校验时,具体用于:
获取所述处方数据获取请求中携带的加密信息,其中,所述加密信息包括加密算法和密钥;
根据所述加密信息,对所述目标患者对应的各处方数据区块进行加密处理,生成所述目标患者对应的各处方数据区块的校验哈希码;
检测所述各处方数据区块对应的校验哈希码是否与所述各处方数据区块对应的区块哈希码匹配;
如果检测结果为是,则确定所述处方数据区块链的校验成功;
如果检测结果为否,则确定所述处方数据区块链的校验失败。
进一步地,所述处方数据区块中包括区块标识;所述处理器501确定所述目标患者对应的各处方数据区块中被非法篡改的目标处方数据区块时,具体用于:
根据所述目标患者对应的各处方数据区块的区块标识,确定所述目标患者对应的各处方数据区块的 校验哈希码与所述目标患者对应的各处方数据区块的区块哈希码不匹配的处方数据区块为被非法篡改的目标处方数据区块。
进一步地,所述处理器501根据各患者的处方数据区块生成处方数据区块链时,具体用于:
获取各患者的处方数据区块的数量;
根据所述处方数据区块的数量,对所述各患者进行排序;
按照排序后的处方数据区块生成所述处方数据区块链。
进一步地,所述处方数据获取请求包括身份验证信息;所述处理器501在接收到第三方针对目标患者的处方数据发送的处方数据获取请求之后,对所述处方数据区块链进行完整性校验之前,还用于:
根据所述处方数据获取请求,获取所述身份验证信息,其中,所述身份验证信息包括密码、指纹、语音中的任意一种或多种信息;
将所述身份验证信息与预设的身份验证信息进行匹配;
如果匹配成功,则触发执行所述对所述处方数据区块链进行完整性校验的步骤。
本申请实施例中,服务器可以获取诊疗终端发送的各患者的处方数据区块,并根据各患者的处方数据区块生成处方数据区块链,当接收到第三方针对目标患者的处方数据发送的处方数据获取请求时,对所述处方数据区块链中所述目标患者对应的各处方数据区块进行校验,如果校验失败,则可以确定所述处方数据区块链中所述目标患者对应的各处方数据区块中存在处方数据被非法篡改的处方数据区块,并拒绝所述第三方的处方数据获取请求,并确定所述目标患者对应的各处方数据区块中被非法篡改的目标处方数据区块,并向所述第三方发送提示信息,通过这种方式,避免了将被非法篡改的处方数据区块发生给第三方,提高了数据的安全性。
应当理解,在本申请实施例中,所称处理器501可以是中央处理单元(Central Processing Unit,CPU),该处理器还可以是其他通用处理器、数字信号处理器(Digital Signal Processor,DSP)、专用集成电路(Application Specific Integrated Circuit,ASIC)、现成可编程门阵列(Field-Programmable Gate Array,FPGA)或者其他可编程逻辑器件、分立门或者晶体管逻辑器件、分立硬件组件等。通用处理器可以是微处理器或者该处理器也可以是任何常规的处理器等。
输入设备502可以包括触控板、麦克风等,输出设备503可以包括显示器(LCD等)、扬声器等。
该存储器504可以包括只读存储器和随机存取存储器,并向处理器501提供指令和数据。存储器504的一部分还可以包括非易失性随机存取存储器。例如,存储器504还可以存储设备类型的信息。
具体实现中,本申请实施例中所描述的处理器501、输入设备502、输出设备503可执行本申请实施例提供的定位检测方法的图1、图2或图3所述的方法实施例中所描述的实现方式,也可执行本申 请实施例图4所描述的数据校验设备的实现方式或图5所描述的服务器的实现方式,在此不再赘述。
本申请实施例中还提供了一种计算机可读存储介质,所述计算机可读存储介质存储有计算机程序,所述计算机程序被处理器执行时实现图1、图2或图3所对应实施例中描述的定位检测方法,也可实现本申请图4所对应实施例的数据校验设备或图5所描述的服务器,在此不再赘述。
所述计算机可读存储介质可以是前述任一实施例所述的数据校验设备的内部存储单元,例如数据校验设备的硬盘或内存。所述计算机可读存储介质也可以是所述数据校验设备的外部存储设备,例如所述数据校验设备上配备的插接式硬盘,智能存储卡(Smart Media Card,SMC),安全数字(Secure Digital,SD)卡,闪存卡(Flash Card)等。进一步地,所述计算机可读存储介质还可以既包括所述数据校验设备的内部存储单元也包括外部存储设备。所述计算机可读存储介质用于存储所述计算机程序以及所述数据校验设备所需的其他程序和数据。所述计算机可读存储介质还可以用于暂时地存储已经输出或者将要输出的数据。
以上所述,仅为本申请的部分实施方式,但本申请的保护范围并不局限于此,任何熟悉本技术领域的技术人员在本申请揭露的技术范围内,可轻易想到各种等效的修改或替换,这些修改或替换都应涵盖在本申请的保护范围之内。

Claims (20)

  1. 一种基于区块链的处方数据校验方法,其特征在于,包括:
    获取诊疗终端发送的各患者的处方数据区块,并根据各患者的处方数据区块生成处方数据区块链,其中,所述处方数据区块是所述诊疗终端根据各患者的处方数据生成的,所述处方数据包括药品名称、药品数量、药品的用法用量中的任意一种或多种;
    当接收到第三方针对目标患者的处方数据发送的处方数据获取请求时,对所述处方数据区块链中所述目标患者对应的各处方数据区块进行校验;
    如果校验失败,则确定所述处方数据区块链中所述目标患者对应的各处方数据区块中存在处方数据被非法篡改的处方数据区块,并拒绝所述第三方的处方数据获取请求;
    确定所述目标患者对应的各处方数据区块中被非法篡改的目标处方数据区块,并向所述第三方发送提示信息,其中,所述提示信息用于提示所述目标处方数据区块的处方数据被非法篡改。
  2. 根据权利要求1所述的方法,其特征在于,所述处方数据区块包括区块哈希码,所述对所述处方数据区块链中所述目标患者对应的各处方数据区块进行校验,包括:
    获取所述处方数据区块链中所述目标患者对应的各处方数据区块的区块哈希码;
    检测与所述目标患者对应的各处方数据区块相邻的处方数据区块间的区块哈希码是否相关联;
    如果检测结果为是,则确定所述处方数据区块链的校验成功;
    如果检测结果为否,则确定所述处方数据区块链的校验失败。
  3. 根据权利要求2所述的方法,其特征在于,所述处方数据区块中包括区块标识;所述确定所述目标患者对应的各处方数据区块中被非法篡改的目标处方数据区块,包括:
    获取与所述目标患者对应的各处方数据区块相邻的处方数据区块间的区块哈希码之间不关联的至少一个篡改处方数据区块;
    根据各篡改处方数据区块中的区块标识,确定所述目标患者对应的各处方数据区块中被非法篡改的目标处方数据区块。
  4. 根据权利要求1所述的方法,其特征在于,所述处方数据区块包括区块哈希码,所述处方数据获取请求中携带了加密信息;所述对所述处方数据区块链中所述目标患者对应的各处方数据区块进行校验,包括:
    获取所述处方数据获取请求中携带的加密信息,其中,所述加密信息包括加密算法和密钥;
    根据所述加密信息,对所述目标患者对应的各处方数据区块进行加密处理,生成所述目标患者对应的各处方数据区块的校验哈希码;
    检测所述各处方数据区块对应的校验哈希码是否与所述各处方数据区块对应的区块哈希码匹配;
    如果检测结果为是,则确定所述处方数据区块链的校验成功;
    如果检测结果为否,则确定所述处方数据区块链的校验失败。
  5. 根据权利要求4所述的方法,其特征在于,所述处方数据区块中包括区块标识;所述确定所述目标患者对应的各处方数据区块中被非法篡改的目标处方数据区块,包括:
    根据所述目标患者对应的各处方数据区块的区块标识,确定所述目标患者对应的各处方数据区块的校验哈希码与所述目标患者对应的各处方数据区块的区块哈希码不匹配的处方数据区块为被非法篡改的目标处方数据区块。
  6. 根据权利要求1所述的方法,其特征在于,所述根据各患者的处方数据区块生成处方数据区块链,包括:
    获取各患者的处方数据区块的数量;
    根据所述处方数据区块的数量,对所述各患者进行排序;
    按照排序后的处方数据区块生成所述处方数据区块链。
  7. 根据权利要求1所述的方法,其特征在于,所述处方数据获取请求包括身份验证信息;所述当接收到第三方针对目标患者的处方数据发送的处方数据获取请求之后,对所述处方数据区块链进行完整性校验之前,还包括:
    根据所述处方数据获取请求,获取所述身份验证信息,其中,所述身份验证信息包括密码、指纹、语音中的任意一种或多种信息;
    将所述身份验证信息与预设的身份验证信息进行匹配;
    如果匹配成功,则触发执行所述对所述处方数据区块链进行完整性校验的步骤。
  8. 一种数据校验设备,其特征在于,包括:
    获取单元,用于获取诊疗终端发送的各患者的处方数据区块,并根据各患者的处方数据区块生成处方数据区块链,其中,所述处方数据区块是所述诊疗终端根据各患者的处方数据生成的,所述处方数据包括药品名称、药品数量、药品的用法用量中的任意一种或多种;
    校验单元,用于当接收到第三方针对目标患者的处方数据发送的处方数据获取请求时,对所述处方数据区块链中所述目标患者对应的各处方数据区块进行校验;
    第一确定单元,用于如果校验失败,则确定所述处方数据区块链中所述目标患者对应的各处方数据区块中存在处方数据被非法篡改的处方数据区块,并拒绝所述第三方的处方数据获取请求;
    第二确定单元,用于确定所述目标患者对应的各处方数据区块中被非法篡改的目标处方数据区块, 并向所述第三方发送提示信息,其中,所述提示信息用于提示所述目标处方数据区块的处方数据被非法篡改。
  9. 根据权利要求8所述的设备,其特征在于,所述处方数据区块包括区块哈希码,所述校验单元对所述处方数据区块链中所述目标患者对应的各处方数据区块进行校验时,具体用于:
    获取所述处方数据区块链中所述目标患者对应的各处方数据区块的区块哈希码;
    检测与所述目标患者对应的各处方数据区块相邻的处方数据区块间的区块哈希码是否相关联;
    如果检测结果为是,则确定所述处方数据区块链的校验成功;
    如果检测结果为否,则确定所述处方数据区块链的校验失败。
  10. 根据权利要求9所述的设备,其特征在于,所述处方数据区块中包括区块标识;第一确定单元确定所述目标患者对应的各处方数据区块中被非法篡改的目标处方数据区块时,具体用于:
    获取与所述目标患者对应的各处方数据区块相邻的处方数据区块间的区块哈希码之间不关联的至少一个篡改处方数据区块;
    根据各篡改处方数据区块中的区块标识,确定所述目标患者对应的各处方数据区块中被非法篡改的目标处方数据区块。
  11. 根据权利要求8所述的设备,其特征在于,所述处方数据区块包括区块哈希码,所述处方数据获取请求中携带了加密信息;所述校验单元对所述处方数据区块链中所述目标患者对应的各处方数据区块进行校验时,具体用于:
    获取所述处方数据获取请求中携带的加密信息,其中,所述加密信息包括加密算法和密钥;
    根据所述加密信息,对所述目标患者对应的各处方数据区块进行加密处理,生成所述目标患者对应的各处方数据区块的校验哈希码;
    检测所述各处方数据区块对应的校验哈希码是否与所述各处方数据区块对应的区块哈希码匹配;
    如果检测结果为是,则确定所述处方数据区块链的校验成功;
    如果检测结果为否,则确定所述处方数据区块链的校验失败。
  12. 根据权利要求11所述的设备,其特征在于,所述处方数据区块中包括区块标识;所述第一确定单元确定所述目标患者对应的各处方数据区块中被非法篡改的目标处方数据区块时,具体用于:
    根据所述目标患者对应的各处方数据区块的区块标识,确定所述目标患者对应的各处方数据区块的校验哈希码与所述目标患者对应的各处方数据区块的区块哈希码不匹配的处方数据区块为被非法篡改的目标处方数据区块。
  13. 根据权利要求8所述的设备,其特征在于,所述获取单元根据各患者的处方数据区块生成处方数 据区块链时,具体用于:
    获取各患者的处方数据区块的数量;
    根据所述处方数据区块的数量,对所述各患者进行排序;
    按照排序后的处方数据区块生成所述处方数据区块链。
  14. 根据权利要求8所述的设备,其特征在于,所述处方数据获取请求包括身份验证信息;所述校验单元在接收到第三方针对目标患者的处方数据发送的处方数据获取请求之后,对所述处方数据区块链进行完整性校验之前,还用于:
    根据所述处方数据获取请求,获取所述身份验证信息,其中,所述身份验证信息包括密码、指纹、语音中的任意一种或多种信息;
    将所述身份验证信息与预设的身份验证信息进行匹配;
    如果匹配成功,则触发执行所述对所述处方数据区块链进行完整性校验的步骤。
  15. 一种服务器,其特征在于,包括处理器、输入设备、输出设备和存储器,所述处理器、输入设备、输出设备和存储器相互连接,其中,所述存储器用于存储计算机程序,所述计算机程序包括程序指令,所述处理器被配置用于调用所述程序指令,执行:
    获取诊疗终端发送的各患者的处方数据区块,并根据各患者的处方数据区块生成处方数据区块链,其中,所述处方数据区块是所述诊疗终端根据各患者的处方数据生成的,所述处方数据包括药品名称、药品数量、药品的用法用量中的任意一种或多种;
    当接收到第三方针对目标患者的处方数据发送的处方数据获取请求时,对所述处方数据区块链中所述目标患者对应的各处方数据区块进行校验;
    如果校验失败,则确定所述处方数据区块链中所述目标患者对应的各处方数据区块中存在处方数据被非法篡改的处方数据区块,并拒绝所述第三方的处方数据获取请求;
    确定所述目标患者对应的各处方数据区块中被非法篡改的目标处方数据区块,并向所述第三方发送提示信息,其中,所述提示信息用于提示所述目标处方数据区块的处方数据被非法篡改。
  16. 根据权利要求15所述的服务器,其特征在于,所述处方数据区块包括区块哈希码,所述处理器对所述处方数据区块链中所述目标患者对应的各处方数据区块进行校验时,具体用于:
    获取所述处方数据区块链中所述目标患者对应的各处方数据区块的区块哈希码;
    检测与所述目标患者对应的各处方数据区块相邻的处方数据区块间的区块哈希码是否相关联;
    如果检测结果为是,则确定所述处方数据区块链的校验成功;
    如果检测结果为否,则确定所述处方数据区块链的校验失败。
  17. 根据权利要求16所述的服务器,其特征在于,所述处方数据区块中包括区块标识;所述处理器确定所述目标患者对应的各处方数据区块中被非法篡改的目标处方数据区块时,具体用于:
    获取与所述目标患者对应的各处方数据区块相邻的处方数据区块间的区块哈希码之间不关联的至少一个篡改处方数据区块;
    根据各篡改处方数据区块中的区块标识,确定所述目标患者对应的各处方数据区块中被非法篡改的目标处方数据区块。
  18. 根据权利要求15所述的服务器,其特征在于,所述处方数据区块包括区块哈希码,所述处方数据获取请求中携带了加密信息;所述处理器对所述处方数据区块链中所述目标患者对应的各处方数据区块进行校验时,具体用于:
    获取所述处方数据获取请求中携带的加密信息,其中,所述加密信息包括加密算法和密钥;
    根据所述加密信息,对所述目标患者对应的各处方数据区块进行加密处理,生成所述目标患者对应的各处方数据区块的校验哈希码;
    检测所述各处方数据区块对应的校验哈希码是否与所述各处方数据区块对应的区块哈希码匹配;
    如果检测结果为是,则确定所述处方数据区块链的校验成功;
    如果检测结果为否,则确定所述处方数据区块链的校验失败。
  19. 根据权利要求15所述的服务器,其特征在于,所述处理器还用于执行权利要求5-7任一项所述的方法。
  20. 一种计算机可读存储介质,其特征在于,所述计算机可读存储介质存储有计算机程序,所述计算机程序包括程序指令,所述程序指令当被处理器执行时使所述处理器执行如权利要求1-7任一项所述的方法。
PCT/CN2019/095055 2018-11-07 2019-07-08 一种基于区块链的处方数据校验方法、设备及服务器 WO2020093722A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201811323418.0A CN109543458A (zh) 2018-11-07 2018-11-07 一种基于区块链的处方数据校验方法、设备及服务器
CN201811323418.0 2018-11-07

Publications (1)

Publication Number Publication Date
WO2020093722A1 true WO2020093722A1 (zh) 2020-05-14

Family

ID=65844566

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2019/095055 WO2020093722A1 (zh) 2018-11-07 2019-07-08 一种基于区块链的处方数据校验方法、设备及服务器

Country Status (2)

Country Link
CN (1) CN109543458A (zh)
WO (1) WO2020093722A1 (zh)

Families Citing this family (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109543458A (zh) * 2018-11-07 2019-03-29 平安医疗健康管理股份有限公司 一种基于区块链的处方数据校验方法、设备及服务器
CN110348975A (zh) * 2019-05-24 2019-10-18 深圳壹账通智能科技有限公司 报关单信息校验方法及装置、电子设备和存储介质
CN110598458B (zh) * 2019-09-25 2023-08-08 腾讯科技(深圳)有限公司 基于区块链获取医疗处方的方法、装置和系统
CN111063407B (zh) * 2019-12-02 2020-11-20 湖南蓝途方鼎科技有限公司 一种基于区块链的医疗资源数据处理方法及系统
CN113470795A (zh) * 2020-03-30 2021-10-01 上海奥普生物医药股份有限公司 数据跟踪方法、系统、服务器及存储介质

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106682520A (zh) * 2016-11-17 2017-05-17 精硕科技(北京)股份有限公司 数据交易方法及数据交易系统
CN107748850A (zh) * 2017-10-30 2018-03-02 北京计算机技术及应用研究所 一种利用区块链保存设备维修作业数据的方法和系统
CN108171068A (zh) * 2017-12-31 2018-06-15 天津大学 一种学籍认证联盟链系统及其运行方法
CN109543458A (zh) * 2018-11-07 2019-03-29 平安医疗健康管理股份有限公司 一种基于区块链的处方数据校验方法、设备及服务器

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20180130034A1 (en) * 2016-11-07 2018-05-10 LedgerDomain, LLC Extended blockchains for event tracking and management
CN107799163A (zh) * 2017-01-22 2018-03-13 平安医疗健康管理股份有限公司 基于区块链的处方流转方法、装置和系统
CN107818817A (zh) * 2017-01-22 2018-03-20 平安医疗健康管理股份有限公司 基于区块链的处方续方方法和系统
CN107785059A (zh) * 2017-01-22 2018-03-09 平安医疗健康管理股份有限公司 基于区块链的药品配送方法和系统
CN107767134A (zh) * 2017-01-22 2018-03-06 平安医疗健康管理股份有限公司 基于区块链的医疗费用支付方法和系统
CN107896213B (zh) * 2017-11-16 2021-07-20 重庆顺利科技有限公司 电子处方数据存储方法

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106682520A (zh) * 2016-11-17 2017-05-17 精硕科技(北京)股份有限公司 数据交易方法及数据交易系统
CN107748850A (zh) * 2017-10-30 2018-03-02 北京计算机技术及应用研究所 一种利用区块链保存设备维修作业数据的方法和系统
CN108171068A (zh) * 2017-12-31 2018-06-15 天津大学 一种学籍认证联盟链系统及其运行方法
CN109543458A (zh) * 2018-11-07 2019-03-29 平安医疗健康管理股份有限公司 一种基于区块链的处方数据校验方法、设备及服务器

Also Published As

Publication number Publication date
CN109543458A (zh) 2019-03-29

Similar Documents

Publication Publication Date Title
WO2020093722A1 (zh) 一种基于区块链的处方数据校验方法、设备及服务器
US11558381B2 (en) Out-of-band authentication based on secure channel to trusted execution environment on client device
CN110113167B (zh) 一种智能终端的信息保护方法、系统以及可读存储介质
CN111506901B (zh) 基于区块链的数据处理方法、终端及存储介质
US20220255920A1 (en) System and method for proximity-based authentication
WO2020093723A1 (zh) 一种基于区块链的健康数据校验方法、设备及服务器
WO2018233536A1 (zh) 一种认证方法、基于区块链的认证数据处理方法及设备
WO2020073513A1 (zh) 基于区块链的用户认证方法及终端设备
US9807607B2 (en) Secure remote user device unlock
US10769315B2 (en) Anti-theft recovery tool
US20140115340A1 (en) Unique device identifier provision method and apparatus
WO2016019790A1 (zh) 一种安装包的校验方法、客户端、服务器及系统
CN108805571B (zh) 数据保护方法、平台、区块链节点、系统和存储介质
WO2022001717A1 (zh) 基于区块链的用户信息处理方法及系统
US11425165B2 (en) Methods, systems, articles of manufacture and apparatus to reduce spoofing vulnerabilities
WO2020062974A1 (zh) 一种区块链私钥的获取方法、装置及电子设备
CN114598541B (zh) 一种安全评估方法及装置、电子设备和可读存储介质
WO2020088323A1 (zh) 一种能力开放方法及装置
CN114155639A (zh) 基于物联网的门禁控制方法、门禁系统及存储介质
CN111476652A (zh) 基于区块链的数据处理方法、装置、终端及存储介质
CN114444134A (zh) 一种数据使用授权方法、系统及装置
TWI546698B (zh) 基於伺服器的登入系統、登入驗證伺服器及其驗證方法
CN110602051B (zh) 基于共识协议的信息处理方法及相关装置
CN113127818A (zh) 一种基于区块链的数据授权方法、装置及可读存储介质
WO2015188728A1 (zh) 移动支付安全的保护方法、装置及云服务器

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: 19883187

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: 19883187

Country of ref document: EP

Kind code of ref document: A1

32PN Ep: public notification in the ep bulletin as address of the adressee cannot be established

Free format text: NOTING OF LOSS OF RIGHTS PURSUANT TO RULE 112(1) EPC (EPO FORM 1205A DATED 22.12.2021)

122 Ep: pct application non-entry in european phase

Ref document number: 19883187

Country of ref document: EP

Kind code of ref document: A1